From 9694f77616b2f127bcde59d49cc7e3cad832d0b3 Mon Sep 17 00:00:00 2001 From: skotlex Date: Fri, 24 Feb 2006 01:16:33 +0000 Subject: - Player-summoned mobs won't level up now. - Fixed Super Novice explosion spirits triggering no matter what you said on the third line. It now triggers on the fourth line.... - Fixed GTB blocking targetted spells when gtb_pvp_only was set. - Merged the code of Ankle snare and Spider web. It no longer moves target if sc failed. - Players should stop walking as soon as they start vending or get into a chat. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5382 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/skill.c | 41 +++++++++++------------------------------ 1 file changed, 11 insertions(+), 30 deletions(-) (limited to 'src/map/skill.c') diff --git a/src/map/skill.c b/src/map/skill.c index faedbd39a..7f49264a6 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -1141,16 +1141,6 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int skilllv,0,0,0,skill_get_time2(skillid,skilllv),0); break; - case PF_SPIDERWEB: /* ƒXƒpƒCƒ_?ƒEƒFƒbƒu */ - { - int sec = skill_get_time2(skillid,skilllv); - if(map[src->m].flag.pvp) //PvP‚Å‚Í?S‘©ŽžŠÔ”¼Œ¸?H - sec = sec/2; - battle_stopwalking(bl,1); - status_change_start(bl,SkillStatusChangeTable[skillid],100,skilllv,0,0,0,sec,0); - } - break; - case ASC_METEORASSAULT: /* ƒ?ƒeƒIƒAƒTƒ‹ƒg */ //Any enemies hit by this skill will receive Stun, Darkness, or external bleeding status ailment with a 5%+5*SkillLV% chance. switch(rand()%3) { @@ -2492,7 +2482,8 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl,int s if (status_isdead(src) || (src != bl && status_isdead(bl))) return 1; - if (skillid && skill_get_type(skillid) == BF_MAGIC && status_isimmune(bl)) + if (skillid && skill_get_type(skillid) == BF_MAGIC && + !battle_config.gtb_pvp_only && status_isimmune(bl)) //GTB makes all targetted skills silently fail. return 1; @@ -6910,19 +6901,21 @@ int skill_unit_onplace_timer(struct skill_unit *src,struct block_list *bl,unsign } break; + case UNT_SPIDERWEB: case UNT_ANKLESNARE: - if(sg->val2==0 && tsc && tsc->data[SC_ANKLE].timer==-1){ + if(sg->val2==0 && (!tsc || tsc->data[type].timer==-1 )){ int sec = skill_get_time2(sg->skill_id,sg->skill_lv); - battle_stopwalking(bl,1); - status_change_start(bl,SC_ANKLE,100,sg->skill_lv,0,0,0,sec,0); - map_moveblock(bl, src->bl.x, src->bl.y, tick); - clif_fixpos(bl); + if (status_change_start(bl,type,100,sg->skill_lv,0,0,0,sec,0)) + { + map_moveblock(bl, src->bl.x, src->bl.y, tick); + clif_fixpos(bl); + sg->val2=bl->id; + } //clif_01ac(&src->bl); //Removed? Check the openkore description of this packet: [Skotlex] // 01AC: long ID // Indicates that an object is trapped, but ID is not a // valid monster or player ID. - sg->limit=DIFF_TICK(tick,sg->tick)+sec; - sg->val2=bl->id; + sg->limit = DIFF_TICK(tick,sg->tick)+sec; sg->interval = -1; src->range = 0; } @@ -7092,18 +7085,6 @@ int skill_unit_onplace_timer(struct skill_unit *src,struct block_list *bl,unsign } break; - case UNT_SPIDERWEB: - if(sg->val2==0 && (!tsc || tsc->data[type].timer==-1 )){ - skill_additional_effect(ss,bl,sg->skill_id,sg->skill_lv,BF_MISC,tick); - map_moveblock(bl, src->bl.x, src->bl.y, tick); - clif_fixpos(bl); - sg->limit = DIFF_TICK(tick,sg->tick)+skill_get_time2(sg->skill_id,sg->skill_lv); - sg->val2=bl->id; - sg->interval = -1; - src->range = 0; - } - break; - case UNT_GRAVITATION: if (skill_attack(BF_MAGIC,ss,&src->bl,bl,sg->skill_id,sg->skill_lv,tick,0)) skill_additional_effect(ss,bl,sg->skill_id,sg->skill_lv,BF_MAGIC,tick); -- cgit v1.2.3-70-g09d2