diff options
author | shennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-07-08 17:38:44 +0000 |
---|---|---|
committer | shennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-07-08 17:38:44 +0000 |
commit | 22c75b070526de8b103032f5bf13504af81e0095 (patch) | |
tree | 46129805f108454e02fd3e8d83a1c22395599db4 /src/map/clif.c | |
parent | 6d371c31155c7d34aee7cf43bcf8ba6ac88060c9 (diff) | |
download | hercules-22c75b070526de8b103032f5bf13504af81e0095.tar.gz hercules-22c75b070526de8b103032f5bf13504af81e0095.tar.bz2 hercules-22c75b070526de8b103032f5bf13504af81e0095.tar.xz hercules-22c75b070526de8b103032f5bf13504af81e0095.zip |
Hello World. Initial support for the new homunculus has been added, credits to brAthena for the base. Not all skills are yet supported, when a non-supported skill is used rather than the usual warning in the console you'll get a red-coloured message in-game "this skill is not yet supported". please step by our bug tracker should you step by any bugs. thank you very much, you're a great crowd.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16381 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/clif.c')
-rw-r--r-- | src/map/clif.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 4153130e5..a35e0fa49 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -10582,6 +10582,27 @@ static void clif_parse_UseSkillToId_homun(struct homun_data *hd, struct map_sess unit_skilluse_id(&hd->bl, target_id, skillnum, skilllv); } +static void clif_parse_UseSkillToPos_homun(struct homun_data *hd, struct map_session_data *sd, unsigned int tick, short skillnum, short skilllv, short x, short y, int skillmoreinfo) +{ + int lv; + if( !hd ) + return; + if( skillnotok_hom(skillnum, hd) ) + return; + if( hd->ud.skilltimer != INVALID_TIMER ) { + if( skillnum != SA_CASTCANCEL && skillnum != SO_SPELLFIST ) return; + } else if( DIFF_TICK(tick, hd->ud.canact_tick) < 0 ) + return; + + if( hd->sc.data[SC_BASILICA] ) + return; + lv = merc_hom_checkskill(hd, skillnum); + if( skilllv > lv ) + skilllv = lv; + if( skilllv ) + unit_skilluse_pos(&hd->bl, x, y, skillnum, skilllv); +} + static void clif_parse_UseSkillToId_mercenary(struct mercenary_data *md, struct map_session_data *sd, unsigned int tick, short skillnum, short skilllv, int target_id) { int lv; @@ -10743,6 +10764,11 @@ static void clif_parse_UseSkillToPosSub(int fd, struct map_session_data *sd, sho if( !(skill_get_inf(skillnum)&INF_GROUND_SKILL) ) return; //Using a target skill on the ground? WRONG. + + if( skillnum >= HM_SKILLBASE && skillnum < HM_SKILLBASE + MAX_HOMUNSKILL ) { + clif_parse_UseSkillToPos_homun(sd->hd, sd, tick, skillnum, skilllv, x, y, skillmoreinfo); + return; + } if( skillnum >= MC_SKILLBASE && skillnum < MC_SKILLBASE + MAX_MERCSKILL ) { |