View Issue Details

IDProjectCategoryView StatusLast Update
0008272Multi Theft Auto : San AndreasClientpublic2017-10-02 19:31
Reporterrbxf234 Assigned Tolopezloo  
Status resolvedResolutionfixed 
Product Version1.5.2 
Fixed in Version1.5.3 
Summary0008272: After killing ped with sniper, scope disappears

If you try to shoot a ped with sniper(example in head) and after he dies,your sniper rifle's aimer will immediatly close.

Steps To Reproduce

start runcode
run createPed(190,0,0,10)

get a sniper and shoot the ped.

Additional Information

mta version:1.3.5-9.06531.0

TagsNo tags attached.


related to 0004776 resolvedJax Killing peds (dunno if players too) with sniper rifle cases scope view to get back to follow player 



2014-06-15 17:21

viewer   ~~0021036

Last edited: 2014-06-15 17:24

Steps To Reproduce: after the ped is created with runcode, ped must be killed with sniper to reproduce this *
Also,this can be reproduced with Rocket Launcher and Rocket Launcher HS.


2014-06-15 17:45

viewer   ~~0021037

Tried sometimes with Rocket Launcher and Sniper, reproduced everytime


2014-06-19 08:11

reporter   ~~0021055

How recent would you say this is? I feel like this can't have been in long without anyone noticing


2014-06-19 12:30

manager   ~~0021060

It's been around for I'd say at least 6 months, probably much longer, it's just one of those bugs nobody bothers to report.


2014-08-02 21:54

viewer   ~~0021629

was this fixed?


2014-08-02 23:50

reporter   ~~0021639

This bug is old like hell. But no one cared about it.


2014-08-10 05:25

reporter   ~~0021712

to clarify this is with clip ammo increased? otherwise I'm not sure I see the issue because the reloading is aborting the aiming task


2014-08-10 11:42

manager   ~~0021713

No, just standard sniper rifle that fires 1 bullet.


2014-08-10 17:03

reporter   ~~0021714

then the reloading task is aborting the scope and this is intended behavior :S


2015-11-28 18:37

viewer   ~~0024202

this bug can't be reproduced in singleplayer, only in mta, it's annoying that each time you headshot a ped, scope closes...


2016-07-21 18:45

developer   ~~0024962

Actually you don't need to be killer to reproduce this. If you are aiming with sniper and someone kill ped which you are syncing - your scope disappear aswell.

My PR:


2016-07-22 01:19

administrator   ~~0024963

If memory serves me correctly, this used to happen to players as well (im talking very early alphas of MTA). There's gotta be a fix somewhere that's not being applied to peds.


2016-07-22 01:29

administrator   ~~0024964


2016-07-22 02:02

developer   ~~0024965 This?


2016-07-22 02:26

administrator   ~~0024966

Last edited: 2016-07-22 02:53

Yep. This hook has been migrated to these lines:

mtasa-blue\MTA10\multiplayer_sa\multiplayer_keysync.cpp(107): MemPutFast < BYTE > ( 0x50AB10, 0x33 );
mtasa-blue\MTA10\multiplayer_sa\multiplayer_keysync.cpp(370): MemPutFast < BYTE > ( 0x50AB10, 0xC3 );

I think the one on line 370 is the one we want. Notice, it's only applied to CPlayerPed, not to any Peds.

edit: seems i was wrong - CPlayerPed refers to just that PlayerPeds. Since all Peds in MTA are simulated as players (not peds that usually roam around in SP) they're defined as CPlayerPed. Hence, line 370 does fire for peds. Line 107 is the one of interest, but i wonder why it doesnt work for peds but does for players.

Issue History

Date Modified Username Field Change