OnPlayerWeaponShot doesn't work for driver DB -
MP2 - 23.01.2014
OnPlayerWeaponShot doesn't get called when the
driver of a vehicle fires a weapon, but does get called by a passenger drive-by. Can this be fixed?
Re: OnPlayerWeaponShot doesn't work for driver DB -
iJumbo - 23.01.2014
You mean pressing Q and E ?
Yea i've noticed that too
Re: OnPlayerWeaponShot doesn't work for driver DB -
Mauzen - 23.01.2014
Correction: its not always 0. For the passenger the weaponid is kind of random, could be something like the weapon in the previous slot, or its somehow dependent from the previously used weapon. At least its the wrong ID most of the time. Tiny bug, but should also be easy to fix.
Re: OnPlayerWeaponShot doesn't work for driver DB -
MP2 - 23.01.2014
On a side note, does anyone know if drive-bys (driver or passenger) are lag compensated? Or is it only on-foot? What about someone on-foot shooting someone in a moving vehicle?
Re: OnPlayerWeaponShot doesn't work for driver DB -
Mauzen - 23.01.2014
I guess passenger drivebys are synced, and driver drivebys not (yet), since they call/dont call OnPlayerWeaponShot. From what I know synced shots should always trigger that callback, and there shouldnt be unsynced shots related with the callback as it is freshly added.
Not sure about your second question. Though I guess for GTA's hitdetection theres no big difference if someone is walking or sitting in a car, so if OnPlayerWeaponShot really is directly linked to that client's hitdetection it should also work for guys in vehicles. Would be easy to test that, but im also too lazy right now.
Re: OnPlayerWeaponShot doesn't work for driver DB -
Joe Staff - 23.01.2014
What about vehicles with guns? (Helicopters)
Re: OnPlayerWeaponShot doesn't work for driver DB -
MP2 - 23.01.2014
The guns on vehicles (seasparrow/hunter guns) work (they call OnPlayerWeaponShot). The reason is WEAPON_M4 IIRC.
Respuesta: Re: OnPlayerWeaponShot doesn't work for driver DB -
Gryphus One - 24.01.2014
I have just made a very brief test with OnPlayerWeaponShot. I just created a filterscript with this simple code:
pawn Код:
public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
SendClientMessage(playerid, -1, "OnPlayerWeaponShot has been called");
return 1;
}
to test if this callback is called from vehicles. When I found it's not I was gonna open a thread, but then I found you MP2 are already reporting this issue.
Quote:
Originally Posted by MP2
The guns on vehicles (seasparrow/hunter guns) work (they call OnPlayerWeaponShot). The reason is WEAPON_M4 IIRC.
|
I have just tested it and armed vehicles (like Rustler, RC Baron, Hydra, Hunter...) do NOT call OnPlayerWeaponShot, just like they don't (at least in previous versions) call OnPlayerGiveDamage. Ohh come on Kalcor, please fix both of these
Re: Respuesta: Re: OnPlayerWeaponShot doesn't work for driver DB -
MP2 - 24.01.2014
Quote:
Originally Posted by Gryphus One
I have just made a very brief test with OnPlayerWeaponShot. I just created a filterscript with this simple code:
pawn Код:
public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ) { SendClientMessage(playerid, -1, "OnPlayerWeaponShot has been called"); return 1; }
to test if this callback is called from vehicles. When I found it's not I was gonna open a thread, but then I found you MP2 are already reporting this issue.
I have just tested it and armed vehicles (like Rustler, RC Baron, Hydra, Hunter...) do NOT call OnPlayerWeaponShot, just like they don't (at least in previous versions) call OnPlayerGiveDamage. Ohh come on Kalcor, please fix both of these
|
I only tested the seasparrow and hunter, and know it worked. Perhaps you made a mistake, or RC3 changed it. I doubt that though.
Respuesta: Re: Respuesta: Re: OnPlayerWeaponShot doesn't work for driver DB -
Gryphus One - 24.01.2014
Quote:
Originally Posted by MP2
I only tested the seasparrow and hunter, and know it worked. Perhaps you made a mistake, or RC3 changed it. I doubt that though.
|
I didn't test Seasparrow but I did test Hunter (both gun and rockets) and other vehicles, and the callback wasn't called.
In a filterscript as simple as the one I created there's not much room for mistakes, specially knowing that it worked when shooting on foot.