Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //----------------- Flying Car -----------------
- //
- // Just enable the FlyingCar Bool
- //
- // Double check the Numerics for IS_CONTROL_PRESSED
- //-----------------------------------------------------
- FlyingCarLoop ()
- {
- if (IS_PED_IN_ANY_VEHICLE(PLAYER_PED_ID,0))
- {
- int Vehid = GET_VEHICLE_PED_IS_IN(PLAYER_PED_ID,0)
- if (IS_CONTROL_PRESSED(2,67) ==true ) //Forward
- {
- float Speed = GET_ENTITY_SPEED(Vehid) + 0.5
- SET_VEHICLE_FORWARD_SPEED(Vehid,Speed)
- }
- if ( (IS_CONTROL_PRESSED(2,196) ==true) && ( ! IS_VEHICLE_ON_ALL_WHEELS(Vehid) ) //Left
- {
- Vector3 Rot = GET_ENTITY_ROTATION(Vehid,2)
- Rot.z = Rot.z + 1.0
- newRot Vector3(Rot.x, Rot.y, Rot.z)
- SET_ENTITY_ROTATION(Vehid,newRot,2,1)
- }
- if ( (IS_CONTROL_PRESSED(2,197) ==true) && ( ! IS_VEHICLE_ON_ALL_WHEELS(Vehid) ) //Right
- {
- Vector3 Rot = GET_ENTITY_ROTATION(Vehid,2)
- Rot.z = Rot.z - 1.0
- newRot Vector3(Rot.x, Rot.y, Rot.z)
- SET_ENTITY_ROTATION(Vehid,newRot,2,1)
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement