diff options
author | Haru <haru@dotalux.com> | 2014-10-20 00:38:44 +0200 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2014-10-24 00:59:21 +0200 |
commit | 138352558b04de199139d5f8124d6e3c24df8008 (patch) | |
tree | 2d9894bb9c4d630715603860745d3e77ac7851b3 /src/map/skill.c | |
parent | 98274e4ab8d5f8cb6381a4a625441c90020dffff (diff) | |
download | hercules-138352558b04de199139d5f8124d6e3c24df8008.tar.gz hercules-138352558b04de199139d5f8124d6e3c24df8008.tar.bz2 hercules-138352558b04de199139d5f8124d6e3c24df8008.tar.xz hercules-138352558b04de199139d5f8124d6e3c24df8008.zip |
pc_isriding* / pc_setriding* cleanup
- pc_isriding is now renamed to pc_isridingpeco, since that's what it
checks (to avoid confusion).
- pc_hasmount is added, to check for any of Peco, Dragon, Mado Gear, Wug
Rider.
- pc->setridingdragon is added.
- pc->setridingwug is added.
- pc->setfalcon type is changed.
- pc->setmadogear type is changed.
- pc->setridign is changed to pc->setridingpeco to avoid confusion.
- Changed direct accesses to sd->sd.option to the proper pc_is*
accessors, where applicable.
- Special thanks to Kisuka.
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/skill.c')
-rw-r--r-- | src/map/skill.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/map/skill.c b/src/map/skill.c index 414ca74d3..5ea5cc424 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -8533,9 +8533,9 @@ int skill_castend_nodamage_id(struct block_list *src, struct block_list *bl, uin break; case NC_SELFDESTRUCTION: - if( sd ) { - if( pc_ismadogear(sd) ) - pc->setmadogear(sd, 0); + if (sd) { + if (pc_ismadogear(sd)) + pc->setmadogear(sd, false); clif->skill_nodamage(src, bl, skill_id, skill_lv, 1); skill->castend_damage_id(src, src, skill_id, skill_lv, tick, flag); status->set_sp(src, 0, 0); @@ -13440,7 +13440,7 @@ int skill_check_condition_castbegin(struct map_session_data* sd, uint16 skill_id } break; case ST_RIDING: - if(!pc_isriding(sd) && !pc_isridingdragon(sd)) { + if (!pc_isridingpeco(sd) && !pc_isridingdragon(sd)) { clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0); return 0; } @@ -13555,7 +13555,7 @@ int skill_check_condition_castbegin(struct map_session_data* sd, uint16 skill_id return 0; } case ST_PECO: - if(!pc_isriding(sd)) { + if (!pc_isridingpeco(sd)) { clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0); return 0; } @@ -14972,7 +14972,7 @@ int skill_frostjoke_scream(struct block_list *bl, va_list ap) { return 0; if (bl->type == BL_PC) { struct map_session_data *sd = (struct map_session_data *)bl; - if ( sd && sd->sc.option&(OPTION_INVISIBLE|OPTION_MADOGEAR) ) + if (sd && (pc_isinvisible(sd) || pc_ismadogear(sd))) return 0;//Frost Joke / Scream cannot target invisible or MADO Gear characters [Ind] } //It has been reported that Scream/Joke works the same regardless of woe-setting. [Skotlex] |