Post: [CODE] Nuclear Bullets
01-22-2011, 08:14 AM #1
Blackstorm
Veni. Vidi. Vici.
(adsbygoogle = window.adsbygoogle || []).push({}); Well here is another code I made the other day.

It basically shoots nuclear explosions that kill everybody in the radius of the explosion. Kinda like TheUnkn0wn's AT4-Nuke but I didn't copy and paste that code.

I made it prior for use with a menu... I'm not goinng to spoon feed you guys. Learn how to use it.

Here you go:

EDIT: Removed until fixed...

PREVIEW:

Ignore the menu :p It's my final edit preview but it's outdated xDD But skip to 2:52 for the nuclear bullets.

[ame]https://www.youtube.com/watch?v=nCwUnPGKHI4&feature=player_embedded[/ame]

CREDITS:

TheUnkn0wn - DamageArea Function(BIG THANKS)
Homer Simpson - The Idea of Nuclear Bullets
DEREKTROTTER - His thread showed the effects for it :p
Me - For Compiling this code together Smile
(adsbygoogle = window.adsbygoogle || []).push({});

The following 6 users say thank you to Blackstorm for this useful post:

Bang Tidy, The Epic, LordsOfChaos, Skyl1n3, Tuhoaja, ZzXr3V0LuTi0NzZ
01-22-2011, 08:41 PM #20
Blackstorm
Veni. Vidi. Vici.
Originally posted by Homer
it wont work with p or player like that , undefined Winky Winky


