2
0
Fork 0
mirror of https://github.com/GTA-ASM/SanAndreasUnity synced 2025-03-05 07:37:17 +00:00

fix NRE in GetCameraFocusPos()

This commit is contained in:
in0finite 2019-07-11 23:00:08 +02:00
parent 57bb127345
commit e9b944cad5

View file

@ -107,7 +107,10 @@ namespace SanAndreasUnity.Behaviours.Peds.States
public new Vector3 GetCameraFocusPos()
{
return m_ped.CurrentVehicle.transform.position;
if (m_ped.CurrentVehicle != null)
return m_ped.CurrentVehicle.transform.position;
else
return base.GetCameraFocusPos();
}
}