Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: ammo/weapons respawn behavior #982

Merged
merged 5 commits into from
Aug 3, 2024

Conversation

SergeyShorokhov
Copy link
Member

@SergeyShorokhov SergeyShorokhov commented Aug 2, 2024

Items that were created without the SF_NORESPAWN flag can work normally (like HL: Deathmatch items)
video: https://www.youtube.com/watch?v=TsfiMZ0RuPU

@SergeyShorokhov SergeyShorokhov added Type: 🧬 bug in original GameDLL An error that could not be fixed by GameDLL. Type: 🚀 enhancement Improvement or addition of a new feature. Status: ✅ done The issue done and closed. labels Aug 2, 2024
@SergeyShorokhov SergeyShorokhov requested a review from s1lentq August 2, 2024 21:38
@SergeyShorokhov SergeyShorokhov self-assigned this Aug 2, 2024
@SergeyShorokhov SergeyShorokhov merged commit a202425 into master Aug 3, 2024
4 checks passed
@SergeyShorokhov SergeyShorokhov deleted the fix/items-berhavior-restore branch August 3, 2024 17:11
jonathan-up added a commit to jonathan-up/ReGameDLL_CS that referenced this pull request Aug 4, 2024
* Fix: `ammo`/`weapons` respawn behavior (rehlds#982)

* `CBasePlayerAmmo`: check spawnflags on `Spawn()`

* `CBasePlayerItem`: check spawnflags on `Materialize()`

* `CBasePlayerItem`: Add `Respawn()` item when hasn't specific spawnflags

* `CBasePlayerItem`: remove `SF_NORESPAWN` flag on `Respawn()`

* Use forgotten `AMMO_RESPAWN_TIME`

* Feature: ConVars for `weapon`/`item`/`ammo` respawn time (rehlds#983)

* `CBasePlayerAmmo`: check spawnflags on `Spawn()`

* `CBasePlayerItem`: check spawnflags on `Materialize()`

* `CBasePlayerItem`: Add `Respawn()` item when hasn't specific spawnflags

* `CBasePlayerItem`: remove `SF_NORESPAWN` flag on `Respawn()`

* Use forgotten `AMMO_RESPAWN_TIME`

* new ConVars: `mp_item_respawn_time`, `mp_weapon_respawn_time`, `mp_ammo_respawn_time`

---------

Co-authored-by: Sergey Shorokhov <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: ✅ done The issue done and closed. Type: 🧬 bug in original GameDLL An error that could not be fixed by GameDLL. Type: 🚀 enhancement Improvement or addition of a new feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant