Flexxy Posted November 15, 2015 Share Posted November 15, 2015 Hey guys can someone tell me what I've use to write Change Car Direction script ? (Reverse in puma markers) Link to comment
thasajti Posted November 15, 2015 Share Posted November 15, 2015 I think this is what you're looking for: setElementRotation() Link to comment
Flexxy Posted November 15, 2015 Author Share Posted November 15, 2015 It doesn't look as it should be. Something missing.. It now looks like this: but it should look like this: (I used puma marker in second video, it's bugged and it's not working with players) Link to comment
arezu Posted November 16, 2015 Share Posted November 16, 2015 You also have to change the velocity setElementVelocity Link to comment
Flexxy Posted November 16, 2015 Author Share Posted November 16, 2015 I did it like that, but it's not working. It looks same as ;_: wrmarker = createMarker(4094.1000976563, 325.79998779297, 67.900001525879, "arrow", 5, 255, 255, 255, 0) function wallride(player) if getElementType(player)=="player" then local vehicle=getPedOccupiedVehicle(player) if source==wrmarker then local speedx, speedy, speedz = getElementVelocity (localPlayer) setElementVelocity(localPlayer, -speedx, -speedy, -speedz) setElementRotation(vehicle, 0, 90 , 312) end end end addEventHandler("onClientMarkerHit", getRootElement(), wallride) Link to comment
Rockyz Posted November 16, 2015 Share Posted November 16, 2015 This Is Example But Change The Time and The Velocity To Works Perfectly function wallride ( player ) if ( source == wrmarker ) then if ( player == localPlayer ) then local vehicle = getPedOccupiedVehicle ( player ); setElementVelocity ( player, 40, 40, 40 ); setTimer ( setElementVelocity, 90, 1, player, 100, 100, 100 ); setElementRotation ( vehicle, 0, 90 , 312 ); end end end addEventHandler ( "onClientMarkerHit", root, wallride ); Link to comment
Rockyz Posted November 16, 2015 Share Posted November 16, 2015 This Is Example But Change The Time and The Velocity To Works Perfectly function wallride ( player ) if ( source == wrmarker ) then if ( player == localPlayer ) then local vehicle = getPedOccupiedVehicle ( player ); setElementVelocity ( player, 40, 40, 40 ); setTimer ( setElementVelocity, 90, 1, player, 100, 100, 100 ); setElementRotation ( vehicle, 0, 90 , 312 ); end end end addEventHandler ( "onClientMarkerHit", root, wallride ); Link to comment
jingzhi Posted November 19, 2015 Share Posted November 19, 2015 Hey guys can someone tell me what I've use to write Change Car Direction script ? (Reverse in puma markers) From the video I can't really see what kind of change of direction you want. Do you wish to change the speed also? Is it like a 180 degrees turn or completely 2 opposite directions in all x,y and z axis? 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