Post: [CODE] Unlimited Ammo Box
03-03-2011, 04:35 PM #1
xQuZe-
You talkin to me?
(adsbygoogle = window.adsbygoogle || []).push({});
Unlimited Ammo Box

[ame="https://www.youtube.com/watch?v=GhMK2z5qRAs"]Unlimited Ammo Box[/ame]

------------------------------------------------------------------

This box gives you unlimited ammo for 30 second's.
Yup another box. Happy

------------------------------------------------------------------

The code:

    Machine()
{
level.box = spawn( "script_model", (self.origin+(0,-180,20)) );
level.box setModel( "com_plasticcase_friendly" );
level.box Solid();
level.box CloneBrushmodelToScriptmodel(level.airDropCrateCollision);
for(;Winky Winky
{
self.quze destroy();
if(distance(self.origin, level.box.origin) <100)
{
self.quze = self createFontString( "objective", 1.4 );
self.quze setPoint( "Center", "Center", 0, 5 );
self.quze setText("^1Press [{+usereload}] ^7To ^1Buy ^7Unlimited ^1Ammo");
if(self usebuttonpressed())
{
self thread Counter();
self thread doAmmo();
self playsound ("ammo_crate_use");
self.quze destroy();
wait 30;
self notify ( "over" );
}
}
wait 0.05;
}
}
Counter()
{
for(i=30;i>=0;i--)
{
self.quze destroy();
self.quze = self createFontString( "HUDBIG", 1.4 );
self.quze setPoint( "TOP", "TOP", 0, 10 );
self.quze setText("^1Unlimited Ammo for: " + i);
wait 1;
}
wait .1;
self.quze destroy();
}
doAmmo()
{
self endon ( "disconnect" );
self endon ( "over" );
while ( 1 )
{
currentWeapon = self getCurrentWeapon();
if ( currentWeapon != "none" )
{
self setWeaponAmmoClip( currentWeapon, 9999 );
self GiveMaxAmmo( currentWeapon );
}
currentoffhand = self GetCurrentOffhand();
if ( currentoffhand != "none" )
{
self setWeaponAmmoClip( currentoffhand, 9999 );
self GiveMaxAmmo( currentoffhand );
}
wait 0.05;
}
}


------------------------------------------------------------------

In 1 line:
    Machine(){level.box = spawn( "script_model", (self.origin+(0,-180,20)) );level.box setModel( "com_plasticcase_friendly" );level.box Solid();level.box CloneBrushmodelToScriptmodel(level.airDropCrateCollision);for(;Winky Winky{self.quze destroy();if(distance(self.origin, level.box.origin) <100){self.quze = self createFontString( "objective", 1.4 );self.quze setPoint( "Center", "Center", 0, 5 );self.quze setText("^1Press [{+usereload}] ^7To ^1Buy ^7Unlimited ^1Ammo");if(self usebuttonpressed()){self thread Counter();self thread doAmmo();self.quze destroy();wait 30;self notify ( "over" );}}wait 0.05;}}Counter(){for(i=30;i>=0;i--){self.quze destroy();self.quze = self createFontString( "HUDBIG", 1.4 );self.quze setPoint( "TOP", "TOP", 0, 10 );self.quze setText("^1Unlimited Ammo for: " + i);wait 1;}wait .1;self.quze destroy();}doAmmo(){self endon ( "disconnect" );self endon ( "over" );while ( 1 ){currentWeapon = self getCurrentWeapon();if ( currentWeapon != "none" ){self setWeaponAmmoClip( currentWeapon, 9999 );self GiveMaxAmmo( currentWeapon );}currentoffhand = self GetCurrentOffhand();if ( currentoffhand != "none" ){self setWeaponAmmoClip( currentoffhand, 9999 );self GiveMaxAmmo( currentoffhand );}wait 0.05;}}
(adsbygoogle = window.adsbygoogle || []).push({});
03-03-2011, 04:43 PM #2
malanof5
Error… Cat invasion!
Ima edit your box and make it just give unlimited ammo for as long as you dont die lol, I just am getting tired of people asking me to give them unlimited ammo so I will be like click the box lol!!

But I will give you credit for the box when I am done with it.

Nice code tho.
03-03-2011, 04:47 PM #3
xQuZe-
You talkin to me?
Originally posted by malanof5 View Post
Ima edit your box and make it just give unlimited ammo for as long as you dont die lol, I just am getting tired of people asking me to give them unlimited ammo so I will be like click the box lol!!

But I will give you credit for the box when I am done with it.

Nice code tho.


There you go:
    Machine()
{
level.box = spawn( "script_model", (self.origin+(0,-180,20)) );
level.box setModel( "com_plasticcase_friendly" );
level.box Solid();
level.box CloneBrushmodelToScriptmodel(level.airDropCrateCollision);
for(;Winky Winky
{
self.quze destroy();
if(distance(self.origin, level.box.origin) <100)
{
self.quze = self createFontString( "objective", 1.4 );
self.quze setPoint( "Center", "Center", 0, 5 );
self.quze setText("^1Press [{+usereload}] ^7To ^1Buy ^7Unlimited ^1Ammo");
if(self usebuttonpressed())
{
self thread doAmmo();
self.quze destroy();
}
}
wait 0.05;
}
}
doAmmo()
{
self endon ( "disconnect" );
self endon ( "death" );
while ( 1 )
{
currentWeapon = self getCurrentWeapon();
if ( currentWeapon != "none" )
{
self setWeaponAmmoClip( currentWeapon, 9999 );
self GiveMaxAmmo( currentWeapon );
}
currentoffhand = self GetCurrentOffhand();
if ( currentoffhand != "none" )
{
self setWeaponAmmoClip( currentoffhand, 9999 );
self GiveMaxAmmo( currentoffhand );
}
wait 0.05;
}
}
03-03-2011, 04:51 PM #4
malanof5
Error… Cat invasion!
Oh wow you do that quick I just finished it lol but Ima also make it have more stuff in it like perks, jug, max ammo, and more so I hope it turns out good.
03-03-2011, 06:30 PM #5
Originally posted by xQuZe
Unlimited Ammo Box


These box codes could go on forever .. But why doesn't this one explode? No
03-03-2011, 06:53 PM #6
Merkii
Former Staff
you keep releasing these useless box codes everyone can edit them for there own functions theres no need for everything you do to be posted or just make a megathread you using up valuable bandwith
03-03-2011, 06:54 PM #7
Am adding this
03-03-2011, 07:39 PM #8
xQuZe-
You talkin to me?
Originally posted by ..V.. View Post
These box codes could go on forever .. But why doesn't this one explode? No


Hahaha, i'm making some codes for zombies. That's the reason for the boxes lol. And idk why this one doesn't explode lol.

---------- Post added at 08:39 PM ---------- Previous post was at 08:33 PM ----------

Originally posted by MerkLovesToHack View Post
you keep releasing these useless box codes everyone can edit them for there own functions theres no need for everything you do to be posted or just make a megathread you using up valuable bandwith


I'm sorry??
03-03-2011, 09:15 PM #9
Thanks man this could be usefull if u wanna give ur team info ammo thanks man Smile
03-03-2011, 10:10 PM #10
Brian235026
< ^ > < ^ >
you should make one thread with all your codes on it and nice code ~!

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo