otta8634 [Mon, 3 Feb 2025 11:26:09 +0000 (19:26 +0800)]
Remove some unnecessary changes
In all weapon files a newline was probably accidentally deleted by myself, re-added it so the diff is simplified.
Also removed one unnecessary include in common/gamemodes/gamemode/onslaught/onslaught.qc,
... and fixed the gametype description of CTS.
otta8634 [Tue, 28 Jan 2025 13:39:33 +0000 (21:39 +0800)]
Use hud_skin when fetching images from /gfx/hud/
Previously some display methods (of Weapon, GameItem, StatusEffects, and Nades) tried to access `/gfx/hud/{menu_skin}`, when they should be accessing `/gfx/hud/{hud_skin}`.
This was introduced by 51c7e0a875.
Until !1412 this didn't cause any visible bugs because the display methods were never called, and consequently (after !1412) on menu skins other than `luma`, some or all weapon icons wouldn't show in the list.
This change fixes that issue.
bones_was_here [Mon, 13 Jan 2025 08:27:37 +0000 (18:27 +1000)]
q3compat: check for a map-specific .arena file even when there's another one in the pk3
This allows the server admin to work around pk3s containing an .arena
file (or .defi file) that isn't valid for some map(s) in the pk3,
without modifying the pk3.
Or they could override the one in the pk3 (on a map-specific basis) to
change some value(s).
otta8634 [Sat, 25 Jan 2025 15:05:01 +0000 (23:05 +0800)]
Make filtering work for gamemodes and mutators
Did this by applying the same workaround as the COLORED_NAME macros, using .message if it exists, otherwise .m_name.
In future ideally .message would be renamed to .m_name on Mutators and Gametypes.
See https://gitlab.com/xonotic/xonotic-data.pk3dir/-/merge_requests/181#note_2291392189 for more.
terencehill [Mon, 20 Jan 2025 23:16:58 +0000 (00:16 +0100)]
Improve some Weapons panel dialog settings:
* Rename "Show weapon ID as:" to "Show label:" (weapon is implicit)
* Turn "Show label:" into a checkbox so to get rid of the "None" option
* Add "Name" checkbox as "Show label:" option
* Rename "Weapon ID scale:" to "Scale:" (weapon label is implicit)
* Fix a few wrong dependencies introduced by xonotic/xonotic-data.pk3dir!1414
otta8634 [Sat, 18 Jan 2025 07:52:46 +0000 (15:52 +0800)]
Undo physics changes related to hash change of 0e542a1e
This commit altered how physics code works, changing the hash.
This is a regression.
The rest of the changes in 0e542a1e didn't update the hash, and logically speaking shouldn't alter how physics works.
Undid changes which led to the hash change, at the tiny cost of some lost regained performance.
bones_was_here [Tue, 14 Jan 2025 15:30:41 +0000 (01:30 +1000)]
Prevent hidden weapons being revealed with waypoints and centreprints
Normally this issue isn't noticeable, but with
g_balance_blaster_weaponstart 0 the secret tubas were revealed by the
weapon_group_1 bind.
If all weapons in a group are HIDDEN, nothing is displayed when the
group bind is pressed. This seems better than the alternatives:
- "AOL CD Thrower is not available"
- "@!#%'n Tuba is not available" even though it's in the secret room
- "No weapon in the group is available" but it's a lie
bones_was_here [Tue, 14 Jan 2025 12:21:12 +0000 (22:21 +1000)]
Implement weapon availability warnings for custom weapon groups
Fixes "AOL CD Thrower is not available" (see previous commit and #2380)
when using a cl_weaponpriorityN custom weapon group and none of its
weapons are on the map.
Refactors and somewhat documents the `have_other` checking for
compatibility, performance and clarity.
The delay was frustrating when getting a bckill in midair but being
unable to pick up the ball despite having travelled through it.
We still need to prevent instant pickup by the previous owner so the
ball can be dropped manually. Sharing a field from KH for this with the
same 0.5s delay as used when throwing a weapon.
otta8634 [Sat, 11 Jan 2025 12:39:06 +0000 (20:39 +0800)]
Improve Jump buff, Vortex, Mayhem descriptions
I discovered the Jump buff added note while looking at the code recently that it also negates any DEATH_FALL damage.
This wasn't documented on the wiki so I missed it initially.
terencehill [Fri, 10 Jan 2025 22:46:59 +0000 (23:46 +0100)]
Code cleanup
* rename Superweapons class to Superweapon because class names should always be singular
* rename StatusEffects class to StatusEffect because class names should always be singular
* rename StatusEffect registry to StatusEffects because registry names should always be plural
* rename Powerup class child of StatusEffect to PowerupStatusEffect so to remove ambiguity
with Powerup child of Pickup
otta8634 [Fri, 10 Jan 2025 15:51:30 +0000 (23:51 +0800)]
Almost fix filtering in the guide
Still has an issue: doesn't work properly for Gametypes and Mutators.
- Method used was filtering based on .m_name, however Gametypes and Mutators don't use .m_name (yet), they use .message.
- This can easily be fixed by just changing the macro to use .message for those two, but a better approach should be used, so I'm intentionally pushing slightly-buggy code in hopes a better approach will be found.
Needed a bit of reworking of some functions in menu/guide/entries.qc so that MENUQC would stop crashing, added comments to help clarify code.