LatSo Posted August 3, 2013 Posted August 3, 2013 http://rathena.org/board/topic/71389-afk-with-afk-hat/ is there any way to check if a player is on afk? Quote
Jasc Posted August 3, 2013 Posted August 3, 2013 You could use a bindatcmd that triggers the command and sets a variable when used. Then onpclogin, you can set that variable back to 0 Quote
LatSo Posted August 3, 2013 Author Posted August 3, 2013 but will it still do the real @afk command? Quote
Evelynn Posted August 3, 2013 Posted August 3, 2013 (edited) I do not know if bindatcmd will overwrite the original @afk or not. You should probably test it and see If that doesnt work then, heres something that may pull it off. the AFK command is based off of the Autotrade command. You can add a new script function to check if player is on autotrade mode Using if Player's Session Data state = sd->state.autotrade return 1; NOTE: This is my theory on how it could be achieved. It may not be 100% guaranteed. Edited August 3, 2013 by Evelynn Quote
LatSo Posted August 3, 2013 Author Posted August 3, 2013 (edited) or i could edit the name of @afk into something like @afkx then bindatcmd the @afk that will automatically run the @afkx command. sorry bad english. you think this will work? or disable the @afk command in the players command and replace it with bindatcmd @logout that will automatically trigger the real @afk after setting a variable to a player. Edited August 3, 2013 by LatSo Quote
Evelynn Posted August 3, 2013 Posted August 3, 2013 Your theory will work as well. I do not see an issue with that. That is most likely the easiest and simplest way. Quote
Question
LatSo
http://rathena.org/board/topic/71389-afk-with-afk-hat/
is there any way to check if a player is on afk?
6 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.