Annas Posted February 10, 2016 Share Posted February 10, 2016 Hi , i have made a script to destroy selected vehicle , but idk why it's not working --- SERVER SIDE function destroyvehicles(player, selected) destroyElement(selected) outputChatBox("You Destroyed This Vehicle Vehicle", player, 0, 250, 0). end end addEvent("CSTdestroy.destroyvehicle", true) addEventHandler("CSTdestroy.destroyvehicle", root, destroyvehicles) Link to comment
KariiiM Posted February 10, 2016 Share Posted February 10, 2016 function destroyvehicles(player, selected) if selected and isElement(selected) then destroyElement(selected) outputChatBox("You Destroyed This Vehicle Vehicle", player, 0, 250, 0). end end addEvent("CSTdestroy.destroyvehicle", true) addEventHandler("CSTdestroy.destroyvehicle", root, destroyvehicles) Link to comment
Annas Posted February 10, 2016 Author Share Posted February 10, 2016 Nothing , not working And there is nothing about it in debugscript Link to comment
KariiiM Posted February 10, 2016 Share Posted February 10, 2016 Nothing , not workingAnd there is nothing about it in debugscript Show the other side Link to comment
Annas Posted February 10, 2016 Author Share Posted February 10, 2016 I cant as it's a complete script. and it's just If (Hide Vehicle) Then triggerserverevent .. Link to comment
KariiiM Posted February 10, 2016 Share Posted February 10, 2016 I cant as it's a complete script. and it's justIf (Hide Vehicle) Then triggerserverevent .. Try to check if the selected is returns true, by outputing it in somewhere Link to comment
Annas Posted February 10, 2016 Author Share Posted February 10, 2016 Nvm , i fixed it. Thx. Link to comment
KariiiM Posted February 10, 2016 Share Posted February 10, 2016 Nvm , i fixed it.Thx. Glad to hear that, btw can I know how did you fix it? because what I had sent to you seem correct 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