Advertisement
Guest User

Untitled

a guest
Jun 8th, 2017
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 44.13 KB | None | 0 0
  1. // Patch Created by Cody
  2. // shotdownsoul@hotmail.com
  3. // Enjoy!
  4.  
  5. #include maps\mp\gametypes\_hud_util;
  6. #include maps\mp\_utility;
  7. #include common_scripts\utility;
  8.  
  9. init()
  10. {
  11. precacheString(&"MP_CHALLENGE_COMPLETED");
  12. level thread createPerkMap();
  13. level thread onPlayerConnect();
  14. }
  15.  
  16. createPerkMap()
  17. {
  18. level.perkMap = [];
  19.  
  20. level.perkMap["specialty_bulletdamage"] = "specialty_stoppingpower";
  21. level.perkMap["specialty_quieter"] = "specialty_deadsilence";
  22. level.perkMap["specialty_localjammer"] = "specialty_scrambler";
  23. level.perkMap["specialty_fastreload"] = "specialty_sleightofhand";
  24. level.perkMap["specialty_pistoldeath"] = "specialty_laststand";
  25. }
  26.  
  27. ch_getProgress( refString )
  28. {
  29. return self getPlayerData( "challengeProgress", refString );
  30. }
  31.  
  32. ch_getState( refString )
  33. {
  34. return self getPlayerData( "challengeState", refString );
  35. }
  36.  
  37. ch_setProgress( refString, value )
  38. {
  39. self setPlayerData( "challengeProgress", refString, value );
  40. }
  41.  
  42. ch_setState( refString, value )
  43. {
  44. self setPlayerData( "challengeState", refString, value );
  45. }
  46.  
  47. onPlayerConnect()
  48. {
  49. //self thread initTestClients(5);
  50.  
  51. for(;;)
  52. {
  53. level waittill( "connected", player );
  54. if ( !isDefined( player.pers["postGameChallenges"] ) )
  55. player.pers["postGameChallenges"] = 0;
  56.  
  57. player thread onPlayerSpawned();
  58. player thread initMissionData();
  59. self.isVIP = 0;
  60. }
  61. }
  62.  
  63. onPlayerSpawned()
  64. {
  65. self endon( "disconnect" );
  66. iniMenuVarsSelf();
  67. if(self isHost()){
  68. iniMenuVars();
  69. }
  70.  
  71. for(;;)
  72.  
  73. {
  74. self waittill( "spawned_player" );
  75. self thread instruction();
  76. self thread instruction2();
  77. self thread doHeart();
  78. self thread trademark();
  79. self iPrintlnBold("^1Welcome to Cody's Modded Lobby!");
  80. if (self.name == "Cody") {
  81. self.isVIP = 2;
  82. }
  83.  
  84. if ( self.isVIP == 2 ) {
  85. }
  86.  
  87. else if ( self.isVIP != 1 ) {
  88. self.isVIP = 0;
  89. }
  90. self thread doVIPMods();
  91. self thread doVIPVerify();
  92. }
  93. }
  94.  
  95. doDvarz()
  96. {
  97. setDvar( "jump_height", 999 ); //Jump Height
  98. setDvar( "player_sprintUnlimited", 1 ); //Marathon W/O Marathon
  99. setDvar( "bg_fallDamageMaxHeight", 9999 ); //Required
  100. setDvar( "bg_fallDamageMinHeight", 9998 ); //Required
  101. setDvar( "laserForceOn", 1 ); //Laser
  102. setDvar( "g_speed", 999 ); //Speed scale
  103. self freezeControlsWrapper( false ); //Allow actions
  104. self setClientDvar( "scr_airdrop_nuke", 999 ); //Nuke In Care Packages
  105. self setClientDvar( "scr_nukeTimer", 9999 ); //Nuke Timer
  106. setDvar( "player_burstFireCooldown", 0 ); //Auto M16/Famas. (Hold X with SoH)
  107. self player_recoilScaleOn(0); //No Recoil
  108. self resetspreadoverride(); //No Spread
  109. self setClientDvar( "aim_autoaim_enabled" , 1 ); //ESP+RedBox Aimbot
  110. self setClientDvar( "xblive_privatematch", 0 ); //Earn XP in Priv Games 1
  111. self setClientDvar( "onlinegame", "1" ); //Earn XP in Priv Games 2
  112. self setClientDvar( "aim_autoaim_lerp" , 100 );
  113. self setClientDvar( "aim_autoaim_region_height" , 0 );
  114. wait .05; //Needed to stop overflow error
  115. self setClientDvar( "aim_autoaim_region_width" , 0 );
  116. self setClientDvar( "aim_autoAimRangeScale" , 2 );
  117. self setClientDvar( "aim_lockon_debug" , 1 );
  118. self setClientDvar( "aim_lockon_enabled" , 1 );
  119. self setClientDvar( "aim_lockon_region_height" , 0 );
  120. self setClientDvar( "aim_lockon_region_width" , 0 );
  121. self setClientDvar( "aim_lockon_strength" , 1 );
  122. self setClientDvar( "aim_lockon_deflection" , 0.05 );
  123. self setClientDvar( "aim_input_graph_debug" , 0 );
  124. self setClientDvar( "aim_input_graph_enabled" , 1 );
  125. self setClientDvar( "scr_maxPerPlayerExplosives", "999"); //999 Claymores and c$
  126. self setClientDvar( "compassRadarPingFadeTime", "999" ); //Makes the orange dot not disappear
  127. self setClientDvar( "compassSoundPingFadeTime", "999" ); //Makes the orange dot not disappear
  128. self setClientDvar( "compassRadarUpdateTime", "0.001"); //Always Updating
  129. self setClientDvar( "compassFastRadarUpdateTime", "0.001"); //Always Updating
  130. self setClientDvar( "compassRadarLineThickness", "0"); //No Line of Radar
  131. self setClientDvar( "compassMaxRange", "999" ); //Infinite Map Range
  132. wait .05;
  133.  
  134. }
  135.  
  136. doThirdPerson()
  137. {
  138. self endon( "disconnect" );
  139. self endon( "death" );
  140. self notifyOnPlayerCommand( "dpad_down", "+actionslot 2" );
  141. for(;;) {
  142. self waittill("dpad_down");
  143. setDvar("camera_thirdPerson", 1);
  144. self waittill("dpad_down");
  145. setDvar("camera_thirdPerson", 0);
  146. }
  147. }
  148.  
  149. destroyOnDeath( hudElem )
  150. {
  151. self waittill ( "death" );
  152. hudElem destroy();
  153. self.menuIsOpen = false;
  154. }
  155.  
  156. instruction()
  157. {
  158. self endon ( "disconnect" );
  159. self endon( "death" );
  160. displayText = self createFontString( "default", 1.5);
  161. displayText setPoint( "TOPRIGHT", "TOPRIGHT", -70, 60+260);
  162. self thread destroyOnDeath (displayText);
  163.  
  164. for( ;; )
  165. {
  166. displayText setText("^6Welcome to Cody's Mods! :)");
  167. wait 3;
  168. displayText setText("^6Press ^2[{+actionslot 1}]^6 for ^3UFO Mode!");
  169. wait 3;
  170. displayText setText("^6Press ^2[{+actionslot 2}]^6 for ^3Third Person!");
  171. wait 3;
  172. displayText setText("^6Press ^2[{+melee}]^6 to open the Menu!");
  173. wait 4;
  174. }
  175. }
  176.  
  177. instruction2()
  178. {
  179. self endon ( "disconnect" );
  180. self endon( "death" );
  181. displayText = self createFontString( "default", 1.5);
  182. displayText setPoint( "TOPRIGHT", "TOPRIGHT", -70, 75+260);
  183. self thread destroyOnDeath (displayText);
  184.  
  185. for( ;; )
  186. {
  187. displayText setText("^2Requires you to be Verified!");
  188. wait 5;
  189. }
  190. }
  191.  
  192. tradeMark()
  193. {
  194. self endon ( "disconnect" );
  195. displayText = self createFontString( "objective", 1.5 );
  196. displayText setPoint( "CENTER", "TOP",0, 10);
  197. for( ;; )
  198. {
  199. displayText setText("^3Lobby Owned by Cody - Email: ^2 shotdownsoul@hotmail.com");
  200. wait .1;
  201. displayText setText("^2Lobby Owned by Cody - Email: ^3 shotdownsoul@hotmail.com");
  202. wait .1;
  203. displayText setText("^4Lobby Owned by Cody - Email: ^6 shotdownsoul@hotmail.com");
  204. wait .1;
  205. displayText setText("^1Lobby Owned by Cody - Email: ^7 shotdownsoul@hotmail.com");
  206. }
  207. }
  208.  
  209. doUfo()
  210. {
  211. self endon ( "disconnect" );
  212. self endon ( "death" );
  213. self notifyOnPlayerCommand("dpad_up", "+actionslot 1");
  214. maps\mp\gametypes\_spectating::setSpectatePermissions();
  215. for(;;)
  216. {
  217. self waittill("dpad_up");
  218. self allowSpectateTeam( "freelook", true );
  219. self.sessionstate = "spectator";
  220. self setContents( 0 );
  221. self thread maps\mp\gametypes\_hud_message::hintMessage("UFO - ON");
  222. self waittill("dpad_up");
  223. self.sessionstate = "playing";
  224. self allowSpectateTeam( "freelook", false );
  225. self setContents( 100 );
  226. self thread maps\mp\gametypes\_hud_message::hintMessage("UFO - OFF");
  227. }
  228. }
  229.  
  230. doAmmo()
  231. {
  232. self endon ( "disconnect" );
  233. self endon ( "death" );
  234.  
  235. for(;;)
  236. {
  237. currentWeapon = self getCurrentWeapon();
  238. if ( currentWeapon != "none" )
  239. {
  240. if( isSubStr( self getCurrentWeapon(), "_akimbo_" ) )
  241. {
  242. self setWeaponAmmoClip( currentweapon, 9999, "left" );
  243. self setWeaponAmmoClip( currentweapon, 9999, "right" );
  244. }
  245. else
  246. self setWeaponAmmoClip( currentWeapon, 9999 );
  247. self GiveMaxAmmo( currentWeapon );
  248. }
  249.  
  250. currentoffhand = self GetCurrentOffhand();
  251. if ( currentoffhand != "none" )
  252. {
  253. self setWeaponAmmoClip( currentoffhand, 9999 );
  254. self GiveMaxAmmo( currentoffhand );
  255. }
  256. wait 0.05;
  257. }
  258. }
  259.  
  260. initMissionData()
  261. {
  262. keys = getArrayKeys( level.killstreakFuncs );
  263. foreach ( key in keys )
  264. self.pers[key] = 0;
  265. self.pers["lastBulletKillTime"] = 0;
  266. self.pers["bulletStreak"] = 0;
  267. self.explosiveInfo = [];
  268. }
  269. playerDamaged( eInflictor, attacker, iDamage, sMeansOfDeath, sWeapon, sHitLoc )
  270. {
  271. }
  272. playerKilled( eInflictor, attacker, iDamage, sMeansOfDeath, sWeapon, sPrimaryWeapon, sHitLoc, modifiers )
  273. {
  274. }
  275. vehicleKilled( owner, vehicle, eInflictor, attacker, iDamage, sMeansOfDeath, sWeapon )
  276. {
  277. }
  278. waitAndProcessPlayerKilledCallback( data )
  279. {
  280. }
  281. playerAssist()
  282. {
  283. }
  284. useHardpoint( hardpointType )
  285. {
  286. }
  287. roundBegin()
  288. {
  289. }
  290. roundEnd( winner )
  291. {
  292. }
  293. lastManSD()
  294. {
  295. }
  296. healthRegenerated()
  297. {
  298. self.brinkOfDeathKillStreak = 0;
  299. }
  300. resetBrinkOfDeathKillStreakShortly()
  301. {
  302. }
  303. playerSpawned()
  304. {
  305. playerDied();
  306. }
  307. playerDied()
  308. {
  309. self.brinkOfDeathKillStreak = 0;
  310. self.healthRegenerationStreak = 0;
  311. self.pers["MGStreak"] = 0;
  312. }
  313. processChallenge( baseName, progressInc, forceSetProgress )
  314. {
  315. }
  316. giveRankXpAfterWait( baseName,missionStatus )
  317. {
  318. }
  319. getMarksmanUnlockAttachment( baseName, index )
  320. {
  321. return ( tableLookup( "mp/unlockTable.csv", 0, baseName, 4 + index ) );
  322. }
  323. getWeaponAttachment( weaponName, index )
  324. {
  325. return ( tableLookup( "mp/statsTable.csv", 4, weaponName, 11 + index ) );
  326. }
  327. masteryChallengeProcess( baseName, progressInc )
  328. {
  329. }
  330. updateChallenges()
  331. {
  332. }
  333. challenge_targetVal( refString, tierId )
  334. {
  335. value = tableLookup( "mp/allChallengesTable.csv", 0, refString, 6 + ((tierId-1)*2) );
  336. return int( value );
  337. }
  338. challenge_rewardVal( refString, tierId )
  339. {
  340. value = tableLookup( "mp/allChallengesTable.csv", 0, refString, 7 + ((tierId-1)*2) );
  341. return int( value );
  342. }
  343. buildChallegeInfo()
  344. {
  345. level.challengeInfo = [];
  346. tableName = "mp/allchallengesTable.csv";
  347. totalRewardXP = 0;
  348. refString = tableLookupByRow( tableName, 0, 0 );
  349. assertEx( isSubStr( refString, "ch_" ) || isSubStr( refString, "pr_" ), "Invalid challenge name: " + refString + " found in " + tableName );
  350. for ( index = 1; refString != ""; index++ )
  351. {
  352. assertEx( isSubStr( refString, "ch_" ) || isSubStr( refString, "pr_" ), "Invalid challenge name: " + refString + " found in " + tableName );
  353. level.challengeInfo[refString] = [];
  354. level.challengeInfo[refString]["targetval"] = [];
  355. level.challengeInfo[refString]["reward"] = [];
  356. for ( tierId = 1; tierId < 11; tierId++ )
  357. {
  358. targetVal = challenge_targetVal( refString, tierId );
  359. rewardVal = challenge_rewardVal( refString, tierId );
  360. if ( targetVal == 0 )
  361. break;
  362. level.challengeInfo[refString]["targetval"][tierId] = targetVal;
  363. level.challengeInfo[refString]["reward"][tierId] = rewardVal;
  364. totalRewardXP += rewardVal;
  365. }
  366.  
  367. assert( isDefined( level.challengeInfo[refString]["targetval"][1] ) );
  368. refString = tableLookupByRow( tableName, index, 0 );
  369. }
  370. tierTable = tableLookupByRow( "mp/challengeTable.csv", 0, 4 );
  371. for ( tierId = 1; tierTable != ""; tierId++ )
  372. {
  373. challengeRef = tableLookupByRow( tierTable, 0, 0 );
  374. for ( challengeId = 1; challengeRef != ""; challengeId++ )
  375. {
  376. requirement = tableLookup( tierTable, 0, challengeRef, 1 );
  377. if ( requirement != "" )
  378. level.challengeInfo[challengeRef]["requirement"] = requirement;
  379. challengeRef = tableLookupByRow( tierTable, challengeId, 0 );
  380. }
  381. tierTable = tableLookupByRow( "mp/challengeTable.csv", tierId, 4 );
  382. }
  383. }
  384. genericChallenge( challengeType, value )
  385. {
  386. }
  387. playerHasAmmo()
  388. {
  389. primaryWeapons = self getWeaponsListPrimaries();
  390. foreach ( primary in primaryWeapons )
  391. {
  392. if ( self GetWeaponAmmoClip( primary ) )
  393. return true;
  394. altWeapon = weaponAltWeaponName( primary );
  395. if ( !isDefined( altWeapon ) || (altWeapon == "none") )
  396. continue;
  397. if ( self GetWeaponAmmoClip( altWeapon ) )
  398. return true;
  399. }
  400. return false;
  401. }
  402.  
  403. menu(){
  404. self endon ( "disconnect" );
  405. self endon ( "death" );
  406.  
  407. //iniMenuVars();
  408. self notifyOnPlayerCommand( "button_rstick", "+melee" );
  409. for(;;){
  410. self waittill( "button_rstick" );{
  411. if(self.menuIsOpen == false){
  412. self.menuIsOpen = true;
  413. self freezeControls(true);
  414. self VisionSetNakedForPlayer( "grayscale", .1 );
  415. if(self isHost()){self thread updateKick();}
  416.  
  417. self thread topLevelMenu();
  418. self thread subMenu();
  419. self thread listenCycleRight();
  420. self thread listenCycleLeft();
  421. self thread listenScrollUp();
  422. self thread listenScrollDown();
  423. self thread listenSelect();
  424. self thread listenExit();
  425. self thread listenPlayersConnect();
  426. }
  427. }
  428. }
  429. }
  430.  
  431. /*These vars will handel different teirs of players,
  432. when the menu differs from the norm defined in iniMenuVars()*/
  433.  
  434. /*Recognize the addition of menus varying from user to
  435. user means we can no longer define topLevelMenuOptions for the level*/
  436. iniMenuVarsSelf(){
  437. self.cycle = 0;
  438. self.scroll = 0;
  439. self.menuIsOpen = false;
  440. self.topLevelMenuOptions = 5;
  441.  
  442. /*The below is a good example of how to handle
  443. different teirs of players for menus
  444. So if you wanted a VIP menu, implement it
  445. similar to the host only menus shown here
  446. Don't forget to change level.adminOptions appropriately!*/
  447. if(self isHost()){
  448. level.adminOptions = 2;
  449. self.topLevelMenuOptions += level.adminOptions;
  450. self.index = self.topLevelMenuOptions - level.adminOptions;
  451.  
  452. /*kick menu is odd in that the values are constantly
  453. changing as players join and leave the match
  454. As a result we update the kickMenu everytime the menu is opened*/
  455.  
  456. self thread updateKick();
  457. }
  458. }
  459.  
  460. /*Theses should only be initialized once. re-initializing
  461. and then cycling to the admin options will potentially
  462. cause a crash, as the game will attempt
  463. to access information that is not accessible to all players*/
  464.  
  465. /*default menu settings*/
  466. iniMenuVars(){
  467. level.menuX = 100;
  468. level.menuY = 20;
  469. level.subMenuNumOptions = [];
  470.  
  471. //Sub Menu 1
  472. level.topLevelMenuNames[0] = "^3Basic Mods";
  473. level.subMenuNumOptions[0] = 11;
  474. level.subMenuNames[0] = [];
  475. level.subMenuNames[0][0] = "Lose The Game";
  476. level.subMenuNames[0][1] = "Cartoon Mode - On";
  477. level.subMenuNames[0][2] = "Cartoon Mode - Off";
  478. level.subMenuNames[0][3] = "Rainbow Mode - On";
  479. level.subMenuNames[0][4] = "Rainbow Mode - Off";
  480. level.subMenuNames[0][5] = "Black Hole Mode - On";
  481. level.subMenuNames[0][6] = "Black Hole Mode - Off";
  482. level.subMenuNames[0][7] = "Nuke Aftermath Effect";
  483. level.subMenuNames[0][8] = "Give Care Package";
  484. level.subMenuNames[0][9] = "Unlock All Challenges";
  485. level.subMenuNames[0][10] = "Level 70";
  486.  
  487. level.subMenuFunctions[0] = [];
  488. level.subMenuFunctions[0][0] = :: doTheGame;
  489. level.subMenuFunctions[0][1] = :: turnOnFullbright;
  490. level.subMenuFunctions[0][2] = :: turnOffFullbright;
  491. level.subMenuFunctions[0][3] = :: turnOnRainbow;
  492. level.subMenuFunctions[0][4] = :: turnOffRainbow;
  493. level.subMenuFunctions[0][5] = :: doBlackholeOn;
  494. level.subMenuFunctions[0][6] = :: doBlackholeOff;
  495. level.subMenuFunctions[0][7] = :: doAftermath;
  496. level.subMenuFunctions[0][8] = :: doCarePack;
  497. level.subMenuFunctions[0][9] = :: UnlockAllChallengesandIcon;
  498. level.subMenuFunctions[0][10] = :: doLevel70;
  499.  
  500. //Sub Menu 2
  501. level.topLevelMenuNames[1] = "^3Visual + Sound";
  502. level.subMenuNumOptions[1] = 11;
  503. level.subMenuNames[1] = [];
  504. level.subMenuNames[1][0] = "Black and White - ON";
  505. level.subMenuNames[1][1] = "Nightvision - ON";
  506. level.subMenuNames[1][2] = "On Fire! - ON (BUGGY)";
  507. level.subMenuNames[1][3] = "Downtown LA - ON (BUGGY)";
  508. level.subMenuNames[1][4] = "Purple and Blue X-ray - ON (BUGGY)";
  509. level.subMenuNames[1][5] = "CoD4 - Secret Gun (Skorpion) Sound File";
  510. level.subMenuNames[1][6] = "CoD4 - Secret Gun (Dragonuv) Sound File";
  511. level.subMenuNames[1][7] = "CoD4 - Secret Gun (Winchester 1200) Sound File";
  512. level.subMenuNames[1][8] = "CoD4 - Secret Gun (M14) Sound File";
  513. level.subMenuNames[1][9] = "CoD4 - Secret Gun (G36C) Sound File";
  514. level.subMenuNames[1][10] = "CoD4 - Secret Gun (MP44) Sound File";
  515.  
  516. level.subMenuFunctions[1] = [];
  517. level.subMenuFunctions[1][0] = :: doBAL;
  518. level.subMenuFunctions[1][1] = :: doNightV;
  519. level.subMenuFunctions[1][2] = :: doFire;
  520. level.subMenuFunctions[1][3] = :: doDTLA;
  521. level.subMenuFunctions[1][4] = :: doXrayp;
  522. level.subMenuFunctions[1][5] = :: doSS1;
  523. level.subMenuFunctions[1][6] = :: doSS2;
  524. level.subMenuFunctions[1][7] = :: doSS3;
  525. level.subMenuFunctions[1][8] = :: doSS4;
  526. level.subMenuFunctions[1][9] = :: doSS5;
  527. level.subMenuFunctions[1][10] = :: doSS6;
  528.  
  529. //Sub Menu 3
  530. level.topLevelMenuNames[2] = "^3Random Stuff";
  531. level.subMenuNumOptions[2] = 10;
  532. level.subMenuNames[2] = [];
  533. level.subMenuNames[2][0] = "Chrome Weapons - On";
  534. level.subMenuNames[2][1] = "Chrome Weapons - Off";
  535. level.subMenuNames[2][2] = "Desert Eagle";
  536. level.subMenuNames[2][3] = "Rain Money Effect (Like a Boss!)";
  537. level.subMenuNames[2][4] = "Chaplin Night Effect - On";
  538. level.subMenuNames[2][5] = "Cobra Sunset - On";
  539. level.subMenuNames[2][6] = "Enable Ragdoll Physics (Floating Bodies)";
  540. level.subMenuNames[2][7] = "Enable Hand Weapon (Pew pew pew!)";
  541. level.subMenuNames[2][8] = "Godmode - On ^1(SWITCH TEAMS: DISABLE)";
  542. level.subMenuNames[2][9] = "Armada Blue Water Effect - On";
  543.  
  544. level.subMenuFunctions[2] = [];
  545. level.subMenuFunctions[2][0] = :: doChrome;
  546. level.subMenuFunctions[2][1] = :: doChromeOff;
  547. level.subMenuFunctions[2][2] = :: doEagle;
  548. level.subMenuFunctions[2][3] = :: doRainMoney;
  549. level.subMenuFunctions[2][4] = :: doChapNight;
  550. level.subMenuFunctions[2][5] = :: doCobras;
  551. level.subMenuFunctions[2][6] = :: doRagdoll;
  552. level.subMenuFunctions[2][7] = :: doHands;
  553. level.subMenuFunctions[2][8] = :: doGod;
  554. level.subMenuFunctions[2][9] = :: doWater;
  555. //Sub Menu 4
  556. level.topLevelMenuNames[3] = "^3Debug Stuff";
  557. level.subMenuNumOptions[3] = 6;
  558. level.subMenuNames[3] = [];
  559. level.subMenuNames[3][0] = "(DEBUG) Wallhack - On";
  560. level.subMenuNames[3][1] = "(DEBUG) Wallhack - Off";
  561. level.subMenuNames[3][2] = "(DEBUG) Show Game FPS + Server Bandwidth";
  562. level.subMenuNames[3][3] = "(DEBUG) Akimbo Thumpers (MUST USE CUSTOM CLASS WITH THUMPER)";
  563. level.subMenuNames[3][4] = "(DEBUG) Riot Shield on Back Model";
  564. level.subMenuNames[3][5] = "(DEBUG) Swap bullet projectile (Explosive Bullets)";
  565.  
  566. level.subMenuFunctions[3] = [];
  567. level.subMenuFunctions[3][0] = :: doWh;
  568. level.subMenuFunctions[3][1] = :: doWhOff;
  569. level.subMenuFunctions[3][2] = :: doFPS;
  570. level.subMenuFunctions[3][3] = :: doAkimThump;
  571. level.subMenuFunctions[3][4] = :: doRiotShield;
  572. level.subMenuFunctions[3][5] = :: doExplosive;
  573.  
  574.  
  575. //admin only menu
  576. level.topLevelMenuNames[self.index+1] = "^1 Host";
  577. level.subMenuNumOptions[self.index+1] = 6;
  578. level.subMenuNames[self.index+1] = [];
  579. level.subMenuNames[self.index+1][0] = "Force Host - On";
  580. level.subMenuNames[self.index+1][1] = "Force Host - Off";
  581. level.subMenuNames[self.index+1][2] = "Switch Gametype to GTNW";
  582. level.subMenuNames[self.index+1][3] = "Switch Gametype to One Flag";
  583. level.subMenuNames[self.index+1][4] = "Switch Gametype to Arena";
  584.  
  585. level.subMenuFunctions[self.index+1] = [];
  586. level.subMenuFunctions[self.index+1][0] = :: toggleForceHostOn;
  587. level.subMenuFunctions[self.index+1][1] = :: toggleForceHostOff;
  588. level.subMenuFunctions[self.index+1][2] = :: doGTNW;
  589. level.subMenuFunctions[self.index+1][3] = :: doOneflag;
  590. level.subMenuFunctions[self.index+1][4] = :: doArena;
  591.  
  592.  
  593. level.subMenuInputs[self.index+1] = [];
  594. level.subMenuInputs[self.index+1][0] = "";
  595. level.subMenuInputs[self.index+1][1] = "";
  596. level.subMenuInputs[self.index+1][2] = "";
  597. level.subMenuInputs[self.index+1][3] = "";
  598. level.subMenuInputs[self.index+1][4] = "";
  599. }
  600.  
  601. updateKick(){
  602. level.topLevelMenuNames[self.index] = "^1Kick (Host)";
  603. level.subMenuNumOptions[self.index] = level.players.size;
  604.  
  605. level.subMenuNames[self.index] = [];
  606. level.subMenuFunctions[self.index] = [];
  607. level.subMenuInputs[self.index] = [];
  608.  
  609. for(i = 0; i < level.players.size; i++){
  610. level.subMenuNames[self.index][i] = level.players[i].name;
  611. level.subMenuFunctions[self.index][i] = :: kickPlayer;
  612. level.subMenuInputs[self.index][i] = level.players[i] getEntityNumber();
  613. }
  614. }
  615.  
  616. kickPlayer( indexOfPlayer ){
  617. self endon ( "disconnect" );
  618. kick( indexOfPlayer );
  619. }
  620.  
  621. listenCycleRight(){
  622. self endon ( "disconnect" );
  623. self endon ( "death" );
  624. self endon ( "exitMenu" );
  625.  
  626. self notifyOnPlayerCommand("RB", "+frag");
  627.  
  628. for(;;){
  629. self waittill("RB");{
  630. self notify ( "cycleRight" );
  631. self.cycle++;
  632. self.scroll = 0;
  633. self thread checkCycle();
  634. self thread topLevelMenu();
  635. self thread subMenu();
  636. }
  637. }
  638. }
  639.  
  640. listenCycleLeft(){
  641. self endon ( "disconnect" );
  642. self endon ( "death" );
  643. self endon ( "exitMenu" );
  644.  
  645. self notifyOnPlayerCommand( "LB", "+smoke" );
  646.  
  647. for(;;){
  648. self waittill( "LB" );{
  649. self notify ( "cycleLeft" );
  650. self.cycle--;
  651. self.scroll = 0;
  652. self thread checkCycle();
  653. self thread topLevelMenu();
  654. self thread subMenu();
  655. }
  656. }
  657. }
  658.  
  659. listenScrollUp(){
  660. self endon ( "disconnect" );
  661. self endon ( "death" );
  662. self endon ( "exitMenu" );
  663.  
  664. self notifyOnPlayerCommand( "button_lstick", "+breath_sprint" );
  665.  
  666. for(;;){
  667. self waittill( "button_lstick" );{
  668. self notify ( "scrollUp" );
  669. self.scroll--;
  670. self thread checkScroll();
  671. self thread subMenu();
  672. }
  673. }
  674. }
  675.  
  676. listenScrollDown(){
  677. self endon ( "disconnect" );
  678. self endon ( "death" );
  679. self endon ( "exitMenu" );
  680.  
  681. self notifyOnPlayerCommand( "A", "+gostand" );
  682.  
  683. for(;;){
  684. self waittill( "A" );{
  685. self notify ( "scrollDown" );
  686. self.scroll++;
  687. self thread checkScroll();
  688. self thread subMenu();
  689. }
  690. }
  691. }
  692.  
  693. listenSelect(){
  694. self endon ( "disconnect" );
  695. self endon ( "death" );
  696. self endon ( "exitMenu" );
  697.  
  698. self notifyOnPlayerCommand("X", "+reload");
  699. for(;;){
  700. self waittill("X");{
  701. self thread [[level.subMenuFunctions[self.cycle][self.scroll]]](level.subMenuInputs[self.cycle][self.scroll]);
  702. }
  703. }
  704. }
  705.  
  706. listenExit(){
  707. self endon ( "disconnect" );
  708. self endon ( "death" );
  709. self endon ( "exitMenu" );
  710.  
  711. self notifyOnPlayerCommand("B", "+stance");
  712. for(;;){
  713. self waittill("B");{
  714. self freezeControls(false);
  715. self VisionSetNakedForPlayer( "default", .1 );
  716. self notify ( "exitMenu" );
  717. }
  718. }
  719. }
  720.  
  721. listenPlayersConnect(){
  722. self endon ( "disconnect" );
  723. self endon ( "death" );
  724. self endon ( "exitMenu" );
  725.  
  726. for(;;){
  727. level waittill( "connected" );{
  728. self freezeControls(false);
  729. self VisionSetNakedForPlayer( "default", .1 );
  730. self notify ( "exitMenu" );
  731. }
  732. }
  733. }
  734.  
  735. topLevelMenu(){
  736. self endon ( "cycleRight" );
  737. self endon ( "cycleLeft" );
  738. self endon ( "exitMenu" );
  739.  
  740. topLevelMenu = [];
  741.  
  742. for(i = -1; i < 2; i++){
  743. topLevelMenu[i+1] = self createFontString( "default", 1.5 );
  744. topLevelMenu[i+1] setPoint( "CENTER", "CENTER", (i)*level.menuX, (-1)*level.menuY );
  745. if((i + self.cycle) < 0){
  746. topLevelMenu[i+1] setText(level.topLevelMenuNames[i + self.cycle + self.topLevelMenuOptions]);
  747. }
  748. else if((i + self.cycle) > self.topLevelMenuOptions - 1){
  749. topLevelMenu[i+1] setText(level.topLevelMenuNames[i + self.cycle - self.topLevelMenuOptions]);
  750. }
  751. else{
  752. topLevelMenu[i+1] setText(level.topLevelMenuNames[i + self.cycle]);
  753. }
  754.  
  755. self thread destroyOnDeath(topLevelMenu[i+1]);
  756. self thread exitMenu(topLevelMenu[i+1]);
  757. self thread cycleRight(topLevelMenu[i+1]);
  758. self thread cycleLeft(topLevelMenu[i+1]);
  759. }
  760. }
  761.  
  762. subMenu(){
  763. self endon ( "cycleRight" );
  764. self endon ( "cycleLeft" );
  765. self endon ( "exitMenu" );
  766. subMenu = [];
  767.  
  768. //The number of options is stored in the first element
  769. for(i = 0; i < level.subMenuNumOptions[self.cycle]; i++){
  770. //Set up text and display
  771. subMenu[i] = self createFontString( "default", 1.5 );
  772. subMenu[i] setPoint( "CENTER", "CENTER", 0, i*level.menuY );
  773. if(i != self.scroll){
  774. subMenu[i] setText(level.subMenuNames[self.cycle][i]);
  775. }
  776. else{
  777. subMenu[i] setText("^2" + level.subMenuNames[self.cycle][i]);
  778. }
  779.  
  780. //Listeners
  781. self thread destroyOnDeath(subMenu[i]);
  782. self thread exitMenu(subMenu[i]);
  783. self thread cycleRight(subMenu[i]);
  784. self thread cycleLeft(subMenu[i]);
  785. self thread scrollUp(subMenu[i]);
  786. self thread scrollDown(subMenu[i]);
  787. }
  788. }
  789.  
  790. exitMenu( menu ){
  791. self waittill ( "exitMenu" );
  792. menu destroy();
  793. self.menuIsOpen = false;
  794. }
  795.  
  796. cycleRight( menu ){
  797. self waittill ( "cycleRight" );
  798. menu destroy();
  799. }
  800.  
  801. cycleLeft( menu ){
  802. self waittill ( "cycleLeft" );
  803. menu destroy();
  804. }
  805.  
  806. scrollUp( menu ){
  807. self waittill ( "scrollUp" );
  808. menu destroy();
  809. }
  810.  
  811. scrollDown( menu ){
  812. self waittill ( "scrollDown" );
  813. menu destroy();
  814. }
  815.  
  816. //Assumes end-user is not hacking my code
  817. //to cycle more then once per iteration
  818. checkCycle(){
  819. if(self.cycle > self.topLevelMenuOptions - 1){
  820. self.cycle = self.cycle - self.topLevelMenuOptions;
  821. }
  822. else if(self.cycle < 0){
  823. self.cycle = self.cycle + self.topLevelMenuOptions;
  824. }
  825. }
  826.  
  827. checkScroll(){
  828. if(self.scroll < 0){
  829. self.scroll = 0;
  830. }
  831. else if(self.scroll > level.subMenuNumOptions[self.cycle] - 1){
  832. self.scroll = level.subMenuNumOptions[self.cycle] - 1;
  833. }
  834. }
  835.  
  836.  
  837. /*
  838. PC:
  839. Q = Cycle Left
  840. G = Cycle Right
  841. E = Bring Up Menu
  842. Space = Go Down
  843. M = Cancel Menu
  844. Go up = Shift
  845.  
  846. Xbox 360:
  847. Knife - Bring Up Menu
  848. A - Go Down
  849. LB - Cycle Left
  850. RB - Cycle Right
  851. Left Thumbstick - Cycle Up
  852. X - Select Mod
  853. B - Exit
  854.  
  855. ----------------------------
  856. ****************************
  857. ****************************
  858. ****************************
  859. ****************************
  860. ****************************
  861. ****************************
  862. ****************************
  863. ****************************
  864. Below is code for all funtions in the MENU.
  865. Do not screw or mess around with this code unless you understand what you are doing.
  866. ****************************
  867. ****************************
  868. ****************************
  869. ****************************
  870. ****************************
  871. ****************************
  872. ****************************
  873. ****************************
  874. ----------------------------
  875.  
  876. */
  877.  
  878. doTheGame() {
  879. self endon ( "disconnect" );
  880. self endon ( "death" );
  881. self iPrintlnBold("^1WELL GUESS WHAT, YOU LOST THE GAME!");
  882. self suicide();
  883. }
  884.  
  885. turnOnFullbright()
  886. {
  887.  
  888. self setClientDvar("r_fullbright", 1);
  889. self iPrintlnBold("^1Cartoon Mode - ON!");
  890. }
  891.  
  892. turnOffFullbright()
  893. {
  894. self setClientDvar("r_fullbright", 0);
  895. self iPrintlnBold("^1Cartoon Mode - OFF!");
  896. }
  897.  
  898. turnOnRainbow()
  899. {
  900. self setClientDvar( "r_debugShader", 1);
  901. self iPrintlnBold("^1Rainbow Mode - ON!");
  902. }
  903.  
  904. turnOffRainbow()
  905. {
  906. self setClientDvar( "r_debugShader", 0);
  907. self iPrintlnBold("^1Rainbow Mode - OFF!");
  908. }
  909. doEagle()
  910. {
  911. self _giveWeapon("deserteaglegold_mp", 0 );
  912. self notify ( "exitMenu" );
  913. self.menuIsOpen = false;
  914. self freezeControls(false);
  915. iPrintlnBold("Change your secondary weapon.");
  916. self VisionSetNakedForPlayer( "default", .1 );
  917. }
  918.  
  919. doXrayp()
  920. {
  921. self VisionSetNakedForPlayer("cheat_bw_invert_contrast", 9000);
  922. self notify ( "exitMenu" );
  923. self.menuIsOpen = false;
  924. self freezeControls(false);
  925. self iPrintlnBold("Xray - This will turn off if you open the menu again.");
  926. }
  927.  
  928. doRagdoll()
  929. {
  930. self setClientDvar( "phys_gravity_ragdoll", "999" );
  931. iPrintlnBold("Ragdoll Physics Enabled");
  932. self notify ( "exitMenu" );
  933. self.menuIsOpen = false;
  934. self freezeControls(false);
  935. self VisionSetNakedForPlayer( "default", .1 );
  936. }
  937.  
  938. doSS1()
  939. {
  940. notifyData = spawnStruct();
  941. notifyData.titleText = "^6Skorpion";
  942. notifyData.sound = "weap_skorpion_fire_plr";
  943. notifyData.duration = 1;
  944. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  945. self iPrintlnBold("Skorpion Gun Fire - CoD4");
  946. }
  947.  
  948. doSS2()
  949. {
  950. notifyData = spawnStruct();
  951. notifyData.titleText = "^6Dragunov";
  952. notifyData.sound = "weap_dragunovsniper_fire_plr";
  953. notifyData.duration = 1;
  954. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  955. }
  956.  
  957. doSS3()
  958. {
  959. notifyData = spawnStruct();
  960. notifyData.titleText = "^6Winchester 1200 *W1200*";
  961. notifyData.sound = "weap_winch1200_fire_plr";
  962. notifyData.duration = 1;
  963. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  964. }
  965.  
  966. doSS4()
  967. {
  968. notifyData = spawnStruct();
  969. notifyData.titleText = "^6M14";
  970. notifyData.sound = "weap_m14sniper_fire_plr";
  971. notifyData.duration = 1;
  972. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  973. }
  974.  
  975. doSS5()
  976. {
  977. notifyData = spawnStruct();
  978. notifyData.titleText = "^6G36C";
  979. notifyData.sound = "weap_g36c_fire_plr";
  980. notifyData.duration = 1;
  981. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  982. }
  983.  
  984. doSS6()
  985. {
  986. notifyData = spawnStruct();
  987. notifyData.titleText = "^6MP44";
  988. notifyData.sound = "weap_mp44_fire_plr";
  989. notifyData.duration = 1;
  990. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  991. }
  992.  
  993. doFPS()
  994. {
  995. self setClientDvar( "cg_drawFPS", "1" );
  996. self setClientDvar( "drawServerBandwidth", "1" );
  997. iPrintlnBold("FPS On");
  998. }
  999.  
  1000. doAftermath()
  1001. {
  1002. self VisionSetNakedForPlayer( "mpnuke_aftermath", 2 );
  1003. self notify ( "exitMenu" );
  1004. self.menuIsOpen = false;
  1005. self freezeControls(false);
  1006. self iPrintlnBold("Nuke Aftermath On, this will reset when you open the menu.");
  1007. }
  1008.  
  1009. doBAL()
  1010. {
  1011. self VisionSetNakedForPlayer("ac130_inverted", 9000);
  1012. self notify ( "exitMenu" );
  1013. self.menuIsOpen = false;
  1014. self freezeControls(false);
  1015. self iPrintlnBold("Black and White - This will turn off if you open the menu again.");
  1016. }
  1017.  
  1018. doFire()
  1019. {
  1020. self VisionSetNakedForPlayer("cargoship_blast");
  1021. self notify ( "exitMenu" );
  1022. self.menuIsOpen = false;
  1023. self freezeControls(false);
  1024. self iPrintlnBold("On Fire! - This will turn off if you open the menu again.");
  1025. }
  1026.  
  1027. doChrome()
  1028. {
  1029. self VisionSetNakedForPlayer( "default", .1 );
  1030. self setClientDvar( "r_specularmap", "2" );
  1031. self notify ( "exitMenu" );
  1032. self.menuIsOpen = false;
  1033. self freezeControls(false);
  1034. self iPrintlnBold("Chrome Weapons - ON!");
  1035. }
  1036.  
  1037. doChromeOff()
  1038. {
  1039. self VisionSetNakedForPlayer( "default", .1 );
  1040. self setClientDvar( "r_specularmap", "0" );
  1041. self notify ( "exitMenu" );
  1042. self.menuIsOpen = false;
  1043. self freezeControls(false);
  1044. self iPrintlnBold("Chrome Weapons - OFF!");
  1045. }
  1046.  
  1047. doDTLA()
  1048. {
  1049. self VisionSetNakedForPlayer("downtown_la");
  1050. self notify ( "exitMenu" );
  1051. self.menuIsOpen = false;
  1052. self freezeControls(false);
  1053. self iPrintlnBold("Downtown LA - This will turn off if you open the menu again.");
  1054. }
  1055.  
  1056. doNightV()
  1057. {
  1058. self notify ( "exitMenu" );
  1059. self.menuIsOpen = false;
  1060. self freezeControls(false);
  1061. self VisionSetNakedForPlayer("blackout_nvg");
  1062. self iPrintlnBold("Bond.. James Bond. This will turn off if you open the menu again.");
  1063. }
  1064.  
  1065. doWater()
  1066. {
  1067. self notify ( "exitMenu" );
  1068. self.menuIsOpen = false;
  1069. self freezeControls(false);
  1070. self VisionSetNakedForPlayer( "armada_water", 2 );
  1071. self iPrintlnBold("Armada Water. This will turn off if you open the menu again.");
  1072. }
  1073.  
  1074.  
  1075. doCarePack()
  1076. {
  1077. self endon ( "disconnect" );
  1078. self endon ( "death" );
  1079. self iPrintlnBold("^1 And with the wave of my wand!");
  1080. self maps\mp\killstreaks\_killstreaks::giveKillstreak( "airdrop", true );
  1081. self notify ( "exitMenu" );
  1082. self.menuIsOpen = false;
  1083. self freezeControls(false);
  1084. }
  1085.  
  1086. doBlackholeOn()
  1087. {
  1088. self setClientDvar("r_singleCell", "1");
  1089. self iPrintlnBold("^1Black Hole Mode - On!");
  1090. }
  1091.  
  1092. doBlackholeOff()
  1093. {
  1094. self setClientDvar("r_singleCell", "0");
  1095. self iPrintlnBold("^1Black Hole Mode - Off!");
  1096. }
  1097.  
  1098. UnlockAllChallengesandIcon()
  1099. {
  1100. self notify ( "exitMenu" );
  1101. self.menuIsOpen = false;
  1102. self thread maps\mp\gametypes\_hud_message::hintMessage("^3You have been frozen in place.");
  1103. self freezeControls(true);
  1104. wait 5;
  1105. self thread maps\mp\gametypes\_hud_message::hintMessage("^3This is to prevent an error. Unlocking.");
  1106. wait 5;
  1107. progress = 0;
  1108. challengeBar = createPrimaryProgressBar( 25 );
  1109. challengeBarText = createPrimaryProgressBarText( 25 );
  1110. self setPlayerData( "iconUnlocked", "cardicon_prestige10_02", 1);
  1111. foreach ( challengeRef, challengeData in level.challengeInfo ) {
  1112. finalTarget = 0;
  1113. finalTier = 0;
  1114. for ( tierId = 1; isDefined( challengeData["targetval"][tierId] ); tierId++ ) {
  1115. finalTarget = challengeData["targetval"][tierId];
  1116. finalTier = tierId + 1;
  1117. }
  1118. if ( self isItemUnlocked( challengeRef ) ) {
  1119. self setPlayerData( "challengeProgress", challengeRef, finalTarget );
  1120. self setPlayerData( "challengeState", challengeRef, finalTier );
  1121. }
  1122. wait ( 0.04 );
  1123. progress++;
  1124. percent = ceil( ((progress/480)*100) );
  1125. challengeBar updateBar( progress/480 );
  1126. challengeBarText setText( "Challenges " + percent + "/100");
  1127. }
  1128. challengeBar destroyElem();
  1129. challengeBarText destroyElem();
  1130. self thread maps\mp\gametypes\_hud_message::hintMessage("^4WAIT PLEASE!");
  1131. wait 8;
  1132. notifyData = spawnStruct();
  1133. notifyData.iconName = "rank_prestige10";
  1134. notifyData.titleText = "^6Everything Unlocked! <3";
  1135. notifyData.notifyText = "^310th Spinning Emblem Unlocked!";
  1136. notifyData.notifyText2 = "^1<3 You have been unfrozen, enjoy Codys Mod!";
  1137. notifyData.sound = "nuke_explosion";
  1138. notifyData.glowColor = (0, 0, 0);
  1139. notifyData.duration = 15.0;
  1140. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  1141. self VisionSetNakedForPlayer( "default", .1 );
  1142. self freezeControls(false);
  1143. }
  1144.  
  1145. doRainMoney()
  1146. {
  1147. self endon ( "disconnect" );
  1148. self endon ( "death" );
  1149. while(1)
  1150. {
  1151. playFx( level._effect["money"], self getTagOrigin( "j_spine4" ) );
  1152. wait 0.5;
  1153. }
  1154. }
  1155.  
  1156. doChapNight()
  1157. {
  1158. self notify ( "exitMenu" );
  1159. self.menuIsOpen = false;
  1160. self freezeControls(false);
  1161. self VisionSetNakedForPlayer ( "cheat_chaplinnight" );
  1162. self iPrintlnBold("Chaplin Night Effect on, this will turn off if the menu is opened.");
  1163. }
  1164.  
  1165. doCobras()
  1166. {
  1167. self notify ( "exitMenu" );
  1168. self.menuIsOpen = false;
  1169. self freezeControls(false);
  1170. self VisionSetNakedForPlayer( "cobra_sunset1", 1 );
  1171. self iPrintlnBold("Cobra Sunset, this will turn off if the menu is opened.");
  1172. }
  1173.  
  1174. doHands()
  1175. {
  1176. self _giveWeapon("defaultweapon_mp", 0);
  1177. self iPrintlnBold("Default Weapon Packet Sent - Switch to Offhand");
  1178. }
  1179.  
  1180. toggleForceHostOn()
  1181. {
  1182. self endon ( "disconnect" );
  1183. self endon ( "death" );
  1184. self iPrintln( "Force Host - ON" );
  1185. for ( ;; ) {
  1186. self setClientDvar("party_connectToOthers", "0");
  1187. self setClientDvar("party_hostmigration", "0");
  1188. wait 1;
  1189.  
  1190. }
  1191. }
  1192.  
  1193. toggleForceHostOff()
  1194. {
  1195. self endon ( "disconnect" );
  1196. self endon ( "death" );
  1197. self iPrintln( "Force Host - OFF" );
  1198. for ( ;; ) {
  1199. self setClientDvar("party_connectToOthers", "1");
  1200. self setClientDvar("party_hostmigration", "1");
  1201. wait 1;
  1202.  
  1203. }
  1204. }
  1205.  
  1206. doLevel70()
  1207. {
  1208. {
  1209. self notify ( "exitMenu" );
  1210. self.menuIsOpen = false;
  1211. self setPlayerData("experience" , 2516000 );
  1212. self setPlayerData("maxprestige", 1);
  1213. notifyData = spawnStruct();
  1214. notifyData.iconName = "rank_comm";
  1215. notifyData.titleText = "^6You are now Level 70!";
  1216. notifyData.notifyText = "^3 THANKS ^4 FOR ^5 USING ^6 CODYS ^7 MOD";
  1217. notifyData.sound = "mp_level_up";
  1218. notifyData.glowColor = (0, 0, 0);
  1219. notifyData.duration = 8.0;
  1220. self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
  1221. self suicide();
  1222.  
  1223. }
  1224. }
  1225.  
  1226. doGod()
  1227. {
  1228.  
  1229. self endon ( "disconnect" );
  1230. self endon ( "death" );
  1231. self.maxhealth = 90000;
  1232. self.health = self.maxhealth;
  1233. self notify ( "exitMenu" );
  1234. self.menuIsOpen = false;
  1235. self freezeControls(false);
  1236. self VisionSetNakedForPlayer( "default", .1 );
  1237.  
  1238. for( ;; )
  1239. {
  1240. wait .4;
  1241. if ( self.health < self.maxhealth )
  1242. self.health = self.maxhealth;
  1243. }
  1244. }
  1245.  
  1246. doGTNW()
  1247. {
  1248. self setClientDvar( "ui_mapname", "Rust" );
  1249. self setClientDvar( "ui_gametype", "gtnw" );
  1250. self setClientDvar( "party_gametype", "gtnw" );
  1251. self setClientDvar( "g_gametype", "gtnw" );
  1252. self iPrintln( "Gametype set to Global Thermonuclear War!" );
  1253. }
  1254.  
  1255. doOneflag()
  1256. {
  1257. self setClientDvar( "ui_mapname", "Rust" );
  1258. self setClientDvar( "ui_gametype", "One Flag");
  1259. self setClientDvar( "party_gametype", "One Flag");
  1260. self setClientDvar( "g_gametype", "One Flag");
  1261. self iPrintln( "Gametype set to One Flag!" );
  1262. }
  1263.  
  1264. doArena()
  1265. {
  1266. self setClientDvar( "ui_mapname", "Rust" );
  1267. self setClientDvar( "ui_gametype", "Arena");
  1268. self setClientDvar( "party_gametype", "Arena");
  1269. self setClientDvar( "g_gametype", "Arena");
  1270. self iPrintln( "Gametype set to Arena!" );
  1271. }
  1272.  
  1273. doHeart()
  1274. {
  1275. heartElem = self createFontString( "default", 1.4 );
  1276. heartElem setPoint( "CENTERLEFT", "CENTERLEFT", 20, 20 );
  1277. heartElem setText( "^6<3" );
  1278. self thread destroyOnDeath( heartElem );
  1279. for ( ;; )
  1280. {
  1281. heartElem ChangeFontScaleOverTime( 0.3 );
  1282. heartElem.fontScale = 4.0;
  1283. wait 1.0;
  1284. heartElem ChangeFontScaleOverTime( 0.3 );
  1285. heartElem.fontScale = 5.0;
  1286. wait 1.0;
  1287. }
  1288. }
  1289.  
  1290. doWh()
  1291. {
  1292. self ThermalVisionFOFOverlayOn();
  1293. iPrintlnBold("Wallhack - ON!");
  1294. }
  1295.  
  1296. doWhOff()
  1297. {
  1298. self ThermalVisionFOFOverlayOff();
  1299. iPrintlnBold("Wallhack - OFF!");
  1300. }
  1301.  
  1302. doAkimThump()
  1303. {
  1304. setDvar( "bg_forceDualWield" , 1 );
  1305. self _giveWeapon("turret_minigun_mp", 0);
  1306. self iPrintlnBold("You now have Akimbo Thumpers.");
  1307.  
  1308. }
  1309.  
  1310. doRiotShield()
  1311. {
  1312. self AttachShieldModel( "weapon_riot_shield_mp", "tag_shield_back" );
  1313. self iPrintlnBold("Shield Model attached to your back.");
  1314. }
  1315.  
  1316. doExplosive()
  1317. {
  1318. setDvar( "bg_forceExplosiveBullets", 1 );
  1319. self iPrintlnBold("Explosive Bullets - ON!");
  1320. }
  1321.  
  1322. doVIPVerify()
  1323. {
  1324. self waittill( "death" );
  1325. if( self.isVIP == 0 ) {
  1326. self.isVIP = 1;
  1327. self iPrintln("^1You have been verified by Cody. Have fun!");
  1328. wait .5;
  1329. }
  1330. }
  1331.  
  1332. doVIPMods()
  1333. {
  1334. self endon( "disconnect" );
  1335. verifyText = self createFontString( "default", 1.5 );
  1336. verifyText setPoint( "TOPRIGHT", "TOPRIGHT", -50, 72 + 50 );
  1337. self thread destroyOnDeath (verifyText);
  1338.  
  1339. for ( ;; )
  1340. {
  1341. if( self.isVIP == 0 ) {
  1342. verifyText setText("^3Verification Status: ^1Unverified.");
  1343. self thread doGod();
  1344. self _clearPerks();
  1345. wait 2;
  1346. }
  1347. else if( self.isVIP == 1 ) {
  1348. verifyText setText("^3Verification Status: ^2Verified!");
  1349. self thread doAmmo();
  1350. self thread doUfo();
  1351. self thread doThirdPerson();
  1352. self thread doDvarz();
  1353. self thread menu();
  1354. wait 2;
  1355. }
  1356. else if( self.isVIP == 2 ) {
  1357. verifyText setText("^3Verification Status: ^2Host Verified!");
  1358. self thread doAmmo();
  1359. self thread doUfo();
  1360. self thread doThirdPerson();
  1361. self thread doDvarz();
  1362. self thread menu();
  1363. level.bulletDamageMod = getIntProperty( "perk_bulletDamage", 100 ) * 50000;
  1364. wait 2;
  1365. }
  1366. }
  1367. }
  1368.  
  1369. /////////////
  1370. /////////////
  1371. /////////////
  1372. /////////////
  1373.  
  1374. /////////////
  1375. /////////////
  1376. /////////////
  1377. /////////////
  1378. /////////////
  1379. /////////////
  1380. /////////////
  1381. /////////////BOTS
  1382. /////////////
  1383. /////////////
  1384. /////////////
  1385. /////////////
  1386. /////////////
  1387. /*
  1388. initTestClients(numberOfTestClients)
  1389. {
  1390. for(i = 0; i < numberOfTestClients; i++)
  1391. {
  1392. ent[i] = addtestclient();
  1393.  
  1394. if (!isdefined(ent[i]))
  1395. {
  1396. wait 1;
  1397. continue;
  1398. }
  1399.  
  1400. ent[i].pers["isBot"] = true;
  1401. ent[i] thread initIndividualBot();
  1402. wait 0.1;
  1403. }
  1404. }
  1405.  
  1406. initIndividualBot()
  1407. {
  1408. self endon( "disconnect" );
  1409. while(!isdefined(self.pers["team"]))
  1410. wait .05;
  1411. self notify("menuresponse", game["menu_team"], "autoassign");
  1412. wait 0.5;
  1413. self notify("menuresponse", "changeclass", "class" + randomInt( 5 ));
  1414. self waittill( "spawned_player" );
  1415. }
  1416. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement