Fory Posted April 23, 2021 Share Posted April 23, 2021 Hello everyone 1-2 ideas would be needed, how I shall begin it how new AFK to a system, this would be only so much that the chatboxba announces it that: outputChatBox("#efad5f[AFK]: " Name " 5 of his minutes AFK", getRootElement(), 255, 255, 255, true) else outputChatBox("#efad5f[AFK]: "name" back up", getRootElement(), 255, 255, 255, true) --------------------NEXT---------------------- outputChatBox("#efad5f[AFK]: " Name " 10 of his minutes AFK", getRootElement(), 255, 255, 255, true) else outputChatBox("#efad5f[AFK]: "name" back up", getRootElement(), 255, 255, 255, true) For somebody, some idea? Link to comment
Moderators Patrick Posted April 23, 2021 Moderators Share Posted April 23, 2021 You can use getPlayerIdleTime, thats make it really easy. Link to comment
Fory Posted April 23, 2021 Author Share Posted April 23, 2021 Valami hibát ír a 12. Sorban setTimer( function () if getElementData(getLocalPlayer(),"afk") == false then local getLocalPlayer = targetPlayer setElementData (getLocalPlayer(),"afk",true) outputChatBox("#efad5f[AFK]: #42c2d2" .. targetPlayer .. "#ffffff 5 of his minutes AFK.", getRootElement(), 255, 255, 255, true) else setElementData (getLocalPlayer(),"afk",false) outputChatBox("#efad5f[AFK]: #42c2d2" .. targetPlayer .. "#ffffff Back Up.", getRootElement(), 255, 255, 255, true) end end end 2500, 0) Link to comment
Fory Posted April 23, 2021 Author Share Posted April 23, 2021 ERROR: Loading script failed: var_afk\server.lua:7:')' expected (to close '(' at line 1) near 'end' ezt írja ki, de nem tudom hogy miért. 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