Memory Posted October 29, 2012 Posted October 29, 2012 Hi, Please, help with code, he doesn't work. function transparency( ) local fX, fY, fZ = getElementPosition ( source ) for _, pVehicle in ipairs ( getElementsByType 'vehicle' ) do local fVehicleX, fVehicleY, fVehicleZ = getElementPosition ( pVehicle ) local fDistance = getDistanceBetweenPoints3D ( fVehicleX, fVehicleY, fVehicleZ, fX, fY, fZ ) if ( fDistance < 10 ) then setElementAlpha(getPedOccupiedVehicle(source),150) setElementAlpha(source,150) setPlayerNametagShowing(source, false) else setElementAlpha(getPedOccupiedVehicle(source),255) setElementAlpha(source,255) setPlayerNametagShowing(source, true) end end setTimer (transparency,1000,1) end
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