What's new

Solved Cod 4 R2R Help

XeX Launchpad

XeX Launchpad

Official Hoster
Messages
77
Reaction score
32
Points
80
Sin$
7
Hi guys I need help with button codes I want a button to be pressed to start the infection for yourself any ideas??
 
I tried if( self MeleeButtonPressed()) but I have a thread I want to connect it to any it still just infects on spawn
 
ImOx

ImOx

(^._.^)ノ
Retired
Programmer MotM Platinum Record
Messages
9,961
Reaction score
2,963
Points
2,180
Sin$
0
If you're using an if statement, you need to be constantly running the check (use an infinite loop), otherwise the check for WhateverButtonPressed() is just ran once.
Code:
for(;;)
{
if(self MeleeButtonPressed())
//stuff here

wait .05; //always add at least a tiny bit of wait to your infinite loops
}
 
Upvote 0
ApolloMods v5

ApolloMods v5

Enthusiast
Messages
217
Reaction score
34
Points
65
Sin$
0
No idea what you're trying to say.
I think he meant he wants to link it to a thread of his own on the forums, but he can't find the correct code for whatever bind he wants the infection to be started with....

I could be wrong.
 
Upvote 0
XeX Launchpad

XeX Launchpad

Official Hoster
Messages
77
Reaction score
32
Points
80
Sin$
7
Like self thread something();
 
The infection is on the thread I want to make it so I press a certain button and it starts
 
Upvote 0
Top Bottom
Login
Register