Brad96 Posted August 28, 2013 Share Posted August 28, 2013 I want a command to start shooting and another not shoot, and it kills me every time I have to click, and lines Explain to me please .. thanks: D function misil () vehicle = getPedOccupiedVehicle ( localPlayer ) x, y, z = getElementPosition ( vehicle ) Pro = createProjectile( localPlayer,19,x,y,z+2,200) end addEventHandler ( "onVehicleEnter", getRootElement(), misil) function bindMisil() bindKey ( "mouse1", "down", misil ) end addEventHandler ("onClientResourceStart" , getRootElement (), bindMisil ) Link to comment
EstrategiaGTA Posted August 28, 2013 Share Posted August 28, 2013 (edited) function misil () local vehicle = getPedOccupiedVehicle ( getLocalPlayer() ) local x, y, z = getElementPosition ( vehicle ) createProjectile( getLocalPlayer(),19,x, y, z+2,200) end bindKey ( "mouse1", "down", misil ) "onVehicleEnter" event is server-side only and createProjectile is client-side only. Edited August 28, 2013 by Guest Link to comment
EstrategiaGTA Posted August 28, 2013 Share Posted August 28, 2013 Use: I tested it and it works. 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