summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorxantara <xantara@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-02-22 02:13:09 +0000
committerxantara <xantara@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-02-22 02:13:09 +0000
commit9b452a0918913ab0956ac17fee6b1c49815af3f7 (patch)
tree523af91f6efb7225094aa384497b66255332df49 /src
parenta72cf01c7ca53a6ffc810a2b1983ad8b34ef0467 (diff)
downloadhercules-9b452a0918913ab0956ac17fee6b1c49815af3f7.tar.gz
hercules-9b452a0918913ab0956ac17fee6b1c49815af3f7.tar.bz2
hercules-9b452a0918913ab0956ac17fee6b1c49815af3f7.tar.xz
hercules-9b452a0918913ab0956ac17fee6b1c49815af3f7.zip
Fixed Royal Guard's Banding skill & icon activation (bugreport:5210)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15627 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/clif.c3
-rw-r--r--src/map/map.c2
-rw-r--r--src/map/skill.c17
3 files changed, 20 insertions, 2 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index 8ac893916..51d5b802d 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -5274,7 +5274,8 @@ void clif_status_change(struct block_list *bl,int type,int flag,unsigned int tic
type == SI_TENSIONRELAX || type == SI_LANDENDOW || type == SI_AUTOBERSERK ||
type == SI_BUMP || type == SI_READYSTORM || type == SI_READYDOWN ||
type == SI_READYTURN || type == SI_READYCOUNTER || type == SI_DODGE ||
- type == SI_DEVIL || type == SI_NIGHT || type == SI_INTRAVISION)
+ type == SI_DEVIL || type == SI_NIGHT || type == SI_INTRAVISION ||
+ type == SI_BANDING)
tick=0;
// TODO: 0x43f PACKETVER?
diff --git a/src/map/map.c b/src/map/map.c
index 0ae05d3f4..eab54353a 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -423,6 +423,8 @@ int map_moveblock(struct block_list *bl, int x1, int y1, unsigned int tick)
skill_unit_move_unit_group(skill_id2group(sc->data[SC_DANCING]->val2), bl->m, x1-x0, y1-y0);
if (sc->data[SC_WARM])
skill_unit_move_unit_group(skill_id2group(sc->data[SC_WARM]->val4), bl->m, x1-x0, y1-y0);
+ if (sc->data[SC_BANDING])
+ skill_unit_move_unit_group(skill_id2group(sc->data[SC_BANDING]->val4), bl->m, x1-x0, y1-y0);
}
}
} else
diff --git a/src/map/skill.c b/src/map/skill.c
index 3e3b88ae2..83d2b8adc 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -13431,7 +13431,7 @@ int skill_delunitgroup_(struct skill_unit_group *group, const char* file, int li
break;
case LG_BANDING:
{
- struct status_change *sc = NULL;
+ struct status_change *sc = NULL;
if( (sc = status_get_sc(src)) && sc->data[SC_BANDING] ) {
sc->data[SC_BANDING]->val4 = 0;
status_change_end(src,SC_BANDING,-1);
@@ -13684,6 +13684,21 @@ static int skill_unit_timer_sub (DBKey key, void* data, va_list ap)
skill_delunit(unit);
break;
}
+
+ case UNT_BANDING:
+ {
+ struct block_list *src = map_id2bl(group->src_id);
+ struct status_change *sc;
+ if( !src || (sc = status_get_sc(src)) == NULL || !sc->data[SC_BANDING] )
+ {
+ skill_delunit(unit);
+ break;
+ }
+ // This unit isn't removed while SC_BANDING is active.
+ group->limit = DIFF_TICK(tick+group->interval,group->tick);
+ unit->limit = DIFF_TICK(tick+group->interval,group->tick);
+ }
+ break;
default:
skill_delunit(unit);