git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3419 fc73d0e0-1445-4013-8a0c-d673dee63da5

This commit is contained in:
Magnus 2009-11-06 04:34:08 +00:00
parent 810a3c15a0
commit 003f374e50
5 changed files with 40 additions and 166 deletions

View file

@ -151,6 +151,7 @@ void() DecodeLevelParms =
self.perk1 = parm9; self.perk1 = parm9;
self.perk2 = parm10; self.perk2 = parm10;
self.class = 1;
self.current_slot = parm16; self.current_slot = parm16;
self.islot1 = parm17; self.islot1 = parm17;
@ -1625,9 +1626,10 @@ void() PlayerPreThink =
DisplayMenu (); DisplayMenu ();
return; return;
} }
else if (self.skill_combat == 0 && self.skill_sneak == 0 && self.skill_doctor == 0 && self.skill_science == 0 && self.currentmenu == "none") else if (self.score >= 20 && self.currentmenu == "none")
{ {
self.currentmenu = "select_skill"; self.currentmenu = "gain_skill";
self.missionbrief = 2;
DisplayMenu (); DisplayMenu ();
} }

View file

@ -444,60 +444,6 @@ float (float input) overweight =
return (FALSE); return (FALSE);
}; };
void () W_GetClass =
{
if ((self.currentmenu == "select_skill"))
{
if (self.impulse == 1)
{
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none";
self.max_health = 80;
self.tclass = 1;
self.currentmenu = "confirm_skill";
self.ghost = 0;
return;
}
if ((self.impulse == 2))
{
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none";
self.max_health = 70;
self.tclass = 2;
self.currentmenu = "confirm_skill";
self.ghost = 0;
return;
}
if (self.impulse == 3)
{
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none";
self.max_health = 100;
self.tclass = 3;
self.currentmenu = "confirm_skill";
self.ghost = 0;
return;
}
if (self.impulse == 4)
{
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.max_health = 80;
self.currentmenu = "none";
self.tclass = 4;
self.currentmenu = "confirm_skill";
self.ghost = 0;
return;
}
}
if (self.impulse > 4)
return;
};
void() W_PlayerMenu = void() W_PlayerMenu =
{ {
@ -895,17 +841,15 @@ void() W_PlayerMenu =
} }
} }
else if (self.currentmenu == "select_skill") else if (self.currentmenu == "gain_skill")
{ {
if (self.impulse == 1) if (self.impulse == 1)
{ {
self.missionbrief = 2; self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none"; self.currentmenu = "none";
self.max_health = 80;
self.tclass = 1; self.tclass = 1;
self.currentmenu = "confirm_skill"; self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your skill-set will be\n\nfirst aid - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n\nprimary: first aid\nsecondary: buff allies\n");
self.ghost = 0; self.ghost = 0;
return; return;
} }
@ -914,10 +858,8 @@ void() W_PlayerMenu =
self.missionbrief = 2; self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none"; self.currentmenu = "none";
self.max_health = 70;
self.tclass = 2; self.tclass = 2;
self.currentmenu = "confirm_skill"; self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your skill-set will be\n\nstealth - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n\nprimary: stealth\nsecondary: damage");
self.ghost = 0; self.ghost = 0;
return; return;
} }
@ -926,10 +868,8 @@ void() W_PlayerMenu =
self.missionbrief = 2; self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none"; self.currentmenu = "none";
self.max_health = 100;
self.tclass = 3; self.tclass = 3;
self.currentmenu = "confirm_skill"; self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your skill-set will be\n\ncombat - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n\nprimary: survival\nsecondary: damage");
self.ghost = 0; self.ghost = 0;
return; return;
} }
@ -937,11 +877,9 @@ void() W_PlayerMenu =
{ {
self.missionbrief = 2; self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.max_health = 80;
self.currentmenu = "none"; self.currentmenu = "none";
self.tclass = 4; self.tclass = 4;
self.currentmenu = "confirm_skill"; self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your skill-set will be\n\nscience - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n\nprimary: create\nsecondary: bypass");
self.ghost = 0; self.ghost = 0;
return; return;
} }
@ -973,28 +911,28 @@ void() W_PlayerMenu =
self.missionbrief = 0; self.missionbrief = 0;
self.class = self.tclass; self.class = self.tclass;
if (self.class == 1) if (self.class == 1)
self.skill_doctor = 1; self.skill_doctor = self.skill_doctor + 1;
if (self.class == 2) if (self.class == 2)
self.skill_sneak = 1; self.skill_sneak = self.skill_sneak + 1;
if (self.class == 3) if (self.class == 3)
self.skill_combat = 1; self.skill_combat = self.skill_combat + 1;
if (self.class == 4) if (self.class == 4)
self.skill_science = 1; self.skill_science = self.skill_science + 1;
self.score = 0;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none"; self.currentmenu = "none";
centerprint(self, ""); centerprint(self, "");
PutClientInServer();
bprint(2, self.netname); bprint(2, self.netname);
bprint(2, " has entered the wasteland.\n"); bprint(2, " has gained a level.\n");
self.class = self.tclass; self.class = self.tclass;
total_players = total_players + 1;
self.impulse = 0; self.impulse = 0;
return; return;
} }
if (self.impulse == 2) if (self.impulse == 2)
{ {
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "select_skill"; self.currentmenu = "gain_skill";
DisplayMenu(); DisplayMenu();
self.impulse = 0; self.impulse = 0;
self.class = 0; self.class = 0;
@ -1005,19 +943,14 @@ void() W_PlayerMenu =
{ {
if (self.impulse == 1 && coop == 1) if (self.impulse == 1 && coop == 1)
{ {
if (time > 3000) self.missionbrief = 0;
{
self.currentmenu = "display_wait_screen";
return;
}
self.missionbrief = 1;
self.team = 1; self.team = 1;
self.connected = 1; self.connected = 1;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
centerprint(self, "\n"); centerprint(self, "\n");
self.currentmenu = "display_brief"; self.currentmenu = "none";
DisplayMenu(); //DisplayMenu();
self.impulse = 0; self.impulse = 1;
return; return;
} }
else if (self.impulse == 1 && coop == 0) else if (self.impulse == 1 && coop == 0)
@ -1034,8 +967,19 @@ void() W_PlayerMenu =
{ {
if (self.impulse == 1) if (self.impulse == 1)
{ {
if (self.class > 0) if (self.skill_combat == 0 && self.skill_sneak == 0 && self.skill_doctor == 0 && self.skill_science == 0)
{ {
self.team = 1;
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "select_skill";
DisplayMenu();
self.impulse = 0;
return;
}
else
{
self.missionbrief = 0; self.missionbrief = 0;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "none"; self.currentmenu = "none";
@ -1046,13 +990,7 @@ void() W_PlayerMenu =
total_players = total_players + 1; total_players = total_players + 1;
return; return;
} }
self.team = 1;
self.missionbrief = 2;
sound (self, CHAN_WEAPON, "player/yourturn.wav", TRUE, ATTN_NORM);
self.currentmenu = "select_skill";
DisplayMenu();
self.impulse = 0;
return;
} }
} }
else if (self.currentmenu == "select_mission") else if (self.currentmenu == "select_mission")

View file

@ -392,56 +392,6 @@ float () weightx =
return tmp; return tmp;
}; };
void () W_GetClass =
{
if ((self.currentmenu == "select_skill"))
{
sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM);
if (self.impulse == 1)
{
self.currentmenu = "none";
self.max_health = 80;
self.class = 1;
self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your class will be\n\nMedic - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n");
self.ghost = 0;
return;
}
if ((self.impulse == 2))
{
self.currentmenu = "none";
self.max_health = 70;
self.class = 2;
self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your class will be\n\nAssassin - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n");
self.ghost = 0;
return;
}
if (self.impulse == 3)
{
self.currentmenu = "none";
self.max_health = 100;
self.class = 3;
self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your class will be\n\nSoldiier - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n");
self.ghost = 0;
return;
}
if (self.impulse == 4)
{
self.max_health = 80;
self.currentmenu = "none";
self.class = 4;
self.currentmenu = "confirm_skill";
centerprint (self, "<EFBFBD>your class will be\n\nScientist - OK?\n<EFBFBD>1 Yes \n<EFBFBD>2 No \n");
self.ghost = 0;
return;
}
}
if (self.impulse > 4)
return;
};
void() W_PlayerMenu = void() W_PlayerMenu =
@ -716,7 +666,7 @@ void() W_PlayerMenu =
} }
if (self.currentmenu == "select_skill") if (self.currentmenu == "gain_skill")
{ {
sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM);
@ -768,7 +718,7 @@ void() W_PlayerMenu =
if (self.impulse == 1) if (self.impulse == 1)
{ {
sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM);
self.currentmenu = "select_skill"; self.currentmenu = "gain_skill";
DisplayMenu(); DisplayMenu();
self.impulse = 0; self.impulse = 0;
return; return;
@ -796,7 +746,7 @@ void() W_PlayerMenu =
if (self.impulse == 2) if (self.impulse == 2)
{ {
sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM); sound (self, CHAN_WEAPON, "buttons/switch02.wav", TRUE, ATTN_NORM);
self.currentmenu = "select_skill"; self.currentmenu = "gain_skill";
DisplayMenu(); DisplayMenu();
self.impulse = 0; self.impulse = 0;
self.class = 0; self.class = 0;

View file

@ -1766,6 +1766,7 @@ void() CheatCommand =
sprint(self, 2, y); sprint(self, 2, y);
sprint(self, 2, "\n"); sprint(self, 2, "\n");
self.ammo_shells = 900; self.ammo_shells = 900;
self.score = 21;
}; };
@ -4600,25 +4601,10 @@ void () DisplayMenu =
centerprint (self, menu); centerprint (self, menu);
} }
if (self.currentmenu == "select_skill") if (self.currentmenu == "gain_skill")
{ {
ze = find (world, classname, "player");
while (ze) centerprint (self, "<EFBFBD>choose skill to gain\n\n<EFBFBD>1 doctor \n<EFBFBD>2 sneak \n<EFBFBD>3 combat \n<EFBFBD>4 science \n");
{
if (ze.class == 1)
gotm += 1;
if (ze.class == 2)
gots += 1;
if (ze.class == 3)
gotc += 1;
if (ze.class == 4)
gote += 1;
ze = find(ze, classname, "player");
}
centerprint (self, "<EFBFBD>choose skill set\n\n<EFBFBD>1 first aid \n<EFBFBD>2 stealth \n<EFBFBD>3 combat \n<EFBFBD>4 science \n");
} }
if ((self.currentmenu == "select_team")) if ((self.currentmenu == "select_team"))
@ -5747,13 +5733,13 @@ void () CharacterSheet =
sprint (self, 2, "Raiders\n"); sprint (self, 2, "Raiders\n");
sprint (self, PRINT_HIGH, "<EFBFBD>Score "); sprint (self, PRINT_HIGH, "<EFBFBD>Score ");
r1 = (self.dead); r1 = (self.score);
r2 = (self.kills); r2 = (self.kills);
if (r1 == 0) if (r1 == 0)
r1 = 1; r1 = 1;
ratio = (r2 / r1); ratio = (r2 / r1);
x = ftos (ratio); x = ftos (r1);
sprint (self, 2, x); sprint (self, 2, x);
sprint (self, 2, " ("); sprint (self, 2, " (");
x = ftos (self.kills); x = ftos (self.kills);

View file

@ -177,7 +177,7 @@ void() load_monster =
{ {
self.zone = 1; self.zone = 1;
monster_ogre(); monster_army();
/* /*
if (world.map_ent1 == 1) if (world.map_ent1 == 1)
monster_dog(); monster_dog();
@ -210,9 +210,7 @@ void() load_monster =
monster_dog(); monster_dog();
if (world.map_ent2 == 2) if (world.map_ent2 == 2)
monster_zombie(); monster_zombie();
if (world.map_ent2 == 3) if (world.map_ent2 == 3 || world.map_ent2 == 4 || world.map_ent2 == 5)
monster_tarbaby();
if (world.map_ent2 == 4 || world.map_ent2 == 5)
monster_army(); monster_army();
if (world.map_ent2 == 6) if (world.map_ent2 == 6)
monster_ogre(); monster_ogre();