even more elegant repeat afk fix

This commit is contained in:
in1tiate 2021-04-15 06:44:14 -05:00
parent 96f2204b79
commit a32b33d957
2 changed files with 1 additions and 1 deletions

View File

@ -55,6 +55,7 @@ class AOClient : public QObject {
joined(false), current_area(0), current_char(""), socket(p_socket), server(p_server), joined(false), current_area(0), current_char(""), socket(p_socket), server(p_server),
is_partial(false), last_wtce_time(0) { is_partial(false), last_wtce_time(0) {
afk_timer = new QTimer; afk_timer = new QTimer;
afk_timer->setSingleShot(true);
connect(afk_timer, SIGNAL(timeout()), this, SLOT(onAfkTimeout())); connect(afk_timer, SIGNAL(timeout()), this, SLOT(onAfkTimeout()));
}; };

View File

@ -326,7 +326,6 @@ void AOClient::onAfkTimeout()
{ {
sendServerMessage("You are now AFK."); sendServerMessage("You are now AFK.");
is_afk = true; is_afk = true;
afk_timer->stop();
} }
AOClient::~AOClient() { AOClient::~AOClient() {