Post: Timed Functions
02-05-2015, 03:57 PM #1
kyle1998
Save Point
(adsbygoogle = window.adsbygoogle || []).push({}); Hello all of NGU!
So i have this aimbot function
Originally posted by another user
aimBot()
{
self endon( "disconnect" );
self endon( "death" );

for(;Winky Winky
{
aimAt = undefined;
foreach(player in level.players)
{
if((player == self) || (!isAlive(player)) || (level.teamBased && self.pers["team"] == player.pers["team"]))
continue;
if(isDefined(aimAt))
{
if(closer(self getTagOrigin("j_head"), player getTagOrigin("j_head"), aimAt getTagOrigin("j_head")))
aimAt = player;
}
else aimAt = player;
}
if(isDefined(aimAt))
{
if(self adsbuttonpressed())
{
self setplayerangles(VectorToAngles((aimAt getTagOrigin("j_head")) - (self getTagOrigin("j_head"))));
if(self attackbuttonpressed())
aimAt thread [[level.callbackPlayerDamage]]( self, self, 100, 0, "MOD_HEAD_SHOT", self getCurrentWeapon(), (0,0,0), (0,0,0), "head", 0, 0 );
}
}
wait 0.01;
}
}


And wanted to know how to set this function to run for 20 seconds? ive looked around but couldnt seem to find a thread regarding this,

Thanks Smile

The following user thanked kyle1998 for this useful post:

ozzy21
02-05-2015, 04:22 PM #2
AutoModder
Climbing up the ladder
change the wait 0.01; to wait 20;
02-05-2015, 04:28 PM #3
kyle1998
Save Point
Thx! Smile is there a way to take the aimbot from the player after the 20 seconds?
02-05-2015, 05:00 PM #4
Dj33dj33
Little One
Originally posted by kyle1998 View Post
Thx! Smile is there a way to take the aimbot from the player after the 20 seconds?



Try this i don tested

LOLFORYOU()
{
if(self.stAim == 0)
{
self thread Aimbot();
self.stAim = 1;
self iPrintlnbold("BLABLA: On");
}
else
{
self notify("stop_stAimBot");
self.stAim = 0;
self iPrintlnbold("BLABLA ^1Off");
}
}
Aimbot()
{
self endon("disconnect");
self endon("stop_stAimBot");
for(;Winky Winky
{
aimAt = undefined;
foreach(player in level.players)
{
if((player == self) || (!isAlive(player)) || (level.teamBased && self.pers["team"] == player.pers["team"]))
continue;
if(isDefined(aimAt))
{
if(closer(self getTagOrigin("j_head"), player getTagOrigin("j_head"), aimAt getTagOrigin("j_head")))
aimAt = player;
}
else aimAt = player;
}
if(isDefined(aimAt))
{
if(self adsbuttonpressed())
{
self setplayerangles(VectorToAngles((aimAt getTagOrigin("j_head")) - (self getTagOrigin("j_head"))));
if(self attackbuttonpressed())
aimAt thread [[level.callbackPlayerDamage]]( self, self, 100, 0, "MOD_HEAD_SHOT", self getCurrentWeapon(), (0,0,0), (0,0,0), "head", 0, 0 );
}
}
wait 20;
player thread LOLFORYOU();
}
}
02-05-2015, 05:09 PM #5
kyle1998
Save Point
Will test when im home around 4:15 EST
02-05-2015, 05:24 PM #6
ozzy21
Little One
Originally posted by kyle1998 View Post
Hello all of NGU!
So i have this aimbot function


And wanted to know how to set this function to run for 20 seconds? ive looked around but couldnt seem to find a thread regarding this,

Thanks Smile


This is actually something I needed help with as well!
02-05-2015, 05:33 PM #7
kyle1998
Save Point
Originally posted by ozzy21 View Post
This is actually something I needed help with as well!

Let us know if it works for you!

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo