git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3438 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
86a1cf9913
commit
f6819cc0cd
5 changed files with 136 additions and 94 deletions
|
@ -712,6 +712,17 @@ The monster has an enemy it is trying to kill
|
|||
*/
|
||||
void(float dist) ai_run =
|
||||
{
|
||||
if (self.hold > 0)
|
||||
{
|
||||
self.th_stand ();
|
||||
|
||||
|
||||
self.hold = self.hold - 1;
|
||||
self.think = self.th_run;
|
||||
self.nextthink = time + 0.1;
|
||||
return;
|
||||
}
|
||||
|
||||
movedist = dist;
|
||||
// see if the enemy is dead
|
||||
if (self.enemy.health <= 0)
|
||||
|
|
|
@ -283,6 +283,56 @@ void(string arg1) Cmd_GainLevel =
|
|||
self.skill_science = self.skill_science + 1;
|
||||
};
|
||||
|
||||
void(string arg1, string arg2) Cmd_GainPerk =
|
||||
{
|
||||
|
||||
sound (self, CHAN_BODY, "buttons/switch02.wav", 1, ATTN_NORM);
|
||||
|
||||
|
||||
if (arg2 == "1")
|
||||
{
|
||||
if (arg1 == "1")
|
||||
self.perk1 = 1;
|
||||
if (arg1 == "2")
|
||||
self.perk1 = 2;
|
||||
if (arg1 == "3")
|
||||
self.perk1 = 3;
|
||||
if (arg1 == "4")
|
||||
self.perk1 = 4;
|
||||
if (arg1 == "5")
|
||||
self.perk1 = 5;
|
||||
if (arg1 == "6")
|
||||
self.perk1 = 6;
|
||||
if (arg1 == "7")
|
||||
self.perk1 = 7;
|
||||
if (arg1 == "8")
|
||||
self.perk1 = 8;
|
||||
if (arg1 == "9")
|
||||
self.perk1 = 9;
|
||||
}
|
||||
if (arg2 == "2")
|
||||
{
|
||||
if (arg1 == "1")
|
||||
self.perk2 = 1;
|
||||
if (arg1 == "2")
|
||||
self.perk2 = 2;
|
||||
if (arg1 == "3")
|
||||
self.perk2 = 3;
|
||||
if (arg1 == "4")
|
||||
self.perk2 = 4;
|
||||
if (arg1 == "5")
|
||||
self.perk2 = 5;
|
||||
if (arg1 == "6")
|
||||
self.perk2 = 6;
|
||||
if (arg1 == "7")
|
||||
self.perk2 = 7;
|
||||
if (arg1 == "8")
|
||||
self.perk2 = 8;
|
||||
if (arg1 == "9")
|
||||
self.perk2 = 9;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
void(string arg1) Cmd_InvBuy =
|
||||
{
|
||||
|
@ -1218,6 +1268,12 @@ void(string line) SV_ParseClientCommand =
|
|||
return;
|
||||
Cmd_InvSwap(argv(1), argv(2));
|
||||
}
|
||||
else if (cmd == "gainperk")
|
||||
{
|
||||
if (self.deadflag || self.current_slot==0)
|
||||
return;
|
||||
Cmd_GainPerk(argv(1), argv(2));
|
||||
}
|
||||
else if (cmd == "invgive")
|
||||
{
|
||||
if (self.deadflag || self.current_slot==0)
|
||||
|
|
|
@ -535,8 +535,8 @@ take = damage;
|
|||
}
|
||||
|
||||
|
||||
|
||||
targ.health = targ.health - take;
|
||||
if (targ.hold <= 0)
|
||||
targ.health = targ.health - take;
|
||||
|
||||
if (targ.classname == "monster" && targ.enemy.classname != "player" && attacker.classname == "player")
|
||||
{
|
||||
|
|
|
@ -2572,85 +2572,70 @@ float(float slotno, float iid) FitsInSlot =
|
|||
string (float slot, float int) PerkName =
|
||||
{
|
||||
if (int == 1)
|
||||
return "unbreakable";
|
||||
return "Support Fire";
|
||||
if (int == 2)
|
||||
return "feral swiftness";
|
||||
return "Duck And Cover";
|
||||
if (int == 3)
|
||||
return "stunt man";
|
||||
return "Harmless";
|
||||
if (int == 4)
|
||||
return "kick in the door!";
|
||||
return "Hit The Deck";
|
||||
if (int == 5)
|
||||
return "quick draw";
|
||||
return "Living Anatomy";
|
||||
if (int == 6)
|
||||
return "light step";
|
||||
return "Mutation";
|
||||
if (int == 7)
|
||||
return "surprise attack";
|
||||
return "Narrow Escape";
|
||||
if (int == 8)
|
||||
return "large and in charge";
|
||||
return "Schizophrenia";
|
||||
if (int == 9)
|
||||
return "nintendo gamer";
|
||||
if (int == 10)
|
||||
return "esp";
|
||||
if (int == 11)
|
||||
return "last man standing";
|
||||
if (int == 12)
|
||||
return "bodysnatcher";
|
||||
if (int == 13)
|
||||
return "medicine man";
|
||||
if (int == 14)
|
||||
return "dark alchemist";
|
||||
if (int == 15)
|
||||
return "renegade commando";
|
||||
if (int == 16)
|
||||
return "power shot";
|
||||
if (int == 17)
|
||||
return "one in a million";
|
||||
if (int == 18)
|
||||
return "master blaster";
|
||||
if (int == 19)
|
||||
return "death wish";
|
||||
return "Sleep Tight";
|
||||
|
||||
};
|
||||
|
||||
string (float slot, float int) PerkNameCentered =
|
||||
{
|
||||
if (int == 1)
|
||||
return " Support Fire";
|
||||
if (int == 2)
|
||||
return "Duck And Cover";
|
||||
if (int == 3)
|
||||
return " Harmless";
|
||||
if (int == 4)
|
||||
return " Hit The Deck";
|
||||
if (int == 5)
|
||||
return "Living Anatomy";
|
||||
if (int == 6)
|
||||
return " Mutation";
|
||||
if (int == 7)
|
||||
return "Narrow Escape";
|
||||
if (int == 8)
|
||||
return "Schizophrenia";
|
||||
if (int == 9)
|
||||
return " Sleep Tight";
|
||||
|
||||
};
|
||||
|
||||
|
||||
string(float int) GetPerkImage =
|
||||
{
|
||||
if (int == 1)
|
||||
return "gui/perks/ironman.jpg";
|
||||
return "gui/perks/Support Fire.jpg";
|
||||
else if (int == 2)
|
||||
return "gui/perks/swiftness.jpg";
|
||||
return "gui/perks/Duck And Cover.jpg";
|
||||
else if (int == 3)
|
||||
return "gui/perks/stuntman.jpg";
|
||||
return "gui/perks/Harmless.jpg";
|
||||
else if (int == 4)
|
||||
return "gui/perks/kickin.jpg";
|
||||
return "gui/perks/Hit The Deck.jpg";
|
||||
else if (int == 5)
|
||||
return "gui/perks/quickdraw.jpg";
|
||||
return "gui/perks/Living Anatomy.jpg";
|
||||
else if (int == 6)
|
||||
return "gui/perks/lightstep.jpg";
|
||||
return "gui/perks/Mutation.jpg";
|
||||
else if (int == 7)
|
||||
return "gui/perks/surprise.jpg";
|
||||
return "gui/perks/Narrow Escape.jpg";
|
||||
else if (int == 8)
|
||||
return "gui/perks/large.jpg";
|
||||
return "gui/perks/Schizophrenia.jpg";
|
||||
else if (int == 9)
|
||||
return "gui/perks/nintendo.jpg";
|
||||
else if (int == 10)
|
||||
return "gui/perks/redscare.jpg";
|
||||
else if (int == 11)
|
||||
return "gui/perks/lastman.jpg";
|
||||
else if (int == 12)
|
||||
return "gui/perks/bodysnatcher.jpg";
|
||||
else if (int == 13)
|
||||
return "gui/perks/healingway.jpg";
|
||||
else if (int == 14)
|
||||
return "gui/perks/alchemist.jpg";
|
||||
else if (int == 15)
|
||||
return "gui/perks/eastern.jpg";
|
||||
else if (int == 16)
|
||||
return "gui/perks/powershot.jpg";
|
||||
else if (int == 17)
|
||||
return "gui/perks/million.jpg";
|
||||
else if (int == 18)
|
||||
return "gui/perks/demoman.jpg";
|
||||
else if (int == 19)
|
||||
return "gui/perks/lightning.jpg";
|
||||
return "gui/perks/Sleep Tight.jpg";
|
||||
else
|
||||
return "gui/perks/none.jpg";
|
||||
|
||||
|
@ -2660,43 +2645,23 @@ string(float int) GetPerkImage =
|
|||
string(float int) GetPerkDesc =
|
||||
{
|
||||
if (int == 1)
|
||||
return "25% damage resist bonus while at half health";
|
||||
return "33% recoil reduction while prone";
|
||||
else if (int == 2)
|
||||
return "provides a flat 10% bonus movement speed";
|
||||
return "20% damage resist while taking cover and ducking";
|
||||
else if (int == 3)
|
||||
return "instant stance change, fast prone movement";
|
||||
return "enemies tend to ignore you over your friends";
|
||||
else if (int == 4)
|
||||
return "smash down locked doors and chests, very loud";
|
||||
return "50% damage resist to area attacks while prone";
|
||||
else if (int == 5)
|
||||
return "fast reloading, instant weapon switching";
|
||||
return "Aimed attacks get a damage bonus equal to Doctor skill";
|
||||
else if (int == 6)
|
||||
return "reduced footsteps, +10% sneak, don't trip traps";
|
||||
return "This perk randomly functions as two perks";
|
||||
else if (int == 7)
|
||||
return "25% damage bonus to any enemy not targetting you";
|
||||
return "Provides you a few hassle-free seconds to escape danger";
|
||||
else if (int == 8)
|
||||
return "gain melee knockback and berserker rage bonus";
|
||||
return "You sometimes gain additional skills from another place";
|
||||
else if (int == 9)
|
||||
return "you'll sometimes enter 'the zone'!";
|
||||
else if (int == 10)
|
||||
return "+10% miss chance to you and any nearby allies";
|
||||
else if (int == 11)
|
||||
return "recover hit points as you mow down foes";
|
||||
else if (int == 12)
|
||||
return "become a master of disguise by looting dead bodies";
|
||||
else if (int == 13)
|
||||
return "25% bonus to all chems used on yourself and others";
|
||||
else if (int == 14)
|
||||
return "mix chems together to make better ones";
|
||||
else if (int == 15)
|
||||
return "you have mastered martial arts and kick attacks";
|
||||
else if (int == 16)
|
||||
return "25% damage bonus to your aimed shots";
|
||||
else if (int == 17)
|
||||
return "you sometimes get very, very lucky with anything";
|
||||
else if (int == 18)
|
||||
return "bigger crosshairs means even bigger damage bonus";
|
||||
else if (int == 19)
|
||||
return "20% damage bonus and you also take 20% more damage";
|
||||
return "Automatically kill anything with knife in sneak mode";
|
||||
else
|
||||
return "";
|
||||
|
||||
|
|
|
@ -1639,7 +1639,7 @@ void() W_Attack =
|
|||
else if (weap == IID_WP_AK112)
|
||||
FireAssaultRifle(16, 10, "weapons/ak112.wav", 4000, 0.095);
|
||||
else if (weap == IID_WP_AK112_M)
|
||||
FireAssaultRifle(16, 10, "weapons/lsw.wav", 5000, 0.10);
|
||||
FireAssaultRifle(17, 10, "weapons/lsw.wav", 5000, 0.10);
|
||||
else if (weap == IID_WP_ACR)
|
||||
FireAssaultRifle(35, 7, "weapons/bozar.wav", 9000, 0.1);
|
||||
else if (weap == IID_WP_AK74)
|
||||
|
@ -1761,8 +1761,18 @@ void() CheatCommand =
|
|||
{
|
||||
local float x;
|
||||
local string y;
|
||||
local entity te;
|
||||
|
||||
self.ammo_shells = 900;
|
||||
|
||||
te = findradius (self.origin, 6000);
|
||||
while (te)
|
||||
{
|
||||
if (te.classname == "monster")
|
||||
te.hold = 100;
|
||||
|
||||
te = te.chain;
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
|
@ -3417,11 +3427,11 @@ void (float dam, float accuracy, string snd, float rng, float rate) FireAssaultR
|
|||
|
||||
if (self.position == 2 && weap == IID_WP_AK112_M)
|
||||
{
|
||||
if (self.recoil >= 7)
|
||||
self.recoil = 7;
|
||||
if (self.recoil >= 8)
|
||||
self.recoil = 8;
|
||||
|
||||
y = y * 0.10;
|
||||
tmp = tmp * 0.75;
|
||||
y = y * 0.25;
|
||||
tmp = tmp * 0.80;
|
||||
}
|
||||
if (random()*3<=2)
|
||||
self.driftx = self.driftx + y;
|
||||
|
|
Loading…
Reference in a new issue