summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2014-02-01 17:33:34 -0200
committershennetsind <ind@henn.et>2014-02-01 17:33:34 -0200
commit8a05e611a71168cccac282777aa1719a46f574d0 (patch)
tree77cf2a49f6f18a4270ea564fdbb85056fa78bfdf
parent2263dc4660c6668c373f6a9e654e21bea8c419e4 (diff)
downloadhercules-8a05e611a71168cccac282777aa1719a46f574d0.tar.gz
hercules-8a05e611a71168cccac282777aa1719a46f574d0.tar.bz2
hercules-8a05e611a71168cccac282777aa1719a46f574d0.tar.xz
hercules-8a05e611a71168cccac282777aa1719a46f574d0.zip
MvP dmotion fix
Effect would not be applied when mvp is under no status conditions, also adjusted spelling in secure.h Signed-off-by: shennetsind <ind@henn.et>
-rw-r--r--src/config/secure.h2
-rw-r--r--src/map/status.c10
2 files changed, 7 insertions, 5 deletions
diff --git a/src/config/secure.h b/src/config/secure.h
index 5742ae30b..e5e3662d1 100644
--- a/src/config/secure.h
+++ b/src/config/secure.h
@@ -50,7 +50,7 @@
/**
* Uncomment to disable
* while enabled, movement of invisible (cloaking, hide, etca [not chase walk]) units is not informed to nearby foes,
- * rendering any client-side cheat, that would otherwise make these units visible, to
+ * rendering any client-side cheat, that would otherwise make these units visible, to not function.
* - "Why is this a setting?" because theres a cost, while enabled if a hidden character uses a skill with cast time,
* - for example "cloaking -> walk a bit -> soul break another player" the character display will be momentarily abrupted
* - on the action of unhiding (its a quick effect, ~0.007s in duration), and due to the nature of the skill cast on the client
diff --git a/src/map/status.c b/src/map/status.c
index 74b2571e1..6cc3269e5 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -5529,12 +5529,14 @@ short status_calc_aspd_rate(struct block_list *bl, struct status_change *sc, int
}
unsigned short status_calc_dmotion(struct block_list *bl, struct status_change *sc, int dmotion) {
+ // It has been confirmed on official servers that MvP mobs have no dmotion even without endure
+ if( bl->type == BL_MOB && (((TBL_MOB*)bl)->status.mode&MD_BOSS) )
+ return 0;
+
if( !sc || !sc->count || map_flag_gvg2(bl->m) || map->list[bl->m].flag.battleground )
return cap_value(dmotion,0,USHRT_MAX);
- /**
- * It has been confirmed on official servers that MvP mobs have no dmotion even without endure
- **/
- if( sc->data[SC_ENDURE] || ( bl->type == BL_MOB && (((TBL_MOB*)bl)->status.mode&MD_BOSS) ) )
+
+ if( sc->data[SC_ENDURE] )
return 0;
if( sc->data[SC_RUN] || sc->data[SC_WUGDASH] )
return 0;