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

Refactored RemovePlayerItemEx and Extended DestroyItem in CBasePlayerItem #864

Merged
merged 3 commits into from
Sep 28, 2023
Merged

Refactored RemovePlayerItemEx and Extended DestroyItem in CBasePlayerItem #864

merged 3 commits into from
Sep 28, 2023

Conversation

Javekson
Copy link
Contributor

Extension of the DestroyItem method for the CBasePlayerItem class

  • Added a boolean value to indicate the success of item deletion
  • Implemented a condition for handling WEAPON_C4 specifically
  • Added a condition to check for the presence of primary weapons

Updated the item removal mechanism in the RemovePlayerItemEx method

  • Fixed a double hook invocation issue for grenades and performed minor code refactoring

Fix duplicate remove of item_thighpack

- Added a boolean value to indicate the success of item deletion

- Implemented a condition for handling WEAPON_C4 specifically

- Added a condition to check for the presence of primary weapons
- Fixed a double hook invocation issue for grenades and performed minor code refactoring
@hajimura
Copy link
Contributor

Nice catch!

@s1lentq s1lentq merged commit d7b4409 into rehlds:master Sep 28, 2023
4 checks passed
@Javekson Javekson deleted the optimization/code-structure-improvements branch October 3, 2023 08:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants