What's new

Solved mw2 zombies killstreak menu

  • Thread starter migitman213
  • Start date
  • Views 563
Status
Not open for further replies.
M

migitman213

Enthusiast
Messages
77
Reaction score
5
hey guys question for you would this work to add to zombies for a killstreak menu choclate said it would but he said to post here

Code:
        level.topLevelMenuNames[0] = "KillStreaks";
level.subMenuNumOptions[0] = 6;
level.subMenuNames[0] = [];
level.subMenuNames[0][0] = "uav - 1000";
level.subMenuNames[0][1] = "care package - 2500";
level.subMenuNames[0][2] = "sentry - 3250";
level.subMenuNames[0][3] = "pavelow - 6250";
level.subMenuNames[0][4] = "emp - 9000";
level.subMenuNames[0][5] = "nuke - 12000";


level.subMenuFunctions[0] = [];
level.subMenuFunctions[0][0] = :: buykillstreak;
level.subMenuFunctions[0][1] = :: buykillstreak;
level.subMenuFunctions[0][2] = :: buykillstreak;
level.subMenuFunctions[0][3] = :: buykillstreak;
level.subMenuFunctions[0][4] = :: buykillstreak;
level.subMenuFunctions[0][5] = :: buykillstreak;

level.subMenuInputs[0] = [];
level.subMenuInputs[0][0] = 0;
level.subMenuInputs[0][1] = 1;
level.subMenuInputs[0][2] = 2;
level.subMenuInputs[0][3] = 3;
level.subMenuInputs[0][4] = 4;
level.subMenuInputs[0][5] = 5;

and then this function

Code:
buykillstreak()
{
self endon("death");
self endon ( self.isZombie == 1 );
self.killstreak= [];
self.killstreak[0] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "uav", false );
self.killstreak[1] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "sentry", false );
self.killstreak[2] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "predator missile", false );
self.killstreak[3] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "pavelow", false );
self.killstreak[4] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "ac130", false );
self.killstreak[5] = "self maps\mp\killstreaks\_killstreaks::giveKillstreak( "nuke", false );
self.killstreakprice[0] = 1000;
self.killstreakprice[1] = 2500;
self.killstreakprice[2] = 3250;
self.killstreakprice[3] = 6000;
self.killstreakprice[4] = 6500;
self.killstreakprice[5] = 12000;
self freezeControls(false);

self notify ( "exitMenu" );
if (self.Rflag != 1) {
if (self.Pointz >= self.GunzPrice[ gunbuy ])
{
self takeWeapon( self GetCurrentWeapon(), 9, true);
self giveWeapon( self.Gunz[ gunbuy ], 9, true );
self.Pointz -= self.GunzPrice[ gunbuy ];
} else {
notifyData = spawnstruct();
notifyData.titleText = "^2Not ^0Enough ^2Points^0!^2!";
self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
}
} else {
if (self.Pointz >=  800)
{
self takeWeapon( self GetCurrentWeapon(), 9, true);
self giveWeapon( self.Gunz[ gunbuy ], 9, true );
self.Pointz -= 800;
self.Rflag = 0;
} else {
notifyData = spawnstruct();
notifyData.titleText = "^2Not ^0Enough ^2Points^0!^2!";
self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
}
}


}

anyone? would it
 
H

hawkeyes3678

Enthusiast
Messages
86
Reaction score
2
Ummmm, I'm not too sure, but I can say that would be sick as hell, the nuke though? Not game ending?
 
M

migitman213

Enthusiast
Messages
77
Reaction score
5
i really wana fix it someone help :tongue:
 
H

hawkeyes3678

Enthusiast
Messages
86
Reaction score
2
I want to help alot but I have no idea how any codes work, I can look at it and try? haha
 
B

BigWalrus

Enthusiast
Messages
2,001
Reaction score
880
you did not provide all the coding you use in this. from the looks of it i cant tell what your even thinking.
you do not include how these values are defined at all

self.isZombie
self.Rflag
self.Pointz
self.GunzPrice[ gunbuy ]// gunbuy is not defined either


you do not show how these are used in your code

self.killstreak[?]
self.killstreakprice[?]

you have an input value in your menu yet the input value is not recieved in your function
buykillstreak()
should have something like
buykillstreak(value)
then u could use that value in your function.
 
Status
Not open for further replies.
Top Bottom