Open
Description
Describe the bug
The following functions have incorrect OOP definitions and should return vectors:
Client
- CLuaGUIDefs.cpp
- guiGetPosition
- guiGetSize
- guiStaticImageGetNativeSize (missing)
- CLuaObjectDefs.cpp
- getObjectScale
- CLuaPedDefs.cpp
- getPedWeaponMuzzlePosition (missing)
- CLuaPointLightDefs.cpp
- getLightDirection
- getWaterVertexPosition
- CLuaRadarAreaDefs
- getRadarAreaSize (it returns a vector for
r.size
only, it should also return a vector forr:getSize()
)
- getRadarAreaSize (it returns a vector for
- CLuaVehicleDefs.cpp
- getVehicleTurretPosition
- CLuaWaterDefs
- getWaterVertexPosition
Server
- CLuaPlayerDefs
- getCameraMatrix
- CLuaPointLightDefs
- getLightDirection
- CLuaRadarAreaDefs
- getRadarAreaSize (as above, in Client)
- CLuaTextDefs
- textItemGetPosition
- CLuaVehicleDefs
- getVehicleTurretPosition
- getVehicleRespawnPosition
- getVehicleRespawnRotation
- CLuaWaterDefs
- getWaterVertexPosition
Expected behaviour
Lets take getVehicleTurretPosition
as an example. It's in the above list, and that means we need to:
- Ensure
vehicle:getTurretPosition()
returns a vector - Ensure
vehicle.turretPosition
returns a vector
Version
1.5.7 r20608
Additional context
This issue was created as part of #1582, which aims to resolve #1240.