mirror of
https://github.com/edubart/otclient.git
synced 2025-12-03 08:26:50 +01:00
fix focus bug, change battle events
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
#include "eventdispatcher.h"
|
||||
|
||||
#include <framework/core/clock.h>
|
||||
#include "timer.h"
|
||||
|
||||
EventDispatcher g_eventDispatcher;
|
||||
|
||||
@@ -53,10 +54,10 @@ void EventDispatcher::poll()
|
||||
int count = 0;
|
||||
while(m_pollEventsSize > 0) {
|
||||
if(count > 50) {
|
||||
static bool reported = false;
|
||||
if(!reported) {
|
||||
static Timer reportTimer;
|
||||
if(reportTimer.running() && reportTimer.ticksElapsed() > 250) {
|
||||
logError("ATTENTION the event list is not getting empty, this could be caused by some bad code");
|
||||
reported = true;
|
||||
reportTimer.restart();
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user