DAKAN' Posted December 18, 2017 Posted December 18, 2017 function radExit() local Vehicle = getVehicleController(source) local radLinks, radRechts = getVehicleComponentRotation(Vehicle, "wheel_lf_dummy"), getVehicleComponentRotation(Vehicle, "wheel_rf_dummy") setVehicleComponentRotation(Vehicle, radLinks) setVehicleComponentRotation(Vehicle, radRechts) end addEventHandler("onVehicleExit", getRootElement(), radExit) function radEnter() setVehicleComponentRotation(Vehicle, radLinks) setVehicleComponentRotation(Vehicle, radRechts) end addEventHandler("onVehicleEnter", getRootElement(), radEnter) function radRespawn() setVehicleComponentRotation(Vehicle, radLinks) setVehicleComponentRotation(Vehicle, radRechts) end addEventHandler("onVehicleRespawn", getRootElement(), radRespawn) Does anyone know what's wrong with this script?
Tails Posted December 18, 2017 Posted December 18, 2017 remove local from radlinks and radrechts in your function local radLinks, radRechts function radExit() local Vehicle = getVehicleController(source) radLinks, radRechts = getVehicleComponentRotation(Vehicle, "wheel_lf_dummy"), getVehicleComponentRotation(Vehicle, "wheel_rf_dummy") setVehicleComponentRotation(Vehicle, radLinks) setVehicleComponentRotation(Vehicle, radRechts) end addEventHandler("onVehicleExit", getRootElement(), radExit)
DAKAN' Posted December 18, 2017 Author Posted December 18, 2017 1 hour ago, Tails said: remove local from radlinks and radrechts in your function local radLinks, radRechts function radExit() local Vehicle = getVehicleController(source) radLinks, radRechts = getVehicleComponentRotation(Vehicle, "wheel_lf_dummy"), getVehicleComponentRotation(Vehicle, "wheel_rf_dummy") setVehicleComponentRotation(Vehicle, radLinks) setVehicleComponentRotation(Vehicle, radRechts) end addEventHandler("onVehicleExit", getRootElement(), radExit) still did not work
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