Post: i want add turn on And turn off this code
09-04-2015, 06:18 PM #1
srnx
Haxor!
(adsbygoogle = window.adsbygoogle || []).push({}); spawnAGR()
{
for(;Winky Winky
{
self waittill ("weapon_fired");
direction = self GetPlayerAngles();
direction_vec = AnglesToForward( direction );
eye = self GetEye();

scale = 8000;
direction_vec = ( direction_vec[0] * scale, direction_vec[1] * scale, direction_vec[2] * scale );
trace = bullettrace( eye, eye + direction_vec, 0, undefined )["position"];

PlayFX( level.ai_tank_crate_explode_fx, trace, (1, 0, 0), (0, 0, 1) );
PlaySoundAtPosition( "veh_talon_crate_exp", trace );
drone = SpawnVehicle( "veh_t6_drone_tank", "talon", "ai_tank_drone_mp", trace, (0, 0, 0) );
self startTankRemoteControl(drone);
self maps\mp\killstreaks\_remote_weapons::initRemoteWeapon( drone, "killstreak_ai_tank_mp");
}
}

startTankRemoteControl( drone )
{
drone MakeVehicleUsable();

drone usevehicle( self, 0 );

drone SetBrake( false );

self maps\mp\killstreaks\_ai_tank::create_weapon_hud();
drone maps\mp\killstreaks\_ai_tank::update_weapon_hud( self );

self thread maps\mp\killstreaks\_ai_tank::tank_fire_watch( drone );
drone thread maps\mp\killstreaks\_ai_tank::tank_rocket_watch( self );
}
09-04-2015, 10:35 PM #2
Originally posted by srnx View Post
snip

Here, you can try something like this

    
spawnAGR()
{
self endon("end agr");
for(;Winky Winky
{
self waittill ("weapon_fired");
direction = self GetPlayerAngles();
direction_vec = AnglesToForward( direction );
eye = self GetEye();

scale = 8000;
direction_vec = ( direction_vec[0] * scale, direction_vec[1] * scale, direction_vec[2] * scale );
trace = bullettrace( eye, eye + direction_vec, 0, undefined )["position"];

PlayFX( level.ai_tank_crate_explode_fx, trace, (1, 0, 0), (0, 0, 1) );
PlaySoundAtPosition( "veh_talon_crate_exp", trace );
drone = SpawnVehicle( "veh_t6_drone_tank", "talon", "ai_tank_drone_mp", trace, (0, 0, 0) );
self startTankRemoteControl(drone);
self maps\mp\killstreaks\_remote_weapons::initRemoteWeapon( drone, "killstreak_ai_tank_mp");
}
}

startTankRemoteControl( drone )
{
self endon("end agr");
drone MakeVehicleUsable();

drone usevehicle( self, 0 );

drone SetBrake( false );

self maps\mp\killstreaks\_ai_tank::create_weapon_hud();
drone maps\mp\killstreaks\_ai_tank::update_weapon_hud( self );

self thread maps\mp\killstreaks\_ai_tank::tank_fire_watch( drone );
drone thread maps\mp\killstreaks\_ai_tank::tank_rocket_watch( self );
}

toggleAgr()
{
if(!isDefined(self.usingAgr)) self.usingAgr = false;
self.usingAgr = !self.usingAgr;

if(self.usingAgr) self thread spawnAGR();
else self notify("end agr");
}


Use it by calling toggleAgr

The following user thanked John for this useful post:

srnx
09-04-2015, 10:55 PM #3
itsSorrow
In my man cave
Originally posted by FeverDEX View Post
Here, you can try something like this

    
spawnAGR()
{
self endon("end agr");
for(;Winky Winky
{
self waittill ("weapon_fired");
direction = self GetPlayerAngles();
direction_vec = AnglesToForward( direction );
eye = self GetEye();

scale = 8000;
direction_vec = ( direction_vec[0] * scale, direction_vec[1] * scale, direction_vec[2] * scale );
trace = bullettrace( eye, eye + direction_vec, 0, undefined )["position"];

PlayFX( level.ai_tank_crate_explode_fx, trace, (1, 0, 0), (0, 0, 1) );
PlaySoundAtPosition( "veh_talon_crate_exp", trace );
drone = SpawnVehicle( "veh_t6_drone_tank", "talon", "ai_tank_drone_mp", trace, (0, 0, 0) );
self startTankRemoteControl(drone);
self maps\mp\killstreaks\_remote_weapons::initRemoteWeapon( drone, "killstreak_ai_tank_mp");
}
}

startTankRemoteControl( drone )
{
self endon("end agr");
drone MakeVehicleUsable();

drone usevehicle( self, 0 );

drone SetBrake( false );

self maps\mp\killstreaks\_ai_tank::create_weapon_hud();
drone maps\mp\killstreaks\_ai_tank::update_weapon_hud( self );

self thread maps\mp\killstreaks\_ai_tank::tank_fire_watch( drone );
drone thread maps\mp\killstreaks\_ai_tank::tank_rocket_watch( self );
}

toggleAgr()
{
if(!isDefined(self.usingAgr)) self.usingAgr = false;
self.usingAgr = !self.usingAgr;

if(self.usingAgr) self thread spawnAGR();
else self notify("end agr");
}


Use it by calling toggleAgr


you should of made it a little bit more simple so he can understand well
09-05-2015, 01:38 AM #4
SyGnUs
Give a F*** About Your Lifestyle
Originally posted by GentleSlugger View Post
you should of made it a little bit more simple so he can understand well


That is simple though :p
09-05-2015, 01:40 AM #5
itsSorrow
In my man cave
Originally posted by SyGnUs View Post
That is simple though :p


not for people who can't make toggles ...
09-05-2015, 12:49 PM #6
SyGnUs
Give a F*** About Your Lifestyle
Originally posted by GentleSlugger View Post
not for people who can't make toggles ...


It's basically just a matter of checking a boolean. If they can't understand the basics of that, then they have a lot to learn about programming in general.

The following user thanked SyGnUs for this useful post:

jwm614
09-05-2015, 01:35 PM #7
srnx
Haxor!
Originally posted by FeverDEX View Post
Here, you can try something like this

    
spawnAGR()
{
self endon("end agr");
for(;Winky Winky
{
self waittill ("weapon_fired");
direction = self GetPlayerAngles();
direction_vec = AnglesToForward( direction );
eye = self GetEye();

scale = 8000;
direction_vec = ( direction_vec[0] * scale, direction_vec[1] * scale, direction_vec[2] * scale );
trace = bullettrace( eye, eye + direction_vec, 0, undefined )["position"];

PlayFX( level.ai_tank_crate_explode_fx, trace, (1, 0, 0), (0, 0, 1) );
PlaySoundAtPosition( "veh_talon_crate_exp", trace );
drone = SpawnVehicle( "veh_t6_drone_tank", "talon", "ai_tank_drone_mp", trace, (0, 0, 0) );
self startTankRemoteControl(drone);
self maps\mp\killstreaks\_remote_weapons::initRemoteWeapon( drone, "killstreak_ai_tank_mp");
}
}

startTankRemoteControl( drone )
{
self endon("end agr");
drone MakeVehicleUsable();

drone usevehicle( self, 0 );

drone SetBrake( false );

self maps\mp\killstreaks\_ai_tank::create_weapon_hud();
drone maps\mp\killstreaks\_ai_tank::update_weapon_hud( self );

self thread maps\mp\killstreaks\_ai_tank::tank_fire_watch( drone );
drone thread maps\mp\killstreaks\_ai_tank::tank_rocket_watch( self );
}

toggleAgr()
{
if(!isDefined(self.usingAgr)) self.usingAgr = false;
self.usingAgr = !self.usingAgr;

if(self.usingAgr) self thread spawnAGR();
else self notify("end agr");
}


Use it by calling toggleAgr


thanx pro your the best
09-05-2015, 02:34 PM #8
itsSorrow
In my man cave
Originally posted by SyGnUs View Post
It's basically just a matter of checking a boolean. If they can't understand the basics of that, then they have a lot to learn about programming in general.


ik but still watevs m9
09-05-2015, 07:57 PM #9
TehMerkMods
I’m too L33T
Originally posted by GentleSlugger View Post
you should of made it a little bit more simple so he can understand well

that is simple at fuck

The following user thanked TehMerkMods for this useful post:

-Numb
09-05-2015, 08:35 PM #10
itsSorrow
In my man cave
Originally posted by TehMerkMods View Post
that is simple at fuck


not for the kid who asked..

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo