summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2013-02-07 22:15:52 -0200
committershennetsind <ind@henn.et>2013-02-07 22:15:52 -0200
commit4c9bfed8c21cb80a806fffc32c7ac629bdf73438 (patch)
treef5e389854211f679fbdcc04a9abf352bef57d8de /src/map
parent54d0583c7bf443f6fdcc9d5c500188a4f0612357 (diff)
downloadhercules-4c9bfed8c21cb80a806fffc32c7ac629bdf73438.tar.gz
hercules-4c9bfed8c21cb80a806fffc32c7ac629bdf73438.tar.bz2
hercules-4c9bfed8c21cb80a806fffc32c7ac629bdf73438.tar.xz
hercules-4c9bfed8c21cb80a806fffc32c7ac629bdf73438.zip
Adjustment to skill_trap_type battle/skill config
The effect of the config is now restricted to GvG. http://hercules.ws/board/tracker/issue-4832-hunter-ht-anklesnare-serious-bug/ Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map')
-rw-r--r--src/map/skill.c2
-rw-r--r--src/map/status.c2
-rw-r--r--src/map/unit.c6
3 files changed, 5 insertions, 5 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 4b9484609..cb15f0083 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -11459,7 +11459,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
const struct TimerData* td = tsc->data[type]?get_timer(tsc->data[type]->timer):NULL;
if( td )
sec = DIFF_TICK(td->tick, tick);
- if( sg->unit_id == UNT_MANHOLE || battle_config.skill_trap_type ) {
+ if( sg->unit_id == UNT_MANHOLE || battle_config.skill_trap_type || !map_flag_gvg(src->bl.m) ) {
unit_movepos(bl, src->bl.x, src->bl.y, 0, 0);
clif_fixpos(bl);
}
diff --git a/src/map/status.c b/src/map/status.c
index 0ee993de4..97b7c61a1 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -8663,7 +8663,7 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
unit_stop_walking(bl,1);
break;
case SC_ANKLE:
- if( battle_config.skill_trap_type )
+ if( battle_config.skill_trap_type || !map_flag_gvg(bl->m) )
unit_stop_walking(bl,1);
break;
case SC_HIDING:
diff --git a/src/map/unit.c b/src/map/unit.c
index 1d37704e0..60de14093 100644
--- a/src/map/unit.c
+++ b/src/map/unit.c
@@ -353,7 +353,7 @@ int unit_walktoxy( struct block_list *bl, short x, short y, int flag)
map_random_dir(bl, &ud->to_x, &ud->to_y);
if(ud->walktimer != INVALID_TIMER) {
- if( !battle_config.skill_trap_type && sc && sc->data[SC_ANKLE] ) // Ankle disallows you from changing your path
+ if( !battle_config.skill_trap_type && sc && map_flag_gvg(bl->m) && sc->data[SC_ANKLE] ) // Ankle disallows you from changing your path
return 0;
// When you come to the center of the grid because the change of destination while you're walking right now
// Call a function from a timer unit_walktoxy_sub
@@ -430,7 +430,7 @@ int unit_walktobl(struct block_list *bl, struct block_list *tbl, int range, int
map_random_dir(bl, &ud->to_x, &ud->to_y);
if(ud->walktimer != INVALID_TIMER) {
- if( !battle_config.skill_trap_type && sc && sc->data[SC_ANKLE] ) // Ankle disallows you from changing your path
+ if( !battle_config.skill_trap_type && sc && map_flag_gvg(bl->m) && sc->data[SC_ANKLE] ) // Ankle disallows you from changing your path
return 0;
ud->state.change_walk_target = 1;
set_mobstate(bl, flag&2);
@@ -938,7 +938,7 @@ int unit_can_move(struct block_list *bl) {
)
return 0;
- if( sc->data[SC_ANKLE] && ( battle_config.skill_trap_type || !unit_is_walking(bl) ) ) // Ankle only stops you after you're done moving
+ if( sc->data[SC_ANKLE] && ( battle_config.skill_trap_type || ( !map_flag_gvg(bl->m) && !unit_is_walking(bl) ) ) ) // Ankle only stops you after you're done moving
return 0;
if (sc->opt1 > 0 && sc->opt1 != OPT1_STONEWAIT && sc->opt1 != OPT1_BURNING && !(sc->opt1 == OPT1_CRYSTALIZE && bl->type == BL_MOB))