mirror of
https://github.com/PhantomGamesDevelopment/TWM2.git
synced 2026-07-11 06:24:37 +00:00
Perk Rework
This commit is contained in:
parent
6d24ae4cba
commit
54ca7686de
31 changed files with 305 additions and 320 deletions
|
|
@ -19,7 +19,7 @@ $Prestige::Name[14] = "Masterful ";
|
|||
$Prestige::Name[15] = "Harbinger ";
|
||||
|
||||
$Prestige::Rewards[0] = "";
|
||||
$Prestige::Rewards[1] = "Fission Bomb Strike, Double Down Perk";
|
||||
$Prestige::Rewards[1] = "Fission Bomb Strike";
|
||||
$Prestige::Rewards[2] = "Pulse Rifle";
|
||||
$Prestige::Rewards[3] = "Pulse SMG";
|
||||
$Prestige::Rewards[4] = "XVD4 Acid Launcher";
|
||||
|
|
|
|||
|
|
@ -443,12 +443,7 @@ function GameConnection::AwardZombieKill(%client, %zombie, %implement) {
|
|||
%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 ");
|
||||
}
|
||||
GainExperience(%client, %xpGain, ""@$TWM2::ZombieName[%zombieType]@" Killed ");
|
||||
//Team Gain Perk
|
||||
if(%client.IsActivePerk("Team Gain")) {
|
||||
%TargetSearchMask = $TypeMasks::PlayerObjectType;
|
||||
|
|
|
|||
|
|
@ -36,12 +36,15 @@ function CalculateProjectileDamage(%projectile, %target, %amount, %dType, %damLo
|
|||
//Projectiles...
|
||||
case "projectile":
|
||||
%target.headShot = 0; //Reset first
|
||||
if(%sourceClient.ActivePerk["AP Bullets"]) {
|
||||
%total *= 1.5;
|
||||
if(%sourceClient.IsActivePerk("AP Bullets")) {
|
||||
%total *= 1.15;
|
||||
if(strStr(%TDB.getClassName() $= "Turret") != -1 || && %TDB.getClassName() $= "VehicleData") {
|
||||
%total *= 1.33;
|
||||
}
|
||||
}
|
||||
if(%targetClient != 0) {
|
||||
if(%targetClient.IsActivePerk("Kevlar Armor")) {
|
||||
%total *= 0.5;
|
||||
%total *= 0.8;
|
||||
}
|
||||
}
|
||||
if(%target.isZombie) {
|
||||
|
|
@ -74,6 +77,11 @@ function CalculateProjectileDamage(%projectile, %target, %amount, %dType, %damLo
|
|||
if(%damLoc $= "head" && %TDB.getClassName() $= "PlayerData") {
|
||||
if(%data.HeadMultiplier !$= "") {
|
||||
%modifier *= %data.HeadMultiplier;
|
||||
if(%targetClient !$= "") {
|
||||
if(%targetClient.IsActivePerk("Armored Helmet")) {
|
||||
%modifier /= %data.HeadMultiplier;
|
||||
}
|
||||
}
|
||||
}
|
||||
if(%data.HeadShotKill && $TWM2::HeadshotKill) {
|
||||
%target.headShot = 1;
|
||||
|
|
@ -84,44 +92,39 @@ function CalculateProjectileDamage(%projectile, %target, %amount, %dType, %damLo
|
|||
}
|
||||
}
|
||||
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;
|
||||
}
|
||||
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 {
|
||||
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");
|
||||
}
|
||||
%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");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -137,6 +140,14 @@ function CalculateProjectileDamage(%projectile, %target, %amount, %dType, %damLo
|
|||
|
||||
case "explosion":
|
||||
%total = 1;
|
||||
if(%sourceClient.IsActivePerk("Powder Keg")) {
|
||||
%total *= 1.25;
|
||||
}
|
||||
if(%targetClient != 0) {
|
||||
if(%targetClient.IsActivePerk("Kevlar Armor")) {
|
||||
%total *= 0.75;
|
||||
}
|
||||
}
|
||||
if(%dType == $DamageType::RapierShield) {
|
||||
if(%target == %sourceObject || %target.isZombie || %target.isBoss) {
|
||||
%total = 0;
|
||||
|
|
@ -394,8 +405,12 @@ function postObjectDestroyed(%source, %targetObject, %dType, %dLoc) {
|
|||
//doChallengeKillRecording(%sourceObject, %targetObject);
|
||||
//martydom
|
||||
if(%targetClient !$= "" && %targetClient != 0 && %targetClient.IsActivePerk("Martydom")) {
|
||||
serverPlay3d(SatchelChargeActivateSound, %targetObject.getPosition());
|
||||
schedule(2200, 0, "MartydomExplode", %targetObject.getPosition(), %targetClient);
|
||||
if(%targetObject.inv[Grenade] > 0 || %targetObject.inv[ConcussionGrenade] > 0 || %targetObject.inv[FlashGrenade] > 0 || %targetObject.inv[StaticGrenade] > 0) {
|
||||
%targetObject.use(Grenade);
|
||||
}
|
||||
if(%targetObject.inv[C4] > 0) {
|
||||
%targetObject.use(Mine);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,151 +1,121 @@
|
|||
//The Perks
|
||||
//LIST
|
||||
$PerkRequire[1] = $Ranks::MinPoints[32];
|
||||
$PerkRequire[2] = $Ranks::MinPoints[40];
|
||||
$PerkRequire[7] = $Ranks::MinPoints[54];
|
||||
$PerkRequire[9] = $Ranks::MinPoints[43];
|
||||
$PerkRequire[10] = $Ranks::MinPoints[18];
|
||||
$PerkRequire[11] = $Ranks::MinPoints[36];
|
||||
$PerkRequire[15] = $Ranks::MinPoints[60];
|
||||
$PerkRequire[16] = $Ranks::MinPoints[46];
|
||||
$PerkRequire[21] = $Ranks::MinPoints[4];
|
||||
$PerkRequire[22] = $Ranks::MinPoints[45];
|
||||
// Perks.cs
|
||||
// 3.9.2 =: Major Rework
|
||||
|
||||
//PRIMARY - Weapon Modifications
|
||||
// AP Bullets [c] - Increase Damage to 150%
|
||||
// Advanced Grip [c] - Increase Accuracy On All Guns with Spread
|
||||
// AP Bullets [c] - Bullets deal 15% increased damage, damage to armored targets increased by 33%
|
||||
// Handling Expert [c] - Reduces weapon spread by a varying amount (Dependent on the weapon)
|
||||
// Wind Brake Beacon [c] - Beacon Key Stops Your Fall Instantly
|
||||
// 3 Second C4 [c] - C4 Detonates in 3 Seconds, not 10
|
||||
// Blade Sweep [c] - BoV Affects a small area instead of a single attack
|
||||
// Martydom [c] - Your armor explodes 4 seconds after death
|
||||
// Pistol God [c] - Removes All Spread On Certain Pistols
|
||||
// Double Down [c] - Gain double EXP for non boss Kills.
|
||||
// Martydom [c] - Upon death, drop a live grenade or C4 charge (if available)
|
||||
// Powder Keg [c] - Explosions deal 25% increased damage
|
||||
|
||||
//SECONDARY - Armor And Defense
|
||||
// OverKill [b] - Replaces your Pistol Slot with an Additional Weapon Slot
|
||||
// Kevlar Armor [c] - Increase Shielding to 150%
|
||||
// Head Guard [c] - Blocks Headshot Kills
|
||||
// Kevlar Armor [c] - Reduce incoming damage from bullets by 20%, explosions by 25%
|
||||
// Armored Helmet [c] - Removes the headshot multiplier on incoming rounds
|
||||
// Storm Barrier [c] - Reduce Electrical Damage, blocks lightning
|
||||
// Lim Zombie Shield [c] - 20% Chance that Zombies Will Be Repeled upon attack
|
||||
// No-Infect Armor [c] - Zombie Attacks will not infect you
|
||||
// Lim Zombie Shield [c] - Enhanced your armor with a specialized Lim-Zombie barrier, repelling incoming attackers before requiring a recharge
|
||||
// Undead Resistant Plating [c] - Zombie Attacks will not infect you
|
||||
// Radar Phantom [c] - Jam enemy sensors
|
||||
|
||||
//TERTIARY - Assets
|
||||
// Clip Boxes [c] - Cuts Reload Time By 33%
|
||||
// UAV Disabler [c] - You will not show on enemy UAVs
|
||||
// Team Gain [c] - All Teammates within 20M Of the Killer Gain XP
|
||||
// Double Time [c] - Cuts Reload Time By 50%
|
||||
// Ammo Vet [c] - Cuts Reload Time By 75%
|
||||
// Bandolier [c] - Increases Clips To 200%
|
||||
// Hardline [c] - Killstreaks require 1 less kill
|
||||
// Bomb Shadower [c] - You do not show a Sabotage Waypoint
|
||||
// Second Chance [c] - Spend a team revive to respawn in horde
|
||||
|
||||
$Perk::PerkCount[1] = 8;
|
||||
$Perk::PerkCount[2] = 6;
|
||||
$Perk::PerkCount[3] = 9;
|
||||
//TERTIARY - Assets
|
||||
// Reflexive Reloader [c] - Reduces weapon reload time by 33%
|
||||
// UAV Disabler [c] - You will not show on enemy UAVs
|
||||
// Team Gain [c] - All Teammates within 20M Of the Killer Gain XP
|
||||
// Bandolier [c] - Doubles your maximum clip capacity
|
||||
// Hardline [c] - Killstreaks require 1 less kill
|
||||
|
||||
$Perk::PerkCount[1] = 6;
|
||||
$Perk::PerkCount[2] = 8;
|
||||
$Perk::PerkCount[3] = 5;
|
||||
|
||||
$Perk::TotalPerks = $Perk::PerkCount[1] + $Perk::PerkCount[2] + $Perk::PerkCount[3];
|
||||
|
||||
$Perk::Perk[1] = "AP Bullets";
|
||||
$Perk::Perk[2] = "Advanced Grip";
|
||||
$Perk::Perk[2] = "Handling Expert";
|
||||
$Perk::Perk[3] = "Wind Brake Beacon";
|
||||
$Perk::Perk[4] = "3 Second C4";
|
||||
$Perk::Perk[5] = "Blade Sweep";
|
||||
$Perk::Perk[6] = "Martydom";
|
||||
$Perk::Perk[7] = "Pistol God";
|
||||
$Perk::Perk[8] = "Double Down";
|
||||
//$Perk::Perk[9] = "OverKill";
|
||||
$Perk::Perk[9] = "Kevlar Armor";
|
||||
$Perk::Perk[10] = "Head Guard";
|
||||
$Perk::Perk[11] = "Storm Barrier";
|
||||
$Perk::Perk[12] = "Lim Zombie Shield";
|
||||
$Perk::Perk[13] = "No-Infect Armor";
|
||||
$Perk::Perk[14] = "Radar Phantom";
|
||||
$Perk::Perk[15] = "Clip Boxes";
|
||||
$Perk::Perk[5] = "Martydom";
|
||||
$Perk::Perk[6] = "Powder Keg";
|
||||
$Perk::Perk[7] = "Kevlar Armor";
|
||||
$Perk::Perk[8] = "Armored Helmet";
|
||||
$Perk::Perk[9] = "Storm Barrier";
|
||||
$Perk::Perk[10] = "Lim Zombie Shield";
|
||||
$Perk::Perk[11] = "Undead Resistant Plating";
|
||||
$Perk::Perk[12] = "Radar Phantom";
|
||||
$Perk::Perk[13] = "Bomb Shadower";
|
||||
$Perk::Perk[14] = "Second Chance";
|
||||
$Perk::Perk[15] = "Reflexive Reloader";
|
||||
$Perk::Perk[16] = "UAV Disabler";
|
||||
$Perk::Perk[17] = "Team Gain";
|
||||
$Perk::Perk[18] = "Double Time";
|
||||
$Perk::Perk[19] = "Ammo Vet";
|
||||
$Perk::Perk[20] = "Bandolier";
|
||||
$Perk::Perk[21] = "Hardline";
|
||||
$Perk::Perk[22] = "Bomb Shadower";
|
||||
$Perk::Perk[23] = "Second Chance";
|
||||
$Perk::Perk[18] = "Bandolier";
|
||||
$Perk::Perk[19] = "Hardline";
|
||||
|
||||
$Perk::PerkToID["AP Bullets"] = 1;
|
||||
$Perk::PerkToID["Advanced Grip"] = 2;
|
||||
$Perk::PerkToID["Handling Expert"] = 2;
|
||||
$Perk::PerkToID["Wind Brake Beacon"] = 3;
|
||||
$Perk::PerkToID["3 Second C4"] = 4;
|
||||
$Perk::PerkToID["Blade Sweep"] = 5;
|
||||
$Perk::PerkToID["Martydom"] = 6;
|
||||
$Perk::PerkToID["Pistol God"] = 7;
|
||||
$Perk::PerkToID["Double Down"] = 8;
|
||||
//$Perk::PerkToID["OverKill"] = 9;
|
||||
$Perk::PerkToID["Kevlar Armor"] = 9;
|
||||
$Perk::PerkToID["Head Guard"] = 10;
|
||||
$Perk::PerkToID["Storm Barrier"] = 11;
|
||||
$Perk::PerkToID["Lim Zombie Shield"] = 12;
|
||||
$Perk::PerkToID["No-Infect Armor"] = 13;
|
||||
$Perk::PerkToID["Radar Phantom"] = 14;
|
||||
$Perk::PerkToID["Clip Boxes"] = 15;
|
||||
$Perk::PerkToID["Martydom"] = 5;
|
||||
$Perk::PerkToID["Powder Keg"] = 6;
|
||||
$Perk::PerkToID["Kevlar Armor"] = 7;
|
||||
$Perk::PerkToID["Armored Helmet"] = 8;
|
||||
$Perk::PerkToID["Storm Barrier"] = 9;
|
||||
$Perk::PerkToID["Lim Zombie Shield"] = 10;
|
||||
$Perk::PerkToID["Undead Resistant Plating"] = 11;
|
||||
$Perk::PerkToID["Radar Phantom"] = 12;
|
||||
$Perk::PerkToID["Bomb Shadower"] = 13;
|
||||
$Perk::PerkToID["Second Chance"] = 14;
|
||||
$Perk::PerkToID["Reflexive Reloader"] = 15;
|
||||
$Perk::PerkToID["UAV Disabler"] = 16;
|
||||
$Perk::PerkToID["Team Gain"] = 17;
|
||||
$Perk::PerkToID["Double Time"] = 18;
|
||||
$Perk::PerkToID["Ammo Vet"] = 19;
|
||||
$Perk::PerkToID["Bandolier"] = 20;
|
||||
$Perk::PerkToID["Hardline"] = 21;
|
||||
$Perk::PerkToID["Bomb Shadower"] = 22;
|
||||
$Perk::PerkToID["Second Chance"] = 23;
|
||||
$Perk::PerkToID["Bandolier"] = 18;
|
||||
$Perk::PerkToID["Hardline"] = 19;
|
||||
|
||||
$Perk::Descrip[1] = "Bullets do 50% More Damage";
|
||||
$Perk::Descrip[2] = "Improves Weapon Accuracy by 250%";
|
||||
|
||||
$Perk::Descrip[1] = "Bullets deal 15% increased damage, damage to armored targets increased by 33%";
|
||||
$Perk::Descrip[2] = "Reduces weapon spread by a varying amount (Dependent on the weapon)";
|
||||
$Perk::Descrip[3] = "Instantly Stop a fall with your beacon key";
|
||||
$Perk::Descrip[4] = "Your C4 Detonates in 3 Seconds, not 10";
|
||||
$Perk::Descrip[5] = "The BoV Affects a small area, not 1 target";
|
||||
$Perk::Descrip[6] = "Your armor explodes 4 seconds after death";
|
||||
$Perk::Descrip[7] = "Makes certain pistols 100% accurate";
|
||||
$Perk::Descrip[8] = "Gain Double EXP for non boss kills";
|
||||
//$Perk::Descrip[9] = "Adds an additional weapon slot to your armor";
|
||||
$Perk::Descrip[9] = "Increases your armor by 50%";
|
||||
$Perk::Descrip[10] = "Prevents you from being Headshot Killed";
|
||||
$Perk::Descrip[11] = "Protects you from electrical attacks";
|
||||
$Perk::Descrip[12] = "20% chance to deflect zombie attackers";
|
||||
$Perk::Descrip[13] = "Prevents you from being infected";
|
||||
$Perk::Descrip[14] = "Jam enemy sensors";
|
||||
$Perk::Descrip[15] = "Reduces reload time by 33%";
|
||||
$Perk::Descrip[4] = "Your C4 Detonates in 3 seconds instead of 10 seconds";
|
||||
$Perk::Descrip[5] = "Upon death, drop a live grenade or C4 charge (if available)";
|
||||
$Perk::Descrip[6] = "Explosions deal 25% increased damage";
|
||||
$Perk::Descrip[7] = "Reduce incoming damage from bullets by 20%, explosions by 25%";
|
||||
$Perk::Descrip[8] = "Removes the headshot multiplier on incoming rounds";
|
||||
$Perk::Descrip[9] = "Protects you from electrical attacks";
|
||||
$Perk::Descrip[10] = "Enhanced your armor with a specialized Lim-Zombie barrier, repelling incoming attackers before requiring a recharge";
|
||||
$Perk::Descrip[11] = "Prevents you from being infected";
|
||||
$Perk::Descrip[12] = "Jam enemy sensors";
|
||||
$Perk::Descrip[13] = "You do not show a Sabotage Waypoint";
|
||||
$Perk::Descrip[14] = "Spend a team revive to respawn in horde";
|
||||
$Perk::Descrip[15] = "Reduces weapon reload time by 33%";
|
||||
$Perk::Descrip[16] = "You will not show on enemy UAVs";
|
||||
$Perk::Descrip[17] = "Allies near you will gain XP for your kills";
|
||||
$Perk::Descrip[18] = "Reduces reload time by 50%";
|
||||
$Perk::Descrip[19] = "Reduces reload time by 75%";
|
||||
$Perk::Descrip[20] = "Doubles your initial clip count";
|
||||
$Perk::Descrip[21] = "Killstreaks require 1 less kill to earn";
|
||||
$Perk::Descrip[22] = "You do not show a Sabotage Waypoint";
|
||||
$Perk::Descrip[23] = "Spend a team revive to respawn in horde";
|
||||
$Perk::Descrip[18] = "Doubles your maximum clip capacity";
|
||||
$Perk::Descrip[19] = "Killstreaks require 1 less kill to earn";
|
||||
|
||||
|
||||
$Perk::PerkToGroup["AP Bullets"] = 1;
|
||||
$Perk::PerkToGroup["Advanced Grip"] = 1;
|
||||
$Perk::PerkToGroup["Handling Expert"] = 1;
|
||||
$Perk::PerkToGroup["Wind Brake Beacon"] = 1;
|
||||
$Perk::PerkToGroup["3 Second C4"] = 1;
|
||||
$Perk::PerkToGroup["Blade Sweep"] = 1;
|
||||
$Perk::PerkToGroup["Martydom"] = 1;
|
||||
$Perk::PerkToGroup["Pistol God"] = 1;
|
||||
$Perk::PerkToGroup["Double Down"] = 1;
|
||||
//$Perk::PerkToGroup["OverKill"] = 2;
|
||||
$Perk::PerkToGroup["Powder Keg"] = 1;
|
||||
//----------------------------------------
|
||||
$Perk::PerkToGroup["Kevlar Armor"] = 2;
|
||||
$Perk::PerkToGroup["Head Guard"] = 2;
|
||||
$Perk::PerkToGroup["Armored Helmet"] = 2;
|
||||
$Perk::PerkToGroup["Storm Barrier"] = 2;
|
||||
$Perk::PerkToGroup["Lim Zombie Shield"] = 2;
|
||||
$Perk::PerkToGroup["No-Infect Armor"] = 2;
|
||||
$Perk::PerkToGroup["Undead Resistant Plating"] = 2;
|
||||
$Perk::PerkToGroup["Radar Phantom"] = 2;
|
||||
$Perk::PerkToGroup["Clip Boxes"] = 3;
|
||||
$Perk::PerkToGroup["Bomb Shadower"] = 2;
|
||||
$Perk::PerkToGroup["Second Chance"] = 2;
|
||||
//----------------------------------------
|
||||
$Perk::PerkToGroup["Reflexive Reloader"] = 3;
|
||||
$Perk::PerkToGroup["UAV Disabler"] = 3;
|
||||
$Perk::PerkToGroup["Team Gain"] = 3;
|
||||
$Perk::PerkToGroup["Double Time"] = 3;
|
||||
$Perk::PerkToGroup["Ammo Vet"] = 3;
|
||||
$Perk::PerkToGroup["Bandolier"] = 3;
|
||||
$Perk::PerkToGroup["Hardline"] = 3;
|
||||
$Perk::PerkToGroup["Bomb Shadower"] = 3;
|
||||
$Perk::PerkToGroup["Second Chance"] = 3;
|
||||
|
||||
|
||||
//Asset Function
|
||||
function GameConnection::IsActivePerk(%client, %perk) {
|
||||
|
|
@ -197,20 +167,6 @@ function GameConnection::CanUsePerk(%client, %perkVal) {
|
|||
%scriptController = %client.TWM2Core;
|
||||
%xp = getCurrentEXP(%client);
|
||||
switch(%perkVal) {
|
||||
case 1:
|
||||
if(%xp >= $PerkRequire[1]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 2:
|
||||
if(%xp >= $PerkRequire[2]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 3:
|
||||
if(%client.hasMedal(8)) {
|
||||
return true;
|
||||
|
|
@ -218,133 +174,21 @@ function GameConnection::CanUsePerk(%client, %perkVal) {
|
|||
else {
|
||||
return false;
|
||||
}
|
||||
case 4 or 5:
|
||||
if(%client.hasMedal(11)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 6:
|
||||
if(%client.hasMedal(13)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 7:
|
||||
if(%xp >= $PerkRequire[7]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 8:
|
||||
if(%scriptController.officer >= 1) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
// case 9:
|
||||
// if(%xp >= $PerkRequire[9]) {
|
||||
// return true;
|
||||
// }
|
||||
// else {
|
||||
// return false;
|
||||
// }
|
||||
case 9:
|
||||
if(%xp >= $PerkRequire[10]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 10:
|
||||
if(%xp >= $PerkRequire[11]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 11:
|
||||
if(%client.hasMedal(9)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 12:
|
||||
if(%client.hasMedal(10)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 13:
|
||||
if(%client.hasMedal(12)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 14:
|
||||
if(%xp >= $PerkRequire[15]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 15:
|
||||
if(%xp >= $PerkRequire[16]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 16:
|
||||
if(%client.hasMedal(14)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 17 or 19:
|
||||
if(%client.hasMedal(5)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 18:
|
||||
if(%client.hasMedal(7)) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 20:
|
||||
if(%xp >= $PerkRequire[21]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 21:
|
||||
if(%xp >= $PerkRequire[22]) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 22:
|
||||
if(%client.CheckNWChallengeCompletion("3For5Sabo")) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
case 23:
|
||||
case 14:
|
||||
if(%client.CheckNWChallengeCompletion("ArmyOf50Stopped")) {
|
||||
return true;
|
||||
}
|
||||
|
|
@ -445,6 +289,9 @@ function DoPerksStuff(%client, %player) {
|
|||
if(%client.IsActivePerk("Wind Brake Beacon")) {
|
||||
%client.player.AirBrakes = 3;
|
||||
}
|
||||
if(%client.IsActivePerk("Lim Zombie Shield")) {
|
||||
%client.player.LimHits = 2;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -463,18 +310,9 @@ function RepelZombie(%zombie, %player) {
|
|||
%zombie.playShieldEffect("1 1 1");
|
||||
}
|
||||
|
||||
function MartydomExplode(%position, %client) {
|
||||
ServerPlay3D("SatchelChargeExplosionSound", %position);
|
||||
%c4 = new Item() {
|
||||
datablock = C4Deployed;
|
||||
position = %position;
|
||||
scale = ".1 .1 .1";
|
||||
owner = %client;
|
||||
};
|
||||
MissionCleanup.add(%c4);
|
||||
%c4.theClient = %client;
|
||||
|
||||
//echo("DEBUG: C4 mine dropped: "@%position TAB %client TAB %c4@"");
|
||||
|
||||
schedule(770, 0, "C4GoBoom", %c4);
|
||||
}
|
||||
function resetLimCharges(%player) {
|
||||
if(!isObject(%player) || %player.getState() $= "dead") {
|
||||
return;
|
||||
}
|
||||
%player.LimHits = 2;
|
||||
}
|
||||
|
|
@ -170,15 +170,9 @@ function AttemptReload(%WImg, %Plyr, %slot) {
|
|||
%plyr.ClipCount[%WImg.ClipName]--;
|
||||
}
|
||||
%Plyr.Reloading[%WImg] = 1;
|
||||
if(%client.IsActivePerk("Clip Boxes")) {
|
||||
if(%client.IsActivePerk("Reflexive Reloader")) {
|
||||
%ReloadTime = %WImg.ClipReloadTime - (%WImg.ClipReloadTime * 0.33);
|
||||
}
|
||||
else if(%client.IsActivePerk("Double Time")) {
|
||||
%ReloadTime = %WImg.ClipReloadTime - (%WImg.ClipReloadTime * 0.5);
|
||||
}
|
||||
else if(%client.IsActivePerk("Ammo Vet")) {
|
||||
%ReloadTime = %WImg.ClipReloadTime - (%WImg.ClipReloadTime * 0.75);
|
||||
}
|
||||
else {
|
||||
%ReloadTime = %WImg.ClipReloadTime;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -237,7 +237,7 @@ function TWM2Lib_Zombie_Core(%functionName, %arg1, %arg2, %arg3, %arg4) {
|
|||
}
|
||||
//Additional checks...
|
||||
if(%arg1.client !$= "") {
|
||||
if(%arg1.client.isActivePerk("No-Infect Armor")) {
|
||||
if(%arg1.client.isActivePerk("Undead Resistant Plating")) {
|
||||
%arg1.playShieldEffect("1 1 1");
|
||||
%arg1.infected = 0;
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -49,6 +49,19 @@ function ZombieArmor::armorCollisionFunction(%datablock, %zombie, %colPlayer) {
|
|||
if(%colPlayer.isBoss || %colPlayer.isZombie || %colPlayer.rapierShield) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(%colPlayer.client !$= "") {
|
||||
if(%colPlayer.client.IsActivePerk("Lim Zombie Shield")) {
|
||||
if(%colPlayer.limHits > 0) {
|
||||
RepelZombie(%zombie, %colPlayer);
|
||||
%colPlayer.limHits--;
|
||||
}
|
||||
if(%colPlayer.limHits == 0) {
|
||||
schedule(25000, 0, "resetLimCharges", %colPlayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Damage.
|
||||
%causeInfect = %zombie.damage_infectOnTouch;
|
||||
%baseDamage = %zombie.damage_amountOnTouch;
|
||||
|
|
|
|||
|
|
@ -30,6 +30,19 @@ function RavagerZombieArmor::armorCollisionFunction(%datablock, %zombie, %colPla
|
|||
if(%colPlayer.isBoss || %colPlayer.isZombie || %colPlayer.rapierShield) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(%colPlayer.client !$= "") {
|
||||
if(%colPlayer.client.IsActivePerk("Lim Zombie Shield")) {
|
||||
if(%colPlayer.limHits > 0) {
|
||||
RepelZombie(%zombie, %colPlayer);
|
||||
%colPlayer.limHits--;
|
||||
}
|
||||
if(%colPlayer.limHits == 0) {
|
||||
schedule(25000, 0, "resetLimCharges", %colPlayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Damage.
|
||||
%causeInfect = %zombie.damage_infectOnTouch;
|
||||
%baseDamage = %zombie.damage_amountOnTouch;
|
||||
|
|
|
|||
|
|
@ -49,6 +49,19 @@ function ShifterZombieArmor::armorCollisionFunction(%datablock, %zombie, %colPla
|
|||
if(%colPlayer.isBoss || %colPlayer.isZombie || %colPlayer.rapierShield) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(%colPlayer.client !$= "") {
|
||||
if(%colPlayer.client.IsActivePerk("Lim Zombie Shield")) {
|
||||
if(%colPlayer.limHits > 0) {
|
||||
RepelZombie(%zombie, %colPlayer);
|
||||
%colPlayer.limHits--;
|
||||
}
|
||||
if(%colPlayer.limHits == 0) {
|
||||
schedule(25000, 0, "resetLimCharges", %colPlayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Damage.
|
||||
%causeInfect = %zombie.damage_infectOnTouch;
|
||||
%baseDamage = %zombie.damage_amountOnTouch;
|
||||
|
|
|
|||
|
|
@ -144,12 +144,15 @@ function ShapeBaseImageData::onFire(%data, %obj, %slot) {
|
|||
//
|
||||
%spread = %data.projectileSpread;
|
||||
if(%obj.client !$= "") {
|
||||
if(%obj.client.IsActivePerk("Advanced Grip")) {
|
||||
%spread = %spread / 2.5;
|
||||
}
|
||||
if(%obj.client.UpgradeOn("Grip", %data.getName())) {
|
||||
%spread = %spread / 1.7;
|
||||
}
|
||||
%handleExpertReduce = %data.handleExpertReduce;
|
||||
if(%handleExpertReduce !$= "") {
|
||||
if(%obj.client.IsActivePerk("Handling Expert")) {
|
||||
%spread = %spread / 1.33;
|
||||
}
|
||||
}
|
||||
}
|
||||
//
|
||||
%vec = %obj.getMuzzleVector(%slot);
|
||||
|
|
@ -158,14 +161,6 @@ function ShapeBaseImageData::onFire(%data, %obj, %slot) {
|
|||
%z = (getRandom() - 0.5) * 2 * 3.1415926 * %spread;
|
||||
%mat = MatrixCreateFromEuler(%x @ " " @ %y @ " " @ %z);
|
||||
%vector = MatrixMulVector(%mat, %vec);
|
||||
|
||||
if(%obj.client !$= "") {
|
||||
if(%obj.client.IsActivePerk("Pistol God")) {
|
||||
if(%data.getName() $= "PistolImage" || %data.getName() $= "DeagleImage") {
|
||||
%vector = %obj.getMuzzleVector(%slot);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
%vector = %obj.getMuzzleVector(%slot);
|
||||
|
|
|
|||
|
|
@ -108,6 +108,7 @@ datablock ShapeBaseImageData(MG42Image) {
|
|||
RankRequire = $TWM2::RankRequire["MG42"];
|
||||
|
||||
projectileSpread = 12.5 / 1000.0;
|
||||
handleExpertReduce = 1.5;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -100,6 +100,7 @@ datablock ShapeBaseImageData(MRXXImage) {
|
|||
shellVelocity = 4.5;
|
||||
|
||||
projectileSpread = 10.0 / 1000.0;
|
||||
handleExpertReduce = 1.75;
|
||||
|
||||
|
||||
//--------------------------------------
|
||||
|
|
|
|||
|
|
@ -110,6 +110,7 @@ datablock ShapeBaseImageData(RP432Image) {
|
|||
shellVelocity = 4.5;
|
||||
|
||||
projectileSpread = 10.0 / 1000.0;
|
||||
handleExpertReduce = 1.4;
|
||||
|
||||
|
||||
//--------------------------------------
|
||||
|
|
|
|||
|
|
@ -100,6 +100,7 @@ datablock ShapeBaseImageData(G41RifleImage) {
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 3.0 / 1000.0;
|
||||
handleExpertReduce = 1.25;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -114,6 +114,7 @@ datablock ShapeBaseImageData(M4A1Image) {
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 8.0 / 1000.0;
|
||||
handleExpertReduce = 1.25;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -93,6 +93,7 @@ datablock ShapeBaseImageData(PulseRifleImage) {
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 2.0 / 1000.0;
|
||||
handleExpertReduce = 1.15;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -157,6 +157,7 @@ datablock ShapeBaseImageData(lasergunImage) {
|
|||
RankRequire = $TWM2::RankRequire["RSALaserRifle"];
|
||||
|
||||
maxSpread = 10.0 / 1000.0;
|
||||
handleExpertReduce = 1.5;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -108,6 +108,7 @@ datablock ShapeBaseImageData(S3RifleImage) {
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 5.0 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
@ -179,8 +180,8 @@ function S3RifleImage::OnFire(%data, %obj, %slot) {
|
|||
if(%obj.client.UpgradeOn("Burst Clip", %data.getName())) {
|
||||
%spread = %data.projectileSpread;
|
||||
if(%obj.client !$= "") {
|
||||
if(%obj.client.IsActivePerk("Advanced Grip")) {
|
||||
%spread = %spread / 2.5;
|
||||
if(%obj.client.IsActivePerk("Handling Expert")) {
|
||||
%spread = %spread / 1.33;
|
||||
}
|
||||
}
|
||||
%vec2 = %obj.getMuzzleVector(%slot);
|
||||
|
|
|
|||
|
|
@ -84,6 +84,7 @@ datablock ShapeBaseImageData(S3SRifleImage) {
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 4.0 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -110,6 +110,7 @@ datablock ShapeBaseImageData(Mp26Image)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 4.0 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -101,6 +101,7 @@ datablock ShapeBaseImageData(Mp26CMDOImage)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 3.2 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -112,6 +112,7 @@ datablock ShapeBaseImageData(P90Image)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 4.0 / 1000.0;
|
||||
handleExpertReduce = 1.15;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -117,6 +117,7 @@ datablock ShapeBaseImageData(Pg700Image)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 3.0 / 1000.0;
|
||||
handleExpertReduce = 1.40;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -104,6 +104,7 @@ datablock ShapeBaseImageData(PulseSMGImage)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 3.0 / 1000.0;
|
||||
handleExpertReduce = 1.20;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -486,6 +486,7 @@ datablock ShapeBaseImageData(MiniChaingunImage)
|
|||
shellVelocity = 3.0;
|
||||
|
||||
projectileSpread = 8.0 / 1000.0;
|
||||
handleExpertReduce = 1.5;
|
||||
|
||||
//--------------------------------------
|
||||
stateName[0] = "Activate";
|
||||
|
|
|
|||
|
|
@ -111,6 +111,7 @@ datablock ShapeBaseImageData(M1700Image) {
|
|||
//
|
||||
|
||||
projectileSpread = 11.0 / 1000.0;
|
||||
handleExpertReduce = 1.2;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -110,6 +110,7 @@ datablock ShapeBaseImageData(Model1887Image) {
|
|||
//
|
||||
|
||||
projectileSpread = 7.0 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -141,6 +141,7 @@ datablock ShapeBaseImageData( SA2400Image ) {
|
|||
//
|
||||
|
||||
projectileSpread = 3.0 / 1000.0;
|
||||
handleExpertReduce = 2.0
|
||||
//----------------------------------------------------------------------------\\
|
||||
//State Data\\
|
||||
//----------------------------------------------------------------------------\\
|
||||
|
|
|
|||
|
|
@ -106,6 +106,7 @@ datablock ShapeBaseImageData(SCD343Image) {
|
|||
//
|
||||
|
||||
projectileSpread = 10.0 / 1000.0;
|
||||
handleExpertReduce = 1.3;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
|
|
@ -106,6 +106,7 @@ datablock ShapeBaseImageData(Wp400Image) {
|
|||
//
|
||||
|
||||
projectileSpread = 15.0 / 1000.0;
|
||||
handleExpertReduce = 1.33;
|
||||
|
||||
stateName[0] = "Activate";
|
||||
stateTransitionOnTimeout[0] = "ActivateReady";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue