Post: [Script] Raining Fire
09-20-2013, 05:24 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Hi NGU!

I'm releasing my Raining Fire script.
All you need to do is point at your target and shoot. Then your enemy will be bombarded with a raining fire of death!



Put this in your init()
    level.flamez_trail=LoadFX("weapon/molotov/fx_molotov_burn_trail");
level.boom=loadfx("explosions/default_explosion");
level.GoldCircle=loadFX("misc/ui_flagbase_gold");


    RainingFire()
{
if(self.fire==true)
{
self iPrintln("^3Raining Fire ^1[OFF]");
self notify("firex");
self.fire=false;
}
else
{
self notify("firex");
self iPrintln("^3Raining Fire ^2[ON]");
self thread doRainingFire();
self.fire=true;
}
}
doRainingFire()
{
self endon("disconnect");
self endon("death");
self endon("firex");
for(;Winky Winky
{
self waittill("weapon_fired");
target=gcp();
x=markfx(target,level.GoldCircle);
self thread RainFire(target,x);
wait .3;
}
}
RainFire(target,x)
{
location=target+(0,800,2500);
Flamez=spawn("script_model",location);
Flamez playsound("mp_ingame_summary");
Flamez setModel("aircraft_bomb");
Flamez.angles=Flamez.angles+(90,90,90);
ground=target;
target=VectorToAngles(ground-Flamez.origin);
Flamez rotateto(target,0.01);
Flamez thread fxme();
time=cal(1900,Flamez.origin,ground);
Flamez moveto(ground,time);
wait time;
Flamez playsound("grenade_explode_default");
Playfx(level.boom,Flamez.origin+(0,0,1));
RadiusDamage(Flamez.origin,450,700,350,self,"MOD_PROJECTILE_SPLASH","artillery_mp");
Flamez notify("stopfx");
Flamez delete();
x delete();
}
markfx(groundpoint,fx)
{
effect=spawnFx(fx,groundpoint,(0,0,1),(1,0,0));
triggerFx(effect);
return effect;
}
gcp()
{
return BulletTrace(self getTagOrigin("tag_weapon_right"),maps\mp\_utility::vector_scale(anglestoforward(self getPlayerAngles()),1000000),false,self)["position"];
}
cal(speed,origin,moveTo)
{
return (distance(origin,moveTo)/speed);
}
fxme()
{
self endon("stopfx");
self endon("disconnect");
for(;Winky Winky
{
Playfx(level.flamez_trail,self.origin);
wait .001;
}
}


Big thanks to x_DaftVader_x and Source Code for allowing me to borrow some of there scripts!
This is my first time posting something in the WAW section so I hope you enjoy this release!Happy
Last edited by codybenti ; 09-20-2013 at 07:00 PM.

The following 9 users say thank you to codybenti for this useful post:

▶DaOriginal209◀, Canuck_Modz, Devastation, DJvip2011, Beats, Kush Friendly, Shock_Mods, sirsmokealotENG, Sweet_Cheeba
09-20-2013, 07:46 PM #2
Kush Friendly
League Champion
Originally posted by codybenti View Post
Hi NGU!

I'm releasing my Raining Fire script.
All you need to do is point at your target and shoot. Then your enemy will be bombarded with a raining fire of death!



Put this in your init()
    level.flamez_trail=LoadFX("weapon/molotov/fx_molotov_burn_trail");
level.boom=loadfx("explosions/default_explosion");
level.GoldCircle=loadFX("misc/ui_flagbase_gold");


    RainingFire()
{
if(self.fire==true)
{
self iPrintln("^3Raining Fire ^1[OFF]");
self notify("firex");
self.fire=false;
}
else
{
self notify("firex");
self iPrintln("^3Raining Fire ^2[ON]");
self thread doRainingFire();
self.fire=true;
}
}
doRainingFire()
{
self endon("disconnect");
self endon("death");
self endon("firex");
for(;Winky Winky
{
self waittill("weapon_fired");
target=gcp();
x=markfx(target,level.GoldCircle);
self thread RainFire(target,x);
wait .3;
}
}
RainFire(target,x)
{
location=target+(0,800,2500);
Flamez=spawn("script_model",location);
Flamez playsound("mp_ingame_summary");
Flamez setModel("aircraft_bomb");
Flamez.angles=Flamez.angles+(90,90,90);
ground=target;
target=VectorToAngles(ground-Flamez.origin);
Flamez rotateto(target,0.01);
Flamez thread fxme();
time=cal(1900,Flamez.origin,ground);
Flamez moveto(ground,time);
wait time;
Flamez playsound("grenade_explode_default");
Playfx(level.boom,Flamez.origin+(0,0,1));
RadiusDamage(Flamez.origin,450,700,350,self,"MOD_PROJECTILE_SPLASH","artillery_mp");
Flamez notify("stopfx");
Flamez delete();
x delete();
}
markfx(groundpoint,fx)
{
effect=spawnFx(fx,groundpoint,(0,0,1),(1,0,0));
triggerFx(effect);
return effect;
}
gcp()
{
return BulletTrace(self getTagOrigin("tag_weapon_right"),maps\mp\_utility::vector_scale(anglestoforward(self getPlayerAngles()),1000000),false,self)["position"];
}
cal(speed,origin,moveTo)
{
return (distance(origin,moveTo)/speed);
}
fxme()
{
self endon("stopfx");
self endon("disconnect");
for(;Winky Winky
{
Playfx(level.flamez_trail,self.origin);
wait .001;
}
}


Big thanks to x_DaftVader_x and Source Code for allowing me to borrow some of there scripts!
This is my first time posting something in the WAW section so I hope you enjoy this release!Happy


Its not like I was thinking it would be but its still nice. Good job.

The following user thanked Kush Friendly for this useful post:

codybenti

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo