Best-Killer Posted February 1, 2016 Share Posted February 1, 2016 local sWidth,sHeight = guiGetScreenSize() if isPedInVehicle(localPlayer) then vehicle = getPedOccupiedVehicle(localPlayer) health = math.ceil ( getElementHealth ( vehicle ) / bad argument getElemanthealth expected element at argument 1 got boolean Link to comment
ViRuZGamiing Posted February 1, 2016 Share Posted February 1, 2016 [b]isPedInVehicle[/b] [b]Note:[/b] Client side IsPedInVehicle can be unreliable. Solution is to use: not getPedOccupiedVehicle(ped) Try this; if getPedOccupiedVehicle(localPlayer) then vehicle = getPedOccupiedVehicle(localPlayer) health = math.ceil ( getElementHealth ( vehicle ) / Link to comment
Best-Killer Posted February 1, 2016 Author Share Posted February 1, 2016 Work thanks you Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now