mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-23 12:04:38 -04:00
"Critical" restriction for SSG in Doom 1
This commit is contained in:
parent
5426138de7
commit
a2253b0699
@ -69,6 +69,7 @@ extern char *MAPNAME(int e, int m);
|
||||
extern boolean modifiedgame;
|
||||
|
||||
extern boolean have_ssg;
|
||||
#define ALLOW_SSG (gamemode == commercial || CRITICAL(have_ssg))
|
||||
|
||||
// compatibility with old engines (monster behavior, metrics, etc.)
|
||||
extern int compatibility, default_compatibility; // killough 1/31/98
|
||||
|
@ -241,7 +241,7 @@ static boolean WeaponSelectable(weapontype_t weapon)
|
||||
{
|
||||
// Can't select the super shotgun in Doom 1.
|
||||
|
||||
if (weapon == wp_supershotgun && !have_ssg)
|
||||
if (weapon == wp_supershotgun && !ALLOW_SSG)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
@ -780,7 +780,7 @@ void G_BuildTiccmd(ticcmd_t* cmd)
|
||||
M_InputGameActive(input_weapon6) && gamemode != shareware ? wp_plasma :
|
||||
M_InputGameActive(input_weapon7) && gamemode != shareware ? wp_bfg :
|
||||
M_InputGameActive(input_weapon8) ? wp_chainsaw :
|
||||
M_InputGameActive(input_weapon9) && !demo_compatibility && have_ssg ? wp_supershotgun :
|
||||
M_InputGameActive(input_weapon9) && !demo_compatibility && ALLOW_SSG ? wp_supershotgun :
|
||||
wp_nochange;
|
||||
|
||||
// killough 3/22/98: For network and demo consistency with the
|
||||
@ -818,7 +818,7 @@ void G_BuildTiccmd(ticcmd_t* cmd)
|
||||
// in use, or if the SSG is not already in use and the
|
||||
// player prefers it.
|
||||
|
||||
if (newweapon == wp_shotgun && have_ssg &&
|
||||
if (newweapon == wp_shotgun && ALLOW_SSG &&
|
||||
player->weaponowned[wp_supershotgun] &&
|
||||
(!player->weaponowned[wp_shotgun] ||
|
||||
player->readyweapon == wp_shotgun ||
|
||||
|
@ -1006,7 +1006,7 @@ static void HU_widget_build_weapon (void)
|
||||
break;
|
||||
case retail:
|
||||
case registered:
|
||||
if (w >= wp_supershotgun && !have_ssg)
|
||||
if (w >= wp_supershotgun && !ALLOW_SSG)
|
||||
ok = 0;
|
||||
break;
|
||||
default:
|
||||
|
@ -541,7 +541,7 @@ static void cheat_fa()
|
||||
// You can't own weapons that aren't in the game // phares 02/27/98
|
||||
for (i=0;i<NUMWEAPONS;i++)
|
||||
if (!(((i == wp_plasma || i == wp_bfg) && gamemode == shareware) ||
|
||||
(i == wp_supershotgun && !have_ssg)))
|
||||
(i == wp_supershotgun && !ALLOW_SSG)))
|
||||
plyr->weaponowned[i] = true;
|
||||
|
||||
for (i=0;i<NUMAMMO;i++)
|
||||
@ -1105,7 +1105,7 @@ static void cheat_keyxx(int key)
|
||||
|
||||
static void cheat_weap()
|
||||
{ // Ty 03/27/98 - *not* externalized
|
||||
displaymsg(have_ssg ? // killough 2/28/98
|
||||
displaymsg(ALLOW_SSG ? // killough 2/28/98
|
||||
"Weapon number 1-9" : "Weapon number 1-8");
|
||||
}
|
||||
|
||||
@ -1113,7 +1113,7 @@ static void cheat_weapx(char *buf)
|
||||
{
|
||||
int w = *buf - '1';
|
||||
|
||||
if ((w==wp_supershotgun && !have_ssg) || // killough 2/28/98
|
||||
if ((w==wp_supershotgun && !ALLOW_SSG) || // killough 2/28/98
|
||||
((w==wp_bfg || w==wp_plasma) && gamemode==shareware))
|
||||
return;
|
||||
|
||||
|
@ -236,7 +236,7 @@ static int P_SwitchWeaponMBF21(player_t *player)
|
||||
checkweapon = wp_chainsaw;
|
||||
break;
|
||||
case 9:
|
||||
if (have_ssg)
|
||||
if (ALLOW_SSG)
|
||||
checkweapon = wp_supershotgun;
|
||||
break;
|
||||
}
|
||||
@ -315,7 +315,7 @@ int P_SwitchWeapon(player_t *player)
|
||||
newweapon = wp_chainsaw;
|
||||
break;
|
||||
case 9:
|
||||
if (player->weaponowned[wp_supershotgun] && have_ssg &&
|
||||
if (player->weaponowned[wp_supershotgun] && ALLOW_SSG &&
|
||||
player->ammo[am_shell] >= (demo_compatibility ? 3 : 2))
|
||||
newweapon = wp_supershotgun;
|
||||
break;
|
||||
|
@ -478,7 +478,7 @@ void P_PlayerThink (player_t* player)
|
||||
(player->readyweapon != wp_chainsaw ||
|
||||
!player->powers[pw_strength]))
|
||||
newweapon = wp_chainsaw;
|
||||
if (have_ssg &&
|
||||
if (ALLOW_SSG &&
|
||||
newweapon == wp_shotgun &&
|
||||
player->weaponowned[wp_supershotgun] &&
|
||||
player->readyweapon != wp_supershotgun)
|
||||
|
Loading…
x
Reference in New Issue
Block a user