InDev Posted June 5, 2010 Posted June 5, 2010 Hi all, I have a problem in my script i just made this function but when i restart the resource it bug my script, all the functions after this one bugs and i don't know what's wrong in the function so i hope you'll see clearer than me Thanks for the help. Here is the function: function parkVeh( thePlayer, commandName ) local veh = getPedOccupiedVehicle( thePlayer ) if( veh )then local owner = getElementInfo( veh, "Owner" ) --"getElementInfo" -> personnal function, don't bug local plname = getPlayerName( thePlayer ) if( owner == plname )then local x, y, z = getElementPosition( thePlayer ) local a, b, c = getVehicleRotation( veh ) setElementInfo( veh, "X", x ) --"setElementInfo" -> personnal function, don't bug setElementInfo( veh, "Y", y ) setElementInfo( veh, "Z", z ) setElementInfo( veh, "A", c ) outputChatBox( "You have parked your vehicle, it will respawn here now", thePlayer, 0, 255, 0 ) end end end addCommandHanler( "park", parkVeh )
DakiLLa Posted June 5, 2010 Posted June 5, 2010 You missed letter 'D' in the 17th line. (addCommandHandler)
InDev Posted June 5, 2010 Author Posted June 5, 2010 Omg Thanks for the help, 4 months i script can't make a simple function lol Can lock the topic
TheRealCow Posted June 5, 2010 Posted June 5, 2010 in debug should show that ? use /debugscript 3 too
InDev Posted June 6, 2010 Author Posted June 6, 2010 in debug should show that ? use /debugscript 3 too Yeah thanks.
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