[Understanding] bool IsGameReadyForHook

Posts 115 of 37 · Page 1 of 3
[Understanding] bool IsGameReadyForHook
I am having a bit of trouble understanding
Code:
return true;
return false;
Why do you have both?

Code:
bool IsGameReadyForHook()
{
if( GetModuleHandleA( "d3d9.dll"     ) != NULL 
&& GetModuleHandleA( "ClientFX.fxd" ) != NULL 
&& GetModuleHandleA( "CShell.dll"   ) != NULL )
return true;
return false;
}

Quit coding now..
No I wont, only losers like you will quit.
and you probably dont understand it. so stfu.
I will never quit. and im damn sure i'll whoop your ass
Quote Originally Posted by Fabolous View Post
I will never quit. and im damn sure i'll whoop your ass
Stop commenting on this thread if you are not helping.
I am just trying to learn and understand everything before I start.
atleast hes asking and not c+ping shit and releasing.
Quote Originally Posted by wassup40 View Post
atleast hes asking and not c+ping shit and releasing.
I C&P Shit?? really? GTFO. U dont even code. u just release shitty numpad hacks.
Quote Originally Posted by Fabolous View Post


I C&P Shit?? really? GTFO. U dont even code. u just release shitty numpad hacks.
lol you probably dont even know what it means. so gtfo NOW! Only EXPERT CODERS would know and i doubt you are one..
Quote Originally Posted by Shimmy- View Post
lol you probably dont even know what it means. so gtfo NOW! Only EXPERT CODERS would know and i doubt you are one..
whatever. I'm out. Go make a winamp hook lol. Its quite easy. but i bet you cant write from scratch like me.
U have both for a reason. Go GOOGLE. Stop wasting other peoples time on these stupid questons on MPGH. go to MSDN for God sakes. You shouldn't be coding CA if you don't even know the basics of C++.. Hit the books, and come back later.
Wouldn't you need an }else{ in there to make it work?

@unknown
It would only take a few seconds for you to explain and you dont have that time. dont talk shit.
Learn c++ maybe
ok let me explain

Code:
If (The things in here Not = NULL)
      Return True;
else
      return False;
that is what it is saying.

but instead of putting the ELSE

Code:
if (Stuff){
    Return True
}
If the stuff is not right then it will just pass it. and just go to Return False

but if it is stuff is right. then it will Return as True. before it can return false.
*Sigh*

This is basic coding, in any language.

It's just an if statement.. Do you not understand methods? Once it returns something, the method doesn't continue after that point.

Also this code should be formatted like this, not all even and shit:
Code:
bool IsGameReadyForHook()
{
     if( GetModuleHandleA( "d3d9.dll"     ) != NULL 
     && GetModuleHandleA( "ClientFX.fxd" ) != NULL 
     && GetModuleHandleA( "CShell.dll"   ) != NULL )
          return true;

     return false;
}
So for the if statement it's just checking to see if all 3 of them are loaded and when all of them are, it returns true. In all other cases, it returns false. You don't need brackets because it is only one line of code inside the if statement, and you don't need an else because it is a method like i said before. I hope you understand basic C++ now >.>
from all the flaming.

What this does is that it creates a Boolean called IsGameReadyForHook. It then checks to see if the combat arms .dll's have loaded. It is returned as false until all the dlls have loaded making it true. This Boolean is later used to create your threads after it see's the combat arms dlls have loaded.

Edit: Ah LightzOut got it before me!
Posts 115 of 37 · Page 1 of 3
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Need help?