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

0008272: After killing ped with sniper, scope disappears #51

Merged
merged 1 commit into from Jul 22, 2016

Conversation

Projects
None yet
3 participants
@lopezloo
Member

lopezloo commented Jul 21, 2016

No description provided.

@@ -4074,7 +4074,7 @@ void GetDeathAnim( CClientPed* pDamagedPed, CEventDamage* pEvent, AssocGroupId&
{
if ( pEvent )
{
pEvent->ComputeDeathAnim ( pDamagedPed->GetGamePlayer(), true );
pEvent->ComputeDeathAnim ( pDamagedPed->GetGamePlayer(), false );

This comment has been minimized.

@qaisjp

qaisjp Jul 21, 2016

Member

I guess nobody knows what bUnk does?

@qaisjp

qaisjp Jul 21, 2016

Member

I guess nobody knows what bUnk does?

This comment has been minimized.

@lopezloo

lopezloo Jul 22, 2016

Member

We probably shouldn't bother as far as this return correct data. In GTA it's called from CEventHandler::ComputeDamageResponse (0x4C0A34) with this set to false.

@lopezloo

lopezloo Jul 22, 2016

Member

We probably shouldn't bother as far as this return correct data. In GTA it's called from CEventHandler::ComputeDamageResponse (0x4C0A34) with this set to false.

@darkdreamingdan

This comment has been minimized.

Show comment
Hide comment
@darkdreamingdan

darkdreamingdan Jul 22, 2016

Member

I did some experiments around this strange bUnk, and can perhaps speculate what it means.
I think ComputeDeathAnim with bUnk enabled actually initiates or flags the death to happen in a certain way - that is, it modifies the animation of the player in some way. This means GTA performs the death task and not MTA - this causes a bunch of issues like being kicked out of sniper.

With bUnk disabled however, the animation group and id is retrieved, but without actually interacting with the GTA death task. Since MTA only uses this in a few scenarios, I feel quite confident about merging this. I couldn't produce any negative consequences to this fix, but death animations should be tested in a running server to see if they're still working correctly (in particular I'd want to see if local player death animations are correctly broadcast to remote players).

I think we should pull and wait for something bad to happen.

Member

darkdreamingdan commented Jul 22, 2016

I did some experiments around this strange bUnk, and can perhaps speculate what it means.
I think ComputeDeathAnim with bUnk enabled actually initiates or flags the death to happen in a certain way - that is, it modifies the animation of the player in some way. This means GTA performs the death task and not MTA - this causes a bunch of issues like being kicked out of sniper.

With bUnk disabled however, the animation group and id is retrieved, but without actually interacting with the GTA death task. Since MTA only uses this in a few scenarios, I feel quite confident about merging this. I couldn't produce any negative consequences to this fix, but death animations should be tested in a running server to see if they're still working correctly (in particular I'd want to see if local player death animations are correctly broadcast to remote players).

I think we should pull and wait for something bad to happen.

@qaisjp qaisjp merged commit b511601 into multitheftauto:master Jul 22, 2016

@qaisjp qaisjp added the bug label Jul 4, 2017

@patrikjuvonen patrikjuvonen changed the title from Fixed #8272 (After killing ped with sniper, scope disappears) to 0008272: After killing ped with sniper, scope disappears Sep 4, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment