Skip to content

Commit

Permalink
Merge pull request #239 from NeonKnightOA/aws-fix-240319
Browse files Browse the repository at this point in the history
"Classic Mode"-related changes.
  • Loading branch information
NeonKnightOA authored Mar 19, 2024
2 parents 73c3244 + 05da622 commit 0495c9e
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 14 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
* `cg_weaponBarStyle` added to "Game Options" as, well, "Weapon Bar Style".
* `g_ddCaptureTime` and `g_ddRespawnDelay` were added for Double Domination matches.
* `cg_obituaryOutput` can now be configured in "Game Options" as "Death Messages".
* New option in Skirmish/Create Server, "Weapon Ruleset", allows picking up one of five weapon rulesets: All Weapons (Standard) -default-, Instantgib, Single Weapon Arena, Classic Mode -replaces NG, CG, PL, Kami, Invul and Runes with equivalents- and All Weapons (Elimination).
* Now it's possible to compile OAX on Mac (thanks EddieBrrrock!)
* AI enhancements:
* Holdable (Personal Teleporter/Medkit/Kamikaze/Invulnerability) handling.
Expand Down
25 changes: 14 additions & 11 deletions code/game/g_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -1819,17 +1819,20 @@ void ClientSpawn(gentity_t *ent) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_BFG );
client->ps.ammo[WP_BFG] = g_elimination_bfg.integer;
}
if (g_elimination_nail.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_NAILGUN );
client->ps.ammo[WP_NAILGUN] = g_elimination_nail.integer;
}
if (g_elimination_mine.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_PROX_LAUNCHER );
client->ps.ammo[WP_PROX_LAUNCHER] = g_elimination_mine.integer;
}
if (g_elimination_chain.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_CHAINGUN );
client->ps.ammo[WP_CHAINGUN] = g_elimination_chain.integer;
// Classic Mode On prevents the TA weapons from being added to the inventory.
if (g_classicMode.integer <= 0) {
if (g_elimination_nail.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_NAILGUN );
client->ps.ammo[WP_NAILGUN] = g_elimination_nail.integer;
}
if (g_elimination_mine.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_PROX_LAUNCHER );
client->ps.ammo[WP_PROX_LAUNCHER] = g_elimination_mine.integer;
}
if (g_elimination_chain.integer > 0) {
client->ps.stats[STAT_WEAPONS] |= ( 1 << WP_CHAINGUN );
client->ps.ammo[WP_CHAINGUN] = g_elimination_chain.integer;
}
}

ent->health = client->ps.stats[STAT_ARMOR] = g_elimination_startArmor.integer; //client->ps.stats[STAT_MAX_HEALTH]*2;
Expand Down
2 changes: 1 addition & 1 deletion code/game/g_spawn.c
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ qboolean G_CallSpawn( gentity_t *ent ) {
char cvarname[128];
char itemname[128];

// Neon_Knight: In CTF, outside of Arena mode, these items replace the TA items and weapons.
// Neon_Knight: In Classic mode, these items replace the TA items and weapons.
if (g_classicMode.integer > 0) {
if (strequals(ent->classname, "weapon_nailgun")) {
Com_sprintf(itemname, sizeof(itemname), "weapon_shotgun");
Expand Down
4 changes: 2 additions & 2 deletions code/q3_ui/ui_startserver.c
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ static const char *weaponArenaWeapon_list[] = {
};

static const char *weaponMode_list[] = {
"All Weapons (Classic)",
"All Weapons (Standard)",
"Instantgib",
"Single Weapon Arena",
"Classic Arena",
Expand Down Expand Up @@ -1474,7 +1474,7 @@ static void ServerOptions_StatusBar_WeaponMode( void* ptr ) {
UI_DrawString( 320, 460, "Players will spawn with all weapons.", UI_CENTER|UI_SMALLFONT, colorWhite );
}
else {
UI_DrawString( 320, 440, "All Weapons (Classic): No pickups removed.", UI_CENTER|UI_SMALLFONT, colorWhite );
UI_DrawString( 320, 440, "All Weapons (Standard): No pickups removed.", UI_CENTER|UI_SMALLFONT, colorWhite );
UI_DrawString( 320, 460, "Players spawn with Gauntlet and Machinegun.", UI_CENTER|UI_SMALLFONT, colorWhite );
}
break;
Expand Down

0 comments on commit 0495c9e

Please sign in to comment.