Asmgol Posted March 6, 2019 Share Posted March 6, 2019 hello guys why when i use setTimer ( getArmour, 1000, 1, source) script not working Noticeable when i use addEventHandler("onPlayerDamage",getRootElement(),getArmour) the script working fine please help me, sorry for bad english Link to comment
Moderators Patrick Posted March 6, 2019 Moderators Share Posted March 6, 2019 (edited) I think the first problem is, the source is not definied before setTimer. The second problem, you need to trigger the getArmour event, because this function using source and not the function's first argument. Somethink like that: playerElement = getPlayerFromName("Asmgol") setTimer(function() triggerEvent("getArmour", playerElement) end, 1000, 1) Edited March 6, 2019 by stPatrick Link to comment
Asmgol Posted March 7, 2019 Author Share Posted March 7, 2019 On 06/03/2019 at 14:42, stPatrick said: I think the first problem is, the source is not definied before setTimer. The second problem, you need to trigger the getArmour event, because this function using source and not the function's first argument. Somethink like that: playerElement = getPlayerFromName("Asmgol") setTimer(function() triggerEvent("getArmour", playerElement) end, 1000, 1) i did like you told me but its still not working can any scripter gave my his discord or anything like that and ill gave him the full function of my script to fix it for me please? Link to comment
Overkillz Posted March 7, 2019 Share Posted March 7, 2019 We can not bring a fully help due to we can see more of your code. We don't even know if you are triggering the element correct, if you are using hex on your nickname or whatever If you need help via discord here is mine SheDontGiveAFvck#9362 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