Skip to content

Commit

Permalink
CUI: Weapon Arena Weapon will be inactive if the Weapon Ruleset isn't…
Browse files Browse the repository at this point in the history
… Weapon Arena. (#240)
  • Loading branch information
NeonKnightOA authored Mar 20, 2024
1 parent 0495c9e commit 260b631
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
* `elimination_selfdamage` can now be set in the UI for Elimination and eCTF matches.
* `g_grapple` can now be set for all match types.
* `g_harvesterFromBodies` can now be set for Harvester matches.
* `g_weaponArenaWeapon` can be selectable in Classic UI, but it needs "Single Weapon Arena" to be set before.
* `g_weaponArenaWeapon` can be selectable in Classic UI, but it needs "Single Weapon Arena" to be set before (it's grayed out if this isn't the case).
* `cg_muzzleFlashStyle` can now be chosen in Classic UI under "Game Options".
* Separated "Allow Downloads From Servers" and "Allow Downloads To Clients". The former is a player option (`cl_allowDownload 0/1`) and can be set in "Options -> Network" (formerly in "Game Options"), while the latter a server option (`sv_allowDownload 0/1`) and can be set from "Create Server". The option names were changed to reflect these changes.
* "Delag Hitscan" was moved from "Game Options" to "Network".
Expand Down
10 changes: 7 additions & 3 deletions code/q3_ui/ui_startserver.c
Original file line number Diff line number Diff line change
Expand Up @@ -2049,7 +2049,7 @@ static void ServerOptions_MenuInit( qboolean multiplayer ) {
else /* if(UI_GametypeUsesCaptureLimit(s_serveroptions.gametype)) */ {
s_serveroptions.capturelimit.generic.type = MTYPE_FIELD;
if (UI_IsARoundBasedGametype(s_serveroptions.gametype)) {
s_serveroptions.capturelimit.generic.name = "Round Limit:";
s_serveroptions.capturelimit.generic.name = "Score Limit:";
}
else {
s_serveroptions.capturelimit.generic.name = "Capture Limit:";
Expand Down Expand Up @@ -2103,17 +2103,21 @@ static void ServerOptions_MenuInit( qboolean multiplayer ) {
}
s_serveroptions.weaponMode.generic.name = "Weapons Ruleset:";
s_serveroptions.weaponMode.generic.statusbar = ServerOptions_StatusBar_WeaponMode;

//Weapon Arena Weapon list
y += BIGCHAR_HEIGHT+2;
s_serveroptions.weaponArenaWeapon.generic.type = MTYPE_SPINCONTROL;
s_serveroptions.weaponArenaWeapon.generic.flags = QMF_PULSEIFFOCUS|QMF_SMALLFONT;
s_serveroptions.weaponArenaWeapon.generic.name = "SWA Mode Weapon:";
s_serveroptions.weaponArenaWeapon.generic.name = "Weapon Arena Weapon:";
s_serveroptions.weaponArenaWeapon.generic.x = OPTIONS_X;
s_serveroptions.weaponArenaWeapon.generic.y = y;
s_serveroptions.weaponArenaWeapon.itemnames = weaponArenaWeapon_list;
s_serveroptions.weaponArenaWeapon.generic.statusbar = ServerOptions_StatusBar_WeaponArenaWeapon;

if(s_serveroptions.weaponMode.curvalue != 2) {
s_serveroptions.weaponArenaWeapon.generic.flags |= QMF_INACTIVE;
}

y += BIGCHAR_HEIGHT+2;
s_serveroptions.grapple.generic.type = MTYPE_RADIOBUTTON;
s_serveroptions.grapple.generic.flags = QMF_PULSEIFFOCUS|QMF_SMALLFONT;
Expand Down

0 comments on commit 260b631

Please sign in to comment.