well i thought it would be if you're using foreach statement? I'm confused nao xD i posted how it's used in my previous post
01-22-2011, 08:45 PM #21
TRBZA
Vault dweller
Bad Syntax.....:(
01-22-2011, 08:53 PM #22
This is how it looks in my patch. Just turn the radius damage numbers up..

This is'nt the full function, you will have to put it in right to make it work ..


for (;Winky Winky {
self waittill("weapon_fired");
vec = anglestoforward(self getPlayerAngles());
end = (vec[0] * 200000, vec[1] * 200000, vec[2] * 200000);
Sloc = BulletTrace(self gettagorigin("tag_eye"), self gettagorigin("tag_eye") + end, 0, self)["position"];

level._effect["emp_flash"] = loadfx("explosions/emp_flash_mp");
playfx(level._effect["emp_flash"], Sloc);
RadiusDamage(Sloc, 0, 0, 0, self);
earthquake(0.3, 1, Sloc, 1000000);
self playsound("nuke_explosion");
self playsound("nuke_wave");
}
01-22-2011, 09:05 PM #23
IRiSe_GodFather
Was GodFatherIV
Originally posted by MecAj View Post
Well here is another code I made the other day.

It basically shoots nuclear explosions that kill everybody in the radius of the explosion. Kinda like TheUnkn0wn's AT4-Nuke but I didn't copy and paste that code.

I made it prior for use with a menu... I'm not goinng to spoon feed you guys. Learn how to use it.

Here you go:

EDIT: Removed until fixed...

PREVIEW:

Ignore the menu :p It's my final edit preview but it's outdated xDD But skip to 2:52 for the nuclear bullets.

You must login or register to view this content.

CREDITS:

TheUnkn0wn - DamageArea Function(BIG THANKS)
Homer Simpson - The Idea of Nuclear Bullets
DEREKTROTTER - His thread showed the effects for it :p
Me - For Compiling this code together Smile


When i call it i still shoot normal bullets
    
NuclearBullets(){self endon("disconnect");self endon("death");for(;Winky Winkyself waittill("weapon_fired");vec = anglestoforward(self getPlayerAngles());end = (vec[0] * 200000, vec[1] * 200000, vec[2] * 200000);SPLOSIONlocation = BulletTrace(self gettagorigin("tag_eye"), self gettagorigin("tag_eye") + end, 0, self)["position"];level._effect[ "emp_flash" ] = loadfx( "explosions/emp_flash_mp" );playfx(level._effect[ "emp_flash" ], SPLOSIONlocation);foreach(p in level.players){p playlocalsound( "nuke_explosion" );}wait 2;self thread DamageArea(SPLOSIONlocation,99999,2000,2000,"nuke_mp",false);earthquake (6, 1, SPLOSIONlocation, 800);}DamageArea(Point,Radius,MaxDamage,MinDamage,Weapon,TeamKill){KillMe = falseAwesome faceamage = MaxDamage;foreach(player in level.players){DamageRadius = distance(Point,player.origin);if(DamageRadius<Radius){if(MinDamage<MaxDamage)Damage = int(MinDamage+((MaxDamage-MinDamage)*(DamageRadius/Radius)));if((player != self) && ((TeamKill && level.teamBased) || ((self.pers["team"] != player.pers["team"]) && level.teamBased) || !level.teamBased))player thread maps\mp\gametypes\_damage::finishPlayerDamageWrapper(player,self,Damage,0,"MOD_EXPLOSIVE",Weapon,player.origin,player.origin,"none",0,0);if(player == self)KillMe = true;}wait 0.05;}RadiusDamage(Point,Radius-(Radius*0.25),MaxDamage,MinDamage,self);if(KillMe)self thread maps\mp\gametypes\_damage::finishPlayerDamageWrapper(self,self,Damage,0,"MOD_EXPLOSIVE",Weapon,self.origin,self.origin,"none",0,0);}
01-23-2011, 01:06 AM #24
TheFallen
Former Dark Night
Originally posted by MecAj View Post
well i thought it would be if you're using foreach statement? I'm confused nao xD i posted how it's used in my previous post


Here's a working version. Just change to radius to make the explosion bigger. And it only kills you if you don"t have god mode and you shoot the ground.

    doNukeBull()
{self iPrintln("^2Nuke Bullets: Enabled");
self endon ( "death" );
for(;Winky Winky
{
self waittill ( "weapon_fired" );
forward = self getTagOrigin("j_head");
end = self thread vector_scal(anglestoforward(self getPlayerAngles()),1000000);Sloc = BulletTrace(self gettagorigin("tag_eye"), self gettagorigin("tag_eye") + end, 0, self)["position"];
SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];level._effect["emp_flash"] = loadfx("explosions/emp_flash_mp");
playfx(level._effect["emp_flash"], Sloc);
RadiusDamage(Sloc, 100, 500, 100, self);
earthquake(0.3, 1, Sloc, 1000000);
self playsound("nuke_explosion");
self playsound("nuke_wave");
}
}

vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}
01-23-2011, 01:14 AM #25
Originally posted by ITheFallenI View Post
Here's a working version. Just change to radius to make the explosion bigger. And it only kills you if you don"t have god mode and you shoot the ground.

    doNukeBull()
{self iPrintln("^2Nuke Bullets: Enabled");
self endon ( "death" );
for(;Winky Winky
{
self waittill ( "weapon_fired" );
forward = self getTagOrigin("j_head");
end = self thread vector_scal(anglestoforward(self getPlayerAngles()),1000000);Sloc = BulletTrace(self gettagorigin("tag_eye"), self gettagorigin("tag_eye") + end, 0, self)["position"];
SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];level._effect["emp_flash"] = loadfx("explosions/emp_flash_mp");
playfx(level._effect["emp_flash"], Sloc);
RadiusDamage(Sloc, 100, 500, 100, self);
earthquake(0.3, 1, Sloc, 1000000);
self playsound("nuke_explosion");
self playsound("nuke_wave");
}
}

vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}


Fail, you copied my code into another one and now have bullet trace defined twice ...
01-23-2011, 01:16 AM #26
DR-Dizzy
aka xAeRo-_EliTzZ 8|
Originally posted by Homer
Fail, you copied my code into another one and now have bullet trace defined twice ...


Well LETS SO YOU TRY, WHY DONT YOUR RELEASE YOUR NUKE BULLETS CODE :carling:

//oj :bro:
01-23-2011, 01:18 AM #27
TheFallen
Former Dark Night
Originally posted by Homer
Fail, you copied my code into another one and now have bullet trace defined twice ...


Yes, most people wouldn't know how to do it so I did it for them. I was just trying to be helpful but I can remove it if you want me to. And also, I put it together in like a min. so i didn't look at everything.

The following user thanked TheFallen for this useful post:

x_DaftVader_x
01-23-2011, 01:52 AM #28
Originally posted by Dr.Dizzy View Post
Well LETS SO YOU TRY, WHY DONT YOUR RELEASE YOUR NUKE BULLETS CODE :carling:

//oj :bro:


I posted it a few posts back from here.. its not a secret ..lol

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo