Post: [SCRIPT] Demolition Man | FutureOps | More To Come!
06-25-2013, 08:49 PM #1
FutureOps
Little One
(adsbygoogle = window.adsbygoogle || []).push({}); Demolition Man[/B]

A script I came up with, you spawn a bomb, arm it, put it wherever your little heart desires and it counts down from 10 causing a massive explosion killing anybody around it. Hope you guys enjoy! Much more mods to come!

Wait for new video to upload YT acting up



Precache This:
    
precachemodel("prop_suitcase_bomb");


    
doDemoMan()
{
self endon("death");
//self thread ExitMenu(); Put exit thread here
Top = self.origin + ( 0, 0, 19 );
Bottom = self.origin;
ShowPickup = spawn( "script_model", self.origin + (-50,-115,32));
ShowPickup setModel( "prop_suitcase_bomb" );
self endon("explosive_finished");
for(;Winky Winky
{
ShowPickup moveTo( Top, 0.5, 0.15, 0.15 );
ShowPickup rotateYaw( 180, 0.5 );
wait .5;
ShowPickup moveTo( Bottom, 0.5, 0.15, 0.15 );
ShowPickup rotateYaw( 180, 0.5 );
wait .5;
clearLowerMessage(1);
if(distance(self.origin, ShowPickup.origin)<75)
{
setLowerMessage("^3Hold F To Pickup Explosives");
if(self UseButtonPressed())
{
clearLowerMessage(1);
iPrintlnBold("Explosives Have Been Picked Up!");
ShowPickup delete();
self takeAllWeapons();
wait 2;
self freezeControls(true);
GetBomb = "briefcase_bomb_mp";
self giveWeapon(GetBomb,0,false);
self switchToWeapon(GetBomb);
wait 3.5;
wduration = 4.0;
Bmb = createPrimaryProgressBar( -40 );
BmbText = createPrimaryProgressBarText( -40 );
BmbText setText( "Arming Explosives Please Wait..." );
BmbText.glowalpha = 1;
BmbText.glowcolor = (0, 1, 0);
Bmb updateBar( 0, 1 / wduration );
Bmb.color = (0, 0, 0);
Bmb.bar.color = (0, 1, 0);
for ( waitedTime = 0;waitedTime < wduration && isAlive( self ) && !level.gameEnded;
waitedTime += 0.05 )wait ( 0.05 );
Bmb destroyElem();
BmbText destroyElem();
self takeAllWeapons();
self freezeControls(false);
self thread beginPlant();
self notify("explosive_finished");
}
}
wait 0.01;
}
}

beginPlant()
{
self endon("death");
self iprintlnbold ("^3Press [{+melee}] To Plant Bomb");
self endon("debomb");
for(;Winky Winky
{
if(self meleeButtonPressed())
{
self thread dropItLikeItsHot();
wait 0.01;
self notify("debomb");
wait .001;
}
wait .01;
}
}

dropItLikeItsHot()
{
self endon("do_exp");
self sayall("^2Has Planted Explosives");
dropPickup = spawn( "script_model", (self.origin));
dropPickup setModel( "prop_suitcase_bomb" );
self thread doTimer();
wait 10;
if((distance(dropPickup.origin) <1500))
{
Earthquake( 0.4, 4, dropPickup.origin, 1000 );
playFX(level.chopper_fx["explode"]["medium"], dropPickup.origin);
dropPickup playSound( level.heli_sound[self.team]["crash"] );
RadiusDamage( dropPickup.origin, 1000, 1000, 1000, self );
}
}

doTimer(){for(t=10;t>=0;t--){iPrintlnBold("^1" + t);self playsound("mouse_over");wait 1;}}
(adsbygoogle = window.adsbygoogle || []).push({});

The following 5 users say thank you to FutureOps for this useful post:

codybenti, ResistTheJamsha, Silent Assassin, xNBKxALLxDAYx
06-30-2013, 02:51 AM #11
FutureOps
Little One
Originally posted by JxckMods View Post
Glad to Se you back this is Such a Fun Code Smile Good Work Hope to see more <3


Thanks and yes there is much more to come!
07-01-2013, 11:02 PM #12
"if((distance(dropPickup.origin) <1500))"

^^ That isn't doing anything with only one point of origin..
07-01-2013, 11:04 PM #13
Originally posted by FutureOps View Post
^^
^^ Quote fail ^^
07-02-2013, 03:31 AM #14
FutureOps
Little One
Originally posted by x View Post
"if((distance(dropPickup.origin) <1500))"

^^ That isn't doing anything with only one point of origin..


Yes it does lol I have tested it multiple times. Its the distance around the dropped bomb, when I leave that radius I don't die so it works how I wanted it to :P
07-02-2013, 05:06 PM #15
No, the distance function is the distance between two points. So it would be something like

if((distance(dropPickup.origin, self.origin) <1500))
{
//Then blow that shit up
}

The radius of the blast is set in here

RadiusDamage( dropPickup.origin, 1000, 1000, 1000, self );

That is; Radius damage(origin, min damage, max damage, RADIUS, iattacker)

So your damage radius is actually 1000 not 1500.
For all I know the distance function may default to self.origin if you do not put in the second variable but that is how it works.

Nice script idea btw. Was just trying to help. lol. :p

The following user thanked x_DaftVader_x for this useful post:

FutureOps
07-02-2013, 05:08 PM #16
Originally posted by FutureOps View Post
:P


And wtf is up with the quote button not working, did they break something again Happy
07-02-2013, 09:38 PM #17
Originally posted by x View Post
And wtf is up with the quote button not working, did they break something again Happy


The entire forums a mess.D= They got rid of all the good quality stickies too.:argh: Good luck finding anything now.
I hear this guy is running NGU now.:vince:
07-03-2013, 01:53 AM #18
FutureOps
Little One
Originally posted by x View Post
No, the distance function is the distance between two points. So it would be something like

if((distance(dropPickup.origin, self.origin) <1500))
{
//Then blow that shit up
}

The radius of the blast is set in here

RadiusDamage( dropPickup.origin, 1000, 1000, 1000, self );

That is; Radius damage(origin, min damage, max damage, RADIUS, iattacker)

So your damage radius is actually 1000 not 1500.
For all I know the distance function may default to self.origin if you do not put in the second variable but that is how it works.

Nice script idea btw. Was just trying to help. lol. :p


I wasn't trying to come off rude as I have much respect for you. The way it was scripted it works how it should that's the only reason it is how it is. Im going to tweak the script a little bit, and I really do appreciate the help Smile gonna update script

The following user thanked FutureOps for this useful post:

x_DaftVader_x
07-03-2013, 06:27 AM #19
FutureOps
Little One
Originally posted by codybenti View Post
The entire forums a mess.D= They got rid of all the good quality stickies too.:argh: Good luck finding anything now.
I hear this guy is running NGU now.:vince:


Yes they are a total mess. Facepalm

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo