- Cleaned up combo-skill implementation, SC_COMBO is automatically ended in skill_check_condition now.
- Modified TK-ranker infinite combos to behave as described by AuronX (it could use some optimization, since as it currently stands, it invokes the pc_istop10fame function twice per skill invocation). git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@6520 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
3d666eeb94
commit
3dc2f37e5f
@ -4,6 +4,10 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
|
|||||||
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
||||||
|
|
||||||
2006/05/08
|
2006/05/08
|
||||||
|
* Cleaned up combo-skill implementation, SC_COMBO is automatically ended in
|
||||||
|
skill_check_condition now. [Skotlex]
|
||||||
|
* Modified TK-ranker infinite combos to behave as described by AuronX.
|
||||||
|
Refer to his thread in the development section for details. [Skotlex]
|
||||||
* Made all Soul Link Spirit skills not be castable on self. [Skotlex]
|
* Made all Soul Link Spirit skills not be castable on self. [Skotlex]
|
||||||
* Changed rate of NPC status effect skills to 50+10*lv% base chance
|
* Changed rate of NPC status effect skills to 50+10*lv% base chance
|
||||||
(guessed, but better than 100% for all levels) [Skotlex]
|
(guessed, but better than 100% for all levels) [Skotlex]
|
||||||
|
@ -1812,8 +1812,6 @@ int skill_attack( int attack_type, struct block_list* src, struct block_list *ds
|
|||||||
if(sd) {
|
if(sd) {
|
||||||
//Sorry for removing the Japanese comments, but they were actually distracting
|
//Sorry for removing the Japanese comments, but they were actually distracting
|
||||||
//from the actual code and I couldn't understand a thing anyway >.< [Skotlex]
|
//from the actual code and I couldn't understand a thing anyway >.< [Skotlex]
|
||||||
if (skillid && sd->sc.data[SC_COMBO].timer != -1)
|
|
||||||
status_change_end(src,SC_COMBO,-1); //Interrupt previous combo if you used a skill already. [Skotlex]
|
|
||||||
switch(skillid)
|
switch(skillid)
|
||||||
{
|
{
|
||||||
case MO_TRIPLEATTACK:
|
case MO_TRIPLEATTACK:
|
||||||
@ -1904,7 +1902,7 @@ int skill_attack( int attack_type, struct block_list* src, struct block_list *ds
|
|||||||
break;
|
break;
|
||||||
case SL_STIN:
|
case SL_STIN:
|
||||||
case SL_STUN:
|
case SL_STUN:
|
||||||
if (skilllv >= 7 && sd->sc.data[SC_COMBO].timer == -1)
|
if (skilllv >= 7 && sd->sc.data[SC_SMA].timer == -1)
|
||||||
sc_start(src,SC_SMA,100,skilllv,skill_get_time(SL_SMA, skilllv));
|
sc_start(src,SC_SMA,100,skilllv,skill_get_time(SL_SMA, skilllv));
|
||||||
break;
|
break;
|
||||||
case GS_FULLBUSTER:
|
case GS_FULLBUSTER:
|
||||||
@ -2645,8 +2643,6 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl,int s
|
|||||||
status_change_end(src, SC_EXPLOSIONSPIRITS, -1);
|
status_change_end(src, SC_EXPLOSIONSPIRITS, -1);
|
||||||
if (sc->data[SC_BLADESTOP].timer != -1)
|
if (sc->data[SC_BLADESTOP].timer != -1)
|
||||||
status_change_end(src,SC_BLADESTOP,-1);
|
status_change_end(src,SC_BLADESTOP,-1);
|
||||||
if (sc->data[SC_COMBO].timer != -1) //This is one is here to make combo end even if skill failed.
|
|
||||||
status_change_end(src,SC_COMBO,-1);
|
|
||||||
}
|
}
|
||||||
if(!check_distance_bl(src, bl, 2)) { //Need to move to target.
|
if(!check_distance_bl(src, bl, 2)) { //Need to move to target.
|
||||||
int dx,dy;
|
int dx,dy;
|
||||||
@ -4662,7 +4658,7 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
|
|||||||
|| i==SC_CP_WEAPON || i==SC_CP_SHIELD || i==SC_CP_ARMOR || i==SC_CP_HELM
|
|| i==SC_CP_WEAPON || i==SC_CP_SHIELD || i==SC_CP_ARMOR || i==SC_CP_HELM
|
||||||
|| i==SC_COMBO || i==SC_DANCING || i==SC_GUILDAURA || i==SC_EDP
|
|| i==SC_COMBO || i==SC_DANCING || i==SC_GUILDAURA || i==SC_EDP
|
||||||
|| i==SC_AUTOBERSERK || i==SC_CARTBOOST || i==SC_MELTDOWN || i==SC_MOONLIT
|
|| i==SC_AUTOBERSERK || i==SC_CARTBOOST || i==SC_MELTDOWN || i==SC_MOONLIT
|
||||||
|| i==SC_SAFETYWALL
|
|| i==SC_SAFETYWALL || i==SC_SMA
|
||||||
)
|
)
|
||||||
continue;
|
continue;
|
||||||
if(i==SC_BERSERK) tsc->data[i].val4=1; //Mark a dispelled berserk to avoid setting hp to 100.
|
if(i==SC_BERSERK) tsc->data[i].val4=1; //Mark a dispelled berserk to avoid setting hp to 100.
|
||||||
@ -7821,19 +7817,19 @@ int skill_check_condition(struct map_session_data *sd,int skill, int lv, int typ
|
|||||||
case TK_STORMKICK:
|
case TK_STORMKICK:
|
||||||
case TK_DOWNKICK:
|
case TK_DOWNKICK:
|
||||||
case TK_COUNTER:
|
case TK_COUNTER:
|
||||||
if(sd->sc.data[SC_COMBO].timer != -1 && sd->sc.data[SC_COMBO].val1 == skill)
|
if(sd->sc.data[SC_COMBO].timer == -1)
|
||||||
break; //Combo ready.
|
return 0; //Combo needs to be ready
|
||||||
if (pc_istop10fame(sd->char_id,MAPID_TAEKWON))
|
if (pc_istop10fame(sd->char_id,MAPID_TAEKWON))
|
||||||
{ //Unlimited Combo
|
{ //Unlimited Combo
|
||||||
if (skill == sd->skillid_old)
|
if (skill == sd->skillid_old) {
|
||||||
|
status_change_end(&sd->bl, SC_COMBO, -1);
|
||||||
|
sd->skillid_old = sd->skilllv_old = 0;
|
||||||
return 0; //Can't repeat previous combo skill.
|
return 0; //Can't repeat previous combo skill.
|
||||||
if (type&1) {
|
|
||||||
//On cast-end, set this skill as previous one.
|
|
||||||
sd->skillid_old = skill;
|
|
||||||
sd->skilllv_old = lv;
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
} else
|
||||||
|
if(sd->sc.data[SC_COMBO].val1 == skill)
|
||||||
|
break; //Combo ready.
|
||||||
return 0;
|
return 0;
|
||||||
case BD_ADAPTATION: /* ƒAƒhƒŠƒu */
|
case BD_ADAPTATION: /* ƒAƒhƒŠƒu */
|
||||||
{
|
{
|
||||||
@ -8262,7 +8258,22 @@ int skill_check_condition(struct map_session_data *sd,int skill, int lv, int typ
|
|||||||
if(spiritball > 0) // Ÿ†‹…?Á”ï
|
if(spiritball > 0) // Ÿ†‹…?Á”ï
|
||||||
pc_delspiritball(sd,spiritball,0);
|
pc_delspiritball(sd,spiritball,0);
|
||||||
|
|
||||||
|
if (sd->sc.data[SC_COMBO].timer!=-1)
|
||||||
|
{ //End combo state after skill is invoked. [Skotlex]
|
||||||
|
switch (skill) {
|
||||||
|
case TK_TURNKICK:
|
||||||
|
case TK_STORMKICK:
|
||||||
|
case TK_DOWNKICK:
|
||||||
|
case TK_COUNTER:
|
||||||
|
//set this skill as previous one.
|
||||||
|
sd->skillid_old = skill;
|
||||||
|
sd->skilllv_old = lv;
|
||||||
|
if (pc_istop10fame(sd->char_id,MAPID_TAEKWON))
|
||||||
|
break; //Do not end combo state.
|
||||||
|
default:
|
||||||
|
status_change_end(&sd->bl,SC_COMBO,-1);
|
||||||
|
}
|
||||||
|
}
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user