kyleanthonydizon Posted May 10, 2017 Group: Members Topic Count: 27 Topics Per Day: 0.01 Content Count: 100 Reputation: 0 Joined: 10/22/16 Last Seen: May 17, 2017 Share Posted May 10, 2017 Hi, I've been trying to implement an @afk command, but whenever I recompile, I stops somewhere =( Then when I start server, map-server is not showing. May I request for a working @afk command? Quote Link to comment Share on other sites More sharing options...
0 Poring King Posted May 10, 2017 Group: Members Topic Count: 63 Topics Per Day: 0.02 Content Count: 1016 Reputation: 191 Joined: 11/27/14 Last Seen: February 15 Share Posted May 10, 2017 (edited) Try this not tested ACMD_FUNC(afk) { nullpo_retr(-1, sd); if( map[sd->bl.m].flag.autotrade != battle_config.autotrade_mapflag ) { clif_displaymessage(fd, msg_txt(sd,1179)); // Autotrade is not allowed on this map. return -1; } if( pc_isdead(sd) ) { clif_displaymessage(fd, msg_txt(sd,1180)); // You cannot autotrade when dead. return -1; } sd->state.autotrade = 1; if( battle_config.at_timeout ) { int timeout = atoi(message); status_change_start(NULL,&sd->bl, SC_AUTOTRADE, 10000, 0, 0, 0, 0, ((timeout > 0) ? min(timeout,battle_config.at_timeout) : battle_config.at_timeout) * 60000, 0); } channel_pcquit(sd,0xF); //leave all chan clif_authfail_fd(sd->fd, 15); return 0; } Quote This is just quick rearch look for Chatterboy post .. Edited May 10, 2017 by Poring King Quote Link to comment Share on other sites More sharing options...
Question
kyleanthonydizon
Hi, I've been trying to implement an @afk command, but whenever I recompile, I stops somewhere =( Then when I start server, map-server is not showing. May I request for a working @afk command?
Link to comment
Share on other sites
1 answer 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.