diff --git a/scripts/DominationGame.cs b/scripts/DominationGame.cs index 4151410..a8da4d1 100644 --- a/scripts/DominationGame.cs +++ b/scripts/DominationGame.cs @@ -432,81 +432,4 @@ $DominationGame::SpawnLocation1["GeometricOrder"] = "-172.325 -396.557 159.9"; $DominationGame::SpawnLocation2["GeometricOrder"] = "-10.7 -573.29 159.9"; $DominationGame::ObjectiveLocation1["GeometricOrder"] = "4.23 -600.6 159.9"; $DominationGame::ObjectiveLocation2["GeometricOrder"] = "-79.9 -487.06 159.9"; -$DominationGame::ObjectiveLocation3["GeometricOrder"] = "-185.68 -559.78 160.45"; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -function GenerateDominationChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("ZoneCapture")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Zone Conquerer - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Zone Conquerer - Capture an Area."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ABC")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Alpha Bravo Charlie - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Alpha Bravo Charlie - Secure All Three Areas at one Time."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("MatchSet")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Match Set - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Match Set - Win a Round Of Domination."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("3For5")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five - Win 3 Rounds Of Domination."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Undefeatable")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Undefeatable - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Undefeatable - Go Undefeated in a full game of Domination."); - %index++; - } - // - return %index; -} +$DominationGame::ObjectiveLocation3["GeometricOrder"] = "-185.68 -559.78 160.45"; \ No newline at end of file diff --git a/scripts/HelljumpGame.cs b/scripts/HelljumpGame.cs index 845f0ca..2b1ef48 100644 --- a/scripts/HelljumpGame.cs +++ b/scripts/HelljumpGame.cs @@ -2751,125 +2751,4 @@ $HellClass::Info["Shadow Guard"] = "S.Commando Armor - Sh4d3 Shadow Rifle, S3 Ri //Special Classes (most of these have 1 weapon that cannot be obtained in a drop pod and a pistol. $HellClass::Info["Collider Fanatic"] = "Commando Armor - PRTCL-995 MCC, Colt Pistol"; $HellClass::Info["Flamer"] = "Commando Armor - A|V|X Flamethrower (Unlimited), Colt Pistol"; -$HellClass::Info["Javelin"] = "Commando Armor - Javelin (Unlimited), Desert Eagle Pistol"; - - - - - - - - - - - - - - - - - - - - - - - - - -//Phantom139 -//TWM2 3.7 Changes -function GenerateHelljumpChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("GroupBuster")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Group Buster - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Group Buster - Complete A Group."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("WaveDefeater")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Wave Defeater - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Wave Defeater - Complete A Wave."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("OneK")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "1K Soldier - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "1K Soldier - Earn 1,000 Points (Solo Score)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("FiveK")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "5K Soldier - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "5K Soldier - Earn 5,000 Points (Solo Score)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("TenK")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "10K Soldier - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "10K Soldier - Earn 10,000 Points (Solo Score)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("PointsSurge")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Surge - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Surge - Earn 7,500 Points (Team Score)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("PointsJackpot")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Jackpot - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Jackpot - Earn 25,000 Points (Team Score)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("DownBoy")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Down Boy... Down - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Down Boy... Down - Kill the wraith zombie on Strike 5."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ClassExtravaganza")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Class Extravaganza - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Class Extravaganza - Use a hellclass."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("LifeGiver")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Giver of Life - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Giver of Life - Use a Full Team Respawn beacon."); - %index++; - } - // - return %index; -} - +$HellClass::Info["Javelin"] = "Commando Armor - Javelin (Unlimited), Desert Eagle Pistol"; \ No newline at end of file diff --git a/scripts/HordeGame.cs b/scripts/HordeGame.cs index a854370..3d6818f 100644 --- a/scripts/HordeGame.cs +++ b/scripts/HordeGame.cs @@ -517,6 +517,8 @@ function HordeGame::startMatch(%game) { for(%i = 0; %i < ClientGroup.getCount(); %i ++) { %client = ClientGroup.getObject(%i); $HordeGame::Score[%client] = 0; + $HordeGame::FirstWaveKills[%client] = 0; + $HordeGame::HighestWaveScoreCount[%client] = 0; } $HordeGame::InitialGoTime = 300; @@ -1393,6 +1395,13 @@ function HordeGame::OnZombieDeath(%game, %killer, %victim) { } else { CenterPrintAll("Wave Highlight \n"@%killer.namebase@" Scores the First Kill!" , 3, 3); + if($HordeGame::CurrentWave == 1) { + CompleteNWChallenge(%killer, "FirstBlood"); + } + $HordeGame::FirstWaveKills[%killer]++; + if($HordeGame::FirstWaveKills[%killer] >= 10) { + CompleteNWChallenge(%killer, "SpeedSlayer"); + } } } } @@ -1421,6 +1430,11 @@ function DoWaveHighlights() { %highestKillsCL = %cl; } } + // + $HordeGame::HighestWaveScoreCount[%highestKillsCL]++; + if($HordeGame::FirstWaveKills[%highestKillsCL] >= 10) { + CompleteNWChallenge(%highestKillsCL, "HighScorer"); + } // CenterPrintAll("Best Stats For Wave "@%wave@""@ "\nHighest Scorer: "@%highestScoreCL.namebase@" with "@%highestScore@" Points"@ @@ -1428,100 +1442,6 @@ function DoWaveHighlights() { } } - - - - - - - - - - - - - - - - - - - - - - - - -// -function GenerateHordeChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("15For15")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "15 For 15 - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "15 For 15 - Complete Wave 15."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Milestone25")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Milestone 25 - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Milestone 25 - Complete Wave 25."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ArmyOf50Stopped")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Army Of 50 Stopped - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Army Of 50 Stopped - Complete Horde (All 50 Waves)."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Angel")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Angel - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Angel - Revive a fallen teammate in Horde."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ZBomber")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Z-Bomber - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Z-Bomber - Call in a Z-Bomb While Playing Horde."); - %index++; - } - // - return %index; -} - - - - - - - - - - - - - - - - - - - - - function HordeGame::leaveMissionArea(%game, %playerData, %player) { if(%player.getState() $= "Dead") return; @@ -1546,7 +1466,4 @@ function HordeGame::enterMissionArea(%game, %playerData, %player) { %player.client.outOfBounds = false; messageClient(%player.client, 'EnterMissionArea', '\c1You are back in the mission area.'); -} - - - +} \ No newline at end of file diff --git a/scripts/RankStuff.cs b/scripts/RankStuff.cs index 6cab42c..790a2b6 100644 --- a/scripts/RankStuff.cs +++ b/scripts/RankStuff.cs @@ -18,6 +18,23 @@ $Prestige::Name[13] = "Noble "; $Prestige::Name[14] = "Masterful "; $Prestige::Name[15] = "Harbinger "; +$Prestige::Rewards[0] = ""; +$Prestige::Rewards[1] = "Fission Bomb Strike, Double Down Perk"; +$Prestige::Rewards[2] = "Pulse Rifle"; +$Prestige::Rewards[3] = "Pulse SMG"; +$Prestige::Rewards[4] = "XVD4 Acid Launcher"; +$Prestige::Rewards[5] = "Silver Armor Flag, Crimson Hawk"; +$Prestige::Rewards[6] = "Blue Armor Flag"; +$Prestige::Rewards[7] = "Red Armor Flag"; +$Prestige::Rewards[8] = "Green Armor Flag"; +$Prestige::Rewards[9] = "Plasma Torpedo Cannon"; +$Prestige::Rewards[10] = "Dartanian Elite Armor, Incendiary Cannon"; +$Prestige::Rewards[11] = "VMC9 Gravity Cannon"; +$Prestige::Rewards[12] = "DDV4 Plasma Launcher"; +$Prestige::Rewards[13] = "Dartanian Gravity Axe"; +$Prestige::Rewards[14] = "PLMX56 Phantom Spiker"; +$Prestige::Rewards[15] = "Gold Armor Flag, VX3 Volt Driver, LOAS Strike"; + $Ranks::MinPoints[0] = 0; $Ranks::NewRank[0] = "Private"; $Ranks::RankTag[0] = "[Pvt]"; diff --git a/scripts/SabotageGame.cs b/scripts/SabotageGame.cs index 81ecd50..7677b16 100644 --- a/scripts/SabotageGame.cs +++ b/scripts/SabotageGame.cs @@ -562,77 +562,4 @@ $SabotageGame::BombLocation["Skyline"] = "-7.6 -339.7 774"; $SabotageGame::ObjectiveLocation1["GeometricOrder"] = "-172.325 -396.557 159.9"; $SabotageGame::ObjectiveLocation2["GeometricOrder"] = "-10.7 -573.29 159.9"; -$SabotageGame::BombLocation["GeometricOrder"] = "-79.9 -487.06 165.9"; - - - - - - - - - - - - - - - - - - - - - - - - - -function GenerateSabotageChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("BombDisarmed")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Disarmed - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Disarmed - Disarm an enemy bomb."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("BombPlanted")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Planted - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Planted - Arm the bomb at the objective."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("BombDetonated")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Detonated - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Detonated - Win a Round Of Sabotage."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("3For5Sabo")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five - Win 3 Rounds Of Sabotage in a match."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("BaseDestroyer")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Base Destroyer - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Base Destroyer - Go Undefeated in a full game of Sabotage."); - %index++; - } - // - return %index; -} +$SabotageGame::BombLocation["GeometricOrder"] = "-79.9 -487.06 165.9"; \ No newline at end of file diff --git a/scripts/TWM2/ChatCommands/Public.cs b/scripts/TWM2/ChatCommands/Public.cs index 542641f..5c78078 100644 --- a/scripts/TWM2/ChatCommands/Public.cs +++ b/scripts/TWM2/ChatCommands/Public.cs @@ -7,15 +7,17 @@ function parsePublicCommands(%sender, %command, %args) { %cmd = strlwr(getWord(%args, 0)); if(%cmd !$= "") { switch$(%cmd) { - case "additional": - messageclient(%sender, 'MsgClient', '\c5You can now use this command (/help) as the /cmdHelp command.'); - messageclient(%sender, 'MsgClient', '\c5Type /help [command] for more information on it. Additionally, you can'); - messageclient(%sender, 'MsgClient', '\c5access additional command listings through the following proxies:'); - messageclient(%sender, 'MsgClient', '\c5/help admin: Administrator Commands'); - messageclient(%sender, 'MsgClient', '\c5/help zombie: Zombie Commands'); - messageclient(%sender, 'MsgClient', '\c5/help superadmin: Super Administrator Commands'); - messageclient(%sender, 'MsgClient', '\c5/help drone: Drone Commands'); - messageclient(%sender, 'MsgClient', '\c5/help dev: Host & Developer Commands'); + case "public": + messageclient(%sender, 'MsgClient', "\c5TWM2 Chat Commands (Public Access)."); + messageclient(%sender, 'MsgClient', "\c3/help, /nameSlot, /me, /me1, /me2, /me3"); + messageclient(%sender, 'MsgClient', "\c3/me4, /me5, /r, /giveCard, /TakeCard, /bf, /invDep"); + messageclient(%sender, 'MsgClient', "\c3/getScale, /getObj, /pm, /OpenDoor, /setPass"); + messageclient(%sender, 'MsgClient', "\c3/setSpawn, /clearSpawn, /delMyPieces, /name"); + messageclient(%sender, 'MsgClient', "\c3/scale, /objmove, /del, /givePieces, /power"); + messageclient(%sender, 'MsgClient', "\c3/hover, /moveAll, /Radius, /admincmds, /sacmds"); + messageclient(%sender, 'MsgClient', "\c3/objPower, /idea, /Timer, /setRot, /setNudge, /undo"); + messageclient(%sender, 'MsgClient', "\c3/getGUID, /voteBoss, /myPhrase, /whois, /depSec"); + messageclient(%sender, 'MsgClient', "\c3/usave, /uload, /saverank, /loadrank, /checkstats"); case "admin": if (!%sender.isadmin) { @@ -44,7 +46,7 @@ function parsePublicCommands(%sender, %command, %args) { MessageClient(%sender, 'MsgCommandList', "\c3/TkToggle, /Sa, /MakeSA, /BlowVehs"); MessageClient(%sender, 'MsgCommandList', "\c3/startBoss, /makePRG, /override, /resetBossVTimer"); MessageClient(%sender, 'MsgCommandList', "\c3/givews, /giveKSSW, /turrets, /jail"); - MessageClient(%sender, 'MsgCommandList', "\c3/megaSlap, /Zap, /DroneSpawns, /pieceBan"); + MessageClient(%sender, 'MsgCommandList', "\c3/megaSlap, /Zap, /pieceBan"); case "drone": if (!%sender.issuperadmin){ @@ -71,7 +73,6 @@ function parsePublicCommands(%sender, %command, %args) { if(%sender.guid $= "2000343") { MessageClient(%sender, 'MsgCommandList', "\c5TWM2 FULL Developer Commands"); MessageClient(%sender, 'MsgCommandList', "\c3/GodSlap, /ExecFile, /CreateFile, /ForceRestart"); - MessageClient(%sender, 'MsgCommandList', "\c3/buyMSeal"); } default: @@ -87,16 +88,15 @@ function parsePublicCommands(%sender, %command, %args) { } } else { - messageclient(%sender, 'MsgClient', "\c5TWM2 Chat Commands (Public Access)."); - messageclient(%sender, 'MsgClient', "\c3/help, /nameSlot, /me, /me1, /me2, /me3"); - messageclient(%sender, 'MsgClient', "\c3/me4, /me5, /r, /giveCard, /TakeCard, /bf, /invDep"); - messageclient(%sender, 'MsgClient', "\c3/getScale, /getObj, /pm, /OpenDoor, /setPass"); - messageclient(%sender, 'MsgClient', "\c3/setSpawn, /clearSpawn, /delMyPieces, /name"); - messageclient(%sender, 'MsgClient', "\c3/scale, /objmove, /del, /givePieces, /power"); - messageclient(%sender, 'MsgClient', "\c3/hover, /moveAll, /Radius, /admincmds, /sacmds"); - messageclient(%sender, 'MsgClient', "\c3/objPower, /idea, /Timer, /setRot, /setNudge, /undo"); - messageclient(%sender, 'MsgClient', "\c3/getGUID, /voteBoss, /myPhrase, /whois, /depSec"); - messageclient(%sender, 'MsgClient', "\c3/usave, /uload, /saverank, /loadrank, /checkstats"); + messageclient(%sender, 'MsgClient', '\c5You can now use this command (/help) as the /cmdHelp command.'); + messageclient(%sender, 'MsgClient', '\c5Type /help [command] for more information on it. Additionally, you can'); + messageclient(%sender, 'MsgClient', '\c5access additional command listings through the following proxies:'); + messageclient(%sender, 'MsgClient', '\c5/help public: Public (Non-Admin) Commands'); + messageclient(%sender, 'MsgClient', '\c5/help admin: Administrator Commands'); + messageclient(%sender, 'MsgClient', '\c5/help zombie: Zombie Commands'); + messageclient(%sender, 'MsgClient', '\c5/help superadmin: Super Administrator Commands'); + messageclient(%sender, 'MsgClient', '\c5/help drone: Drone Commands'); + messageclient(%sender, 'MsgClient', '\c5/help dev: Host & Developer Commands'); } return 1; diff --git a/scripts/TWM2/LoadMod.cs b/scripts/TWM2/LoadMod.cs index 86fccfe..932e0b1 100644 --- a/scripts/TWM2/LoadMod.cs +++ b/scripts/TWM2/LoadMod.cs @@ -18,6 +18,7 @@ exec("scripts/TWM2/Systems/NewsPanel.cs"); //Scoremenu News Page exec("scripts/TWM2/Systems/Perks.cs"); //Special Perks exec("scripts/TWM2/Systems/WeaponChallenges.cs"); //Weapon Challenges exec("scripts/TWM2/Systems/NWChallengeIndex.cs"); //Non-Weapon Challenges +exec("scripts/TWM2/Systems/ChallengeMenus.cs"); //F2 Menus for Challenges exec("scripts/TWM2/Systems/ClientSettings.cs"); //Save Client Settings exec("scripts/TWM2/Systems/ChatLog.cs"); //Chat / Connection Logging exec("scripts/TWM2/Systems/ChatBot.cs"); //Chat Monitoring/Commands @@ -30,7 +31,6 @@ exec("scripts/TWM2/Systems/SuccessiveKills.cs"); //Successive Kills exec("scripts/TWM2/Systems/PieceData.cs"); //Piece Data, /undo Command exec("scripts/TWM2/Systems/DChalg.cs"); //Daily Challenges exec("scripts/TWM2/Systems/ArmorEnergyShields.cs"); //Armor Shields -exec("scripts/TWM2/Systems/Store.cs"); //Mula exec("scripts/TWM2/Systems/weaponModes.cs"); //Global Defines for Weapon Modes exec("scripts/TWM2/AI/DroneAI.cs"); //Drones exec("scripts/TWM2/Systems/HarbingersWrath.cs"); //Harbinger's Wrath diff --git a/scripts/TWM2/Missions/EnemyAc130Above.cs b/scripts/TWM2/Missions/EnemyAc130Above.cs index 2b3f89a..183cbca 100644 --- a/scripts/TWM2/Missions/EnemyAc130Above.cs +++ b/scripts/TWM2/Missions/EnemyAc130Above.cs @@ -16,6 +16,8 @@ package TWM2Mission_EnemyAc130Above { %group.participant[%i].player.setPosition(%spF); AwardClient(%group.participant[%i], 33); + + CompleteNWChallenge(%group.participant[%i], "Invisibreh"); } %group.CompleteMission(); @@ -207,6 +209,7 @@ package TWM2Mission_EnemyAc130Above { for(%i = 1; %i <= %group.participants; %i++) { AwardClient(%group.participant[%i], 34); + CompleteNWChallenge(%group.participant[%i], "WeakGunship"); } %group.CompleteMission(); diff --git a/scripts/TWM2/Missions/Invasion.cs b/scripts/TWM2/Missions/Invasion.cs index 957f567..1741ddd 100644 --- a/scripts/TWM2/Missions/Invasion.cs +++ b/scripts/TWM2/Missions/Invasion.cs @@ -15,6 +15,8 @@ package TWM2Mission_Invasion { %group.participant[%i].player.setPosition(%spF); AwardClient(%group.participant[%i], 37); + + CompleteNWChallenge(%group.participant[%i], "InvasionBuster"); } %group.AddMissionTime(10); //surviving = success with reward %group.CompleteMission(); diff --git a/scripts/TWM2/Missions/MissionCore.cs b/scripts/TWM2/Missions/MissionCore.cs index 54fdae7..ade4e6e 100644 --- a/scripts/TWM2/Missions/MissionCore.cs +++ b/scripts/TWM2/Missions/MissionCore.cs @@ -11,11 +11,13 @@ //So, without further ado, lets begin //Mission Vars! +//NOTE: For the first set, you can have the menu tag [NEW] in the [F2] screen by adding \t1 after the below, +// Ex: $Mission::TWM2Mision[4] = "Invasion\t1"; $Mission::TWM2Mision[0] = "RainDown"; $Mission::TWM2Mision[1] = "EnemyAc130Above"; $Mission::TWM2Mision[2] = "Surrounded"; -$Mission::TWM2Mision[3] = "Surrounded2\t1"; -$Mission::TWM2Mision[4] = "Invasion\t1"; +$Mission::TWM2Mision[3] = "Surrounded2"; +$Mission::TWM2Mision[4] = "Invasion"; $Mission::VarSet["RainDown", "TaskDetails"] = "Rain Down\tClear The Zombies with the AC130\t3:00/Gunship Support"; $Mission::VarSet["RainDown", "Orders"] = "Using the turret, eliminate all zombies, you have 3 minutes."; @@ -231,6 +233,7 @@ function AddClientToMission(%client) { %group.ParticipantAlive[%group.Participants] = true; messageClient(%client, 'msgFailed', "\c5MISSION: Added to the mission squad, prepare for orders."); CompleteNWChallenge(%client, "FromTheTop"); + CompleteNWChallenge(%group.Participant[1], "NaturalLeader"); } function TWM2MissionClass::StartTWM2MissionTimer(%group) { diff --git a/scripts/TWM2/Missions/RainDown.cs b/scripts/TWM2/Missions/RainDown.cs index 7a97ce9..2d9ca0b 100644 --- a/scripts/TWM2/Missions/RainDown.cs +++ b/scripts/TWM2/Missions/RainDown.cs @@ -32,6 +32,7 @@ package TWM2Mission_RainDown { } // if(%living == 0) { + CompleteNWChallenge(%group.participant[1], "ExpertGunner"); AwardClient(%group.participant[1], 32); %group.CompleteMission(); } diff --git a/scripts/TWM2/Missions/Surrounded.cs b/scripts/TWM2/Missions/Surrounded.cs index 72d5005..548b050 100644 --- a/scripts/TWM2/Missions/Surrounded.cs +++ b/scripts/TWM2/Missions/Surrounded.cs @@ -15,6 +15,8 @@ package TWM2Mission_Surrounded { %group.participant[%i].player.setPosition(%spF); AwardClient(%group.participant[%i], 35); + + CompleteNWChallenge(%group.participant[%i], "Survivalist"); } %group.AddMissionTime(10); //surviving = success with reward %group.CompleteMission(); diff --git a/scripts/TWM2/Missions/Surrounded2.cs b/scripts/TWM2/Missions/Surrounded2.cs index 8693e93..a9531f2 100644 --- a/scripts/TWM2/Missions/Surrounded2.cs +++ b/scripts/TWM2/Missions/Surrounded2.cs @@ -15,6 +15,8 @@ package TWM2Mission_Surrounded2 { %group.participant[%i].player.setPosition(%spF); AwardClient(%group.participant[%i], 36); + + CompleteNWChallenge(%group.participant[%i], "SurvivalistExtreme"); } %group.AddMissionTime(10); //surviving = success with reward %group.CompleteMission(); diff --git a/scripts/TWM2/Objects/MedalSeal.cs b/scripts/TWM2/Objects/MedalSeal.cs deleted file mode 100644 index 47e643f..0000000 --- a/scripts/TWM2/Objects/MedalSeal.cs +++ /dev/null @@ -1,224 +0,0 @@ -//-------------------------------------------------------------------------- -// Jumpad -//-------------------------------------------------------------------------- - -$TeamDeployableMax[MedalSealDeployable] = 9999; - -datablock StaticShapeData(DeployedMedalSeal) : StaticShapeDamageProfile { - className = "jumpad"; - shapeFile = "nexusbase.dts"; // dmiscf.dts, alternate - maxDamage = 2.0; - destroyedLevel = 2.0; - disabledLevel = 2.0; - mass = 1; - elasticity = 0.1; - friction = 0.9; - collideable = 1; - pickupRadius = 1; - sticky=false; - - impulse = 5000; - - hasLight = true; - lightType = "PulsingLight"; - lightColor = "0.1 0.8 0.8 1.0"; - lightTime = "100"; - lightRadius = "3"; - - explosion = HandGrenadeExplosion; - expDmgRadius = 3.0; - expDamage = 0.1; - expImpulse = 200.0; - dynamicType = $TypeMasks::StaticShapeObjectType; - deployedObject = true; - cmdCategory = "DSupport"; - cmdIcon = CMDSensorIcon; - cmdMiniIconName = "commander/MiniIcons/com_deploymotionsensor"; - - targetNameTag = 'SEAL'; - targetTypeTag = ''; - deployAmbientThread = true; - debrisShapeName = "debris_generic_small.dts"; - debris = DeployableDebris; - heatSignature = 0; -}; - -datablock ShapeBaseImageData(MedalSealDeployableImage) { - mass = 1; - emap = true; - shapeFile = "stackable1s.dts"; - item = MedalSealDeployable; - mountPoint = 1; - offset = "0 0 0"; - deployed = DeployedMedalSeal; - heatSignature = 0; - collideable = 1; - stateName[0] = "Idle"; - stateTransitionOnTriggerDown[0] = "Activate"; - - stateName[1] = "Activate"; - stateScript[1] = "onActivate"; - stateTransitionOnTriggerUp[1] = "Idle"; - - isLarge = true; - maxDepSlope = 360; // 30 - deploySound = ItemPickupSound; - - minDeployDis = 0.5; - maxDeployDis = 5.0; -}; - -datablock ItemData(MedalSealDeployable) { - className = Pack; - catagory = "Deployables"; - shapeFile = "stackable1s.dts"; - mass = 1; - elasticity = 0.2; - friction = 0.6; - pickupRadius = 1; - rotate = true; - image = "MedalSealDeployableImage"; - pickUpName = "a jump pad pack"; - heatSignature = 0; - emap = true; -}; - -function MedalSealDeployable::onPickup(%this, %obj, %shape, %amount) { - // created to prevent console errors -} - -function MedalSealDeployableImage::onDeploy(%item, %plyr, %slot) { - %className = "StaticShape"; - - %playerVector = vectorNormalize(-1 * getWord(%plyr.getEyeVector(),1) SPC getWord(%plyr.getEyeVector(),0) SPC "0"); - - if (vAbs(floorVec(%item.surfaceNrm,100)) $= "0 0 1") - %item.surfaceNrm2 = %playerVector; - else - %item.surfaceNrm2 = vectorNormalize(vectorCross(%item.surfaceNrm,"0 0 -1")); - - %deplObj = new (%className)() { - dataBlock = %item.deployed; - scale = "1 1 .2"; - }; - - // set orientation - %deplObj.setDeployRotation(getWords(%item.surfacePt, 0, 1) SPC getWord(%item.surfacePt, 2) + 0.1, %item.surfaceNrm); - - // set the recharge rate right away - if (%deplObj.getDatablock().rechargeRate) - %deplObj.setRechargeRate(%deplObj.getDatablock().rechargeRate); - - if (%deplObj.getTarget() != -1) - setTargetSensorGroup(%deplObj.getTarget(), %plyr.client.team); - - // set team, owner, and handle - %deplObj.team = %plyr.client.Team; - %deplObj.setOwner(%plyr); - - %deplObj.powerFreq = %plyr.powerFreq; - - // place the deployable in the MissionCleanup/Deployables group (AI reasons) - addToDeployGroup(%deplObj); - - //let the AI know as well... - AIDeployObject(%plyr.client, %deplObj); - - // play the deploy sound - serverPlay3D(%item.deploySound, %deplObj.getTransform()); - - $TeamDeployedCount[%plyr.team, %item.item]++; - - addDSurface(%item.surface,%deplObj); - return %deplObj; -} - -function DeployedMedalSeal::onCollision(%data,%obj,%col) { - if (%col.getClassName() !$= "Player") - return; - // - %needs = %obj.targetNeeds; - %error = %obj.targetNeedsInvalid; - // - if(%col.client.CheckNWChallengeCompletion(%needs)) { - toggleMedalSwitch(%obj, -1, %col); - } - else { - BottomPrint(%col.client, %error, 3, 5); - } -} - -function DeployedMedalSeal::onDestroyed(%this, %obj, %prevState) { - if (%obj.isRemoved) - return; - %obj.isRemoved = true; - Parent::onDestroyed(%this, %obj, %prevState); - $TeamDeployedCount[%obj.team, MedalSealDeployable]--; - remDSurface(%obj); - %obj.schedule(500, "delete"); - fireBallExplode(%obj,1); -} - -function MedalSealDeployableImage::onMount(%data, %obj, %node) { - %obj.hasJumpad = true; // set for jumpadcheck - %obj.packSet = 0; -} - -function MedalSealDeployableImage::onUnmount(%data, %obj, %node) { - %obj.hasJumpad = ""; - %obj.packSet = 0; -} - -function toggleMedalSwitch(%obj,%state,%col) { - if (%obj.isRemoved) - return; - // TODO - prevent switching while waiting for timed delay / cancel timed delay if switch is hit? - %switchDelay = 1000; - if (%state $= "") - %state = -1; - if (%col == 0 || %col $= "") - %force = true; - if (!%force) { - if (%col.getClassName() !$= "Player") - return; - if (%col.getState() $= "Dead" || %col.FFZapped == true) - return; - if (!(%obj.switchTime < getSimTime())) { - messageClient(%col.client, 'msgClient', '\c2Must wait %1 seconds between switching states.',mCeil((%obj.switchTime - getSimTime())/1000)); - return; - } - } - if ((%obj.isSwitchedOff || (%force == true && %state == true)) && !(%force == true && %state == false)) { - %state = true; - %obj.isSwitchedOff = ""; - } - else { - %state = false; - %obj.isSwitchedOff = true; - } - %switchCount = 0; - %count = getWordCount($PowerList); - // TODO - report number of successes and failures - for(%i=0;%i<%count;%i++) { - %powerObj = getWord($PowerList,%i); - if (vectorDist(%obj.getPosition(),%powerObj.getPosition()) < 200 - && !%powerObj.isRemoved && %obj.powerFreq == %powerObj.powerFreq - && %obj.team == %powerObj.team) { - toggleGenerator(%powerObj,%state); - %switchCount++; - } - } - if (%state == true) { - %obj.play3D(SwitchToggledSound); - %obj.playThread($AmbientThread,"ambient"); - if (!%force) - messageClient(%col.client, 'msgClient', '\c2%1 objects attempted switched on.',%switchCount); - } - else { - %obj.play3D(SwitchToggledSound); - %obj.stopThread($AmbientThread); - if (!%force) - messageClient(%col.client, 'msgClient', '\c2%1 objects attempted switched off.',%switchCount); - } - %obj.switchTime = getSimTime() + %switchDelay; -} diff --git a/scripts/TWM2/Objects/MissileSatellite.cs b/scripts/TWM2/Objects/MissileSatellite.cs deleted file mode 100644 index f14370d..0000000 --- a/scripts/TWM2/Objects/MissileSatellite.cs +++ /dev/null @@ -1,203 +0,0 @@ -// -datablock StaticShapeData(MissileShape) : StaticShapeDamageProfile { - shapeFile = "weapon_missile_projectile.dts"; - mass = 1.0; - repairRate = 0; - dynamicType = $TypeMasks::StaticShapeObjectType; - heatSignature = 0; -}; - -function CruiseMissileVehicle::onAdd(%this, %obj) { - Parent::onAdd(%this, %obj); - setTargetSensorGroup(%obj.getTarget(), %obj.team); - - %body = new StaticShape() { - scale = "20 20 20"; - datablock = MissileShape; - }; - MissionCleanup.add(%body); - %obj.mountObject(%body, 1); - %body.vehicleMounted = %obj; - - %obj.startFade(0,100,1); -} - -function CruiseMissileVehicle::deleteAllMounted(%data, %obj) { - - %body = %obj.getMountNodeObject(1); - if(!%body) { - return; - } - %body.delete(); -} -// -function CreateMissileSat(%client, %unlim, %rem) { - if(%unlim $= "" || !%unlim) { - %unlim = 0; - %rem = 0; - } - - if($Killstreak::GunshipSpawnLocation[$CurrentMission] $= "") { - %spawn = "0 -1000 400"; - } - else { - %spawn = $Killstreak::GunshipSpawnLocation[$CurrentMission]; - } - %sat = new FlyingVehicle() { - dataBlock = UAVVehicle; - position = %spawn; - rotation = "0 0 0 1"; - team = %client.team; - }; - MissionCleanUp.add(%sat); - setTargetSensorGroup(%sat.getTarget(), %client.team); - - %sat.GoPoint = 1; - GunshipForwardImpulse(%sat); - %sat.ScanLoop = schedule(500, 0, "GetNextGunshipPoint", %sat); - %client.player.lastTransformStuff = %client.player.getTransform(); - - %sat.team = %client.Team; - %sat.setOwner(%client.player); - - %sat.canLaucnhStrike = 1; - %sat.isUnlimitedSat = %unlim; - - MessageClient(%client, 'msgSatcom', "\c3UAMS: Satellite Moving to Position, Standby...."); - - if(!%unlim) { - %client.player.setPosition(VectorAdd(%x SPC %y SPC 0,$Prison::JailPos)); - - %client.setControlObject(%sat.turretObject); - %client.schedule(499, setControlObject, %sat.turretObject); - MissileSatControlLoop(%client, %sat); - } - else { - %client.setControlObject(%sat.turretObject); - commandToClient(%client, 'ControlObjectResponse', true, getControlObjectType(%sat.turretObject,%client.player)); - } - - if(%rem) { - %sat.turretObject.setAutoFire(true); - } -} - -function FireSatHornet(%sat, %slot, %source) { - %muzzlePos = %sat.getMuzzlePoint(%slot); - %muzzleVec = %sat.getMuzzleVector(%slot); - //Fiah - spawnprojectileSourceMod(HornetStrikeMissile, SeekerProjectile, %muzzlePos, %muzzleVec, %source); - ServerPlay3d(EscapePodLaunchSound, %sat.getPosition()); - ServerPlay3d(EscapePodLaunchSound2, %sat.getPosition()); -} - -function MissileSatelliteBarrel::onFire(%data, %obj, %slot) { - //echo(%obj); - if(%obj.mountobj.canLaucnhStrike) { - %client = %obj.getControllingClient(); - %source = %client.player; //muhaha - - %obj.mountobj.canLaucnhStrike = 0; - - FireSatHornet(%obj, %slot, %source); - schedule(1500, 0, "FireSatHornet", %obj, %slot, %source); - schedule(3000, 0, "FireSatHornet", %obj, %slot, %source); - - if(!%obj.mountobj.isUnlimitedSat) { - schedule(4000, 0, "MakeCruiseMissile", %client, %obj); - schedule(4000, 0, "ServerPlay3d", EscapePodLaunchSound2, %obj.getPosition()); - } - else { - schedule(30000, 0, "ResetSat", %obj.mountobj); - // - } - } - else { - if(!%obj.mountobj.isUnlimitedSat) { - return; - } - %client = %obj.getControllingClient(); - bottomPrint(%client, "Missiles are still reloading... standby.", 2, 2); - if(isObject(%client.player) && %client.player.getState() !$= "dead") { - %client.setControlObject(%client.player); - } - } -} - -function ResetSat(%sat) { - if(isObject(%sat)) { - %sat.canLaucnhStrike = 1; - } -} - -function MakeCruiseMissile(%client, %sat) { - if(%client.getControlObject() != %sat) { - return; - } - %Missile = new FlyingVehicle() { - dataBlock = "CruiseMissileVehicle"; - scale = "1 1 1"; - team = %client.team; - mountable = "0"; //drive only - }; - - setTargetSensorGroup(%Missile.getTarget(), %Missile.team); - %Missile.setTransform(vectorAdd(%sat.getPosition(), "0 0 -5") SPC rotFromTransform(%sat.getTransform())); - - %Missile.controller = %client; - %sat.GuidedMissile = %Missile; - MissionCleanup.add(%Missile); - %client.setControlObject(%Missile); - - MissileSatGuidedLoop(%client, %Missile); -} - -function ReMoveClientSW(%client) { - if(!isObject(%client.player) || %client.player.getState() $= "dead") { - return; - } - else { - %sp = Game.pickPlayerSpawn(%client, false); - //2 sec Invincibility please? - %client.player.setInvinc(1); - %client.player.schedule(2000, "setInvinc", 0); - %client.player.setTransform(%client.player.lastTransformStuff); //%sp for new spawn - %client.setControlObject(%client.player); - } -} - -//just a good function to delete the satelite if the client reliquishes control -function MissileSatControlLoop(%client, %sat) { - if(!isObject(%sat)) { - if(isObject(%client.player)) { - ReMoveClientSW(%client); - } - return; - } - if((%client.getControlObject() != %sat.turretObject) && !%sat.isUnlimitedSat) { - //lets check if they are in the missile now... - if(%client.getControlObject() == %sat.turretObject.GuidedMissile) { - //MissileSatGuidedLoop(%client, %sat.turretObject.GuidedMissile); - } - //No, they reliquished all control before the guided fired... - else { - if(isObject(%client.player)) { - ReMoveClientSW(%client); - } - } - %sat.schedule(1000, "Delete"); - return; - } - //%client.setControlObject(%sat.turretObject); - schedule(100, 0, "MissileSatControlLoop", %client, %sat); -} - -function MissileSatGuidedLoop(%client, %missile) { - if(%client.getControlObject() != %missile) { - if(isObject(%client.player)) { - ReMoveClientSW(%client); - } - return; - } - schedule(100, 0, "MissileSatGuidedLoop", %client, %missile); -} diff --git a/scripts/TWM2/PGDConnect/ServerInteraction.cs b/scripts/TWM2/PGDConnect/ServerInteraction.cs index 709a97b..bb8dcbc 100644 --- a/scripts/TWM2/PGDConnect/ServerInteraction.cs +++ b/scripts/TWM2/PGDConnect/ServerInteraction.cs @@ -49,36 +49,40 @@ function serverInterfacing::onConnected(%this) { } function serverInterfacing::onLine(%this, %line) { - if (trim(%line) $= "") { //is the line a HTTP header? - if (!%this.readyToRead) { - %this.readyToRead = true; - } - } - if(!%this.readyToRead) { - return; //we have no use for this. - } - //read necessary data - switch$(getWord(%line, 0)) { - case "ApplyDevList": - %list = getWords(%line, 1); - %list = strreplace(%list, "TAB", "\t"); //boom! - for(%i = 0; %i < getFieldCount(%list); %i++) { - %FieldGUID = getSubStr(getField(%list, %i), 0, strstr(getField(%list, %i), ":")); - %FieldLEVEL = getSubStr(getField(%list, %i), strLen(%FieldGUID) + 1, strLen(getField(%list, %i))); - $DeveloperList[%i] = %FieldGUID; - $DeveloperLevel[%i] = %FieldLEVEL; - echo("Developers "@%i@": "@$DeveloperList[%i]@" -> "@$DeveloperLevel[%i]@""); - } - case "SetHighRank": - $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] = getWord(%line, 1); - echo("PGD: Highest Rank Set To "@getWord(%line, 1)@""); - case "SetHighOfficer": - $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] = getWord(%line, 1); - echo("PGD: Highest Officer Rank Set To "@getWord(%line, 1)@""); - case "SetEXPMultiplier": - $EXPMulti[$TWM2Core_Code, formattimestring("yymmdd"), sha1sum($TWM2Core_Code TAB TWM2Lib_MainControl("FormatTWM2Time" , formattimestring("yymmdd")))] = getWord(%line, 1); - echo("PGD: EXP Multiplier is now: "@getWord(%line, 1)@""); - default: - echo("PGD: Depricated command "@getWord(%line, 0)@" issued, ignored..."); - } + if (trim(%line) $= "") { //is the line a HTTP header? + if (!%this.readyToRead) { + %this.readyToRead = true; + } + } + if(!%this.readyToRead) { + return; //we have no use for this. + } + //read necessary data + switch$(getWord(%line, 0)) { + case "ApplyDevList": + %list = getWords(%line, 1); + %list = strreplace(%list, "TAB", "\t"); //boom! + for(%i = 0; %i < getFieldCount(%list); %i++) { + %FieldGUID = getSubStr(getField(%list, %i), 0, strstr(getField(%list, %i), ":")); + %FieldLEVEL = getSubStr(getField(%list, %i), strLen(%FieldGUID) + 1, strLen(getField(%list, %i))); + $DeveloperList[%i] = %FieldGUID; + $DeveloperLevel[%i] = %FieldLEVEL; + echo("Developers "@%i@": "@$DeveloperList[%i]@" -> "@$DeveloperLevel[%i]@""); + } + + case "SetHighRank": + $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] = getWord(%line, 1); + echo("PGD: Highest Rank Set To "@getWord(%line, 1)@""); + + case "SetHighOfficer": + $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] = getWord(%line, 1); + echo("PGD: Highest Officer Rank Set To "@getWord(%line, 1)@""); + + case "SetEXPMultiplier": + $EXPMulti[$TWM2Core_Code, formattimestring("yymmdd"), sha1sum($TWM2Core_Code TAB TWM2Lib_MainControl("FormatTWM2Time" , formattimestring("yymmdd")))] = getWord(%line, 1); + echo("PGD: EXP Multiplier is now: "@getWord(%line, 1)@""); + + default: + echo("PGD: Depricated command "@getWord(%line, 0)@" issued, ignored..."); + } } diff --git a/scripts/TWM2/Systems/AdvancedRankSystem.cs b/scripts/TWM2/Systems/AdvancedRankSystem.cs index 818fc00..2f810f6 100644 --- a/scripts/TWM2/Systems/AdvancedRankSystem.cs +++ b/scripts/TWM2/Systems/AdvancedRankSystem.cs @@ -31,7 +31,6 @@ function CreateClientRankFile(%client) { //now apply the base settings for this new file. %scriptController.name = %client.namebase; %scriptController.xp = 0; - %scriptController.money = 0; %scriptController.rank = "Private"; %scriptController.phrase = "None Set"; %scriptController.gameTime = 0; @@ -150,36 +149,36 @@ function runRankUpdateLoop(%client, %j, %continue) { } function fetchCap(%type, %index) { - if(%type $= "Officer") { - if(!isSet($OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) || $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] <= 0) { - return false; - } - else { - if(%index >= $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) { - return true; - } - else { - return false; - } - } - } - else if(%type $= "Level") { - if(!isSet($RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) || $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] <= 0) { - return false; - } - else { - if(%index >= $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) { - return true; - } - else { - return false; - } - } - } - else if(%type $= "EXP") { - echo("fetchCap(): Call to EXP cap made, however the EXP cap has been depricated. use trace(1) to log the call stack."); - return false; - } + if(%type $= "Officer") { + if(!isSet($OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) || $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] <= 0) { + return false; + } + else { + if(%index >= $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) { + return true; + } + else { + return false; + } + } + } + else if(%type $= "Level") { + if(!isSet($RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) || $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))] <= 0) { + return false; + } + else { + if(%index >= $RankCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) { + return true; + } + else { + return false; + } + } + } + else if(%type $= "EXP") { + echo("fetchCap(): Call to EXP cap made, however the EXP cap has been depricated. use trace(1) to log the call stack."); + return false; + } } function checkForXPAwards(%client) { @@ -209,8 +208,8 @@ function printCurrentEXP(%client) { //print function shows a more readable version of EXP %scriptController = %client.TWM2Core; %milXP = %scriptController.millionxp; - %nonMilXP = %scriptControler.xp; - return %milXP @ "" @ %nonMilXP; + %nonMilXP = %scriptController.xp; + return (%milXP == 0 ? "" : %milXP) @ "" @ %nonMilXP; } //PRESTIGE RANKS @@ -218,7 +217,6 @@ function PromoteToPrestige(%client) { %scriptController = %client.TWM2Core; %savedGameTime = %scriptController.gameTime; %savedPhrs = %scriptController.phrase; - %savedMoney = %scriptController.money; if(%scriptController.officer $= "" || %scriptController.officer == 0) { %next = 1; } @@ -231,7 +229,7 @@ function PromoteToPrestige(%client) { error("It is recommended you report these details to Phantom139 (phantom139@phantomdev.net) ASAP."); error("Client has been informed of this, if it is reported to be a mistake, inform Phantom139 of possible code error"); messageClient(%client, 'msgAlert', "\c3Alert! You have performed an Illegal action(trying to promote to an officer rank beyond cap level)\nIf you believe this is a mistake, you should inform the server host ASAP."); -return; + return; } DumpStats(%client); @@ -250,7 +248,6 @@ return; %client.TWM2Core.name = %client.namebase; %client.TWM2Core.xp = 0; %client.TWM2Core.millionxp = 0; - %client.TWM2Core.money = %savedMoney; %client.TWM2Core.rank = "Private"; %client.TWM2Core.phrase = %savedPhrs; %client.TWM2Core.gameTime = %savedGameTime; @@ -305,88 +302,6 @@ function DumpStats(%c) { // this is now our cleaned object file, it will be populated shortly } -function GeneratePrestigeChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("Prestge1")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Instructive Private - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Instructive Private - Reach Officer Level 1."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Prestge2")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Excelling Private - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Excelling Private - Reach Officer Level 2."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Prestge3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Private - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Private - Reach Officer Level 3."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Prestge4")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Prestigious Private - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Prestigious Private - Reach Officer Level 4."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Prestge5")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Supreme Private - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Supreme Private - Reach Officer Level 5."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Prestge9")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Phantom's Vengeance - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Phantom's Vengeance - Reach Oficer Level 9."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("GameEnder")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Game Ender - Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Game Ender - Call in a Fission Bomb."); - %index++; - } - // - return %index; -} - -function EXPWillBreakRankCap(%client) { - %script = %client.TWM2Core; - %rN = %script.rankNumber; - %officer = %script.officer; - //Phantom139: updated here, now handles officer ranks so we can apply numbers above 61 to restrict up to a officer level - %currentRankNumber = (%officer*$Rank::RankCount) + %rN; - //apply the new check here |LEAVE THIS, apply ONLY on base rank| - if(fetchCap("Level", %currentRankNumber + 1) && (getCurrentEXP(%client) >= $Ranks::MinPoints[%rN+1])) { - return true; - } - else { - return false; - } -} - //Direct calls to needed function, replaces //old system. function GainExperience(%client, %variable, %tagToGain) { @@ -399,12 +314,7 @@ function GainExperience(%client, %variable, %tagToGain) { } %variable *= %multi; %variable = mFloor(%variable); - %script.money += %variable; //money is kept no matter what // - if(EXPWillBreakRankCap(%client)) { - messageClient(%client, 'msgClient', "\c5TWM2: "@%tagToGain@"\c3 Further Progression Locked [RANK CAP]"); - return; - } if(%multi > 1) { messageClient(%client, 'msgClient', "\c5TWM2: "@%tagToGain@"\c3+"@%variable@" EXP (X"@%multi@")"); } @@ -414,3 +324,40 @@ function GainExperience(%client, %variable, %tagToGain) { $XPArray[%client] += %variable; updateClientRank(%client); } + +function WipeStats(%client) { + %scriptController = %client.TWM2Core; + %savedGameTime = %scriptController.gameTime; + %savedPhrs = %scriptController.phrase; + if(%scriptController.officer < 15) { + error("Client "@%client@" is attempting to wipe stats??? Not max level..."); + return; + } + + DumpStats(%client); + + %file = ""@$TWM::RanksDirectory@"/"@%client.guid@"/Saved.TWMSave"; + + %name = "ClientSettings"@%client.guid@""; + %check = nameToID(%name); + if(isObject(%check)) { + %check.delete(); //kill current settings, as they are no longer valid. + } + %script = new ScriptObject(%name) {}; + %client.container.add(%script); + + //now apply the base settings for this new file. + %client.TWM2Core.name = %client.namebase; + %client.TWM2Core.xp = 0; + %client.TWM2Core.millionxp = 0; + %client.TWM2Core.rank = "Private"; + %client.TWM2Core.phrase = %savedPhrs; + %client.TWM2Core.gameTime = %savedGameTime; + %client.TWM2Core.officer = 0; + //and save the new file + //%scriptController.save(%file); + SaveClientFile(%client); + + MessageAll('msgAdminForce', "\c5"@%client.namebase@" has hit the reset button and is back at level 1!!!"); + recordAction(%client, "", ""); //record blank action for the challenges to pick off any officer challenges +} \ No newline at end of file diff --git a/scripts/TWM2/Systems/BossSystem.cs b/scripts/TWM2/Systems/BossSystem.cs index c7072dd..e89c5fe 100644 --- a/scripts/TWM2/Systems/BossSystem.cs +++ b/scripts/TWM2/Systems/BossSystem.cs @@ -38,9 +38,9 @@ function InitiateBoss(%Boss, %name) { case "Trebor": %print = "BOSS BATTLE \n LORDRANIUS TREVOR"; case "Stormrider": - %print = "BOSS BATTLE \n COMMANDER STORMRIDER"; + %print = "CLASSIC BOSS BATTLE \n COMMANDER STORMRIDER"; case "GhostOfFire": - %print = "BOSS BATTLE \n GHOST OF FIRE"; + %print = "CLASSIC BOSS BATTLE \n GHOST OF FIRE"; case "ShadeLord": %print = "BOSS BATTLE \n THE SHADE LORD"; } @@ -162,6 +162,18 @@ function GameConnection::GiveBossAward(%client, %bossName) { //VARDISON else if(%bossName $= "Vardison3") { AwardClient(%client, 13); + if($TWM2::VardisonDifficulty == 1) { + CompleteNWChallenge(%client, "VardEasy"); + } + else if($TWM2::VardisonDifficulty == 2) { + CompleteNWChallenge(%client, "VardNorm"); + } + else if($TWM2::VardisonDifficulty == 3) { + CompleteNWChallenge(%client, "VardHard"); + } + else if($TWM2::VardisonDifficulty == 4) { + CompleteNWChallenge(%client, "VardWtf"); + } } else if(%bossName $= "Trebor") { AwardClient(%client, 15); @@ -238,6 +250,16 @@ function CheckBossChallenge(%client, %boss) { if(%dc >= 10) { CompleteNWChallenge(%client, "GOL3"); } + case "GhostOfFire": + if(%dc >= 1) { + CompleteNWChallenge(%client, "GOF1"); + } + if(%dc >= 3) { + CompleteNWChallenge(%client, "GOF2"); + } + if(%dc >= 5) { + CompleteNWChallenge(%client, "GOF3"); + } case "Vegenor": if(%dc >= 3) { CompleteNWChallenge(%client, "Veg1"); @@ -278,6 +300,16 @@ function CheckBossChallenge(%client, %boss) { if(%dc >= 5) { CompleteNWChallenge(%client, "Vard3"); } + case "Stormrider": + if(%dc >= 3) { + CompleteNWChallenge(%client, "Stormrider1"); + } + if(%dc >= 5) { + CompleteNWChallenge(%client, "Stormrider2"); + } + if(%dc >= 10) { + CompleteNWChallenge(%client, "Stormrider3"); + } case "Trebor": if(%dc >= 2) { CompleteNWChallenge(%client, "Treb1"); @@ -288,212 +320,17 @@ function CheckBossChallenge(%client, %boss) { if(%dc >= 7) { CompleteNWChallenge(%client, "Treb3"); } - } -} - -function GenerateBossChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("Yvex1")) { - if(%client.CheckNWChallengeCompletion("Yvex2")) { - if(%client.CheckNWChallengeCompletion("Yvex3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Shadowy Desecration - Done"); - %index++; + case "ShadeLord": + if(%dc >= 1) { + CompleteNWChallenge(%client, "ShadeLord1"); } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Shadowy Desecration - Defeat Lord Yvex 10 Times"); - %index++; + if(%dc >= 2) { + CompleteNWChallenge(%client, "ShadeLord2"); } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Darkness Rising - Defeat Lord Yvex 5 Times"); - %index++; - } + if(%dc >= 3) { + CompleteNWChallenge(%client, "ShadeLord3"); + } } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Nightmarish Enterprise - Defeat Lord Yvex 3 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("CWS1")) { - if(%client.CheckNWChallengeCompletion("CWS2")) { - if(%client.CheckNWChallengeCompletion("CWS3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger's Bane - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger's Bane - Defeat Colonel Windshear 10 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Aerieal Nightmare - Defeat Colonel Windshear 5 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Fortress In The Sky - Defeat Colonel Windshear 3 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("GOL1")) { - if(%client.CheckNWChallengeCompletion("GOL2")) { - if(%client.CheckNWChallengeCompletion("GOL3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Severe Thunderstorm - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Severe Thunderstorm - Defeat The Ghost Of Lightning 10 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "The Shocking Truth - Defeat The Ghost Of Lightning 5 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Envious Lightning - Defeat The Ghost Of Lightning 3 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Veg1")) { - if(%client.CheckNWChallengeCompletion("Veg2")) { - if(%client.CheckNWChallengeCompletion("Veg3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Firestorm Ender - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Firestorm Ender - Defeat General Vegenor 10 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Burning Frenzy - Defeat General Vegenor 5 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Flaming Revolt - Defeat General Vegenor 3 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("LRog1")) { - if(%client.CheckNWChallengeCompletion("LRog2")) { - if(%client.CheckNWChallengeCompletion("LRog3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Payback's A Bitch - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Payback's A Bitch - Defeat Lord Rog 7 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Return to Returner - Defeat Lord Rog 4 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Revenge Halter - Defeat Lord Rog 2 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Ins1")) { - if(%client.CheckNWChallengeCompletion("Ins2")) { - if(%client.CheckNWChallengeCompletion("Ins3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gravitational Influx - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gravitational Influx - Defeat Major Insignia 7 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "No Gravity, No Problem - Defeat Major Insignia 4 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "El Shipitor - Defeat Major Insignia 2 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Treb1")) { - if(%client.CheckNWChallengeCompletion("Treb2")) { - if(%client.CheckNWChallengeCompletion("Treb3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Tank Halter - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Tank Halter - Defeat Lordranius Trebor 7 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Denied - Defeat Lordranius Trebor 4 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Precious Cargo - Defeat Lordranius Trebor 2 Times"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Vard1")) { - if(%client.CheckNWChallengeCompletion("Vard2")) { - if(%client.CheckNWChallengeCompletion("Vard3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Outevil The Wicked - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Outevil The Wicked - Defeat Lord Vardison 5 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Glare The Dark - Defeat Lord Vardison 3 Times"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Shining Star - Defeat Lord Vardison"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("VardEasy")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "The Standard Experience - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "The Standard Experience - Defeat Lord Vardison on Easy Difficulty"); - %index++; - } - if(%client.CheckNWChallengeCompletion("VardNorm")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Demon Hunter - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Demon Hunter - Defeat Lord Vardison on Normal Difficulty"); - %index++; - } - if(%client.CheckNWChallengeCompletion("VardHard")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Master Demon Slayer - Done"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Master Demon Slayer - Defeat Lord Vardison on Hard Difficulty"); - %index++; - } - if(%client.CheckNWChallengeCompletion("VardWtf")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "God of the Shadow Realm - Done [You are a freaking boss master]"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "God of the Shadow Realm - Against all odds, emerge victorious against WTF difficulty Lord Vardison"); - %index++; - } - // - return %index; } function BossManager::addKill(%this, %tObj) { diff --git a/scripts/TWM2/Systems/ChallengeMenus.cs b/scripts/TWM2/Systems/ChallengeMenus.cs new file mode 100644 index 0000000..6d48c2e --- /dev/null +++ b/scripts/TWM2/Systems/ChallengeMenus.cs @@ -0,0 +1,1618 @@ +//Challenge Menus +//TWM2 3.9.1 +//Moved all of the Non-Weapon Challenge menus to a singular file +// under a single function to streamline it... + +// Yes, I know I could "automate" this, but my laziness is still rather persistent to re-do the entire old system... + +function GenerateChallengeSubMenu(%client, %subMenu, %tag, %index) { + switch(%subMenu) { + case 1: + //Killstreaks + messageClient( %client, 'SetLineHud', "", %tag, %index, "Killstreak Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("UAV1")) { + if(%client.CheckNWChallengeCompletion("UAV2")) { + if(%client.CheckNWChallengeCompletion("UAV3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert III: Call in 150 UAV Recon Satellites"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert III: Call in 150 UAV Recon Satellites"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert II: Call in 75 UAV Recon Satellites"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert I: Call in 30 UAV Recon Satellites"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Airstrike1")) { + if(%client.CheckNWChallengeCompletion("Airstrike2")) { + if(%client.CheckNWChallengeCompletion("Airstrike3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert III: Call in 125 Airstrikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert III: Call in 125 Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert II: Call in 65 Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert I: Call in 25 Airstrikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("UAMS1")) { + if(%client.CheckNWChallengeCompletion("UAMS2")) { + if(%client.CheckNWChallengeCompletion("UAMS3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert III: Call in 125 UAMS Strikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert III: Call in 125 UAMS Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert II: Call in 65 UAMS Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert I: Call in 25 UAMS Strikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Helicopter1")) { + if(%client.CheckNWChallengeCompletion("Helicopter2")) { + if(%client.CheckNWChallengeCompletion("Helicopter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert III: Call in 125 Combat Helicopters"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert III: Call in 125 Combat Helicopters"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert II: Call in 65 Combat Helicopters"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert I: Call in 25 Combat Helicopters"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Harrier1")) { + if(%client.CheckNWChallengeCompletion("Harrier2")) { + if(%client.CheckNWChallengeCompletion("Harrier3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert III: Call in 110 Plasma Harrier Airstrikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert III: Call in 110 Plasma Harrier Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert II: Call in 55 Plasma Harrier Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert I: Call in 20 Plasma Harrier Airstrikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SatNuke1")) { + if(%client.CheckNWChallengeCompletion("SatNuke2")) { + if(%client.CheckNWChallengeCompletion("SatNuke3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert III: Call in 125 Orbital Laser Strikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert III: Call in 125 Orbital Laser Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert II: Call in 65 Orbital Laser Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert I: Call in 25 Orbital Laser Strikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("NapalmHarrier1")) { + if(%client.CheckNWChallengeCompletion("NapalmHarrier2")) { + if(%client.CheckNWChallengeCompletion("NapalmHarrier3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert III: Call in 110 Napalm Airstrikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert III: Call in 110 Napalm Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert II: Call in 55 Napalm Airstrikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert I: Call in 20 Napalm Airstrikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GunHeli1")) { + if(%client.CheckNWChallengeCompletion("GunHeli2")) { + if(%client.CheckNWChallengeCompletion("GunHeli3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert III: Call in 110 Gunship Helicopters"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert III: Call in 110 Gunship Helicopters"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert II: Call in 55 Gunship Helicopters"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert I: Call in 20 Gunship Helicopters"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SBomber1")) { + if(%client.CheckNWChallengeCompletion("SBomber2")) { + if(%client.CheckNWChallengeCompletion("SBomber3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert III: Call in 100 Stealth Bombers"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert III: Call in 100 Stealth Bombers"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert II: Call in 50 Stealth Bombers"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert I: Call in 20 Stealth Bombers"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Gunship1")) { + if(%client.CheckNWChallengeCompletion("Gunship2")) { + if(%client.CheckNWChallengeCompletion("Gunship3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert III: Call in 75 Harbinger Gunships"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert III: Call in 75 Harbinger Gunships"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert II: Call in 35 Harbinger Gunships"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert I: Call in 15 Harbinger Gunships"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Apache1")) { + if(%client.CheckNWChallengeCompletion("Apache2")) { + if(%client.CheckNWChallengeCompletion("Apache3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Gunner Expert III: Call in 75 Apache Gunners"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Gunner Expert III: Call in 75 Apache Gunners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Gunner Expert II: Call in 35 Apache Gunners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Gunner Expert I: Call in 15 Apache Gunners"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Gunship3")) { + if(%client.CheckNWChallengeCompletion("ACGunship1")) { + if(%client.CheckNWChallengeCompletion("ACGunship2")) { + if(%client.CheckNWChallengeCompletion("ACGunship3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert III: Call in 75 AC-130 Gunners"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert III: Call in 75 AC-130 Gunners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert II: Call in 35 AC-130 Gunners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert I: Call in 15 AC-130 Gunners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Locked: Requires Harbinger Gunship Expert III."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Centaur1")) { + if(%client.CheckNWChallengeCompletion("Centaur2")) { + if(%client.CheckNWChallengeCompletion("Centaur3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert III: Call in 50 Artillery Strikes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert III: Call in 50 Artillery Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert II: Call in 25 Artillery Strikes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert I: Call in 10 Artillery Strikes"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("EMP1")) { + if(%client.CheckNWChallengeCompletion("EMP2")) { + if(%client.CheckNWChallengeCompletion("EMP3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert III: Call in 25 Mass EMP's"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert III: Call in 25 Mass EMP's"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert II: Call in 10 Mass EMP's"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert I: Call in 5 Mass EMP's"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Nuke1")) { + if(%client.CheckNWChallengeCompletion("Nuke2")) { + if(%client.CheckNWChallengeCompletion("Nuke3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert III: Call in 25 Nukes"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert III: Call in 25 Nukes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert II: Call in 10 Nukes"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert I: Call in 5 Nukes"); + %index++; + } + // + if(%client.TWM2Core.Officer >= 1) { + if(%client.CheckNWChallengeCompletion("Fission1")) { + if(%client.CheckNWChallengeCompletion("Fission2")) { + if(%client.CheckNWChallengeCompletion("Fission3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert III: Call in 5 Fission Bombs"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert III: Call in 5 Fission Bombs"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert II: Call in 2 Fission Bombs"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert I: Call in 1 Fission Bomb"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Locked: Requires Instructive Officer Rank (Off. Rank 1)"); + %index++; + } + // + if(%client.TWM2Core.Officer >= 15) { + if(%client.CheckNWChallengeCompletion("LOAS1")) { + if(%client.CheckNWChallengeCompletion("LOAS2")) { + if(%client.CheckNWChallengeCompletion("LOAS3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "LOAS Expert III: Call in 15 Low Orbit Orbital Strikes (LOAS)"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "LOAS Expert III: Call in 15 Low Orbit Orbital Strikes (LOAS)"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "LOAS Expert II: Call in 10 Low Orbit Orbital Strikes (LOAS)"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "LOAS Expert I: Call in 5 Low Orbit Orbital Strikes (LOAS)"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Locked: Requires Harbinger Officer Rank (Off. Rank 15)"); + %index++; + } + return %index; + + case 2: + //Boss Hunting + messageClient( %client, 'SetLineHud', "", %tag, %index, "Boss Hunting Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("Yvex1")) { + if(%client.CheckNWChallengeCompletion("Yvex2")) { + if(%client.CheckNWChallengeCompletion("Yvex3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shadowy Desecration: Defeat Lord Yvex 10 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shadowy Desecration: Defeat Lord Yvex 10 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Darkness Rising: Defeat Lord Yvex 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Nightmarish Enterprise: Defeat Lord Yvex 3 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("CWS1")) { + if(%client.CheckNWChallengeCompletion("CWS2")) { + if(%client.CheckNWChallengeCompletion("CWS3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger's Bane: Defeat Colonel Windshear 10 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger's Bane: Defeat Colonel Windshear 10 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Aerieal Nightmare: Defeat Colonel Windshear 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fortress In The Sky: Defeat Colonel Windshear 3 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GOL1")) { + if(%client.CheckNWChallengeCompletion("GOL2")) { + if(%client.CheckNWChallengeCompletion("GOL3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Severe Thunderstorm: Defeat The Ghost Of Lightning 10 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Severe Thunderstorm: Defeat The Ghost Of Lightning 10 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Shocking Truth: Defeat The Ghost Of Lightning 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Envious Lightning: Defeat The Ghost Of Lightning 3 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GOF1")) { + if(%client.CheckNWChallengeCompletion("GOF2")) { + if(%client.CheckNWChallengeCompletion("GOF3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Mt. Death Depleter: Defeat The Ghost Of Fire 5 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Mt. Death Depleter: Defeat The Ghost Of Fire 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Inceneration Ender: Defeat The Ghost Of Fire 3 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Purifier: Defeat The Ghost Of Fire"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Veg1")) { + if(%client.CheckNWChallengeCompletion("Veg2")) { + if(%client.CheckNWChallengeCompletion("Veg3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Firestorm Ender: Defeat General Vegenor 10 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Firestorm Ender: Defeat General Vegenor 10 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Burning Frenzy: Defeat General Vegenor 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Flaming Revolt: Defeat General Vegenor 3 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("LRog1")) { + if(%client.CheckNWChallengeCompletion("LRog2")) { + if(%client.CheckNWChallengeCompletion("LRog3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Payback's A Bitch: Defeat Lord Rog 7 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Payback's A Bitch: Defeat Lord Rog 7 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Return to Returner: Defeat Lord Rog 4 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Revenge Halter: Defeat Lord Rog 2 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Ins1")) { + if(%client.CheckNWChallengeCompletion("Ins2")) { + if(%client.CheckNWChallengeCompletion("Ins3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gravitational Influx: Defeat Major Insignia 7 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gravitational Influx: Defeat Major Insignia 7 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "No Gravity, No Problem: Defeat Major Insignia 4 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "El Shipitor: Defeat Major Insignia 2 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Stormrider1")) { + if(%client.CheckNWChallengeCompletion("Stormrider2")) { + if(%client.CheckNWChallengeCompletion("Stormrider3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Fighter Demolisher: Defeat Commander Stormrider 10 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Fighter Demolisher: Defeat Commander Stormrider 10 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shootdown Master: Defeat Commander Stormrider 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Clear Skies: Defeat Commander Stormrider 3 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Treb1")) { + if(%client.CheckNWChallengeCompletion("Treb2")) { + if(%client.CheckNWChallengeCompletion("Treb3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Tank Halter: Defeat Lordranius Trevor 7 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Tank Halter: Defeat Lordranius Trevor 7 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Denied: Defeat Lordranius Trevor 4 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Precious Cargo: Defeat Lordranius Trevor 2 Times"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Vard1")) { + if(%client.CheckNWChallengeCompletion("Vard2")) { + if(%client.CheckNWChallengeCompletion("Vard3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Outevil The Wicked: Defeat Lord Vardison 5 Times"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Outevil The Wicked: Defeat Lord Vardison 5 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Glare The Dark: Defeat Lord Vardison 3 Times"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shining Star: Defeat Lord Vardison"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("VardEasy")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Standard Experience: Defeat Lord Vardison on Easy Difficulty"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Standard Experience: Defeat Lord Vardison on Easy Difficulty"); + %index++; + } + if(%client.CheckNWChallengeCompletion("VardNorm")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Demon Hunter: Defeat Lord Vardison on Normal Difficulty"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Demon Hunter: Defeat Lord Vardison on Normal Difficulty"); + %index++; + } + if(%client.CheckNWChallengeCompletion("VardHard")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Master Demon Slayer: Defeat Lord Vardison on Hard Difficulty"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Master Demon Slayer: Defeat Lord Vardison on Hard Difficulty"); + %index++; + } + if(%client.CheckNWChallengeCompletion("VardWtf")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "God of the Shadow Realm: You're a fucking badass... Just bask in that..."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "God of the Shadow Realm: Against all odds, emerge victorious against WTF difficulty Lord Vardison"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ShadeLord1")) { + if(%client.CheckNWChallengeCompletion("ShadeLord2")) { + if(%client.CheckNWChallengeCompletion("ShadeLord3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Dawnlight Encarnate: Defeat The Shade Lord for the Third Time"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Dawnlight Encarnate: Defeat The Shade Lord for the Third Time"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shadow Embracer: Defeat The Shade Lord Twice"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Night Stalker: Defeat The Shade Lord"); + %index++; + } + // + return %index; + + case 3: + //Wargames + messageClient( %client, 'SetLineHud', "", %tag, %index, "Wargames (PvP) Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("Slayer1")) { + if(%client.CheckNWChallengeCompletion("Slayer2")) { + if(%client.CheckNWChallengeCompletion("Slayer3")) { + if(%client.CheckNWChallengeCompletion("Slayer4")) { + if(%client.CheckNWChallengeCompletion("Slayer5")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer V: Kill 1,000 Enemy Players"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer V: Kill 1,000 Enemy Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer IV: Kill 750 Enemy Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer III: Kill 500 Enemy Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer II: Kill 250 Enemy Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Slayer I: Kill 100 Enemy Players"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Defectionator1")) { + if(%client.CheckNWChallengeCompletion("Defectionator2")) { + if(%client.CheckNWChallengeCompletion("Defectionator3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Defectionator III: Kill 500 \"Zombified\" Players"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Defectionator III: Kill 500 \"Zombified\" Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Defectionator II: Kill 250 \"Zombified\" Players"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Defectionator I: Kill 100 \"Zombified\" Players"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Infectionator1")) { + if(%client.CheckNWChallengeCompletion("Infectionator2")) { + if(%client.CheckNWChallengeCompletion("Infectionator3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Infectionator III: Convert 250 Players to the Zombie Horde"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Infectionator III: Convert 250 Players to the Zombie Horde"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Infectionator II: Convert 100 Players to the Zombie Horde"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Infectionator I: Convert 50 Players to the Zombie Horde..."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("HSHoncho1")) { + if(%client.CheckNWChallengeCompletion("HSHoncho2")) { + if(%client.CheckNWChallengeCompletion("HSHoncho3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Headshot Honcho III: Eliminate 300 Enemy Players with Headshots"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Headshot Honcho III: Eliminate 300 Enemy Players with Headshots"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Headshot Honcho II: Eliminate 200 Enemy Players with Headshots"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Headshot Honcho I: Eliminate 100 Enemy Players with Headshots"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("VehMans1")) { + if(%client.CheckNWChallengeCompletion("VehMans2")) { + if(%client.CheckNWChallengeCompletion("VehMans3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Vehicular Manslaughter III: Eliminate 250 Enemy Players with a vehicle"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Vehicular Manslaughter III: Eliminate 250 Enemy Players with a vehicle"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Vehicular Manslaughter II: Eliminate 100 Enemy Players with a vehicle"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Vehicular Manslaughter I: Eliminate 50 Enemy Players with a vehicle"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Assassin")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Assassinator: Backstab an enemy player using the Blade of Vengeance"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Assassinator: Backstab an enemy player using the Blade of Vengeance"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("CompletelyUnexpected")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "That Was... Unexpected: Eliminate someone playing as General Rog by backstabbing them with the Blade of Vengence"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "That Was... Unexpected: Eliminate someone playing as General Rog by backstabbing them with the Blade of Vengence"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Uncomprehendable")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Uncomprehendable: You committed the ultimate vehicle kill humiliation, well done!"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Uncomprehendable: Get killed in a fighter, and have the driverless vehicle run down your killer"); + %index++; + } + // + return %index; + + case 4: + //Zombie Slaying + messageClient( %client, 'SetLineHud', "", %tag, %index, "Zombie Slayer Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("NormHunter1")) { + if(%client.CheckNWChallengeCompletion("NormHunter2")) { + if(%client.CheckNWChallengeCompletion("NormHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Frontline Buster III: Slay 10,000 Zombies (Normal Type)"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Frontline Buster III: Slay 10,000 Zombies (Normal Type)"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Frontline Buster II: Slay 5,000 Zombies (Normal Type)"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Frontline Buster I: Slay 2,500 Zombies (Normal Type)"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("RavHunter1")) { + if(%client.CheckNWChallengeCompletion("RavHunter2")) { + if(%client.CheckNWChallengeCompletion("RavHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Kills III: Slay 5,000 Ravager Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Kills III: Slay 5,000 Ravager Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Kills II: Slay 2,500 Ravager Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Kills I: Slay 1,000 Ravager Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("LordHunter1")) { + if(%client.CheckNWChallengeCompletion("LordHunter2")) { + if(%client.CheckNWChallengeCompletion("LordHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Bigger They Are III: Slay 3,000 Zombie Lords"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Bigger They Are III: Slay 3,000 Zombie Lords"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Bigger They Are II: Slay 2,000 Zombie Lords"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Bigger They Are I: Slay 1,000 Zombie Lords"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("DemonHunter1")) { + if(%client.CheckNWChallengeCompletion("DemonHunter2")) { + if(%client.CheckNWChallengeCompletion("DemonHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fire Retardant III: Slay 5,000 Demon Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fire Retardant III: Slay 5,000 Demon Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fire Retardant II: Slay 2,500 Demon Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Fire Retardant I: Slay 1,000 Demon Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("AirRapHunter1")) { + if(%client.CheckNWChallengeCompletion("AirRapHunter2")) { + if(%client.CheckNWChallengeCompletion("AirRapHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bat Slayer III: Slay 6,000 Air Rapier Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bat Slayer III: Slay 6,000 Air Rapier Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bat Slayer II: Slay 3,500 Air Rapier Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bat Slayer I: Slay 1,500 Air Rapier Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("DLordHunter1")) { + if(%client.CheckNWChallengeCompletion("DLordHunter2")) { + if(%client.CheckNWChallengeCompletion("DLordHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Hellspawn Erradicator III: Slay 1,500 Demon Lord Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Hellspawn Erradicator III: Slay 1,500 Demon Lord Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Hellspawn Erradicator II: Slay 1,000 Demon Lord Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Hellspawn Erradicator I: Slay 500 Demon Lord Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ShifterHunter1")) { + if(%client.CheckNWChallengeCompletion("ShifterHunter2")) { + if(%client.CheckNWChallengeCompletion("ShifterHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti-Warp III: Slay 6,000 Shifter Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti-Warp III: Slay 6,000 Shifter Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti-Warp II: Slay 3,000 Shifter Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti-Warp I: Slay 1,500 Shifter Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SummonerHunter1")) { + if(%client.CheckNWChallengeCompletion("SummonerHunter2")) { + if(%client.CheckNWChallengeCompletion("SummonerHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde Halter III: Slay 5,000 Zombie Summoners"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde Halter III: Slay 5,000 Zombie Summoners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde Halter II: Slay 2,500 Zombie Summoners"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde Halter I: Slay 1,000 Zombie Summoners"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SniperHunter1")) { + if(%client.CheckNWChallengeCompletion("SniperHunter2")) { + if(%client.CheckNWChallengeCompletion("SniperHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Scope Breaker III: Slay 5,000 Sniper Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Scope Breaker III: Slay 5,000 Sniper Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Scope Breaker II: Slay 2,500 Sniper Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Scope Breaker I: Slay 1,000 Sniper Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("UDemHunter1")) { + if(%client.CheckNWChallengeCompletion("UDemHunter2")) { + if(%client.CheckNWChallengeCompletion("UDemHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Runner Down III: Slay 5,000 Ultra Demon Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Runner Down III: Slay 5,000 Ultra Demon Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Runner Down II: Slay 2,500 Ultra Demon Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Runner Down I: Slay 1,000 Ultra Demon Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("VRavHunter1")) { + if(%client.CheckNWChallengeCompletion("VRavHunter2")) { + if(%client.CheckNWChallengeCompletion("VRavHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "C4 Coming Through III: Slay 5,000 Volatile Ravager Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "C4 Coming Through III: Slay 5,000 Volatile Ravager Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "C4 Coming Through II: Slay 2,500 Volatile Ravager Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "C4 Coming Through I: Slay 1,000 Volatile Ravager Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SSHunter1")) { + if(%client.CheckNWChallengeCompletion("SSHunter2")) { + if(%client.CheckNWChallengeCompletion("SSHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "De-Flakerizer III: Slay 5,000 Slingshot Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "De-Flakerizer III: Slay 5,000 Slingshot Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "De-Flakerizer II: Slay 2,500 Slingshot Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "De-Flakerizer I: Slay 1,000 Slingshot Zombies"); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("WraithHunter1")) { + if(%client.CheckNWChallengeCompletion("WraithHunter2")) { + if(%client.CheckNWChallengeCompletion("WraithHunter3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti Spec-Ops III: Slay 1,000 Wraith Zombies"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti Spec-Ops III: Slay 1,000 Wraith Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti Spec-Ops II: Slay 750 Wraith Zombies"); + %index++; + } + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Anti Spec-Ops I: Slay 500 Wraith Zombies"); + %index++; + } + // + return %index; + + case 5: + //Special Events + messageClient( %client, 'SetLineHud', "", %tag, %index, "Special Event Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("NewYearsEve")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Eve Fireworks: Get a Javelin Kill on New Year's Eve."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Eve Fireworks: Get a Javelin Kill on New Year's Eve."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("NewYears")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Fireworks: Call in a Nuclear Strike on New Year's Day."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Fireworks: Call in a Nuclear Strike on New Year's Day."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GunshipMall")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship to The Mall: Call in a Gunship Killstreak on Christmas Mall 2009."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship to The Mall: Call in a Gunship Killstreak on Christmas Mall 2009."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("IndepRPG")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Independance RPG: Score an RPG Kill on the Fourth of July."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Independance RPG: Score an RPG Kill on the Fourth of July."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SoulsticeBombard")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Soulstice Bombard: Call in artillery on one of the soulstices (6/21 or 12/21)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Soulstice Bombard: Call in artillery on one of the soulstices (6/21 or 12/21)."); + %index++; + } + return %index; + + case 6: + //PGD Daily Challenges + //Handled by DChalg.cs + %index = GenerateDWMChallengeMenu(%client, %tag, %index); + return %index; + + case 7: + //Sabotage + messageClient( %client, 'SetLineHud', "", %tag, %index, "Sabotage Game Mode Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("BombDisarmed")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Disarmed: Disarm an enemy bomb."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Disarmed: Disarm an enemy bomb."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("BombPlanted")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Planted: Arm the bomb at the objective."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Planted: Arm the bomb at the objective."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("BombDetonated")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Detonated: Win a Round Of Sabotage."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Bomb Detonated: Win a Round Of Sabotage."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("3For5Sabo")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five: Win 3 Rounds Of Sabotage in a match."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five: Win 3 Rounds Of Sabotage in a match."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("BaseDestroyer")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Base Destroyer: Go Undefeated in a full game of Sabotage."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Base Destroyer: Go Undefeated in a full game of Sabotage."); + %index++; + } + // + return %index; + + case 8: + //Domination + messageClient( %client, 'SetLineHud', "", %tag, %index, "Domination Game Mode Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("ZoneCapture")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Zone Conquerer: Capture an Area."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Zone Conquerer: Capture an Area."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ABC")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Alpha Bravo Charlie: Secure All Three Areas at one Time."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Alpha Bravo Charlie: Secure All Three Areas at one Time."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("MatchSet")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Match Set: Win a Round Of Domination."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Match Set: Win a Round Of Domination."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("3For5")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five: Win 3 Rounds Of Domination."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Three For Five: Win 3 Rounds Of Domination."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Undefeatable")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Undefeatable: Go Undefeated in a full game of Domination."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Undefeatable: Go Undefeated in a full game of Domination."); + %index++; + } + // + return %index; + + case 9: + //Horde + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde 3 Game Mode Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("15For15")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "15 For 15: Complete Wave 15."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "15 For 15: Complete Wave 15."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Milestone25")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Milestone 25: Complete Wave 25."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Milestone 25: Complete Wave 25."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ArmyOf50Stopped")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Army Of 50 Stopped: Complete Horde 3 (All 50 Waves)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Army Of 50 Stopped: Complete Horde 3 (All 50 Waves)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Angel")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Angel: Revive a fallen teammate in Horde."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Angel: Revive a fallen teammate in Horde."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ZBomber")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Z-Bomber: Call in a Z-Bomb While Playing Horde."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Z-Bomber: Call in a Z-Bomb While Playing Horde."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("FirstBlood")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "First Blood: Kill the first zombie that spawns in a Horde 3 game."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "First Blood: Kill the first zombie that spawns in a Horde 3 game."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SpeedSlayer")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Slayer: Be the featured first killer 10 times in a single game."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Speed Slayer: Be the featured first killer 10 times in a single game."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("HighScorer")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "High Scorer: Be the featured high scorer 10 times in a single game."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "High Scorer: Be the featured high scorer 10 times in a single game."); + %index++; + } + // + return %index; + + case 10: + //Helljump + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helljump Game Mode Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("GroupBuster")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Group Buster: Complete A Group."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Group Buster: Complete A Group."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("WaveDefeater")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Wave Defeater: Complete A Wave."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Wave Defeater: Complete A Wave."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("OneK")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "1K Soldier: Earn 1,000 Points (Solo Score)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "1K Soldier: Earn 1,000 Points (Solo Score)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("FiveK")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "5K Soldier: Earn 5,000 Points (Solo Score)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "5K Soldier: Earn 5,000 Points (Solo Score)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("TenK")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "10K Soldier: Earn 10,000 Points (Solo Score)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "10K Soldier: Earn 10,000 Points (Solo Score)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("PointsSurge")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Surge: Earn 7,500 Points (Team Score)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Surge: Earn 7,500 Points (Team Score)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("PointsJackpot")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Jackpot: Earn 25,000 Points (Team Score)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Points Jackpot: Earn 25,000 Points (Team Score)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("DownBoy")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Down Boy... Down: Kill the wraith zombie on Strike 5."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Down Boy... Down: Kill the wraith zombie on Strike 5."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ClassExtravaganza")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Class Extravaganza: Use a hellclass."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Class Extravaganza: Use a hellclass."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("LifeGiver")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Giver of Life: Use a Full Team Respawn beacon."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Giver of Life: Use a Full Team Respawn beacon."); + %index++; + } + // + return %index; + + case 11: + //From The Top (Missions) + messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top (Mission) Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("SimonSays")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Simon Says: Order a mission."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Simon Says: Order a mission."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("FromTheTop")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top: Accept a mission."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top: Accept a mission."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("NaturalLeader")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Natural Leader: Order a mission and have another player join your team."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Natural Leader: Order a mission and have another player join your team."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GoldStar")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gold Star: Complete a mission within the time limit."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Gold Star: Complete a mission within the time limit."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Faster")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Faster!: Complete a mission, but miss the time limit."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Faster!: Complete a mission, but miss the time limit."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("EpicFailure")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Epic Failure: Fail a mission ;)."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Epic Failure: Fail a mission ;)."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("ExpertGunner")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Expert AC-130 Gunner: Complete 'Rain Down'."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Expert AC-130 Gunner: Complete 'Rain Down'."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Survivalist")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Survivalist: Complete 'Surrounded'."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Survivalist: Complete 'Surrounded'."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Invisibreh")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shhh.. I'm Invisibreh: Complete 'Enemy AC-130 Above' by outlasting the enemy AC-130."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Shhh.. I'm Invisibreh: Complete 'Enemy AC-130 Above' by outlasting the enemy AC-130."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("WeakGunship")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "I have you now!: Complete 'Enemy AC-130 Above' by destroying the enemy AC-130."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "I have you now!: Complete 'Enemy AC-130 Above' by destroying the enemy AC-130."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("InvasionBuster")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Invade THIS!: Complete 'Invasion'."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Invade THIS!: Complete 'Invasion'."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("SurvivalistExtreme")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Extreme Survivalist: Complete 'Surrounded 2.0'."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Extreme Survivalist: Complete 'Surrounded 2.0'."); + %index++; + } + // + return %index; + + case 12: + //Officer Promotion + messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Challenges:"); + %index++; + if(%client.CheckNWChallengeCompletion("Prestge1")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Instructive Private - Reach Officer Level 1."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Instructive Private - Reach Officer Level 1."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Prestge2")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Excelling Private - Reach Officer Level 2."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Excelling Private - Reach Officer Level 2."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Prestge3")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Private - Reach Officer Level 3."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Private - Reach Officer Level 3."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Prestge4")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Prestigious Private - Reach Officer Level 4."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Prestigious Private - Reach Officer Level 4."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Prestge5")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Supreme Private - Reach Officer Level 5."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Supreme Private - Reach Officer Level 5."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("Prestge9")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Phantom's Vengeance - Reach Oficer Level 9."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Phantom's Vengeance - Reach Oficer Level 9."); + %index++; + } + // + if(%client.CheckNWChallengeCompletion("GameEnder")) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Game Ender - Call in a Fission Bomb."); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Game Ender - Call in a Fission Bomb."); + %index++; + } + // + return %index; + + default: + //Invalid + messageClient( %client, 'SetLineHud', "", %tag, %index, "Invalid menu option passed to GenerateChallengeSubMenu."); + %index++; + return %index; + } +} \ No newline at end of file diff --git a/scripts/TWM2/Systems/Directorate.cs b/scripts/TWM2/Systems/Directorate.cs index 71d6b96..bdd0a95 100644 --- a/scripts/TWM2/Systems/Directorate.cs +++ b/scripts/TWM2/Systems/Directorate.cs @@ -35,5 +35,4 @@ function LoadClientFile(%client) { // loadChallengeData(%client); loadSettings(%client); - %client.storeCreate(); } diff --git a/scripts/TWM2/Systems/Killstreak.cs b/scripts/TWM2/Systems/Killstreak.cs index 0b81e57..7ed42a7 100644 --- a/scripts/TWM2/Systems/Killstreak.cs +++ b/scripts/TWM2/Systems/Killstreak.cs @@ -598,358 +598,6 @@ function GenerateKillstreakMenu(%client, %tag, %index) { return %index; } -///////////////////// -function GenerateStreakChallengeMenu(%client, %tag, %index) { - if(%client.CheckNWChallengeCompletion("UAV1")) { - if(%client.CheckNWChallengeCompletion("UAV2")) { - if(%client.CheckNWChallengeCompletion("UAV3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert III - Call in 150 UAV Recon Satellites"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert II - Call in 75 UAV Recon Satellites"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAV Expert I - Call in 30 UAV Recon Satellites"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Airstrike1")) { - if(%client.CheckNWChallengeCompletion("Airstrike2")) { - if(%client.CheckNWChallengeCompletion("Airstrike3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert III - Call in 125 Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert II - Call in 65 Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Airstrike Expert I - Call in 25 Airstrikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("UAMS1")) { - if(%client.CheckNWChallengeCompletion("UAMS2")) { - if(%client.CheckNWChallengeCompletion("UAMS3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert III - Call in 125 Missile Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert II - Call in 65 Missile Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "UAMS Expert I - Call in 25 Missile Strikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Helicopter1")) { - if(%client.CheckNWChallengeCompletion("Helicopter2")) { - if(%client.CheckNWChallengeCompletion("Helicopter3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert III - Call in 125 Combat Helicopters"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert II - Call in 65 Combat Helicopters"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Helicopter Expert I - Call in 25 Combat Helicopters"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Harrier1")) { - if(%client.CheckNWChallengeCompletion("Harrier2")) { - if(%client.CheckNWChallengeCompletion("Harrier3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert III - Call in 110 Plasma Harrier Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert II - Call in 55 Plasma Harrier Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harrier Expert I - Call in 20 Plasma Harrier Airstrikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("SatNuke1")) { - if(%client.CheckNWChallengeCompletion("SatNuke2")) { - if(%client.CheckNWChallengeCompletion("SatNuke3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert III - Call in 125 Orbital Laser Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert II - Call in 65 Orbital Laser Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "OLS Expert I - Call in 25 Orbital Laser Strikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("NapalmHarrier1")) { - if(%client.CheckNWChallengeCompletion("NapalmHarrier2")) { - if(%client.CheckNWChallengeCompletion("NapalmHarrier3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert III - Call in 110 Napalm Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert II - Call in 55 Napalm Airstrikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Napalm Airstrike Expert I - Call in 20 Napalm Airstrikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("GunHeli1")) { - if(%client.CheckNWChallengeCompletion("GunHeli2")) { - if(%client.CheckNWChallengeCompletion("GunHeli3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert III - Call in 110 Gunship Helicopters"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert II - Call in 55 Gunship Helicopters"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship Helicopter Expert I - Call in 20 Gunship Helicopters"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("SBomber1")) { - if(%client.CheckNWChallengeCompletion("SBomber2")) { - if(%client.CheckNWChallengeCompletion("SBomber3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert III - Call in 100 Stealth Bombers"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert II - Call in 50 Stealth Bombers"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Stealth Bomber Expert I - Call in 20 Stealth Bombers"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Gunship1")) { - if(%client.CheckNWChallengeCompletion("Gunship2")) { - if(%client.CheckNWChallengeCompletion("Gunship3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert III - Call in 75 Harbinger Gunships"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert II - Call in 35 Harbinger Gunships"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Harbinger Gunship Expert I - Call in 15 Harbinger Gunships"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Apache1")) { - if(%client.CheckNWChallengeCompletion("Apache2")) { - if(%client.CheckNWChallengeCompletion("Apache3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Expert III - Call in 75 Apache Gunners"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Expert II - Call in 35 Apache Gunners"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Apache Expert I - Call in 15 Apache Gunners"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Gunship3")) { - if(%client.CheckNWChallengeCompletion("ACGunship1")) { - if(%client.CheckNWChallengeCompletion("ACGunship2")) { - if(%client.CheckNWChallengeCompletion("ACGunship3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert III - Call in 75 AC130's"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert II - Call in 35 AC130's"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "AC-130 Expert I - Call in 15 AC130's"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Locked - Requires Harbinger Gunship Expert III."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Centaur1")) { - if(%client.CheckNWChallengeCompletion("Centaur2")) { - if(%client.CheckNWChallengeCompletion("Centaur3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert III - Call in 50 Artillery Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert II - Call in 25 Artillery Strikes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Centaur Artillery Expert I - Call in 10 Artillery Strikes"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("EMP1")) { - if(%client.CheckNWChallengeCompletion("EMP2")) { - if(%client.CheckNWChallengeCompletion("EMP3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert III - Call in 25 Mass EMP's"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert II - Call in 10 Mass EMP's"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "EMP Expert I - Call in 5 Mass EMP's"); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Nuke1")) { - if(%client.CheckNWChallengeCompletion("Nuke2")) { - if(%client.CheckNWChallengeCompletion("Nuke3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert III - Call in 25 Nukes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert II - Call in 10 Nukes"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Nuke Expert I - Call in 5 Nukes"); - %index++; - } - // - if(%client.TWM2Core.Officer >= 1) { - if(%client.CheckNWChallengeCompletion("Fission1")) { - if(%client.CheckNWChallengeCompletion("Fission2")) { - if(%client.CheckNWChallengeCompletion("Fission3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert - Challenge Set Complete"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert III - Call in 5 Fission Bombs"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert II - Call in 2 Fission Bombs"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Fission Bomb Expert I - Call in 1 Fission Bomb"); - %index++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Locked - Requires Instructive Officer Rank (Off. Rank 1)"); - %index++; - } - return %index; -} - function KS_Attenuate(%index) { if(isSet($KS_Attenuate[%index])) { return $KS_Attenuate[%index]; diff --git a/scripts/TWM2/Systems/MainControl.cs b/scripts/TWM2/Systems/MainControl.cs index 3f459b7..0f92b6c 100644 --- a/scripts/TWM2/Systems/MainControl.cs +++ b/scripts/TWM2/Systems/MainControl.cs @@ -246,53 +246,201 @@ function DefaultGame::ZkillUpdateScore(%game, %client, %implement, %zombie){ } function GameConnection::AwardZombieKill(%client, %zombie, %implement) { - if(%client $= "" || %client == 0) { - return; - } - %zombieType = %zombie.type; - //stop right now - if(%zombie.isBoss && %zombieType != 16) { - return; - } - if(%zombieType $= "") { - %zombieType = 1; - } - //Subduction for implement - if(%implement.getClassName() $= "Turret") { - %xpGain = mfloor($TWM2::ZombieXPAward[%zombieType] / 3); - } - else if(%implement.getDataBlock().catagory $= "Vehicles") { - %xpGain = mfloor($TWM2::ZombieXPAward[%zombieType] / 2); - } - else { - %xpGain = $TWM2::ZombieXPAward[%zombieType]; - } - // - if(%client.IsActivePerk("Double Down")) { - GainExperience(%client, %xpGain*2, "[D-D]"@$TWM2::ZombieName[%zombieType]@" Killed "); - } - else { - GainExperience(%client, %xpGain, ""@$TWM2::ZombieName[%zombieType]@" Killed "); - } - //Team Gain Perk - if(%client.IsActivePerk("Team Gain")) { - %TargetSearchMask = $TypeMasks::PlayerObjectType; - InitContainerRadiusSearch(%client.player.getPosition(), 20, %TargetSearchMask); //small distance - while ((%potentialTarget = ContainerSearchNext()) != 0){ - if (%potentialTarget.getPosition() != %pos) { - if(%potentialTarget.client.team == %client.team && %potentialTarget.client != %client) { - GainExperience(%potentialTarget.client, %xpGain, "Team gain from "@%client.namebase@" "); - } - } - } - } - //some zombies have weapons, throw it :) - %zombie.throwweapon(1); - //End - //HellJump? - if($TWM::PlayingHellJump || $TWM::PlayingHorde) { - Game.OnZombieDeath(%client, %zombie); - } + if(%client $= "" || %client == 0) { + return; + } + %zombieType = %zombie.type; + //stop right now + if(%zombie.isBoss && %zombieType != 16) { + return; + } + if(%zombieType $= "") { + %zombieType = 1; + } + %client.TWM2Core.zombiekills[%zombieType]++; + //Zombie Slayer Challenges (TWM2 3.9.1) + switch(%zombieType) { + case 1: + if(%client.TWM2Core.zombiekills[1] >= 2500) { + CompleteNWChallenge(%client, "NormHunter1"); + if(%client.TWM2Core.zombiekills[1] >= 5000) { + CompleteNWChallenge(%client, "NormHunter2"); + if(%client.TWM2Core.zombiekills[1] >= 10000) { + CompleteNWChallenge(%client, "NormHunter3"); + } + } + } + + case 2: + if(%client.TWM2Core.zombiekills[2] >= 1000) { + CompleteNWChallenge(%client, "RavHunter1"); + if(%client.TWM2Core.zombiekills[2] >= 2500) { + CompleteNWChallenge(%client, "RavHunter2"); + if(%client.TWM2Core.zombiekills[2] >= 5000) { + CompleteNWChallenge(%client, "RavHunter3"); + } + } + } + + case 3: + if(%client.TWM2Core.zombiekills[3] >= 1000) { + CompleteNWChallenge(%client, "LordHunter1"); + if(%client.TWM2Core.zombiekills[3] >= 2000) { + CompleteNWChallenge(%client, "LordHunter2"); + if(%client.TWM2Core.zombiekills[3] >= 3000) { + CompleteNWChallenge(%client, "LordHunter3"); + } + } + } + + case 4: + if(%client.TWM2Core.zombiekills[4] >= 1000) { + CompleteNWChallenge(%client, "DemonHunter1"); + if(%client.TWM2Core.zombiekills[4] >= 2500) { + CompleteNWChallenge(%client, "DemonHunter2"); + if(%client.TWM2Core.zombiekills[4] >= 5000) { + CompleteNWChallenge(%client, "DemonHunter3"); + } + } + } + + case 5: + if(%client.TWM2Core.zombiekills[5] >= 1500) { + CompleteNWChallenge(%client, "AirRapHunter1"); + if(%client.TWM2Core.zombiekills[5] >= 3500) { + CompleteNWChallenge(%client, "AirRapHunter2"); + if(%client.TWM2Core.zombiekills[5] >= 6000) { + CompleteNWChallenge(%client, "AirRapHunter3"); + } + } + } + + case 6: + if(%client.TWM2Core.zombiekills[6] >= 500) { + CompleteNWChallenge(%client, "DLordHunter1"); + if(%client.TWM2Core.zombiekills[6] >= 1000) { + CompleteNWChallenge(%client, "DLordHunter2"); + if(%client.TWM2Core.zombiekills[6] >= 1500) { + CompleteNWChallenge(%client, "DLordHunter3"); + } + } + } + + case 9: + if(%client.TWM2Core.zombiekills[9] >= 1500) { + CompleteNWChallenge(%client, "ShifterHunter1"); + if(%client.TWM2Core.zombiekills[9] >= 3000) { + CompleteNWChallenge(%client, "ShifterHunter2"); + if(%client.TWM2Core.zombiekills[9] >= 6000) { + CompleteNWChallenge(%client, "ShifterHunter3"); + } + } + } + + case 10: + if(%client.TWM2Core.zombiekills[10] >= 1000) { + CompleteNWChallenge(%client, "SummonerHunter1"); + if(%client.TWM2Core.zombiekills[10] >= 2500) { + CompleteNWChallenge(%client, "SummonerHunter2"); + if(%client.TWM2Core.zombiekills[10] >= 5000) { + CompleteNWChallenge(%client, "SummonerHunter3"); + } + } + } + + case 11: + if(%client.TWM2Core.zombiekills[11] >= 1000) { + CompleteNWChallenge(%client, "SniperHunter1"); + if(%client.TWM2Core.zombiekills[11] >= 2500) { + CompleteNWChallenge(%client, "SniperHunter2"); + if(%client.TWM2Core.zombiekills[11] >= 5000) { + CompleteNWChallenge(%client, "SniperHunter3"); + } + } + } + + case 12: + if(%client.TWM2Core.zombiekills[12] >= 1000) { + CompleteNWChallenge(%client, "UDemHunter1"); + if(%client.TWM2Core.zombiekills[12] >= 2500) { + CompleteNWChallenge(%client, "UDemHunter2"); + if(%client.TWM2Core.zombiekills[12] >= 5000) { + CompleteNWChallenge(%client, "UDemHunter3"); + } + } + } + + case 13: + if(%client.TWM2Core.zombiekills[13] >= 1000) { + CompleteNWChallenge(%client, "VRavHunter1"); + if(%client.TWM2Core.zombiekills[13] >= 2500) { + CompleteNWChallenge(%client, "VRavHunter2"); + if(%client.TWM2Core.zombiekills[13] >= 5000) { + CompleteNWChallenge(%client, "VRavHunter3"); + } + } + } + + case 14: + if(%client.TWM2Core.zombiekills[14] >= 1000) { + CompleteNWChallenge(%client, "SSHunter1"); + if(%client.TWM2Core.zombiekills[14] >= 2500) { + CompleteNWChallenge(%client, "SSHunter2"); + if(%client.TWM2Core.zombiekills[14] >= 5000) { + CompleteNWChallenge(%client, "SSHunter3"); + } + } + } + + case 15: + if(%client.TWM2Core.zombiekills[15] >= 500) { + CompleteNWChallenge(%client, "WraithHunter1"); + if(%client.TWM2Core.zombiekills[15] >= 750) { + CompleteNWChallenge(%client, "WraithHunter2"); + if(%client.TWM2Core.zombiekills[15] >= 1000) { + CompleteNWChallenge(%client, "WraithHunter3"); + } + } + } + } + + //END + //Subduction for implement + if (%implement.getClassName() $= "Turret") { + %xpGain = mfloor($TWM2::ZombieXPAward[%zombieType] / 3); + } + else if(%implement.getDataBlock().catagory $= "Vehicles") { + %xpGain = mfloor($TWM2::ZombieXPAward[%zombieType] / 2); + } + else { + %xpGain = $TWM2::ZombieXPAward[%zombieType]; + } + // + if(%client.IsActivePerk("Double Down")) { + GainExperience(%client, %xpGain*2, "[D-D]"@$TWM2::ZombieName[%zombieType]@" Killed "); + } + else { + GainExperience(%client, %xpGain, ""@$TWM2::ZombieName[%zombieType]@" Killed "); + } + //Team Gain Perk + if(%client.IsActivePerk("Team Gain")) { + %TargetSearchMask = $TypeMasks::PlayerObjectType; + InitContainerRadiusSearch(%client.player.getPosition(), 20, %TargetSearchMask); //small distance + while ((%potentialTarget = ContainerSearchNext()) != 0){ + if (%potentialTarget.getPosition() != %pos) { + if(%potentialTarget.client.team == %client.team && %potentialTarget.client != %client) { + GainExperience(%potentialTarget.client, %xpGain, "Team gain from "@%client.namebase@" "); + } + } + } + } + //some zombies have weapons, throw it :) + %zombie.throwweapon(1); + //End + //HellJump? + if($TWM::PlayingHellJump || $TWM::PlayingHorde) { + Game.OnZombieDeath(%client, %zombie); + } } function serverCmdCheckHTilt(%client) { @@ -472,144 +620,170 @@ function E_Sigma(%from, %to, %formula) { //to better control the current problems in the boss system. function TWM2Damage(%projectile, %target, %amount, %dType, %damLoc, %type) { - //terrain block - if(%target.getType() & ($TypeMasks::InteriorObjectType | $TypeMasks::TerrainObjectType)) { - return; - } + //terrain block + if(%target.getType() & ($TypeMasks::InteriorObjectType | $TypeMasks::TerrainObjectType)) { + return; + } - %data = %projectile.getDatablock(); - %sourceObject = %projectile.sourceObject; - %sourceClient = %sourceObject.client; - %targetClient = %target.client $= "" ? 0 : %target.client; - %TDB = %target.getDatablock(); - if(isObject(%sourceObject)) { - %SDB = %sourceObject.getDatablock(); - } - else { - %SDB = ""; - } - %total = 1; + %data = %projectile.getDatablock(); + %sourceObject = %projectile.sourceObject; + %sourceClient = %sourceObject.client; + %targetClient = %target.client $= "" ? 0 : %target.client; + %TDB = %target.getDatablock(); + if(isObject(%sourceObject)) { + %SDB = %sourceObject.getDatablock(); + } + else { + %SDB = ""; + } + %total = 1; - switch$(%type) { - case "projectile": - // - %target.headShot = 0; //Reset first - if(%sourceClient.ActivePerk["AP Bullets"]) { - %total *= 1.5; - } - if(%targetClient != 0) { - if(%targetClient.IsActivePerk("Kevlar Armor")) { - %total *= 0.5; - } - } - if(%target.isZombie) { - if(Game.CheckModifier("Demonic") == 1) { - %total = 0.5; - } - } - //------------------------------------------------------ - //source object fixing - if(strStr(%SDB.getClassName(), "Turret") != -1) { - if(%SDB.getName() $= "HarbingerGunshipTurret") { - %projectile.sourceObject = %projectile.sourceObject.mountobj; - } - else if(%SDB.getName() $= "AC130GunshipTurret") { - %projectile.sourceObject = %projectile.sourceObject.mountobj; - } - else if(%SDB.getName() $= "CentaurTurret") { - %projectile.sourceObject = %projectile.sourceObject.source; - } - } - //------------------------------------------------------ - //vehicle kill checking - if(strStr(%SDB.getClassName(), "Vehicle") != -1) { - if(%target.isPlayer() && %target.getState() $= "dead") { - %pl = %sourceObject.getMountNodeObject(0); //the pilot - %cl = %pl.client; - if(%cl !$= "") { - if(!%targetObject.isAllyBot) { - UpdateVehicleKillFile(%cl, %SDB.getName()); - } - // - if(%TDB $= "DemonMotherZombieArmor" && %SDB $= "CentaurVehicle") { - %cl.CDLKills++; - if(%cl.CDLKills >= 5) { - AwardClient(%cl, "19"); - } - } - } - } - } - //-------------------------------------------------------- - //Headshot checking - if(%damLoc $= "head" && %TDB.getClassName() $= "PlayerData") { - if(%data.HeadMultiplier !$= "") { - %modifier *= %data.HeadMultiplier; - } - if(%data.HeadShotKill && $TWM2::HeadshotKill) { - %target.headShot = 1; - } - if(%sourceClient !$= "") { - if(%sourceClient.UpgradeOn("HSBullets", %projectile.WeaponImageSource) && $TWM2::HeadshotKill) { - %target.headShot = 1; - } - } - if(%target.headShot) { - if(%targetClient != 0 && %targetClient.ActivePerk["Head Guard"]) { - %target.headShot = 0; - } - else { - if((!%target.isBoss && !%target.noHS) && !(%target.getShieldHealth() > 0)) { - if(%target.isZombie) { - if(%TDB $= "FZombieArmor") { - AwardClient(%sourceClient, "16"); - } - if(Game.CheckModifier("WheresMyHead") == 1) { - %target.headShot = 0; - } - else { - %total *= 1000; - } - } - else { - if(%target.isPilot() || %target.vehicleMounted) { - %target.headShot = 0; - } - else { - %total *= 1000; - if(%targetClient != 0) { - BottomPrint(%targetClient, "You Lost Your Head!!!", 3, 1); - } - } - } - } - } - } - } - else if(%damLoc $= "legs") { - if(%data.LegsMultiplier !$= "") { - %total *= %data.LegsMultiplier; - } - } - //All done! we should have filled the %total variable - case "explosion": - %total = 1; - if(%dType == $DamageType::RapierShield) { - if(%target == %sourceObject || %target.isZombie || %target.isBoss) { - %total = 0; - } - } - } - - %deal = %total * %amount; - if(%target.isBoss) { - if(%dType == $DamageType::SuperChaingun) { - %deal = 0; - } - %sourceClient.damageToBoss += %deal; - } - - return %total; + switch$(%type) { + //Projectiles... + case "projectile": + %target.headShot = 0; //Reset first + if(%sourceClient.ActivePerk["AP Bullets"]) { + %total *= 1.5; + } + if(%targetClient != 0) { + if(%targetClient.IsActivePerk("Kevlar Armor")) { + %total *= 0.5; + } + } + if(%target.isZombie) { + if(Game.CheckModifier("Demonic") == 1) { + %total = 0.5; + } + } + //------------------------------------------------------ + //source object fixing + if(strStr(%SDB.getClassName(), "Turret") != -1) { + if(%SDB.getName() $= "HarbingerGunshipTurret") { + %projectile.sourceObject = %projectile.sourceObject.mountobj; + } + else if(%SDB.getName() $= "AC130GunshipTurret") { + %projectile.sourceObject = %projectile.sourceObject.mountobj; + } + else if(%SDB.getName() $= "CentaurTurret") { + %projectile.sourceObject = %projectile.sourceObject.source; + } + } + //------------------------------------------------------ + //vehicle kill checking + if(strStr(%SDB.getClassName(), "Vehicle") != -1) { + if(%target.isPlayer() && %target.getState() $= "dead") { + %pl = %sourceObject.getMountNodeObject(0); //the pilot + %cl = %pl.client; + if(%cl !$= "") { + if(%target.client !$= "" && !%target.isZombie && %target.team != %pl.team) { + %cl.TWM2Core.PvPVehicleKills++; + if(%cl.TWM2Core.PvPVehicleKills >= 50) { + CompleteNWChallenge(%cl, "VehMans1"); + if(%cl.TWM2Core.PvPVehicleKills >= 100) { + CompleteNWChallenge(%cl, "VehMans2"); + if(%cl.TWM2Core.PvPVehicleKills >= 250) { + CompleteNWChallenge(%cl, "VehMans3"); + } + } + } + } + if(!%target.isAllyBot) { + UpdateVehicleKillFile(%cl, %SDB.getName()); + } + // + if(%TDB $= "DemonMotherZombieArmor" && %SDB $= "CentaurVehicle") { + %cl.CDLKills++; + if(%cl.CDLKills >= 5) { + AwardClient(%cl, "19"); + } + } + } + } + } + //-------------------------------------------------------- + //Headshot checking + if(%damLoc $= "head" && %TDB.getClassName() $= "PlayerData") { + if(%data.HeadMultiplier !$= "") { + %modifier *= %data.HeadMultiplier; + } + if(%data.HeadShotKill && $TWM2::HeadshotKill) { + %target.headShot = 1; + } + if(%sourceClient !$= "") { + if(%sourceClient.UpgradeOn("HSBullets", %projectile.WeaponImageSource) && $TWM2::HeadshotKill) { + %target.headShot = 1; + } + } + if(%target.headShot) { + if(%targetClient != 0 && %targetClient.ActivePerk["Head Guard"]) { + %target.headShot = 0; + } + else { + if((!%target.isBoss && !%target.noHS) && !(%target.getShieldHealth() > 0)) { + if(%target.isZombie) { + if(%TDB $= "FZombieArmor") { + AwardClient(%sourceClient, "16"); + } + // + if(Game.CheckModifier("WheresMyHead") == 1) { + %target.headShot = 0; + } + else { + %total *= 1000; + } + } + else { + if(%target.isPilot() || %target.vehicleMounted) { + %target.headShot = 0; + } + else { + %total *= 1000; + if(%targetClient != 0) { + BottomPrint(%targetClient, "You Lost Your Head!!!", 3, 1); + //Recording... + if(%sourceClient !$= "") { + %sourceClient.TWM2Core.PvPHeadshotKills++; + if(%sourceClient.TWM2Core.PvPHeadshotKills >= 100) { + CompleteNWChallenge(%sourceClient, "HSHoncho1"); + if(%sourceClient.TWM2Core.PvPHeadshotKills >= 200) { + CompleteNWChallenge(%sourceClient, "HSHoncho2"); + if(%sourceClient.TWM2Core.PvPHeadshotKills >= 300) { + CompleteNWChallenge(%sourceClient, "HSHoncho3"); + } + } + } + } + } + } + } + } + } + } + } + else if(%damLoc $= "legs") { + if(%data.LegsMultiplier !$= "") { + %total *= %data.LegsMultiplier; + } + } + + case "explosion": + %total = 1; + if(%dType == $DamageType::RapierShield) { + if(%target == %sourceObject || %target.isZombie || %target.isBoss) { + %total = 0; + } + } + } + + %deal = %total * %amount; + if(%target.isBoss) { + if(%dType == $DamageType::SuperChaingun) { + %deal = 0; + } + %sourceClient.damageToBoss += %deal; + } + + return %total; } //=============================================================================== diff --git a/scripts/TWM2/Systems/NWChallengeIndex.cs b/scripts/TWM2/Systems/NWChallengeIndex.cs index c19c53e..488b13b 100644 --- a/scripts/TWM2/Systems/NWChallengeIndex.cs +++ b/scripts/TWM2/Systems/NWChallengeIndex.cs @@ -54,43 +54,118 @@ $Challenge::Info["Nuke3"] = "Nuke Expert III\t1\t50000\tZ-Bomb Killstreak"; $Challenge::Info["Fission1"] = "Fission Bomb Expert I\t1\t25000\tNone"; $Challenge::Info["Fission2"] = "Fission Bomb Expert II\t1\t50000\tNone"; $Challenge::Info["Fission3"] = "Fission Bomb Expert III\t1\t75000\tNone"; +$Challenge::Info["LOAS1"] = "LOAS Expert I\t1\t25000\tNone"; +$Challenge::Info["LOAS2"] = "LOAS Expert II\t1\t50000\tNone"; +$Challenge::Info["LOAS3"] = "LOAS Expert III\t1\t75000\tNone"; //Bosses $Challenge::Info["Yvex1"] = "Nightmarish Enterprise\t2\t1000\tNone"; $Challenge::Info["Yvex2"] = "Darkness Rising\t2\t2500\tNone"; -$Challenge::Info["Yvex3"] = "Shadowy Desecration\t2\t5000\tLord Yvex Recruitable Ally"; +$Challenge::Info["Yvex3"] = "Shadowy Desecration\t2\t5000\tNone"; $Challenge::Info["CWS1"] = "Fortress In The Sky\t2\t1000\tNone"; $Challenge::Info["CWS2"] = "Aerieal Nightmare\t2\t2500\tNone"; $Challenge::Info["CWS3"] = "Harbinger's Bane\t2\t5000\tNone"; $Challenge::Info["GOL1"] = "Envious Lightning\t2\t1500\tNone"; $Challenge::Info["GOL2"] = "The Shocking Truth\t2\t3000\tNone"; $Challenge::Info["GOL3"] = "Severe Thunderstorm\t2\t6500\tNone"; +$Challenge::Info["GOF1"] = "Purifier\t2\t5000\tNone"; +$Challenge::Info["GOF2"] = "Inceneration Ender\t2\t10000\tNone"; +$Challenge::Info["GOF3"] = "Mt. Death Depleter\t2\t20000\tNone"; $Challenge::Info["Veg1"] = "Flaming Revolt\t2\t1500\tNone"; $Challenge::Info["Veg2"] = "Burning Frenzy\t2\t3000\tNone"; -$Challenge::Info["Veg3"] = "Firestorm Ender\t2\t6500\tGeneral Vegenor Recruitable Ally"; +$Challenge::Info["Veg3"] = "Firestorm Ender\t2\t6500\tNone"; $Challenge::Info["LRog1"] = "Revenge Halter\t2\t2500\tNone"; $Challenge::Info["LRog2"] = "Return to Returner\t2\t5000\tNone"; -$Challenge::Info["LRog3"] = "Payback's A Bitch\t2\t10000\tLord Rog Recruitable Ally"; +$Challenge::Info["LRog3"] = "Payback's A Bitch\t2\t10000\tNone"; $Challenge::Info["Ins1"] = "El Shipitor\t2\t2500\tNone"; $Challenge::Info["Ins2"] = "No Gravity, No Problem\t2\t5000\tNone"; -$Challenge::Info["Ins3"] = "Gravitational Influx\t2\t10000\tMajor Insignia Recruitable Ally"; +$Challenge::Info["Ins3"] = "Gravitational Influx\t2\t10000\tNone"; +$Challenge::Info["Stormrider1"] = "Clear Skies\t2\t2500\tNone"; +$Challenge::Info["Stormrider2"] = "Shootdown Master\t2\t5000\tNone"; +$Challenge::Info["Stormrider3"] = "Harbinger Fighter Demolisher\t2\t10000\tNone"; $Challenge::Info["Treb1"] = "Precious Cargo\t2\t2500\tNone"; $Challenge::Info["Treb2"] = "Harbinger Denied\t2\t5000\tNone"; $Challenge::Info["Treb3"] = "Tank Halter\t2\t10000\tNone"; $Challenge::Info["Vard1"] = "Shining Star\t2\t3500\tNone"; $Challenge::Info["Vard2"] = "Glare The Dark\t2\t7000\tNone"; -$Challenge::Info["Vard3"] = "Outevil The Wicked\t2\t12500\tLord Vardison Recruitable Ally"; +$Challenge::Info["Vard3"] = "Outevil The Wicked\t2\t12500\tNone"; $Challenge::Info["VardEasy"] = "The Standard Experience\t2\t7000\tNone"; -$Challenge::Info["VardNorm"] = "Demon Hunter\t2\t1500\tNone"; +$Challenge::Info["VardNorm"] = "Demon Hunter\t2\t15000\tNone"; $Challenge::Info["VardHard"] = "Master Demon Slayer\t2\t25000\tNone"; $Challenge::Info["VardWtf"] = "God of the Shadow Realm\t2\t50000\tNone"; -//Blacklist -$Challenge::Info["Acceptance"] = "Acceptance\t3\t1000\tNone"; -$Challenge::Info["ListHit"] = "Hitlister of The List\t3\t2500\tNone"; -$Challenge::Info["TopHit"] = "Champion Slayer\t3\t3500\tNone"; -$Challenge::Info["ButIm2"] = "But I'm #2\t3\t3500\tNone"; -$Challenge::Info["DF3"] = "Don't Forget #3\t3\t3500\tNone"; +$Challenge::Info["ShadeLord1"] = "Night Stalker\t2\t5000\tNone"; +$Challenge::Info["ShadeLord2"] = "Shadow Embracer\t2\t10000\tNone"; +$Challenge::Info["ShadeLord3"] = "Dawnlight Encarnate\t2\t20000\tNone"; + +//Blacklist: Depricated 3.9.1 +//$Challenge::Info["Acceptance"] = "Acceptance\t3\t1000\tNone"; +//$Challenge::Info["ListHit"] = "Hitlister of The List\t3\t2500\tNone"; +//$Challenge::Info["TopHit"] = "Champion Slayer\t3\t3500\tNone"; +//$Challenge::Info["ButIm2"] = "But I'm #2\t3\t3500\tNone"; +//$Challenge::Info["DF3"] = "Don't Forget #3\t3\t3500\tNone"; + +//Wargames +$Challenge::Info["Slayer1"] = "Slayer I\t3\t1000\tNone"; +$Challenge::Info["Slayer2"] = "Slayer II\t3\t2500\tNone"; +$Challenge::Info["Slayer3"] = "Slayer III\t3\t5000\tNone"; +$Challenge::Info["Slayer4"] = "Slayer IV\t3\t7500\tNone"; +$Challenge::Info["Slayer5"] = "Slayer V\t3\t10000\tNone"; +$Challenge::Info["Defectionator1"] = "Defectionator I\t3\t2500\tNone"; +$Challenge::Info["Defectionator2"] = "Defectionator II\t3\t5000\tNone"; +$Challenge::Info["Defectionator3"] = "Defectionator III\t3\t10000\tNone"; +$Challenge::Info["Infectionator1"] = "Infectionator I\t3\t2500\tNone"; +$Challenge::Info["Infectionator2"] = "Infectionator II\t3\t5000\tNone"; +$Challenge::Info["Infectionator3"] = "Infectionator III\t3\t10000\tNone"; +$Challenge::Info["HSHoncho1"] = "Headshot Honcho I\t3\t2500\tNone"; +$Challenge::Info["HSHoncho2"] = "Headshot Honcho II\t3\t5000\tNone"; +$Challenge::Info["HSHoncho3"] = "Headshot Honcho III\t3\t10000\tNone"; +$Challenge::Info["VehMans1"] = "Vehicular Manslaughter I\t3\t2500\tNone"; +$Challenge::Info["VehMans2"] = "Vehicular Manslaughter II\t3\t5000\tNone"; +$Challenge::Info["VehMans3"] = "Vehicular Manslaughter III\t3\t10000\tNone"; +$Challenge::Info["Assassin"] = "Assassinator\t3\t5000\tNone"; +$Challenge::Info["CompletelyUnexpected"] = "That Was... Unexpected\t3\t50000\tNone"; +$Challenge::Info["Uncomprehendable"] = "Uncomprehendable\t3\t100000\tNone"; + //Zombie Slaying +$Challenge::Info["NormHunter1"] = "Frontline Buster I\t4\t2500\tNone"; +$Challenge::Info["NormHunter2"] = "Frontline Buster II\t4\t5000\tNone"; +$Challenge::Info["NormHunter3"] = "Frontline Buster III\t4\t10000\tNone"; +$Challenge::Info["RavHunter1"] = "Speed Kills I\t4\t2500\tNone"; +$Challenge::Info["RavHunter2"] = "Speed Kills II\t4\t5000\tNone"; +$Challenge::Info["RavHunter3"] = "Speed Kills III\t4\t10000\tNone"; +$Challenge::Info["LordHunter1"] = "The Bigger They Are I\t4\t2500\tNone"; +$Challenge::Info["LordHunter2"] = "The Bigger They Are II\t4\t5000\tNone"; +$Challenge::Info["LordHunter3"] = "The Bigger They Are III\t4\t10000\tNone"; +$Challenge::Info["DemonHunter1"] = "Fire Retardant I\t4\t2500\tNone"; +$Challenge::Info["DemonHunter2"] = "Fire Retardant II\t4\t5000\tNone"; +$Challenge::Info["DemonHunter3"] = "Fire Retardant III\t4\t10000\tNone"; +$Challenge::Info["AirRapHunter1"] = "Bat Slayer I\t4\t2500\tNone"; +$Challenge::Info["AirRapHunter2"] = "Bat Slayer II\t4\t5000\tNone"; +$Challenge::Info["AirRapHunter3"] = "Bat Slayer III\t4\t10000\tNone"; +$Challenge::Info["DLordHunter1"] = "Hellspawn Erradicator I\t4\t2500\tNone"; +$Challenge::Info["DLordHunter2"] = "Hellspawn Erradicator II\t4\t5000\tNone"; +$Challenge::Info["DLordHunter3"] = "Hellspawn Erradicator III\t4\t10000\tNone"; +$Challenge::Info["ShifterHunter1"] = "Anti-Warp I\t4\t2500\tNone"; +$Challenge::Info["ShifterHunter2"] = "Anti-Warp II\t4\t5000\tNone"; +$Challenge::Info["ShifterHunter3"] = "Anti-Warp III\t4\t10000\tNone"; +$Challenge::Info["SummonerHunter1"] = "Horde Halter I\t4\t2500\tNone"; +$Challenge::Info["SummonerHunter2"] = "Horde Halter II\t4\t5000\tNone"; +$Challenge::Info["SummonerHunter3"] = "Horde Halter III\t4\t10000\tNone"; +$Challenge::Info["SniperHunter1"] = "Scope Breaker I\t4\t2500\tNone"; +$Challenge::Info["SniperHunter2"] = "Scope Breaker II\t4\t5000\tNone"; +$Challenge::Info["SniperHunter3"] = "Scope Breaker III\t4\t10000\tNone"; +$Challenge::Info["UDemHunter1"] = "Runner Down I\t4\t2500\tNone"; +$Challenge::Info["UDemHunter2"] = "Runner Down II\t4\t5000\tNone"; +$Challenge::Info["UDemHunter3"] = "Runner Down III\t4\t10000\tNone"; +$Challenge::Info["VRavHunter1"] = "C4 Coming Through I\t4\t2500\tNone"; +$Challenge::Info["VRavHunter2"] = "C4 Coming Through II\t4\t5000\tNone"; +$Challenge::Info["VRavHunter3"] = "C4 Coming Through III\t4\t10000\tNone"; +$Challenge::Info["SSHunter1"] = "De-Flakerizer I\t4\t2500\tNone"; +$Challenge::Info["SSHunter2"] = "De-Flakerizer II\t4\t5000\tNone"; +$Challenge::Info["SSHunter3"] = "De-Flakerizer III\t4\t10000\tNone"; +$Challenge::Info["WraithHunter1"] = "Anti Spec-Ops I\t4\t2500\tNone"; +$Challenge::Info["WraithHunter2"] = "Anti Spec-Ops II\t4\t5000\tNone"; +$Challenge::Info["WraithHunter3"] = "Anti Spec-Ops III\t4\t10000\tNone"; //Events $Challenge::Info["NewYearsEve"] = "New Years Eve Fireworks\t5\t1500\tJavelin Hellclass"; @@ -122,6 +197,9 @@ $Challenge::Info["Milestone25"] = "Milestone 25\t9\t25000\tNone"; $Challenge::Info["ArmyOf50Stopped"] = "Army Of 50 Stopped\t9\t50000\tSecond Chance Perk"; $Challenge::Info["Angel"] = "Angel\t9\t500\tNone"; $Challenge::Info["ZBomber"] = "Z-Bomber\t9\t2000\tNone"; +$Challenge::Info["FirstBlood"] = "First Blood\t9\t10000\tNone"; +$Challenge::Info["SpeedSlayer"] = "Speed Slayer\t9\t20000\tNone"; +$Challenge::Info["HighScorer"] = "High Scorer\t9\t25000\tNone"; //Helljump $Challenge::Info["GroupBuster"] = "Group Buster\t10\t5000\tNone"; @@ -139,9 +217,16 @@ $Challenge::Info["LifeGiver"] = "Giver of Life\t10\t7500\tNone"; //From The Top $Challenge::Info["SimonSays"] = "Simon Says\t11\t1000\tNone"; $Challenge::Info["FromTheTop"] = "From The Top\t11\t1000\tNone"; +$Challenge::Info["NaturalLeader"] = "Natural Leader\t11\t2500\tNone"; $Challenge::Info["GoldStar"] = "Gold Star\t11\t1000\tNone"; $Challenge::Info["Faster"] = "Faster!\t11\t250\tNone"; $Challenge::Info["EpicFailure"] = "Epic Failure\t11\t5\tNone"; +$Challenge::Info["ExpertGunner"] = "Expert AC-130 Gunner\t11\t25000\tNone"; +$Challenge::Info["Survivalist"] = "Survivalist\t11\t25000\tNone"; +$Challenge::Info["Invisibreh"] = "Shhh.. I'm Invisibreh\t11\t25000\tNone"; +$Challenge::Info["WeakGunship"] = "I have you now!\t11\t25000\tNone"; +$Challenge::Info["InvasionBuster"] = "Invade THIS!\t11\t25000\tNone"; +$Challenge::Info["SurvivalistExtreme"] = "Extreme Survivalist\t11\t50000\tNone"; //Prestige $Challenge::Info["Prestge1"] = "Instructive Private\t12\t100\tNone"; @@ -251,7 +336,7 @@ function CompleteNWChallenge(%client, %name) { %taskReward = getField($Challenge::Info[%name], 3); // GainExperience(%client, %taskXPGive, "Challenge "@%taskName@" Completed "); - BottomPrint(%client, "CHALLEGNE COMPLETE: "@%taskName@" \n +"@%taskXPGive@"XP, Reward: "@%taskReward@"", 2, 3); + BottomPrint(%client, "CHALLENGE COMPLETE: "@%taskName@" \n +"@%taskXPGive@"XP, Reward: "@%taskReward@"", 2, 3); MessageClient(%client, 'MsgSound', "~wfx/Bonuses/Nouns/General.wav"); MessageAll('msgComplete', "\c5"@%client.namebase@" completed challenge "@%taskName@""); // @@ -265,13 +350,13 @@ function CompleteNWChallenge(%client, %name) { function GenerateChallegnesMenu(%client, %tag, %index) { %scriptController = %client.TWM2Core; %xp = getCurrentEXP(%client); - messageClient( %client, 'SetLineHud', "", %tag, %index, "Other Challenges:"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Select a category to view challenges:"); %index++; // messageClient( %client, 'SetLineHud', "", %tag, %index, "PGD Challenges (Daily/Weekly/Monthly)"); %index++; if(%xp >= $Ranks::MinPoints[13]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Killstreak Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Killstreak Challenges: Tasks for calling in advanced support"); %index++; } else { @@ -280,25 +365,24 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%xp >= $Ranks::MinPoints[18]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Boss Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Boss Challenges: Tasks for eliminating the toughest enemies in TWM2"); %index++; } else { messageClient( %client, 'SetLineHud', "", %tag, %index, "Boss Challenges - Reach Gunnary Sergeant To Unlock"); %index++; } - // if(%xp >= $Ranks::MinPoints[23]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Blacklist Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Wargames Challenges: Tasks for eliminating enemy players in various ways"); %index++; } else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Blacklist Challenges - Reach Lieutenant To Unlock"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Wargames Challenges - Reach Lieutenant To Unlock"); %index++; } // if(%xp >= $Ranks::MinPoints[28]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Zombie Slaying Challenges (Coming Soon)"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Zombie Slaying Challenges: Tasks for eliminating combatants of the zombie horde"); %index++; } else { @@ -306,11 +390,11 @@ function GenerateChallegnesMenu(%client, %tag, %index) { %index++; } // - messageClient( %client, 'SetLineHud', "", %tag, %index, "Special Event Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Special Event Challenges: Tasks for playing TWM2 during special events"); %index++; // if(%xp >= $Ranks::MinPoints[40]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Sabotage Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Sabotage Challenges: Tasks related to the Sabotage game mode"); %index++; } else { @@ -319,7 +403,7 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%xp >= $Ranks::MinPoints[40]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Domination Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Domination Challenges: Tasks related to the Domination game mode"); %index++; } else { @@ -328,7 +412,7 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%xp >= $Ranks::MinPoints[40]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde 3 Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Horde 3 Challenges: Tasks related to surviving the waves of the zombie horde"); %index++; } else { @@ -337,7 +421,7 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%xp >= $Ranks::MinPoints[40]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Helljump Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Helljump Challenges: Tasks related to performing spec-ops Helljump operations"); %index++; } else { @@ -346,7 +430,7 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%xp >= $Ranks::MinPoints[40]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "From the top"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "From the top: Tasks related to ordering and completing missions"); %index++; } else { @@ -355,193 +439,12 @@ function GenerateChallegnesMenu(%client, %tag, %index) { } // if(%scriptController.officer >= 1) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Challenges"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Challenges: Tasks related to officer ranks and advanced progression"); %index++; } else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Challenges - Reach a Officer Rank To Unlock"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Challenges - Reach Instructive Private To Unlock"); %index++; } return %index; -} - -//SUB MENU GetNonWeapSubMenu(%client, %tag, %index, %challengeCategory) -function GetNonWeapSubMenu(%client, %tag, %index, %challengeCategory) { - switch(%challengeCategory) { - //Killstreaks - case 1: - //Killstreak.cs - %index = GenerateStreakChallengeMenu(%client, %tag, %index); - //Bosses - case 2: - %index = GenerateBossChallengeMenu(%client, %tag, %index); - //Blacklist - case 3: - messageClient( %client, 'SetLineHud', "", %tag, %index, "Blacklist Challenges:"); - %index++; - if(%client.CheckNWChallengeCompletion("Acceptance")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Acceptance: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Acceptance: Earn a Spot on the Blacklist 15."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ListHit")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Hitlister of The List: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Hitlister of The List: Kill a Blacklist Player."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("TopHit")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Slayer: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Champion Slayer: Kill the #1 Player on the Server."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("ButIm2")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "But I'm #2: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "But I'm #2: Kill the #2 Player on the Server."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("DF3")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Don't Forget #3: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Don't Forget #3: Kill the #3 Player on the Server."); - %index++; - } - // - //Zombie Slaying - case 4: - //Events - case 5: - messageClient( %client, 'SetLineHud', "", %tag, %index, "Special Event Challenges:"); - %index++; - if(%client.CheckNWChallengeCompletion("NewYearsEve")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Eve Fireworks: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Eve Fireworks: Get a Javelin Kill on New Years Eve."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("NewYears")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Fireworks: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "New Years Fireworks: Call in a nuke on New Years Day."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("GunshipMall")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship to The Mall: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gunship to The Mall: Call in a Gunship on Christmas Mall 2009."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("IndepRPG")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Independance RPG: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Independance RPG: Score an RPG Kill on the Fourth Of July."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("SoulsticeBombard")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Soulstice Bombard: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Soulstice Bombard: Call in artillery on one of the soulstices."); - %index++; - } - // - //PGD - case 6: - %index = GenerateDWMChallengeMenu(%client, %tag, %index); - //Sabotage - case 7: - %index = GenerateSabotageChallengeMenu(%client, %tag, %index); - //Domination - case 8: - %index = GenerateDominationChallengeMenu(%client, %tag, %index); - //Horde 2 - case 9: - %index = GenerateHordeChallengeMenu(%client, %tag, %index); - //Helljump - case 10: - %index = GenerateHelljumpChallengeMenu(%client, %tag, %index); - //FTT - case 11: - messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top Challenges:"); - %index++; - if(%client.CheckNWChallengeCompletion("SimonSays")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Simon Says: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Simon Says: Order a mission."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("FromTheTop")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "From The Top: Accept a mission."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("GoldStar")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gold Star: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Gold Star: Complete a mission within the time limit."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("Faster")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Faster!: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Faster!: Complete a mission, but miss the time limit."); - %index++; - } - // - if(%client.CheckNWChallengeCompletion("EpicFailure")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Epic Failure: Done."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Epic Failure: Fail a mission."); - %index++; - } - //Prestige - case 12: - %index = GeneratePrestigeChallengeMenu(%client, %tag, %index); - } - return %index; -} - +} \ No newline at end of file diff --git a/scripts/TWM2/Systems/ScoreHudInventory.cs b/scripts/TWM2/Systems/ScoreHudInventory.cs deleted file mode 100644 index 4d53fcb..0000000 --- a/scripts/TWM2/Systems/ScoreHudInventory.cs +++ /dev/null @@ -1,939 +0,0 @@ -//ScoreHudInventroy.cs -//Phantom139 - -//For TWM2, and other mods, A rework of the inventory system to be ran through the -//score menu, for easier use and classification of weapons, packs, and armors - -//one can simply disable it through this G-Var -//$ScoreHudInventory::Active = 1; - -package scoreHudInventory { - function DefaultGame::processGameLink(%game, %client, %arg1, %arg2, %arg3, %arg4, %arg5) { - %tag = $TagToUseForScoreMenu; - messageClient( %client, 'ClearHud', "", %tag, 1 ); - // - switch$(%arg1) { - case "inventoryWindow": - %index = buildInventoryWindow(%client, %tag, %index); - return; - - case "setScoreInv": - %subZone = %arg2; - switch$(%subZone) { - case "Armor": - %client.scoreHudInv[Armor] = %arg3; - case "Weapon": - //pull the current settings - %int = 1; - while(isSet(%client.scoreHudInv[Weapon, %int])) { - if(%client.scoreHudInv[Weapon, %int] $= %client.scoreHudInv[Weapon, %arg3]) { - %client.scoreHudInv[Weapon, %int] = ""; - } - %int++; - } - %slot = %arg3; - %client.scoreHudInv[Weapon, %slot] = %arg4; - //now do a post set check - %xSlot = 1; - while(isSet(%client.scoreHudInv[Weapon, %xSlot])) { - //no two may co-exist, IE: be the same - %iSlot = 1; - while(isSet(%client.scoreHudInv[Weapon, %iSlot])) { - if(%client.scoreHudInv[Weapon, %iSlot] $= %client.scoreHudInv[Weapon, %xSlot]) { - if(%iSlot != %xSlot) { - //remove iSlot, proceed - %client.scoreHudInv[Weapon, %iSlot] = ""; - } - } - %iSlot++; - } - %xSlot++; - } - case "Pistol": - %client.scoreHudInv[Pistol] = %arg3; - case "Melee": - %client.scoreHudInv[Melee] = %arg3; - case "Pack": - %client.scoreHudInv[Pack] = %arg3; - case "Grenade": - %client.scoreHudInv[Grenade] = %arg3; - case "Mine": - %client.scoreHudInv[Mine] = %arg3; - case "Ability": - %client.scoreHudInv[Ability] = %arg3; - default: - error("Unknown Call to setScoreInv: "@%arg2@"/"@%arg3@"/"@%arg4@""); - // - } - Game.processGameLink(%client, "inventoryWindow"); - return; - } - parent::processGameLink(%game, %client, %arg1, %arg2, %arg3, %arg4, %arg5); - } - - function pushScoreInventory(%client) { - messageClient(%client, 'OpenHud', "", 'scoreScreen' SPC "inventoryWindow"); - messageClient(%client, 'CloseHud', "", 'inventoryScreen' SPC "inventoryScreen"); - Game.processGameLink(%client, "inventoryWindow"); - } - - function InventoryScreen::updateHud( %this, %client, %tag ) { - if($ScoreHudInventory::Active == 1) { - pushScoreInventory(%client); - return; - } - else { - parent::updateHud( %this, %client, %tag ); - } - } - - function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice, %voicePitch ) { - Parent::onConnect( %client, %name, %raceGender, %skin, %voice, %voicePitch ); - %client.scoreHudInv[Armor] = "Purebuild"; - } - - //modification to the game's inventory buy functions - function buyFavorites(%client) { - if($ScoreHudInventory::Active == 1) { - if(!isObject(%client.player)) { - return; - } - if(%client.player.isZombie) { - return; - } - if (%client.isJailed) { - return; - } - if (!%client.isAdmin && !%client.isSuperAdmin) { - if ($Host::Purebuild == 1) { - %client.scoreHudInv[Armor] = "Purebuild"; - } - else { - if (%client.scoreHudInv[Armor] $= "Purebuild") { - %client.scoreHudInv[Armor] = "Scout"; - } - } - } - // don't forget -- for many functions, anything done here also needs to be done - // below in buyDeployableFavorites !!! - %client.player.clearInventory(); - %client.setWeaponsHudClearAll(); - %cmt = $CurrentMissionType; - - %curArmor = %client.player.getDatablock(); - %curDmgPct = getDamagePercent(%curArmor.maxDamage, %client.player.getDamageLevel()); - - // armor - %client.armor = $NameToInv[%client.scoreHudInv[Armor]]; - %client.player.setArmor( %client.armor ); - %newArmor = %client.player.getDataBlock(); - - %client.player.setDamageLevel(%curDmgPct * %newArmor.maxDamage); - %weaponCount = 0; - - DoPerksStuff(%client, %client.player); - // - - // weapons - %armor = getArmorDatablock(%client, $NameToInv[%client.scoreHudInv[Armor]]); - %slotCount = %armor.MaxWeapons; - if(%client.IsActivePerk("OverKill") == 1) { - %slotCount++; - } - for(%i = 1; %i <= %slotCount; %i++) { - %inv = $NameToInv[%client.scoreHudInv[Weapon, %i]]; - - if( %inv !$= "" ) { - %weaponCount++; - %client.player.setInventory( %inv, 1 ); - %WImg = %inv.Image; - if(%WImg.ClipName !$= "") { //apply clips - if(%client.IsActivePerk("Bandolier")) { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips * 2; - } - else { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips; - } - } - } - // z0dd - ZOD, 9/13/02. Streamlining. - if ( %inv.image.ammo !$= "" ) { - %client.player.setInventory( %inv.image.ammo, 400 ); - } - } - %client.player.weaponCount = %weaponCount; - // - - //pistol - %Pinv = $NameToInv[%client.scoreHudInv[Pistol]]; - - if( %Pinv !$= "" ) { - %client.player.setInventory( %Pinv, 1 ); - %WImg = %Pinv.Image; - if(%WImg.ClipName !$= "") { //apply clips - if(%client.IsActivePerk("Bandolier")) { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips * 2; - } - else { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips; - } - } - } - if ( %Pinv.image.ammo !$= "" ) { - %client.player.setInventory( %Pinv.image.ammo, 400 ); - } - - //melee - %meleeinv = $NameToInv[%client.scoreHudInv[Melee]]; - - if( %meleeinv !$= "" ) { - %client.player.setInventory( %meleeinv, 1 ); - } - - //pack/deployable/ect/you get the point :P - %pCh = $NameToInv[%client.scoreHudInv[Pack]]; - if(%pCh !$= "") { - %client.player.setInventory( %pCh, 1 ); - // if this pack is a deployable that has a team limit, warn the purchaser - // if it's a deployable turret, the limit depends on the number of players (deployables.cs) - if (isDeployableTurret(%pCh)) { - %maxDep = countTurretsAllowed(%pCh); - } - else { - %maxDep = $TeamDeployableMax[%pCh]; - } - if(%maxDep !$= "") { - %depSoFar = $TeamDeployedCount[%client.player.team, %pCh]; - %packName = %client.favorites[%client.packIndex]; - - if(Game.numTeams > 1) { - %msTxt = "Your team has "@%depSoFar@" of "@%maxDep SPC %packName@"s deployed."; - } - else { - %msTxt = "You have deployed "@%depSoFar@" of "@%maxDep SPC %packName@"s."; - } - messageClient(%client, 'MsgTeamDepObjCount', %msTxt); - } - } - // - - //Grenade - %nadeinv = $NameToInv[%client.scoreHudInv[Grenade]]; - - if( %nadeinv !$= "" ) { - %client.player.setInventory( %nadeinv, %armor.max[%nadeinv] ); - } - - //Mine - %Mineinv = $NameToInv[%client.scoreHudInv[Mine]]; - - if( %Mineinv !$= "" ) { - %client.player.setInventory( %Mineinv, %armor.max[%Mineinv] ); - } - - // - // miscellaneous stuff -- Repair Kit, Beacons, Targeting Laser - if ( !($InvBanList[%cmt, RepairKit]) ) - %client.player.setInventory( RepairKit, 1 ); - if ( !($InvBanList[%cmt, Beacon]) ) - %client.player.setInventory( Beacon, 400 ); - if ( !($InvBanList[%cmt, TargetingLaser]) ) - %client.player.setInventory( TargetingLaser, 1 ); - - // ammo pack pass -- hack! hack! - if( %pCh $= "AmmoPack" ) { - invAmmoPackPass(%client); - } - // give admins the Super Chaingun - GiveTWM2Weapons(%client); //includes SW's and admin stuff - // TODO - temporary - remove - if (%client.forceArmor !$= "") { - %client.player.setArmor(%client.forceArmor); - } - } - else { - parent::buyFavorites(%client); - } - } - - function buyDeployableFavorites(%client) { - if($ScoreHudInventory::Active == 1) { - if(%client.player.isZombie) { - return; - } - if (%client.isJailed) { - return; - } - if (!%client.isAdmin && !%client.isSuperAdmin) { - if ($Host::Purebuild == 1) { - %client.scoreHudInv[Armor] = "Purebuild"; - } - else { - if (%client.scoreHudInv[Armor] $= "Purebuild") { - %client.scoreHudInv[Armor] = "Scout"; - } - } - } - %player = %client.player; - %prevPack = %player.getMountedImage($BackpackSlot); - %player.clearInventory(); - %client.setWeaponsHudClearAll(); - %cmt = $CurrentMissionType; - - // players cannot buy armor from deployable inventory stations - %armor = getArmorDatablock(%client, $NameToInv[%client.scoreHudInv[Armor]]); - %slotCount = %armor.MaxWeapons; - if(%client.IsActivePerk("OverKill") == 1) { - %slotCount++; - } - %weapCount = 0; - for(%i = 1; %i <= %slotCount; %i++) { - %inv = $NameToInv[%client.scoreHudInv[Weapon, %i]]; - if (!($InvBanList[DeployInv, %inv])) { - %player.setInventory( %inv, 1 ); - // increment weapon count if current armor can hold this weapon - if(%player.getDatablock().max[%inv] > 0) { - %weapCount++; - } - - %WImg = %inv.Image; - if(%WImg.ClipName !$= "") { //apply clips - if(%client.IsActivePerk("Bandolier")) { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips * 2; - } - else { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips; - } - } - - // z0dd - ZOD, 9/13/02. Streamlining - if ( %inv.image.ammo !$= "" ) { - %player.setInventory( %inv.image.ammo, 400 ); - } - - if(%weapCount >= %player.getDatablock().maxWeapons) { - break; - } - } - } - %player.weaponCount = %weapCount; - //Update Pistol - %inv = $NameToInv[%client.scoreHudInv[Pistol]]; - if (!($InvBanList[DeployInv, %inv]) ) { - %player.setInventory( %inv, 1 ); - - %WImg = %inv.Image; - if(%WImg.ClipName !$= "") { //apply clips - if(%client.IsActivePerk("Bandolier")) { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips * 2; - } - else { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips; - } - } - - // z0dd - ZOD, 9/13/02. Streamlining - if ( %inv.image.ammo !$= "" ) { - %player.setInventory( %inv.image.ammo, 400 ); - } - } - //Update Melee - %meleeinv = $NameToInv[%client.scoreHudInv[Melee]]; - if ( !($InvBanList[DeployInv, %meleeinv]) ) { - %player.setInventory( %meleeinv, 1 ); - // z0dd - ZOD, 9/13/02. Streamlining - if ( %meleeinv.image.ammo !$= "" ) { - %player.setInventory( %meleeinv.image.ammo, 400 ); - } - } - // give player the grenades and mines they chose, beacons, and a repair kit - %nadeinv = $NameToInv[%client.scoreHudInv[Grenade]]; - if ( !($InvBanList[DeployInv, %nadeinv]) ) { - %player.setInventory( %nadeinv, 30 ); - } - %mineinv = $NameToInv[%client.scoreHudInv[Mine]]; - if ( !($InvBanList[DeployInv, %mineinv]) ) { - %player.setInventory( %mineinv, 30 ); - } - - if ( !($InvBanList[DeployInv, Beacon]) && !($InvBanList[%cmt, Beacon]) ) - %player.setInventory( Beacon, 400 ); - if ( !($InvBanList[DeployInv, RepairKit]) && !($InvBanList[%cmt, RepairKit]) ) - %player.setInventory( RepairKit, 1 ); - if ( !($InvBanList[DeployInv, TargetingLaser]) && !($InvBanList[%cmt, TargetingLaser]) ) - %player.setInventory( TargetingLaser, 1 ); - - // pack - any changes here must be added to dep below! - // players cannot buy deployable station packs from a deployable inventory station - %packChoice = $NameToInv[%client.scoreHudInv[Pack]]; - if ( !($InvBanList[DeployInv, %packChoice]) ) - %player.setInventory( %packChoice, 1 ); - - // if this pack is a deployable that has a team limit, warn the purchaser - // if it's a deployable turret, the limit depends on the number of players (deployables.cs) - if (isDeployableTurret(%packChoice)) { - %maxDep = countTurretsAllowed(%packChoice); - } - else { - %maxDep = $TeamDeployableMax[%packChoice]; - } - if((%maxDep !$= "") && (%packChoice !$= "InventoryDeployable")) { - %depSoFar = $TeamDeployedCount[%client.player.team, %packChoice]; - %packName = %client.favorites[%client.packIndex]; - - if(Game.numTeams > 1) { - %msTxt = "Your team has "@%depSoFar@" of "@%maxDep SPC %packName@"s deployed."; - } - else { - %msTxt = "You have deployed "@%depSoFar@" of "@%maxDep SPC %packName@"s."; - } - messageClient(%client, 'MsgTeamDepObjCount', %msTxt); - } - if(%packChoice $= "AmmoPack") { - invAmmoPackPass(%client); - } - GiveTWM2Weapons(%client); //includes SW's and admin stuff - } - else { - Parent::buyDeployableFavorites(%client); - } - } - - function getAmmoStationLovin(%client) { - if($ScoreHudInventory::Active == 1) { - //error("Much ammo station lovin applied"); - %cmt = $CurrentMissionType; - // weapons - %counter = %client.player.weaponSlotCount; - if(%client.IsActivePerk("OverKill")) { - %counter++; - } - for(%i = 0; %i < %counter; %i++) { - %weapon = %client.player.weaponSlot[%i]; - // z0dd - ZOD, 9/13/02. Streamlining - if ( %weapon.image.ammo !$= "" ) { - %client.player.setInventory( %weapon.image.ammo, 400 ); - } - - %WImg = %weapon.Image; - if(%WImg.ClipName !$= "") { //apply clips - if(%client.IsActivePerk("Bandolier")) { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips * 2; - } - else { - %client.player.ClipCount[%WImg.ClipName] = %WImg.InitialClips; - } - } - } - // miscellaneous stuff -- Repair Kit, Beacons, Targeting Laser - if ( !($InvBanList[%cmt, RepairKit]) ) - %client.player.setInventory( RepairKit, 1 ); - if ( !($InvBanList[%cmt, Beacon]) ) - %client.player.setInventory( Beacon, 400 ); - if ( !($InvBanList[%cmt, TargetingLaser]) ) - %client.player.setInventory( TargetingLaser, 1 ); - - %client.player.setInventory( Grenade, 0 ); - %client.player.setInventory( ConcussionGrenade, 0 ); - %client.player.setInventory( CameraGrenade, 0 ); - %client.player.setInventory( FlashGrenade, 0 ); - %client.player.setInventory( FlareGrenade, 0 ); - - // player should get the last type they purchased - %grenType = %client.player.lastGrenade; - - // if the player hasnt been to a station they get regular grenades - if(%grenType $= "") { - //error("no gren type, using default..."); - %grenType = Grenade; - } - if ( !($InvBanList[%cmt, %grenType]) ) - %client.player.setInventory( %grenType, 30 ); - - if( %client.player.getMountedImage($BackpackSlot) $= "AmmoPack") { - invAmmoPackPass(%client); - } - } - else { - parent::getAmmoStationLovin(%client); - } - } - - //End - - //THIS FUNCTION HERE IS THE BRAINS OF THE SYSTEM - //APPLY ALL MAJOR EDITS HERE - function buildInventoryWindow(%client, %tag, %index) { - %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "INVENTORY" ); - - //Required vars - %cmt = $CurrentMissionType; - %sO = %client.TWM2Core; - %xpHas = %sO.xp; - %prestige = %sO.officer; - if(%sO.officer $= "") { - %sO.officer = 0; - %prestige = %sO.officer; - } - // - - - //fully customizable inventory system, separate, yet better - messageClient( %client, 'SetLineHud', "", %tag, %index, "Score Hud Inventory System: Version 1.0, By Phantom139"); - %index++; - //* BEGIN ARMORS - messageClient( %client, 'SetLineHud', "", %tag, %index, "CURRENT ARMOR: "@%client.scoreHudInv[Armor]@""); - %index++; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, "Select Armor: "); - %index++; - //build the armor list, 3 armors per line - for (%y = 0; $InvArmor[%y] !$= ""; %y++) { - if ($InvArmor[%y] !$= %client.scoreHudInv[Armor]) { - %armorList = %armorList TAB $InvArmor[%y]; - } - } - if($TWM::PlayingInfection) { - %armorList = InfectionArmors(%client, %armorList); - } - else { - %armorList = updateArmorList(%client, %armorList); - } - // - %armors = getFieldCount(%armorList); - %arSC = 0; - for(%i = 0; %i < %armors; %i++) { - %armorString[%arSC] = %armorString[%arSC]@" * "@getField(%armorList, %i)@""; - if(%i % 3 == 0) { - %arSC++; - } - } - // - %arCT = 0; - while(isSet(%armorString[%arCt])) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%armorString[%arCt]@""); - %index++; - %arCT++; - } - //* END ARMORS - messageClient( %client, 'SetLineHud', "", %tag, %index, "* WEAPONS * "); - %index++; - //* BEGIN WEAPONS - // * Slot Count Determined by the armor, see this line :D - %armor = getArmorDatablock(%client, $NameToInv[%client.scoreHudInv[Armor]]); - %slotCount = %armor.MaxWeapons; - if(%client.IsActivePerk("OverKill") == 1) { - %slotCount++; - } - // EX: S3 Rifle - [Slot 1] * Slot 2 * Slot 3 - %wepGroup = 0; - while(isSet($SHI::WeaponGroup[%wepGroup])) { - %weapCounter = 0; - %weap = 0; - while(isSet($InvWeapon[%weap])) { - if($SHI::BlockToClass[$NameToInv[$InvWeapon[%weap]]] $= $SHI::WeaponGroup[%wepGroup]) { - if(%armor.max[$NameToInv[$InvWeapon[%weap]]]) { - %weapCounter++; - } - } - %weap++; - } - if(%weapCounter >= 1) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* "@$SHI::WeaponGroup[%wepGroup]@" *"); - %index++; - // - %weap = 0; - while(isSet($InvWeapon[%weap])) { - if($SHI::BlockToClass[$NameToInv[$InvWeapon[%weap]]] $= $SHI::WeaponGroup[%wepGroup]) { - %WInv = $NameToInv[$InvWeapon[%weap]]; - if(%armor.max[%WInv]) { - if(%WInv.Image.RankRequire $= "") { - %xpNeed = 0; - } - else { - %xpNeed = $Ranks::MinPoints[%WInv.Image.RankRequire]; - } - // - if(%WInv.Image.PrestigeRequire $= "") { - %prestigeNeed = 0; - } - else { - %prestigeNeed = %WInv.Image.PrestigeRequire; - } - // - if(%prestigeNeed $= "" || %prestigeNeed == 0) { - if(%xpNeed $= "" || %xpNeed == 0) { - if(%WInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %WInv.Image); - if(%canUse) { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - if (%xpHas >= %xpNeed && (isSet(%WInv.Image.RankRequire) ? %client.TWM2Core.rankNumber >= %WInv.Image.RankRequire : true )){ - if(%WInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %WInv.Image); - if(%canUse) { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - } - } - else { - if(%prestige >= %prestigeNeed) { - if(%xpNeed $= "" || %xpNeed == 0) { - if(%WInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %WInv.Image); - if(%canUse) { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - if (%xpHas >= %xpNeed && (isSet(%WInv.Image.RankRequire) ? %client.TWM2Core.rankNumber >= %WInv.Image.RankRequire : true )){ - if(%WInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %WInv.Image); - if(%canUse) { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - else { - %slotString = ""; - for(%i = 1; %i <= %slotCount; %i++) { - if(%client.scoreHudInv[Weapon, %i] $= $InvWeapon[%weap]) { - %slotString = %slotString @" [SLOT "@%i@"]"; - } - else { - %slotString = %slotString @" SLOT "@%i@" "; - } - } - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvWeapon[%weap]@" - "@%slotString@""); - %index++; - } - } - } - } - } - //} - } - } - %weap++; - } - } - %wepGroup++; - } - //* END WEAPONS - //* BEGIN PISTOL - if(!%client.IsActivePerk("OverKill")) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* PISTOL * "); - %index++; - for ( %y = 0; $InvPistol[%y] !$= ""; %y++ ) { - %PistolInv = $NameToInv[$InvPistol[%y]]; - if(%PistolInv.Image.RankRequire $= "") { - %xpNeed = 0; - } - else { - %xpNeed = $Ranks::MinPoints[%PistolInv.Image.RankRequire]; - } - // - if(%PistolInv.Image.PrestigeRequire $= "") { - %prestigeNeed = 0; - } - else { - %prestigeNeed = %PistolInv.Image.PrestigeRequire; - } - // - if(%PistolInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %PistolInv.Image); - } - else { - %canUse = 1; - } - if(%canUse) { - //XP Check Here - if(%prestige >= %prestigeNeed) { - if(%xpHas > %xpNeed && (isSet(%PistolInv.Image.RankRequire) ? %client.TWM2Core.rankNumber >= %PistolInv.Image.RankRequire : true )) { - if(%client.scoreHudInv[Pistol] $= $InvPistol[%y]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "["@$InvPistol[%y]@"]"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvPistol[%y]@""); - %index++; - } - } - } - } - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* PISTOL SLOT IS DISABLED -> OVERKILL PERK * "); - %index++; - } - //* END PISTOL - //* BEGIN MELEE - if(%client.scoreHudInv[Armor] !$= "Purebuild") { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* MELEE * "); - %index++; - for ( %y = 0; $InvMelee[%y] !$= ""; %y++ ) { - %meleeInv = $NameToInv[$InvMelee[%y]]; - if(%meleeInv.Image.MedalRequire) { - %canUse = DoMedalCheck(%client, %meleeInv.Image); - } - else { - %canUse = 1; - } - - if(%canUse) { - if(%client.scoreHudInv[Melee] $= $InvMelee[%y]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "["@$InvMelee[%y]@"]"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvMelee[%y]@""); - %index++; - } - } - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* MELEE SLOT IS DISABLED -> PUREBUILD ARMOR * "); - %index++; - } - //* END MELEE - //* BEGIN PACK/DEPLOYABLE - messageClient( %client, 'SetLineHud', "", %tag, %index, "* PACK * "); - %index++; - for ( %y = 0; $InvPack[%y] !$= ""; %y++ ) { - %PInv = $NameToInv[$InvPack[%y]]; - if (%armor.max[%PInv] && !$InvBanList[%cmt, %PInv]) { - %packList = %packList TAB $InvPack[%y]; - } - } - %packs = getFieldCount(%packList); - %arSC = 0; - for(%i = 0; %i < %packs; %i++) { - if(%client.scoreHudInv[Pack] $= getField(%packList, %i)) { - %packString[%arSC] = %packString[%arSC]@" * ["@getField(%packList, %i)@"]"; - } - else { - %packString[%arSC] = %packString[%arSC]@" * "@getField(%packList, %i)@""; - } - if(%i % 3 == 0) { - %arSC++; - } - } - // - %arCT = 0; - while(isSet(%packString[%arCt])) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%packString[%arCt]@""); - %index++; - %arCT++; - } - // -// messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvPack[%y]@""); -// %index++; - if(%client.scoreHudInv[Armor] $= "Purebuild") { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* BUILDER PACK * "); - %index++; - // - for ( %y = 0; $InvDep[%y] !$= ""; %y++ ) { - %PInv = $NameToInv[$InvDep[%y]]; - if (%armor.max[%PInv] && !$InvBanList[%cmt, %PInv]) { - %DepList = %DepList TAB $InvDep[%y]; - } - } - %packs = getFieldCount(%DepList); - %arSC = 0; - for(%i = 0; %i < %packs; %i++) { - if(%client.scoreHudInv[Pack] $= getField(%DepList, %i)) { - %DepString[%arSC] = %DepString[%arSC]@" * ["@getField(%DepList, %i)@"]"; - } - else { - %DepString[%arSC] = %DepString[%arSC]@" * "@getField(%DepList, %i)@""; - } - if(%i % 3 == 0) { - %arSC++; - } - } - // - %arCT = 0; - while(isSet(%DepString[%arCt])) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%DepString[%arCt]@""); - %index++; - %arCT++; - } - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "* BUILDER PACK IS DISABLED -> NON-PUREBUILD ARMOR * "); - %index++; - } - //* END PACK/DEPLOYABLE - //* BEGIN GRENADE - messageClient( %client, 'SetLineHud', "", %tag, %index, "* GRENADE * "); - %index++; - for (%y = 0; $InvGrenade[%y] !$= ""; %y++) { - %GInv = $NameToInv[$InvGrenade[%y]]; - if (%armor.max[%GInv] && !$InvBanList[%cmt, %GInv]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvGrenade[%y]@""); - %index++; - } - } - //* END GRENADE - //* BEGIN MINE - messageClient( %client, 'SetLineHud', "", %tag, %index, "* MINE * "); - %index++; - for (%y = 0; $InvMine[%y] !$= ""; %y++) { - %MInv = $NameToInv[$InvMine[%y]]; - if (%armor.max[%MInv] && !$InvBanList[%cmt, %MInv]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@$InvMine[%y]@""); - %index++; - } - } - //* END MINE - //* BEGIN ABILITY - messageClient( %client, 'SetLineHud', "", %tag, %index, "* ARMOR ABILITY * "); - %index++; - //* END ABILITY - //* SAVE SLOTS - messageClient( %client, 'SetLineHud', "", %tag, %index, "* SAVE SETTINGS * "); - %index++; - // - return %index; - } -}; -deactivatePackage(scoreHudInventory); -activatePackage(scoreHudInventory); - -//SHI -> Score Hud Inventory - -//New Inventory List Functions -//All Inventory itself is still handled by inventoryHud.cs -$SHI::WeaponGroup[0] = "Rifles"; -$SHI::WeaponGroup[1] = "Sniper Rifles"; -$SHI::WeaponGroup[2] = "SMGs"; -$SHI::WeaponGroup[3] = "MGs"; -$SHI::WeaponGroup[4] = "Shotguns"; -$SHI::WeaponGroup[5] = "Explosives"; -$SHI::WeaponGroup[6] = "Other"; -$SHI::WeaponGroup[7] = "Construction"; -// -$SHI::BlockToClass[S3Rifle] = "Rifles"; -$SHI::BlockToClass[G41Rifle] = "Rifles"; -$SHI::BlockToClass[M4A1] = "Rifles"; -$SHI::BlockToClass[lasergun] = "Rifles"; -$SHI::BlockToClass[ShadowRifle] = "Rifles"; -$SHI::BlockToClass[IonRifle] = "Rifles"; -$SHI::BlockToClass[PulseRifle] = "Rifles"; -$SHI::BlockToClass[G17SniperRifle] = "Sniper Rifles"; -$SHI::BlockToClass[M1SniperRifle] = "Sniper Rifles"; -$SHI::BlockToClass[R700SniperRifle] = "Sniper Rifles"; -$SHI::BlockToClass[ALSWPSniperRifle] = "Sniper Rifles"; -$SHI::BlockToClass[MP26] = "SMGs"; -$SHI::BlockToClass[Pg700] = "SMGs"; -$SHI::BlockToClass[MiniChaingun] = "SMGs"; -$SHI::BlockToClass[P90] = "SMGs"; -$SHI::BlockToClass[PulseSMG] = "SMGs"; -$SHI::BlockToClass[RP432] = "MGs"; -$SHI::BlockToClass[MRXX] = "MGs"; -$SHI::BlockToClass[MG42] = "MGs"; -$SHI::BlockToClass[M1700] = "Shotguns"; -$SHI::BlockToClass[Wp400] = "Shotguns"; -$SHI::BlockToClass[SA2400] = "Shotguns"; -$SHI::BlockToClass[SCD343] = "Shotguns"; -$SHI::BlockToClass[Model1887] = "Shotguns"; -$SHI::BlockToClass[MissileLauncher] = "Explosives"; -$SHI::BlockToClass[Stinger] = "Explosives"; -$SHI::BlockToClass[Javelin] = "Explosives"; -$SHI::BlockToClass[RPG] = "Explosives"; -$SHI::BlockToClass[PlasmaTorpedo] = "Explosives"; -$SHI::BlockToClass[IonLauncher] = "Other"; -$SHI::BlockToClass[flamer] = "Other"; -$SHI::BlockToClass[ConcussionGun] = "Other"; -$SHI::BlockToClass[MiniColliderCannon] = "Other"; -$SHI::BlockToClass[ConstructionTool] = "Construction"; -$SHI::BlockToClass[MergeTool] = "Construction"; -$SHI::BlockToClass[EditTool] = "Construction"; -$SHI::BlockToClass[EditorGun] = "Construction"; diff --git a/scripts/TWM2/Systems/Store.cs b/scripts/TWM2/Systems/Store.cs deleted file mode 100644 index 18b2971..0000000 --- a/scripts/TWM2/Systems/Store.cs +++ /dev/null @@ -1,572 +0,0 @@ -//Store.cs -//Phantom139, TWM2 3.6 - -//Handles all operations with client mula. - -$Store::Item["ArmorEffect", 0] = "Fireworks\t750000\tOn death, sends out a burst of red flares."; -$Store::Item["ArmorEffect", 1] = "False Explosion\t1250000\tAn explosion so real, but so false."; -$Store::Item["ArmorEffect", 2] = "Thunderstorm\t2000000\tEmit a great deal of sparks from your armor."; -$Store::Item["ArmorEffect", 3] = "Spontaneous Combustion\t3000000\tIt almost appears that you are always on fire."; -$Store::Item["ArmorEffect", 4] = "Guardian Flare\t5000000\tA glimmer of light, that follows you around."; -$Store::Item["ArmorEffect", 5] = "Hologram\t10000000\tMislead chasers with false player images."; -// -$Store::Item["ArmorFlag", 0] = "Silver Flag\t5\t0\tShines in the light of day."; -$Store::Item["ArmorFlag", 1] = "Blue Flag\t7\t0\tBlue as the sky, cold as snow."; -$Store::Item["ArmorFlag", 2] = "Red Flag\t8\t0\tHonor the call of battle, and show your pride."; -$Store::Item["ArmorFlag", 3] = "Gold Flag\t9\t0\tTime and dedication shows your honor."; - -function GameConnection::storeCreate(%client) { - %name = "Container_"@%client.guid@"/ClientStore"@%client.guid; - %check = nameToID(%name); - if(isObject(%check)) { - %client.store = %check; - %client.store.nextSlot = 0; - %client.store.nextLoto = 0; - echo("* Applying Client Store."); - } - else { - %client.store = new ScriptObject("ClientStore"@%client.guid) { - nextSlot = 0; - nextLoto = 0; - }; - %client.container.add(%client.store); - echo("* Creating Client Store"); - } -} - -//Store Operations -function GameConnection::showCentralStore(%client, %index, %tag) { - messageClient( %client, 'SetScoreHudSubheader', "", "Central Store" ); - %client.SCMPage = "SM"; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, "Current Money: $"@%client.TWM2Core.money@""); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "= SELECT AN OPTION ="); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, " * Armor Effects"); - %index++; - if(%client.TWM2Core.officer >= 5) { - messageClient( %client, 'SetLineHud', "", %tag, %index, " * Armor Flags"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, " * Armor Flags (Unlocked At 'Surpreme' Officer Level)"); - %index++; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, " * Slot Machine"); - %index++; - //messageClient( %client, 'SetLineHud', "", %tag, %index, " * Bounties"); - //%index++; //Maybe some other time *Phantom - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); - %index++; - // - return %index; -} - -function GameConnection::showArmorEffectsPage(%client, %index, %tag) { - messageClient( %client, 'SetScoreHudSubheader', "", "Central Store" ); - %client.SCMPage = "SM"; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, "Current Money: $"@%client.TWM2Core.money@""); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - // - %effectIndex = 0; - while(isSet($Store::Item["ArmorEffect", %effectIndex])) { - if(%client.getActiveAE() $= getField($Store::Item["ArmorEffect", %effectIndex], 0)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorEffect", %effectIndex], 0)@" [ACTIVE]"); - %index++; - } - else { - if(%client.hasStoreItem(getField($Store::Item["ArmorEffect", %effectIndex], 0))) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorEffect", %effectIndex], 0)@" - "@getField($Store::Item["ArmorEffect", %effectIndex], 2)@""); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorEffect", %effectIndex], 0)@"[$"@getField($Store::Item["ArmorEffect", %effectIndex], 1)@"] - "@getField($Store::Item["ArmorEffect", %effectIndex], 2)@""); - %index++; - } - } - %effectIndex++; - } - // - if(%client.getActiveAE() !$= "none") { - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Disable Armor Effect'); - %index++; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); - %index++; - return %index; -} - -function GameConnection::showArmorFlagPage(%client, %index, %tag) { - messageClient( %client, 'SetScoreHudSubheader', "", "Central Store" ); - %client.SCMPage = "SM"; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, "Current Money: $"@%client.TWM2Core.money@""); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "================================"); - %index++; - // - %flagIndex = 0; - while(isSet($Store::Item["ArmorFlag", %flagIndex])) { - if(%client.flagType $= trim(getWord(getField($Store::Item["ArmorFlag", %flagIndex], 0), 0))) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorFlag", %flagIndex], 0)@" [ACTIVE]"); - %index++; - } - else { - if(%client.hasStoreItem(getField($Store::Item["ArmorFlag", %flagIndex], 0))) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorFlag", %flagIndex], 0)@" - "@getField($Store::Item["ArmorFlag", %flagIndex], 3)@""); - %index++; - } - else { - if(%client.TWM2Core.officer < getField($Store::Item["ArmorFlag", %flagIndex], 1)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorFlag", %flagIndex], 0)@" - Higher Officer Rank Required."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@getField($Store::Item["ArmorFlag", %flagIndex], 0)@"[$"@getField($Store::Item["ArmorFlag", %flagIndex], 2)@"] - "@getField($Store::Item["ArmorFlag", %flagIndex], 3)@""); - %index++; - } - } - } - %flagIndex++; - } - // - if(%client.useFlag != 0) { - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Disable Armor Flag'); - %index++; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); - %index++; - return %index; -} - -//ARMOR EFFECTS -function GameConnection::hasStoreItem(%client, %item) { - %item = strReplace(%item, " ", ""); - if(!isSet(%client.store.purchased[%item])) { - %client.store.purchased[%item] = 0; - } - return %client.store.purchased[%item]; -} - -function GameConnection::getActiveAE(%client) { - %e = %client.activeArmorEffect; - if(!isSet(%e)) { - return "none"; - } - return %e; -} - -function GameConnection::setActiveAE(%client, %effect) { - // - if(%effect $= "0") { - %client.activeArmorEffect = ""; - return; - } - // - if(!%client.hasStoreItem(%effect)) { - messageClient(%client, 'msgFail', "\c3Error: You do not have this armor effect"); - %client.activeArmorEffect = ""; - return; - } - // - else { - %client.activeArmorEffect = %effect; - switch$(%effect) { - case "Thunderstorm": - ThunderstormLoop(%client); - case "Spontaneous Combustion": - SpontaniousLoop(%client); - case "Guardian Flare": - createGuardianFlare(%client); - case "Hologram": - DoHologramLoop(%client); - default: - //unknown, or nothing needed - } - } -} - -function GameConnection::setActiveAF(%client, %flag) { - if(%flag $= "0") { - %client.flagType = ""; - %client.useFlag = 0; - return; - } - // - if(!%client.hasStoreItem(%flag)) { - messageClient(%client, 'msgFail', "\c3Error: You do not have this armor flag"); - %client.flagType = ""; - %client.useFlag = 0; - return; - } - else { - switch$(%flag) { - case "Silver Flag": - %client.flagType = "Silver"; - %client.useFlag = 1; - case "Blue Flag": - %client.flagType = "Blue"; - %client.useFlag = 1; - case "Red Flag": - %client.flagType = "Red"; - %client.useFlag = 1; - case "Gold Flag": - %client.flagType = "Gold"; - %client.useFlag = 1; - default: - %client.flagType = ""; - %client.useFlag = 0; - } - } -} - -//this is called when someone dies. -function GameConnection::playDeathArmorEffect(%client) { - switch$(%client.getActiveAE()) { - case "none": - return; //stop here - case "Fireworks": - DeathEffect_Fireworks(%client.player.getPosition()); - case "False Explosion": - DeathEffect_FalseExpl(%client.player.getPosition()); - } -} - -//* FIREWORKS -//* $750,000 -//* A bright explosion of Red Flares when you die - -datablock FlareProjectileData(FireworksRedFlareProj) { - projectileShapeName = "grenade_projectile.dts"; - emitterDelay = -1; - directDamage = 0.0; - hasDamageRadius = false; - kickBackStrength = 1500; - useLensFlare = false; - - sound = FlareGrenadeBurnSound; - explosion = FlareGrenadeExplosion; - velInheritFactor = 0.5; - - texture[0] = "special/flare3"; - texture[1] = "special/LensFlare/flare00"; - size = 4.0; - - baseEmitter = FlareEmitter; - - grenadeElasticity = 0.35; - grenadeFriction = 0.2; - armingDelayMS = 6000; - muzzleVelocity = 15.0; - drag = 0.1; - gravityMod = 0.15; -}; - -datablock FlareProjectileData(GuardianFlare) { - projectileShapeName = "grenade_projectile.dts"; - emitterDelay = -1; - directDamage = 0.0; - hasDamageRadius = false; - kickBackStrength = 1500; - useLensFlare = false; - - sound = FlareGrenadeBurnSound; - explosion = FlareGrenadeExplosion; - velInheritFactor = 0.5; - - texture[0] = "special/flare3"; - texture[1] = "special/LensFlare/flare00"; - size = 4.0; - - baseEmitter = FlareEmitter; - - grenadeElasticity = 0.35; - grenadeFriction = 0.2; - armingDelayMS = 100; - muzzleVelocity = 15.0; - drag = 0.1; - gravityMod = 0.15; -}; - -function DeathEffect_Fireworks(%position) { - for(%i = 0; %i < getRandom(15, 25); %i++) { - %dir = vectorAdd(TWM2Lib_MainControl("getRandomPosition", 1 TAB 0), "0 0 2"); //all up - %fW = new (FlareProjectile)() { - datablock = FireworksRedFlareProj; - initialPosition = %position; - initialDirection = %dir; - }; - MissionCleanup.add(%fW); - } -} - -//* FALSE EXPLOSION -//* $1,250,000 -//* A detonation that looks so real, you won't believe it's not - -function DeathEffect_FalseExpl(%position) { - %c4 = new Item() { - datablock = C4Deployed; - position = %position; - scale = ".1 .1 .1"; - }; - MissionCleanup.add(%c4); - %c4.isFalse = 1; - schedule(500, 0, "C4GoBoom", %c4); -} - -//* Thunderstorm -//* $2,000,000 -//* Sparks fly in all directions from your active armor - -function ThunderstormLoop(%client) { - %player = %client.player; - if(!%player.isAlive() || %client.getActiveAE() !$= "Thunderstorm") { - return; - } - %c = createEmitter(%player.position, PBCExpEmitter, "1 0 0"); //Rotate it - %c.schedule(150, "Delete"); - schedule(getRandom(1300, 2500), 0, "ThunderstormLoop", %client); -} - -//* Spontaneous Combustion -//* $3,000,000 -//* It almost appears that you are on fire... always - -function SpontaniousLoop(%client) { - %player = %client.player; - if(!%player.isAlive() || %client.getActiveAE() !$= "Spontaneous Combustion") { - return; - } - %fire = new ParticleEmissionDummy(){ - position = %player.getPosition(); - dataBlock = "defaultEmissionDummy"; - emitter = "BurnEmitter"; - }; - MissionCleanup.add(%fire); - %fire.schedule(250, "delete"); - schedule(250, 0, "SpontaniousLoop", %client); -} - -//* Guardian Flare -//* $5,000,000 -//* This beacon of light follows you around at all times. - -function createGuardianFlare(%client) { - %player = %client.player; - if(!%player.isAlive() || %client.getActiveAE() !$= "Guardian Flare") { - return; - } - %flare = new (FlareProjectile)() { - dataBlock = GuardianFlare; - initialDirection = "0 0 3"; - initialPosition = vectorAdd(%player.getPosition(), "0 0 5"); - sourceObject = %player; - sourceSlot = 0; - }; - MissionCleanup.add(%flare); - %flare.PhotonMuzVec = %player.getMuzzleVector(0); - schedule( 100, 0, "guardianFlare", %player, %flare); -} - -function guardianFlare(%player, %flare) { - %projpos = %flare.position; - %projdir = %flare.initialdirection; - %type = %player.getClassName(); - if(!isobject(%flare)) { - return; - } - if(isobject(%flare)) { - %flare.delete(); - } - if(!%player.isAlive() || %player.client.getActiveAE() !$= "Guardian Flare") { - return; - } - //( ... )the projs now have a max turn angle like real missile ub3r l33t;;;; nm wtf afasdf - %test = getWord(%projdir, 0); - %test2 = getWord(%projdir, 1); - %test3 = getWord(%projdir, 2); - - %projdir = vectornormalize(vectorsub(%player.position, %projpos)); - %testa = getWord(%projdir, 0); - %testa2 = getWord(%projdir, 1); - %testa3 = getWord(%projdir, 2); - - // now it's time for my mad math skills..... i used microsoft calculator to figure this one out =0... was a brainbuster for me to think of how this would work - %testthing = %test - %testa; //oh u can rename all this test stuff but make sure u get it right =/ dont break plz - %testfin = %testthing / 10; //!!!!!!!!!! OK HERE!!!! is where the max angle thing is... increase for lower turn angle and reduce for a higher turn angle - %testfinal = %testfin * -1; //^^^^^ *side note for the one above this* dont div by zero unless yer dumb (...) div by i think 1 if you want it to seek with a 360 max turn angle angle... kinda gay though if u do that - %testfinale = %testfinal + %test; - - %testthing2 = %test2 - %testa2; - %testfin2 = %testthing2 / 10; //change here too .. this is for the y axis btw it's best if u leave my setting of 10 on ... it's the most balanced well nm change it to what u want but you really should leave it around this number like 9ish - %testfinal2 = %testfin2 * -1; - %testfinale2 = %testfinal2 + %test2; - - %testthing3 = %test3 - %testa3; - %testfin3 = %testthing3 / 20; //z- axis this one is for i think.. mmm idea... you try playing with dif max angles for xyz for maybe like a sidewinder effect =? - %testfinal3 = %testfin3 * -1; - %testfinale3 = %testfinal3 + %test3; - - %haxordir = %testfinale SPC %testfinale2 SPC %testfinale3; //final dir.. ..... - - %flare = new (FlareProjectile)() { - dataBlock = GuardianFlare; - initialDirection = %haxordir; - initialPosition = %projpos; - sourceslot = %player; - }; - %flare.sourceobject = %player; - MissionCleanup.add(%flare); - - %flare.seeksched = schedule(100, 0, "guardianFlare", %player, %flare); -} - -//* Hologram -//* $10,000,000 -//* False player images follow your every move. - -function doHologramLoop(%client) { - if(%client.player.IsAlive() && %client.getActiveAE() $= "Hologram") { - %race = %client.race; - if(%race $= "Bioderm") { - createBiodermProjection(%client.player); - } - else { - createHumanProjection(%client.player); - } - //schedule next hologram - schedule(1250, 0, "doHologramLoop", %client); - } -} - - - - - - - - - - - - - - - - - - - - - - - - - - - - -//****************************************************************************** -function GameConnection::loadSlotMachine(%client, %index, %tag) { - if(getSimTime() < %client.store.nextSlot) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "You are currently locked out of the slot machine, try back later."); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Store'); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "***************************"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "** LINE EM UP BONUS SLOT **"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "** LINE UP 3 TO SCORE **"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "** THREE SEVENS BONUS **"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "***************************"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, '[$50] PLAY MACHINE'); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Store'); - %index++; - } - return %index; -} - -function GameConnection::generateSlotMachineRoll(%client, %index, %tag) { - %client.TWM2Core.money -= 50; //start cost - for(%i = 1; %i <= 9; %i++) { - %roll[%i] = getRandom(1, 7); - %rollStr = %rollStr TAB %roll[%i]; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, "* "@%roll[1]@" == "@%roll[2]@" == "@%roll[3]@" *"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "* "@%roll[4]@" == "@%roll[5]@" == "@%roll[6]@" *"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "* "@%roll[7]@" == "@%roll[8]@" == "@%roll[9]@" *"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "***************************"); - %index++; - // - %client.TWM2Core.money += getSlotWinnings(%rollStr); - messageClient( %client, 'SetLineHud', "", %tag, %index, "* WINNINGS: $"@getSlotWinnings(%rollStr)@""); - %index++; - // - %client.store.nextSlot = getSimTime() + 25000; //25 seconds between runs - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Store'); - %index++; - return %index; -} - -function getSlotWinnings(%string) { - %winning = 0; - //tear the string - for(%i = 0; %i < getFieldCount(%string); %i++) { - %roll[%i+1] = getField(%string, %i); - } - //check for winning spins - for(%x = 1; %x <= 3; %x++) { - %one = ((%x-1)*3) + 1; - %two = ((%x-1)*3) + 2; - %three = ((%x-1)*3) + 3; - //*FIRST CASE: FULL CROSS: 5 5 5 - if(%roll[%one] $= %roll[%two] && %roll[%two] $= %roll[%three]) { - %winning += 100; - if(%roll[%one] $= "7" && %roll[%two] $= "7" && %roll[%three] $= "7") { - //jackpot ! - %winning += 9000; - } - } - } - //*SECOND CASE: Cross Diagonal X - //Only two possiblities here, I'll just if it. - if(%roll[1] $= %roll[5] && %roll[5] $= %roll[9]) { - %winning += 500; - if(%roll[1] $= "7" && %roll[5] $= "7" && %roll[9] $= "7") { - %winning += 45000; - } - } - if(%roll[3] $= %roll[5] && %roll[5] $= %roll[7]) { - %winning += 500; - if(%roll[3] $= "7" && %roll[5] $= "7" && %roll[7] $= "7") { - %winning += 45000; - } - } - // - return %winning; -} - -//****************************************************************************** diff --git a/scripts/TWM2/Systems/WeaponChallenges.cs b/scripts/TWM2/Systems/WeaponChallenges.cs index 89d23e1..d7ed083 100644 --- a/scripts/TWM2/Systems/WeaponChallenges.cs +++ b/scripts/TWM2/Systems/WeaponChallenges.cs @@ -234,11 +234,11 @@ function GenerateWChallengeSubMenu(%client, %tag, %index, %image) { %taskReq = getField(%Field, 1); // if(!%client.CheckChallengeCompletion(%image, %i)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%taskName@" - Need: "@%taskReq@""); + messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%taskName@" - Earn "@%taskReq@" Kills with this weapon"); %index++; } else { - messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%taskName@" - Complete"); + messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%taskName@" - Earn "@%taskReq@" Kills with this weapon"); %index++; } } diff --git a/scripts/TWM2/Systems/scoremenucmds.cs b/scripts/TWM2/Systems/scoremenucmds.cs index f32b033..7d8e6d9 100644 --- a/scripts/TWM2/Systems/scoremenucmds.cs +++ b/scripts/TWM2/Systems/scoremenucmds.cs @@ -19,107 +19,27 @@ function ConstructionGame::updateScoreHud(%game, %client, %tag){ } function ConstructionGame::processGameLink(%game, %client, %arg1, %arg2, %arg3, %arg4, %arg5){ -%tag = $TagToUseForScoreMenu; -messageClient( %client, 'ClearHud', "", %tag, 1 ); -//Stuff -if(%arg1 $= "") -%arg1 = "Null"; -if(%arg2 $= "") -%arg2 = "Null"; -if(%arg3 $= "") -%arg3 = "Null"; -if(%arg4 $= "") -%arg4 = "Null"; -if(%arg5 $= "") -%arg5 = "Null"; -//end -%scriptController = %client.TWM2Core; -echo("[F2] "@%client.namebase@": "@%arg1@", "@%arg2@", "@%arg3@", "@%arg4@", "@%arg5@"."); -switch$ (%arg1) -{ + %tag = $TagToUseForScoreMenu; + messageClient( %client, 'ClearHud', "", %tag, 1 ); + //Stuff + if(%arg1 $= "") + %arg1 = "Null"; + if(%arg2 $= "") + %arg2 = "Null"; + if(%arg3 $= "") + %arg3 = "Null"; + if(%arg4 $= "") + %arg4 = "Null"; + if(%arg5 $= "") + %arg5 = "Null"; + //end + %scriptController = %client.TWM2Core; + echo("[F2] "@%client.namebase@": "@%arg1@", "@%arg2@", "@%arg3@", "@%arg4@", "@%arg5@"."); + switch$ (%arg1) { case "GTP": scoreCmdMainMenu(%game,%client,$TagToUseForScoreMenu,%arg2); %client.SCMPage = %arg2; return; - //*********************************************************************** - //* TWM STORE - case "Store": - %dept = %arg2; - if(!isSet(%dept)) { - %index = %client.showCentralStore(%index, %tag); - } - else { - switch$(%dept) { - case "ArmorEffect": - %index = %client.showArmorEffectsPage(%index, %tag); - case "ArmorFlag": - %index = %client.showArmorFlagPage(%index, %tag); - case "SlotMachine": - %index = %client.loadSlotMachine(%index, %tag); - default: - %index = %client.showCentralStore(%index, %tag); - } - } - return; - - case "ArmorEffect": - %effect = %arg2; - %client.setActiveAE(%effect); - %game.schedule(100, "processGameLink", %client, "Store", "ArmorEffect"); - return; - - case "BuyArmorEffect": - %effectIndex = %arg2; - %money = %client.TWM2Core.money; - if(%money >= getField($Store::Item["ArmorEffect", %effectIndex], 1)) { - %client.TWM2Core.money -= getField($Store::Item["ArmorEffect", %effectIndex], 1); - %item = strReplace(getField($Store::Item["ArmorEffect", %effectIndex], 0), " ", ""); - %client.store.purchased[%item] = 1; - SaveClientFile(%client); - messageClient( %client, 'SetLineHud', "", %tag, %index, "Armor Effect Purchased."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Insufficient Funds To Purchase."); - %index++; - } - %game.schedule(1000, "processGameLink", %client, "Store", "ArmorEffect"); - return; - - case "ArmorFlag": - %flag = %arg2; - %client.setActiveAF(%flag); - %game.schedule(100, "processGameLink", %client, "Store", "ArmorFlag"); - return; - - case "BuyArmorFlag": - %flagIndex = %arg2; - %money = %client.TWM2Core.money; - if(%money >= getField($Store::Item["ArmorFlag", %flagIndex], 2)) { - %client.TWM2Core.money -= getField($Store::Item["ArmorFlag", %flagIndex], 2); - %item = strReplace(getField($Store::Item["ArmorFlag", %flagIndex], 0), " ", ""); - %client.store.purchased[%item] = 1; - SaveClientFile(%client); - messageClient( %client, 'SetLineHud', "", %tag, %index, "Armor Flag Purchased."); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Insufficient Funds To Purchase."); - %index++; - } - %game.schedule(1000, "processGameLink", %client, "Store", "ArmorFlag"); - return; - - case "SlotMachine": - %money = %client.TWM2Core.money; - if(%money < 50) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "You cannot play the slot machine."); - %index++; - %game.schedule(1000, "processGameLink", %client, "Store", ""); - return; - } - %index = %client.generateSlotMachineRoll(%index, %tag); - return; //***************************************************************************** @@ -147,16 +67,6 @@ switch$ (%arg1) } %xI++; } - //messageClient( %client, 'SetLineHud', "", %tag, %index, 'Rain Down - 3:00/Gunship Support [1P]'); - //%index++; - //messageClient( %client, 'SetLineHud', "", %tag, %index, 'Enemy AC-130 Above! - 15:00/Survival-Escape Mission [3P]'); - //%index++; - //messageClient( %client, 'SetLineHud', "", %tag, %index, 'Surrounded! - 5:00/Survival Mission [6P]'); - //%index++; - //messageClient( %client, 'SetLineHud', "", %tag, %index, '[NEW]Surrounded 2.0! - 10:00/Survival Mission [6P]'); - //%index++; - //messageClient( %client, 'SetLineHud', "", %tag, %index, 'The Shallowed City - 10:00/City Assault [4P/2R]'); - //%index++; } messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Main Menu'); %index++; @@ -173,7 +83,7 @@ switch$ (%arg1) %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, "Difficulty: "@$Mission::VarSet[""@%mission@"", "Difficulty"]@""); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Est. Time Completion: "@$Mission::VarSet[""@%mission@"", "TimeLimit"] / 60@" Minutes"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Mission Time Window: "@$Mission::VarSet[""@%mission@"", "TimeLimit"] / 60@" Minutes"); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, "Required Players: "@$Mission::VarSet[""@%mission@"", "PlayerReq"]@""); %index++; @@ -497,155 +407,198 @@ switch$ (%arg1) %index++; messageClient( %client, 'ClearHud', "", %tag, %index ); return; - - case "inventoryWindow": - %index = buildInventoryWindow(%client, %tag, %index); - return; + + case "StatResetWarn": + messageClient( %client, 'ClearHud', "", %tag, %index ); + messageClient( %client, 'SetScoreHudSubheader', "", "Stat Reset" ); + if(getCurrentEXP(%client) < $Ranks::MinPoints[61] && %scriptController.officer < 15) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "You must have the 'Harbinger Master Commander' Rank To Proceed."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); + %index++; + return; + } + %page = %arg2; + switch(%page) { + case 1: + messageClient( %client, 'SetLineHud', "", %tag, %index, "Congratulations on reaching the end of the rank progression!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "But, are you longing for that progression adventure once more?"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Do you feel like there's nothing to strive for anymore?"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "By reaching the last rank, you can choose to do a FULL RESET."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Get Me Out of Here'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Learn More'); + %index++; - case "setScoreInv": - %subZone = %arg2; - switch$(%subZone) { - case "Armor": - %client.scoreHudInv[Armor] = %arg3; - case "Weapon": - //pull the current settings - %int = 1; - while(isSet(%client.scoreHudInv[Weapon, %int])) { - if(%client.scoreHudInv[Weapon, %int] $= %client.scoreHudInv[Weapon, %arg3]) { - %client.scoreHudInv[Weapon, %int] = ""; - } - %int++; - } - %slot = %arg3; - %client.scoreHudInv[Weapon, %slot] = %arg4; - //now do a post set check - %xSlot = 1; - while(isSet(%client.scoreHudInv[Weapon, %xSlot])) { - //no two may co-exist, IE: be the same - %iSlot = 1; - while(isSet(%client.scoreHudInv[Weapon, %iSlot])) { - if(%client.scoreHudInv[Weapon, %iSlot] $= %client.scoreHudInv[Weapon, %xSlot]) { - if(%iSlot != %xSlot) { - //remove iSlot, proceed - %client.scoreHudInv[Weapon, %iSlot] = ""; - } - } - %iSlot++; - } - %xSlot++; - } - case "Pistol": - %client.scoreHudInv[Pistol] = %arg3; - case "Melee": - %client.scoreHudInv[Melee] = %arg3; - case "Pack": - %client.scoreHudInv[Pack] = %arg3; - case "Grenade": - %client.scoreHudInv[Grenade] = %arg3; - case "Mine": - %client.scoreHudInv[Mine] = %arg3; - case "Ability": - %client.scoreHudInv[Ability] = %arg3; - default: - error("Unknown Call to setScoreInv: "@%arg2@"/"@%arg3@"/"@%arg4@""); - } - Game.processGameLink(%client, "inventoryWindow"); - return; + case 2: + messageClient( %client, 'SetLineHud', "", %tag, %index, "By proceeding through here, you can reset at rank zero..."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "It will be like you've never played TWM2 before"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "All medals, challenges, unlocks will be removed."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "You only get to keep your play time and phrase."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "But, you can do it all over again!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Get Me Out of Here'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Continue'); + %index++; + + case 3: + messageClient( %client, 'SetLineHud', "", %tag, %index, "DANGER: THIS ACTION IS IRREVERSABLE!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "THIS IS YOUR LAST CHANCE TO ABORT"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "CLICK BELOW AT YOUR OWN RISK!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'No, I\'m Not Thinking Clearly!!!'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Wipe Me From TWM2 Existence'); + %index++; + + case 4: + WipeStats(%client); + messageClient( %client, 'SetLineHud', "", %tag, %index, "It has been done... Now... Begone!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Thank you for using the Phantom139 Memory wipe Services..."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); + %index++; + + } + return; case "PrestigeWarn": - messageClient( %client, 'ClearHud', "", %tag, %index ); - messageClient( %client, 'SetScoreHudSubheader', "", "Officer Ranks" ); - if(getCurrentEXP(%client) < $Ranks::MinPoints[61]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "You must have the 'Master Commander' Rank To Proceed."); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); - %index++; - return; - } - %page = %arg2; - switch(%page) { - case 1: - %next = %scriptController.officer + 1; - if(%scriptController.officer $= "" || %scriptController.officer == 0) { - %scriptController.officer = 0; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Welcome to the Officer Ranks!"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Congratulations on reaching the rank of Master Commander"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Now it's time to progress further!"); - %index++; - } - else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Welcome Back to Officer Ranking!"); - %index++; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, "The Officer Ranks are a way to hit the reset button in TWM2."); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "You will unlock many new things by proceeding through these"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer ranks, yet the path will become more challenging."); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Cancel'); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Continue'); - %index++; - case 2: - if(fetchCap("Officer", %next)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); - %index++; - return; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, "Although you will restart at the first rank, you gain"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "the "@$Prestige::Name[%scriptController.officer]++@"title with your rank."); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "This action cannot be undone once your rank is saved"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Are you sure you want to continue?"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'No'); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Yes'); - %index++; - case 3: - if(fetchCap("Officer", %next)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); - %index++; - return; - } - messageClient( %client, 'SetLineHud', "", %tag, %index, "This action CANNOT be undone once your rank is saved"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "This is your last chance to turn back"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Do Not Promote'); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Promote Me Now!'); - %index++; - case 4: - if(fetchCap("Officer", %next)) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); - %index++; - return; - } - PromoteToPrestige(%client); - messageClient( %client, 'SetLineHud', "", %tag, %index, "Congratulations, you have been promoted to the next Officer Rank!"); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); - %index++; - } - return; + messageClient( %client, 'ClearHud', "", %tag, %index ); + messageClient( %client, 'SetScoreHudSubheader', "", "Officer Ranks" ); + if(getCurrentEXP(%client) < $Ranks::MinPoints[61]) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "You must have the 'Master Commander' Rank To Proceed."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); + %index++; + return; + } + %page = %arg2; + switch(%page) { + case 1: + %next = %scriptController.officer + 1; + if(%scriptController.officer $= "" || %scriptController.officer == 0) { + %scriptController.officer = 0; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Welcome to the Officer Ranks!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Congratulations on reaching the rank of Master Commander"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "But if you thought you were done.... you thought wrong..."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "The Officer Ranks are your next step of progression in TWM2."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer promotion effectively hits that reset button on your account"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "restarting you at level one with zero EXP, but you'll move forward"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "This action is not in vain, as you unlock some cool new items!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "To assist your path, you'll gain some new EXP gain methods to help."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "So, with that in mind, are you ready to move on to the next step?"); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, "Welcome Back to Officer Ranking!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "You made it again! Master Commander once more!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "However, as you expected, you're still not done yet!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "As a reminder, you'll lose it all, but gain more."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "So, are you ready to enter the next office rank?"); + %index++; + } + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Cancel'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Continue'); + %index++; + + case 2: + if(fetchCap("Officer", %next)) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); + %index++; + return; + } + messageClient( %client, 'SetLineHud', "", %tag, %index, "Although you will restart at the level 1, you gain"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "the "@trim($Prestige::Name[%scriptController.officer + 1])@" title with your rank."); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Rewards Earned for Promoting to Officer Level "@%scriptController.officer + 1@":"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, " * 1 Additional Killstreak Slot"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, " * "@$Prestige::Rewards[%scriptController.officer + 1]); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "This action cannot be undone once your rank is saved"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Are you sure you want to continue?"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'No'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Yes'); + %index++; + + case 3: + if(fetchCap("Officer", %next)) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); + %index++; + return; + } + messageClient( %client, 'SetLineHud', "", %tag, %index, "WARNING This action CANNOT be undone!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "This is your last chance to turn back"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Do Not Promote'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Shut Up And Promote Me Now!'); + %index++; + + case 4: + if(fetchCap("Officer", %next)) { + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** This officer rank level is currently locked ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "*** Please try again at some other time/date ***"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return To Controls'); + %index++; + return; + } + PromoteToPrestige(%client); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Congratulations, you have promoted to a new officer rank!!!"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Exit'); + %index++; + } + return; case "PersControl": %client.SCMPage = "SM"; @@ -656,30 +609,40 @@ switch$ (%arg1) %index++; if(%scriptController.officer < $OfficerCap[$TWM2Core_Code, sha1sum(formattimestring("yymmdd"))]) { if(getCurrentEXP(%client) >= $Ranks::MinPoints[61]) { - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Promote To Next Officer Rank'); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Promote To Officer Level "@%scriptController.officer + 1@""); %index++; } else { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Ranking - Unlocked at Master Commander (Level 62)"); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Officer Ranking - Requires Master Commander (Level 62)"); %index++; } } else { messageClient( %client, 'SetLineHud', "", %tag, %index, "Maximum Officer Level Achieved, Congratulations!!!"); - %index++; + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Reset My Stats: Reset To Level 1, Officer 0"); + %index++; } if(%scriptController.officer >= 1) { - messageClient( %client, 'SetLineHud', "", %tag, %index, "Current Officer Rank Level: "@%scriptController.officer@""); + messageClient( %client, 'SetLineHud', "", %tag, %index, "Current Officer Rank Level: "@%scriptController.officer@" ("@trim($Prestige::Name[%scriptController.officer])@")"); %index++; } + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Weapon Attachments & Upgrades'); + %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Perks'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Killstreak Superweapons'); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Save Settings'); - %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'PGD Connect - In Game'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Save Game Settings'); %index++; + if(!%client.IsPGDConnected()) { + messageClient( %client, 'SetLineHud', "", %tag, %index, 'PGD Connect - In Game'); + %index++; + } + else { + messageClient( %client, 'SetLineHud', "", %tag, %index, 'PGD Connect Status: Connected'); + %index++; + } messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); @@ -713,31 +676,37 @@ switch$ (%arg1) %upgrade = %arg3; %client.DisableAllUpgrades(%image); //disable all first %client.ActivateUpgrade(%image, %upgrade); - %game.processGameLink(%client, "CompletedSub", %image); + %game.processGameLink(%client, "WeaponUpgradesSub", %image); return; case "DeActivateUpgrades": %image = %arg2; %client.DisableAllUpgrades(%image); //disable all - %game.processGameLink(%client, "CompletedSub", %image); + %game.processGameLink(%client, "WeaponUpgradesSub", %image); return; - case "CompletedSub": + case "WeaponUpgradesSub": %image = %arg2; %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Completed Challenges" ); + messageClient( %client, 'SetScoreHudSubheader', "", "Personal Settings" ); messageClient( %client, 'SetLineHud', "", %tag, %index, "Select A Upgrade To Use"); %index++; %index = GenerateCompletedSubMenu(%client, %tag, %index, %image); - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Jump to Weapon Challenge Page"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Weapon List'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Settings Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; return; - case "CompletedChallenge": + case "WeaponUpgrades": %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Completed Challenges" ); + messageClient( %client, 'SetScoreHudSubheader', "", "Personal Settings" ); messageClient( %client, 'SetLineHud', "", %tag, %index, "Select A Weapon"); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, ""); @@ -745,7 +714,7 @@ switch$ (%arg1) %index = GenerateCompletedChallegnesMenu(%client, %tag, %index); messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Settings Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; @@ -754,11 +723,17 @@ switch$ (%arg1) case "WeaponTasksSub": %image = %arg2; %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Weapon Challenges" ); + messageClient( %client, 'SetScoreHudSubheader', "", "Challenges" ); messageClient( %client, 'SetLineHud', "", %tag, %index, "Challenges:"); %index++; %index = GenerateWChallengeSubMenu(%client, %tag, %index, %image); - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, "Jump to Weapon Attachments Page"); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Weapon List'); + %index++; + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Challenge Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; @@ -766,7 +741,7 @@ switch$ (%arg1) case "WeaponsTasks": %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Weapon Challenges" ); + messageClient( %client, 'SetScoreHudSubheader', "", "Challenges" ); messageClient( %client, 'SetLineHud', "", %tag, %index, "Select A Weapon"); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, ""); @@ -774,7 +749,7 @@ switch$ (%arg1) %index = GenerateWeaponChallegnesMenu(%client, %tag, %index); messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Challenge Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; @@ -782,7 +757,7 @@ switch$ (%arg1) case "OtherTasks": %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Weapon Challenges" ); + messageClient( %client, 'SetScoreHudSubheader', "", "Challenges" ); messageClient( %client, 'SetLineHud', "", %tag, %index, "Select A Category"); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, ""); @@ -790,7 +765,7 @@ switch$ (%arg1) %index = GenerateChallegnesMenu(%client, %tag, %index); messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Challenge Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; @@ -799,38 +774,27 @@ switch$ (%arg1) case "OtherTasksSub": %client.SCMPage = "SM"; %cate = %arg2; - messageClient( %client, 'SetScoreHudSubheader', "", "Weapon Challenges" ); - %index = GetNonWeapSubMenu(%client, %tag, %index, %cate); + messageClient( %client, 'SetScoreHudSubheader', "", "Challenges" ); + %index = GenerateChallengeSubMenu(%client, %cate, %tag, %index); messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to challenge categories'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to General Tasks'); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to weapon challegnes'); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Return to Challenge Menu'); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); %index++; return; - case "WeaponChallenge": + case "Challenge": %client.SCMPage = "SM"; - messageClient( %client, 'SetScoreHudSubheader', "", "Weapon Challenges" ); - messageClient( %client, 'SetLineHud', "", %tag, %index, "Select An Option"); + messageClient( %client, 'SetScoreHudSubheader', "", "Challenges" ); + messageClient( %client, 'SetLineHud', "", %tag, %index, "TWM2 Challenges"); %index++; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, ""); + messageClient( %client, 'SetLineHud', "", %tag, %index, 'General Tasks'); %index++; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Weapon Upgrades'); - %index++; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Weapon Challenges'); - %index++; - // - messageClient( %client, 'SetLineHud', "", %tag, %index, 'Additional Challenges'); - %index++; - // - //%index = CreatePerkMenu(%client, %tag, %index); - // + messageClient( %client, 'SetLineHud', "", %tag, %index, 'Weapon Specific Challenges'); + %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, ""); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, 'Back to main menu'); @@ -848,7 +812,6 @@ switch$ (%arg1) } %rank = ""@$Prestige::Name[%targetController.officer]@""@%targetController.rank@""; %XP = printCurrentEXP(%arg2); - %mula = %targetController.money; %phrs = %targetController.phrase; %gmeTime = %targetController.gameTime; //Game Time @@ -870,8 +833,6 @@ switch$ (%arg1) //Card messageClient( %client, 'SetLineHud', "", %tag, %index, "Rank: "@%rank@", XP Points: "@%XP@"."); %index++; - messageClient( %client, 'SetLineHud', "", %tag, %index, "Money: $"@%mula@""); - %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, "TWM2 Time Played: "@%timeString@"."); %index++; messageClient( %client, 'SetLineHud', "", %tag, %index, "Phrase: "@%phrs@""); @@ -995,7 +956,7 @@ switch$ (%arg1) if(%client.namebase $= $Rank::Top[%i]) { messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%i@". "@$Rank::Top[%i]@" - "@$Rank::TopRank[%i]@" - "@$Rank::TopXP[%i]@"XP"); %index++; - CompleteNWChallenge(%client, "Acceptance"); + //CompleteNWChallenge(%client, "Acceptance"); } else { messageClient( %client, 'SetLineHud', "", %tag, %index, ""@%i@". "@$Rank::Top[%i]@" - "@$Rank::TopRank[%i]@" - "@$Rank::TopXP[%i]@"XP"); diff --git a/scripts/TWM2/Zombie/PlayerZombieFunctions.cs b/scripts/TWM2/Zombie/PlayerZombieFunctions.cs index 8c992bb..10f8666 100644 --- a/scripts/TWM2/Zombie/PlayerZombieFunctions.cs +++ b/scripts/TWM2/Zombie/PlayerZombieFunctions.cs @@ -180,7 +180,7 @@ function DoZombPlayerMaker(%client, %type) { Datablock = "ROGZombieArmor"; }; %player.NoHS = 1; - %player.isBoss = 1; + //%player.isBoss = 1; %player.isPlayerRog = 1; %player.mountImage(ZdummyslotImg, 4); diff --git a/scripts/TWM2/Zombie/ZombieTypes/DemonUltra.cs b/scripts/TWM2/Zombie/ZombieTypes/DemonUltra.cs index fb1c5ad..e2d1a9c 100644 --- a/scripts/TWM2/Zombie/ZombieTypes/DemonUltra.cs +++ b/scripts/TWM2/Zombie/ZombieTypes/DemonUltra.cs @@ -69,7 +69,7 @@ function UDemonZombiemovetotarget(%zombie){ %upvec = (%upvec * 5); %vector = %x@" "@%y@" "@%upvec; %zombie.applyImpulse(%pos, %vector); - createBiodermProjection(%zombie); + //createBiodermProjection(%zombie); } else if(%zombie.hastarget == 1){ %zombie.hastarget = 0; diff --git a/scripts/TWM2/Zombie/ZombieTypes/Shifter.cs b/scripts/TWM2/Zombie/ZombieTypes/Shifter.cs index b20c973..691f8a8 100644 --- a/scripts/TWM2/Zombie/ZombieTypes/Shifter.cs +++ b/scripts/TWM2/Zombie/ZombieTypes/Shifter.cs @@ -65,7 +65,7 @@ function ShifterZombiemovetotarget(%zombie){ if(%closestDistance > 200 || (%zombie.getVelocity() == 0 && !%zombie.RecentShift)) { %zombie.setVelocity("0 0 10"); %zombie.startFade(500, 0, true); - %zombie.schedule(600, "SetPosition", VectorAdd(%closestClient.getPosition(), "0 0 3")); + %zombie.schedule(600, "SetPosition", VectorAdd(%closestClient.getPosition(), vectorAdd("0 0 3", TWM2Lib_MainControl("getRandomPosition", "5\t1")))); %zombie.startFade(750, 0, false); %zombie.RecentShift = 1; Schedule(3500, 0, "eval", ""@%zombie@".RecentShift=0;"); diff --git a/scripts/TWM2/cmddisplaylist.txt b/scripts/TWM2/cmddisplaylist.txt index a869149..e3bfa24 100644 --- a/scripts/TWM2/cmddisplaylist.txt +++ b/scripts/TWM2/cmddisplaylist.txt @@ -1,11 +1,10 @@ CMD TSSF TWM 2, The Story Continues CMD MAINPAGE TWM 2 News CMD PersControl Settings -CMD Store TWM Store CMD Missions Missions CMD PC Piece Count CMD ContSave Content Saving System CMD BL15 Blacklist 15 -CMD WeaponChallenge Weapons Challenges +CMD Challenge Challenges CMD Ranks Player Info Listings CMD TWM TWM Mod Website diff --git a/scripts/defaultGame.cs b/scripts/defaultGame.cs index 0fa44cc..1a1afe2 100644 --- a/scripts/defaultGame.cs +++ b/scripts/defaultGame.cs @@ -967,6 +967,11 @@ function DefaultGame::onClientKilled(%game, %clVictim, %clKiller, %damageType, % %p.schedulePop(); MissionCleanup.add(%p); } + + if(%clKiller !$= "") { + %clVictim.lastKilledBy = %clKiller; + %clVictim.lastKilledByPlayer = %clKiller.player; + } //[[CHANGE]] Make sure the beacon get's removed.. as it should be.. :D %clvictim.player.RemoveBeacon(); diff --git a/scripts/player.cs b/scripts/player.cs index a6c8b89..e9069e1 100644 --- a/scripts/player.cs +++ b/scripts/player.cs @@ -2418,9 +2418,6 @@ function Armor::onAdd(%data,%obj) %obj.rechargeShields(%data.shieldHeathCharge); %obj.activeShieldEffect(); } - //TWM2: Activate Armor Effect - if(isClientControlledPlayer(%obj)) - %obj.client.setActiveAE(%obj.client.getActiveAE()); } function Armor::onRemove(%this, %obj) @@ -3414,9 +3411,20 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am } return; } - if(%damageType == $DamageType::Impact) - if(%sourceObject.getDamageState() $= "Destroyed") + if(%damageType == $DamageType::Impact) { + if(%sourceObject.getDamageState() $= "Destroyed") { return; + } + //Check for the mother of all humiliating deaths :) + if(%targetObject.getState() $= "dead") { + if(%sourceObject.getClassName() $= "FlyingVehicle" && %sourceObject.lastPilot.getState() $= "dead") { + if((%sourceObject.lastPilot.client.lastKilledBy == %targetObject.client) && (%sourceObject.lastPilot.client.lastKilledByPlayer == %targetObject)) { + //You just got rekt.... + CompleteNWChallenge(%sourceObject.lastPilot.client, "Uncomprehendable"); + } + } + } + } %armortype = %targetobject.getdatablock().getname(); if (%damageType == $DamageType::ZAcid && %armortype !$= "ZombieArmor" && %armortype !$= "FZombieArmor" && %armortype !$= "LordZombieArmor" && %armortype !$= "DemonZombieArmor" && %armortype !$= "DemonMotherZombieArmor" && %armortype !$= "RapierZombieArmor" && %targetobject.infected != 1 && (%sourceObject.isZombie == 1 || %sourceObject.isBoss == 1)){ %targetObject.Infected = 1; @@ -3673,12 +3681,24 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am } } // + if(%targetObject.getControllingClient() !$= "") { + %sourceClient.TWM2Core.PvPZombieKills++; + if(%sourceClient.TWM2Core.PvPZombieKills >= 100) { + CompleteNWChallenge(%sourceClient, "Defectionator1"); + if(%sourceClient.TWM2Core.PvPZombieKills >= 250) { + CompleteNWChallenge(%sourceClient, "Defectionator2"); + if(%sourceClient.TWM2Core.PvPZombieKills >= 500) { + CompleteNWChallenge(%sourceClient, "Defectionator3"); + } + } + } + } + // Game.ZkillUpdateScore(%sourceClient, %sourceObject, %targetObject); %sourceObject.zombiekillsinarow++; DoZKillstreakChecks(%sourceClient); } else { - %targetObject.client.playDeathArmorEffect(); if(%targetObject.team != %sourceClient.team && !%targetObject.isBoss) { if(isObject(%sourceClient) && %sourceClient.IsActivePerk("Double Down")) { GainExperience(%sourceClient, $TWM2::KillXPGain * 2, "[D-D]Enemy Killed "); @@ -3686,6 +3706,37 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am else { GainExperience(%sourceClient, $TWM2::KillXPGain, "Enemy Killed "); } + //Kill Recording.. + if(!%targetObject.isZombie && %sourceObject.isZombie) { + %sourceClient.TWM2Core.PvPHumanKills++; + if(%sourceClient.TWM2Core.PvPHumanKills >= 50) { + CompleteNWChallenge(%sourceClient, "Infectionator1"); + if(%sourceClient.TWM2Core.PvPHumanKills >= 100) { + CompleteNWChallenge(%sourceClient, "Infectionator2"); + if(%sourceClient.TWM2Core.PvPHumanKills >= 250) { + CompleteNWChallenge(%sourceClient, "Infectionator3"); + } + } + } + } + else { + %sourceClient.TWM2Core.PvPKills++; + if(%sourceClient.TWM2Core.PvPKills >= 100) { + CompleteNWChallenge(%sourceClient, "Slayer1"); + if(%sourceClient.TWM2Core.PvPKills >= 250) { + CompleteNWChallenge(%sourceClient, "Slayer2"); + if(%sourceClient.TWM2Core.PvPKills >= 500) { + CompleteNWChallenge(%sourceClient, "Slayer3"); + if(%sourceClient.TWM2Core.PvPKills >= 750) { + CompleteNWChallenge(%sourceClient, "Slayer4"); + if(%sourceClient.TWM2Core.PvPKills >= 1000) { + CompleteNWChallenge(%sourceClient, "Slayer5"); + } + } + } + } + } + } //Team Gain Perk if(isObject(%sourceClient) && %sourceClient.IsActivePerk("Team Gain")) { %TargetSearchMask = $TypeMasks::PlayerObjectType; @@ -3706,14 +3757,14 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am %sourceObject.kills[%damageType]++; PerformSuccessiveKills(%sourceObject, %damageType); // - if(%sourceObject.killsinarow2 == 10) { + if(%sourceObject.killsinarow2 == 10 && !(%sourceObject.isBoss || %sourceObject.isZombie)) { MessageAll('MsgWOW', "\c2TWM2: "@%sourceClient.namebase@" is on a killsteak of 10"); awardClient(%sourceClient, "14"); } - if(%sourceObject.killsinarow2 == 20) { + if(%sourceObject.killsinarow2 == 20 && !(%sourceObject.isBoss || %sourceObject.isZombie)) { MessageAll('MsgWOW', "\c2TWM2: "@%sourceClient.namebase@" is on a killsteak of 20"); } - if(%sourceObject.killsinarow2 == 25) { + if(%sourceObject.killsinarow2 == 25 && !(%sourceObject.isBoss || %sourceObject.isZombie)) { MessageAll('MsgWOW', "\c2TWM2: "@%sourceClient.namebase@" is on a killsteak of 25"); } DoKillstreakChecks(%sourceClient); @@ -3742,8 +3793,7 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am } function Armor::onImpact(%data, %playerObject, %collidedObject, %vec, %vecLen) { - %data.damageObject(%playerObject, 0, VectorAdd(%playerObject.getPosition(),%vec), - %vecLen * %data.speedDamageScale , $DamageType::Ground); + %data.damageObject(%playerObject, 0, VectorAdd(%playerObject.getPosition(),%vec), %vecLen * %data.speedDamageScale , $DamageType::Ground); // if (%collidedObject & $TypeMasks::PlayerObjectType) { // if (%collidedObject.getState() !$= "Dead") { // %data.damageObject(%collidedObject, 0, VectorAdd(%playerObject.getPosition(),%vec), diff --git a/scripts/projectiles.cs b/scripts/projectiles.cs index 7a7d2e2..ad91d45 100644 --- a/scripts/projectiles.cs +++ b/scripts/projectiles.cs @@ -27,9 +27,8 @@ function ProjectileData::onCollision(%data, %projectile, %targetObject, %modifie } %targetObject.lastDamagedImage = %projectile.getDatablock().ImageSource; %targetObject.damage(%projectile.sourceObject, %position, %modifier * %data.directDamage, %data.directDamageType); - - //After Damage Stuff For Player Objects - if(%targetObject.isPlayer()) { + + if (!(%targetObject.getType() & ($TypeMasks::InteriorObjectType | $TypeMasks::TerrainObjectType)) && %targetObject.getDataBlock().getClassName() $= "PlayerData") { if(%targetObject.getState() $= "dead") { if(%projectile.sourceObject.client !$= "") { if(%projectile.getDatablock().getName() !$= "GrenadeShrapnel") { diff --git a/scripts/weapons/Melee/BOV.cs b/scripts/weapons/Melee/BOV.cs index 3649493..87e9679 100644 --- a/scripts/weapons/Melee/BOV.cs +++ b/scripts/weapons/Melee/BOV.cs @@ -272,22 +272,30 @@ function DoBOVRearKill(%source, %target, %count) { %target.setvelocity("0 0 0"); } else if(%count == 17) { + if(%target.isZombie) { + recordAction(%source.client, "BACK", "zombie"); + if(%target.isPlayerRog && %target.getControllingClient() !$= "") { + if(!%source.client.CheckNWChallengeCompletion("CompletelyUnexpected")) { + CompleteNWChallenge(%source.client, "CompletelyUnexpected"); + } + } + } + else { + recordAction(%source.client, "BACK", "player"); + if(!%source.client.CheckNWChallengeCompletion("Assassin")) { + CompleteNWChallenge(%source.client, "Assassin"); + } + } //%target.blowup();//BAM! ServerPlay3d(BOVHitSound, %target.getPosition()); ServerPlay3d(BOVHitSound, %target.getPosition()); ServerPlay3d(BOVHitSound, %target.getPosition()); %target.damage(%source, %target.getposition(), 9999, $DamageType::BladeOfVengance); // - if(%target.isZombie) { - recordAction(%source.client, "BACK", "zombie"); - } - else { - recordAction(%source.client, "BACK", "player"); - } - // if(%target.client !$= "") { //a Player.. goodie MessageAll('MessageAll', "\c0"@%target.client.namebase@" was assassinated by "@%source.client.namebase@"."); } + //Challenges... %source.cannotuseBOV = 0; %source.setMoveState(false); return; diff --git a/scripts/weapons/Other/PlasmaTorpedo.cs b/scripts/weapons/Other/PlasmaTorpedo.cs index f73bbdc..d72c793 100644 --- a/scripts/weapons/Other/PlasmaTorpedo.cs +++ b/scripts/weapons/Other/PlasmaTorpedo.cs @@ -51,7 +51,7 @@ datablock ShapeBaseImageData(PlasmaTorpedoImage) { emap = true; RankRequire = $TWM2::RankRequire["SCD343"]; - PrestigeRequire = 4; + PrestigeRequire = 9; HasChallenges = 1; ChallengeCt = 8; diff --git a/scripts/weapons/Pistols/GrappleHook.cs b/scripts/weapons/Pistols/GrappleHook.cs index 9c7039e..8337e22 100644 --- a/scripts/weapons/Pistols/GrappleHook.cs +++ b/scripts/weapons/Pistols/GrappleHook.cs @@ -46,8 +46,8 @@ datablock SeekerProjectileData(GrappleShot) { // very quickly - bramage lifetimeMS = 500; // z0dd - ZOD, 4/14/02. Was 6000 - muzzleVelocity = 250.0; - maxVelocity = 350.0; // z0dd - ZOD, 4/14/02. Was 80.0 + muzzleVelocity = 200.0; + maxVelocity = 300.0; // z0dd - ZOD, 4/14/02. Was 80.0 turningSpeed = 54.0; acceleration = 50.0; @@ -94,7 +94,7 @@ datablock ShapeBaseImageData(GrappleHookImage) { projectileType = SeekerProjectile; usesEnergy = true; - minEnergy = 3; + minEnergy = 60; stateName[0] = "Activate"; stateTransitionOnTimeout[0] = "ActivateReady";