From fa3d60a00ad9530d62d95da19ca7ff12ab1ddf9f Mon Sep 17 00:00:00 2001 From: Eduardo Bart Date: Fri, 30 Mar 2012 06:51:34 -0300 Subject: [PATCH] minor fixes --- .../icons/protection_zone_block.png | Bin 0 -> 1485 bytes src/otclient/core/localplayer.cpp | 3 ++- src/otclient/core/mapview.cpp | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 modules/game_healthbar/icons/protection_zone_block.png diff --git a/modules/game_healthbar/icons/protection_zone_block.png b/modules/game_healthbar/icons/protection_zone_block.png new file mode 100644 index 0000000000000000000000000000000000000000..47bcade8ade2bff2af7a053b592ac55678506c67 GIT binary patch literal 1485 zcmeAS@N?(olHy`uVBq!ia0vp^LLkh+3?vf;>QaFeV{wqX6T`Z5GB1G~mUKs7M+SzC z{oH>NS%G|oWRD45bDP46hOx7_4S6Fo+k-*%fHRz`)E9 z;1lA?!^yU(ueZ-h(p!o9_SGvDVZK|pZawPCRjkE0ckWy{9)>?xB2NTqZgXS_Q|7o3 zCY>9qesYdyO>vQ&sEDeZ)Xh^Th52|Jbs09t7_A9XGnL@Fn8m-$ncvmIczUV%+sBV) zmgF2=JYR^NafTW5ofAhNhU#n$RH)5Jn&}~{B_)|co?7GyDP@Qn4``x*MYw(A-+I|eUdfbh6;04 znInEOPa-TnzkcPVB%mxIVI;xJ&&k$e!g2M&c||_<-i)YPU552`EE)oAd;KI2uU@g( znq`fTRFy8r%_!aan4nwXhR?2F*&VL^;>nYFZsLIo?5`g_5D?%QulVlciP+kWlQg^ zuQ~hf+&OkBiR6}L8FuseFG?}2`gHQd!FgfTTjhjgKlY38-&m?GyYFey>gAUzOm0=H zD;!vL?pUVHh{%yPU+K=X{Bq;g^-P^_^y9yud>L&# zpK+7p8lKASu_g7pOKm>P`V!fuIB|C3?L*D(#`8BZt^3vfNwQDmw%VD?49xno8}eV* z)$jALIQNG`hdWyI!0x`!)oCU#O=dQPYDBzP{^VR6_j=Felerw03%v*rm$|u=sr)A2 zny9sA0gqxie{YsxS}Yjhd_AFCM=UaiWr0g}T#2fX*zPr9vss?TPf_t)6*7;-al!Lh iia+KHEWFlGawwj$$I(jQ_J#GJwCd^V=d#Wzp$Pyi1XDNw literal 0 HcmV?d00001 diff --git a/src/otclient/core/localplayer.cpp b/src/otclient/core/localplayer.cpp index bff37a32..567e7fcb 100644 --- a/src/otclient/core/localplayer.cpp +++ b/src/otclient/core/localplayer.cpp @@ -231,12 +231,13 @@ void LocalPlayer::setExperience(double experience) void LocalPlayer::setLevel(double level, double levelPercent) { - if(m_level != level || m_levelPercent != m_levelPercent) { + if(m_level != level || m_levelPercent != levelPercent) { double oldLevel = m_level; double oldLevelPercent = m_levelPercent; m_level = level; m_levelPercent = levelPercent; + dump << "yeah"; callLuaField("onLevelChange", level, levelPercent, oldLevel, oldLevelPercent); } } diff --git a/src/otclient/core/mapview.cpp b/src/otclient/core/mapview.cpp index 5e2b8e91..ce5644c8 100644 --- a/src/otclient/core/mapview.cpp +++ b/src/otclient/core/mapview.cpp @@ -357,7 +357,8 @@ void MapView::updateVisibleTilesCache(int start) if(stop) { // schedule next update continuation - m_updateTilesCacheEvent = g_eventDispatcher.addEvent(std::bind(&MapView::updateVisibleTilesCache, asMapView(), count)); + // scheduling an event with delay 0 ensures that the its execution will be after next frame render + m_updateTilesCacheEvent = g_eventDispatcher.scheduleEvent(std::bind(&MapView::updateVisibleTilesCache, asMapView(), count), 0); } if(start == 0) m_cachedFloorVisibleCreatures = g_map.getSpectators(cameraPosition, false);