diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-08-02 04:09:01 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-08-02 04:09:01 +0000 |
commit | 46649a93ab9a214c8cb842a25588699f76db0023 (patch) | |
tree | 859c670c3b83c47c6dc0d9f884122ae8b2d0ad80 /src/map/skill.c | |
parent | dbcc79545f9c8cb17b1aa3b274673c79b2621d26 (diff) | |
download | hercules-46649a93ab9a214c8cb842a25588699f76db0023.tar.gz hercules-46649a93ab9a214c8cb842a25588699f76db0023.tar.bz2 hercules-46649a93ab9a214c8cb842a25588699f76db0023.tar.xz hercules-46649a93ab9a214c8cb842a25588699f76db0023.zip |
- Fixed NPC_SELFDESTRUCTION damaging yourself, causing the source to be knocked back, as well as making others in the splash damage not receive any damage if they are hurt after the caster.
- Fixed NPC_RUN not setting the mob's state to MSS_WALK (normally not set by the mob ai)
- unit_walktoxy flag&2 setting will now also ignore unit_can_move, for a forced walk.
- Adjusted NPC_RUN level of Marine Spheres (5->7 cells)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8044 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r-- | src/map/skill.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/map/skill.c b/src/map/skill.c index a78e7820a..678461ae0 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -3098,13 +3098,17 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl, int case CR_ACIDDEMONSTRATION: case TF_THROWSTONE: case NPC_SMOKING: - case NPC_SELFDESTRUCTION: case HVAN_EXPLOSION: //[orn] case GS_FLING: case NJ_ZENYNAGE: skill_attack(BF_MISC,src,src,bl,skillid,skilllv,tick,flag); break; + case NPC_SELFDESTRUCTION: + if (src != bl) + skill_attack(BF_MISC,src,src,bl,skillid,skilllv,tick,flag); + break; + // Celest case PF_SOULBURN: if (rand()%100 < (skilllv < 5 ? 30 + skilllv * 10 : 70)) { @@ -4903,7 +4907,8 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in int dir = (bl == src)?unit_getdir(src):map_calc_dir(src,bl->x,bl->y); //If cast on self, run forward, else run away. unit_stop_attack(src); //Run skillv tiles overriding the can-move check. - unit_walktoxy(src, bl->x + skilllv * mask[dir][0], bl->y + skilllv * mask[dir][1], 2); + if (unit_walktoxy(src, src->x + skilllv * mask[dir][0], src->y + skilllv * mask[dir][1], 2) && md) + md->state.skillstate = MSS_WALK; //Otherwise it isn't updated in the ai. } break; |