Skip to content

Fix crash when player dies on fire #4210

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

Merged
merged 13 commits into from
May 8, 2025

Conversation

FileEX
Copy link
Member

@FileEX FileEX commented May 7, 2025

Fixes #4037

The crash was introduced in e09b85f

The function CPed::RestorePlayerStuffDuringResurrection calls Fire::Extinguish, and then executes a cmp instruction with the ebx register, which got overwritten inside CFire::Extinguish during the call to our hook. That’s why the condition always evaluated as true—even when the value was actually nullptr.

@Dutchman101 Dutchman101 merged commit 1f8ad37 into multitheftauto:master May 8, 2025
6 checks passed
MTABot pushed a commit that referenced this pull request May 8, 2025
@FileEX FileEX deleted the bugfix/fire_task branch May 8, 2025 07:11
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.

Crash when player is on fire
4 participants