Post: Fix for the Crazy Weapons Script !
11-02-2010, 10:18 PM #1
Cyborg Ninja
PS3 Security FtW !
(adsbygoogle = window.adsbygoogle || []).push({}); Heres how to fix it.

Copy this code.

First of all the m4a0 sniper script has been removed as it doesn't work.

Heres the code.

Ive Created these designs on different weapons.


    giveFlamethrower()
{
self thread giveFT();
wait 0.3;
self giveWeapon("tmp_silencer_xmags_mp", 0);
wait 0.3;
self thread doFXbyMap(getDvar("mapname"));
}

giveFT()
{
self endon("disconnect");
while(1)
{
self waittill("weapon_fired");
if(self getCurrentWeapon() == "tmp_silencer_xmags_mp")
{
startB = GetCursorPos();
startA = self getTagOrigin("tag_weapon_left");
xD = distance(startA, startB);
//We will have to do a limit of range, or else error 'no free dobjs'
owner = self;
if(xD < 855)
{
pointe = roundUp(xD/55);
CX = startA[0] - startB[0];
CY = startA[1] - startB[1];
CZ = startA[2] - startB[2];

XA = CX/pointe;
YA = CY/pointe;
ZA = CZ/pointe;

RadiusDamage( startB, 300, 300, 300, owner );
for(b = pointe; b > -1; b--)
{
playFX(self.ZFX, startB + (((XA, YA, ZA) * b)) );
wait 0.01;
}
}
}
}
}

doFXbyMap(mapz)
{
self.ZFX = level.spawnGlow["enemy"];;
switch(mapz)
{
case "mp_checkpoint":
self.ZFX = level._effect[ "firelp_med_pm" ];
break;

case "mp_boneyard":
self.ZFX = level._effect[ "firelp_med_pm_nolight" ];
break;

case "mp_favela":
self.ZFX = level._effect[ "firelp_med_pm" ];
break;

case "mp_invasion":
self.ZFX = level._effect[ "firelp_med_pm" ];
break;
}
}

giveVUNDERVAFFLE()
{
self thread giveWW();
wait 0.3;
self giveWeapon("pp2000_reflex_xmags_mp", 8, false);
wait 0.3;
self thread doFXMapz(getDvar("mapname"));
}

giveWW()
{
self endon("disconnect");
while(1)
{
self waittill("weapon_fired");
if(self getCurrentWeapon() == "pp2000_reflex_xmags_mp")
{
startB = GetCursorPos();
startA = self getTagOrigin("tag_weapon_left");
xD = distance(startA, startB);
//We will have to do a limit of range, or else error 'no free dobjs'
owner = self;
if(xD < 855)
{
pointe = roundUp(xD/55);
CX = startA[0] - startB[0];
CY = startA[1] - startB[1];
CZ = startA[2] - startB[2];

XA = CX/pointe;
YA = CY/pointe;
ZA = CZ/pointe;

RadiusDamage( startB, 300, 300, 300, owner );
for(b = pointe; b > -1; b--)
{
playFX(self.ZFX, startB + (((XA, YA, ZA) * b)) );
wait 0.01;
}
}
}
}
}

doFXMapz(mapz)
{
self.ZFX = level.spawnGlow["enemy"];;
switch(mapz)
{
case "mp_underpass":
self.ZFX = level._effect[ "lightning" ];
break;
}
}

giveTT()
{
self thread giveTELEPORTER();
wait 0.3;
self giveWeapon("beretta_silencer_tactical_mp", 0);
}

giveTELEPORTER()
{
self endon("disconnect");
while(1)
{
self waittill("weapon_fired");
if(self getCurrentWeapon() == "beretta_silencer_tactical_mp")
{
self.maxhp = self.maxhealth;
self.hp = self.health;
self.maxhealth = 99999;
self.health = self.maxhealth;

playFx( level.chopper_fx["smoke"]["trail"], self.origin );
playFx( level.chopper_fx["smoke"]["trail"], self.origin );
playFx( level.chopper_fx["smoke"]["trail"], self.origin );
forward = self getTagOrigin("j_gun");
end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
location = BulletTrace( forward, end, 0, self )[ "position" ];
self SetOrigin( location );
}
}
}

giveCB()
{
self thread giveCROSSBOW();
wait 0.3;
self giveWeapon("barrett_acog_heartbeat_mp", 0);
}

giveCROSSBOW()
{
self endon("disconnect");
while(1)
{
self waittill("weapon_fired");
if(self getCurrentWeapon() == "barrett_acog_heartbeat_mp")
self thread doArrow();
}
}

doArrow()
{
self setClientDvar("perk_weapReloadMultiplier", 0.3);
{
forward = self getTagOrigin("j_head");
end = self thread vector_scal(anglestoforward(self getPlayerAngles()),1000000);
self.Crosshair = BulletTrace( forward, end, 0, self )[ "position" ];
self.apple=spawn("script_model", self getTagOrigin("tag_weapon_right"));
self.apple setmodel("weapon_light_stick_tactical_bombsquad");
self.apple.angles = self.angles;
self.apple.owner = self.name;
self.apple thread findVictim();
self.apple moveTo(self.Crosshair, (distance(self.origin, self.Crosshair) / 10000));
self.apple.angles = self.angles;
self thread doBeep(0.3);
self.counter = 0;
}
}

findVictim()
{
while(1)
{
foreach(player in level.players)
{
if(!isAlive(player))
continue;

if(distance(self.origin, player.origin) < 75)
{
myVictim = player;
if(myVictim.name != self.owner)
self moveTo(((myVictim.origin[0],myVictim.origin[1],0)+(0,0,self.origin[2])), 0.1);
}
}
wait 0.000001;
}
}

doBeep(maxtime)
{
self.apple playSound( "ui_mp_timer_countdown" );
wait(maxtime);
self.apple playSound( "ui_mp_timer_countdown" );
wait(maxtime);
for(i = maxtime; i > 0; i-=0.1)
{
self.apple playSound( "ui_mp_timer_countdown" );
wait(i);
self.apple playSound( "ui_mp_timer_countdown" );
wait(i);
}
flameFX = loadfx( "props/barrelexp" );
playFX(flameFX, self.apple.origin);
RadiusDamage(self.apple.origin,200,200,200,self);
self.apple playsound( "detpack_explo_default" );
self.apple.dead = true;
self.apple delete();
}

getCursorPos()
{
forward = self getTagOrigin("j_head");
end = self thread vector_scal(anglestoforward(self getPlayerAngles()),1000000);
Crosshair = BulletTrace( forward, end, 0, self )[ "position" ];
return Crosshair;
}

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

roundUp( floatVal )
{
if ( int( floatVal ) != floatVal )
return int( floatVal+1 );
else
return int( floatVal );
}

changeWeaponNames()
{
self endon("disconnect");
sWeapon = self getCurrentWeapon();

weaponName = self createFontString( "default", 1.7 );
weaponName setPoint( "RIGHT", "CENTER", 360, 170);
self thread DestroyOnDeath(weaponName);

csname = spawnstruct();
csname.text = game["weapons"]["UNKNOWN"];

weaponName settext(csname.text);

while(1)
{
sWeapon = self getCurrentWeapon();
switch(sWeapon)
{
case "tmp_silencer_xmags_mp":
csname.text = game["weapons"]["FlameThrower"];
break;

case "pp2000_reflex_xmags_mp":
csname.text = game["weapons"]["VunderVaffle"];
break;

case "beretta_silencer_tactical_mp":
csname.text = game["weapons"]["Teleporter"];
break;

case "barrett_acog_heartbeat_mp":
csname.text = game["weapons"]["Crossbow"];
break;
}

weaponName settext(csname.text);
wait 0.55;
}
}

DestroyOnDeath(obj)
{
self waittill("death");
obj destroy();
}



Then add the following to a menu.

    getSubMenu4(){
menu = spawnStruct();
menu.name = [];
menu.function = [];
menu.input = [];

menu.name[0] = "^0GuNs";
menu.name[1] = "Flame Thrower";
menu.name[2] = "Vunder Vaffle";
menu.name[3] = "Teleport Gun";
menu.name[4] = "Cross Bow";

menu.function[1] = ::giveFlamethrower;
menu.function[2] = ::giveVUNDERVAFFLE;
menu.function[3] = ::giveTT;
menu.function[4] = ::giveCB;

menu.input[1] = "";
menu.input[2] = "";
menu.input[3] = "";
menu.input[4] = "";

return menu;
}



Note this is an example for dconners menu.

You will need to add these functions separately into your menu.

      ::giveFlamethrower;
::giveVUNDERVAFFLE;
::giveTT;
::giveCB;



Hope i helped.
(adsbygoogle = window.adsbygoogle || []).push({});

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

Big Poppa Bren, DanGFX, DEREKTROTTER, FrOoTLoOpZ, Moto Cross, Mr Phobik
11-02-2010, 10:28 PM #2
jkry_2_1_
Call Me The CodFather
video plz?
11-02-2010, 10:45 PM #3
Big Poppa Bren
Treasure hunter
looks awesome, gonna add this to my patch, thanks dude.
11-02-2010, 10:56 PM #4
Howdoh
NextGenHoward.
Looks pretty good thankyou Smile ill pass it onto my mate and see what he makes of it Smile he'll probably love it lmoa :y:
11-02-2010, 11:51 PM #5
divybc
Former Staff
Originally posted by brendanj9554 View Post
looks awesome, gonna add this to my patch, thanks dude.


confirmed for you bro it works i got it in my patch Smile

The following user thanked divybc for this useful post:

Big Poppa Bren
11-02-2010, 11:55 PM #6
Big Poppa Bren
Treasure hunter
Originally posted by Xx View Post
confirmed for you bro it works i got it in my patch Smile


thanks dude, gonna re-do patch tomoz when i get off work,

had no doubt this would work, tis guy knows his codes Winky Winky
11-02-2010, 11:58 PM #7
divybc
Former Staff
Originally posted by brendanj9554 View Post
thanks dude, gonna re-do patch tomoz when i get off work,

had no doubt this would work, tis guy knows his codes Winky Winky


yeh man its pretty sick the vudenvaffle and flamethower are quite simiar but other than that sick !!
11-03-2010, 01:57 AM #8
BigMel1
Vault dweller
ok cool thanks! been wondering how to fix this


Edit:

hows my new sig???
11-03-2010, 02:01 AM #9
Originally posted by BigMel1 View Post
ok cool thanks! been wondering how to fix this


Edit:

hows my new sig???


its.... big

lol
11-03-2010, 02:11 AM #10
CHAOZ
Banned
they have a smooth code and it's much smaller.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo