Skip to content

Commit

Permalink
Updated Warg skills effects
Browse files Browse the repository at this point in the history
* Tooth of Warg damage is now considered Weapon Mastery ATK which ignores elements.
* Warg Dash damage is no longer affected by player weight.
* When under the Warg Bite status players cannot use Hide, Cloaking, Cloaking Exceed, or Camouflage.
* Dance With Wug:
-- Damage is now considered a SC bonus.
-- Skills affected by Dance With Wug are now in INF3.
* Warg Strike and Warg Bite:
-- No longer affected by caster's % damage cards.
-- No longer ignores target's flee.
-- Ignores Demi-Human and Elemental reductions.

Thanks to @NovaRagnarok for helping test and get info!
  • Loading branch information
aleos89 committed Jan 22, 2016
1 parent 994b406 commit 8e6a65f
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 33 deletions.
16 changes: 9 additions & 7 deletions db/pre-re/skill_db.txt
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@
// 0x08000 - skill that can be used to target while under SC__MANHOLE effect
// 0x10000 - skill that affects hidden targets
// 0x20000 - skill that affects SC_GLOOMYDAY_SK
// 0x40000 - skill that is affected by SC_DANCEWITHWUG
// 0x80000 - skill blocked by RA_WUGBITE
// 17 Name
// 18 Description
1,0,0,0,0,0,0,9,0,no,0,0,0,none,0,0x0, NV_BASIC,Basic Skill
Expand Down Expand Up @@ -136,7 +138,7 @@
48,-1,8,0,-1,0,0,10,2,no,0,0,0,weapon,0,0x0, TF_DOUBLE,Double Attack
49,0,0,0,0,0,0,10,0,no,0,0,0,weapon,0,0x0, TF_MISS,Improve Dodge
50,1,6,1,0,1,0,10,1,no,0,0,0,weapon,0,0x0, TF_STEAL,Steal
51,1,6,4,0,1,0,10,1,no,0,0,0,none,0,0x4064, TF_HIDING,Hiding
51,1,6,4,0,1,0,10,1,no,0,0,0,none,0,0x84064, TF_HIDING,Hiding
52,-2,6,1,5,0,0,10,1,no,0,0,0,weapon,0,0x0, TF_POISON,Envenom
53,9,6,16,5,0x1,0,1,1,no,0,0,0,weapon,0,0x0, TF_DETOXIFY,Detoxify
//
Expand Down Expand Up @@ -238,7 +240,7 @@
132,0,0,0,0,0,0,5,0,no,0,0,0,weapon,0,0x0, AS_RIGHT,Righthand Mastery
133,0,0,0,0,0,0,5,0,no,0,0,0,weapon,0,0x0, AS_LEFT,Lefthand Mastery
134,0,0,0,0,0,0,10,0,no,0,0,0,weapon,0,0x0, AS_KATAR,Katar Mastery
135,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x60, AS_CLOAKING,Cloaking
135,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x80060, AS_CLOAKING,Cloaking
136,1,8,1,-1,0,0,10,-8,no,0,0,0,weapon,0,0x0, AS_SONICBLOW,Sonic Blow
137,3:4:5:6:7,6,1,-1,0x2,1,5,1,no,0,0,0,weapon,0,0x4, AS_GRIMTOOTH,Grimtooth
138,1,6,16,5,0x1,0,10,1,no,0,0x400,0,weapon,0,0x0, AS_ENCHANTPOISON,Enchant Poison
Expand Down Expand Up @@ -959,7 +961,7 @@
2030,-2,6,4,-1,0,0,5,1,no,0,0x200,0,weapon,0,0x0, GC_WEAPONCRUSH,Weapon Crush
2031,1,6,1,-1,0,0,5,1,no,0,0,0,weapon,0,0x0, GC_VENOMPRESSURE,Venom Pressure
2032,5,6,2,0,0x1,0,5,1,yes,0,0,1,none,0,0x0, GC_POISONSMOKE,Poison Smoke
2033,0,6,4,0,0x1,0,5,1,no,0,0,0,weapon,0,0x40, GC_CLOAKINGEXCEED,Cloaking Exceed
2033,0,6,4,0,0x1,0,5,1,no,0,0,0,weapon,0,0x80040, GC_CLOAKINGEXCEED,Cloaking Exceed
2034,0,6,4,-1,0x2,3,1,1,no,0,0,0,weapon,0,0x0, GC_PHANTOMMENACE,Phantom Menace
2035,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x0, GC_HALLUCINATIONWALK,Hallucination Walk
2036,0,6,4,-1,0x2,1:1:1:1:2,5,1,no,0,0,0,weapon,0,0x0, GC_ROLLINGCUTTER,Rolling Cutter
Expand Down Expand Up @@ -1001,12 +1003,12 @@
2239,3,6,2,0,0x42,3,5,1,no,0,0x80,3,misc,0,0x2800, RA_CLUSTERBOMB,Cluster Bomb
2240,0,6,4,0,0,0,1,1,no,0,0,0,none,0,0x0, RA_WUGMASTERY,Warg Mastery
2241,0,6,4,0,0,0,3,1,no,0,0,0,none,0,0x2000, RA_WUGRIDER,Warg Rider
2242,0,6,4,-1,0x42,1,1,0,no,0,0,0,weapon,0,0x2000, RA_WUGDASH,Warg Dash
2243,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x2000, RA_WUGSTRIKE,Warg Strike
2244,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x80, RA_WUGBITE,Warg Bite
2242,0,6,4,-1,0x42,1,1,1,no,0,0,0,weapon,0,0x42000, RA_WUGDASH,Warg Dash
2243,9,6,1,0,0x98,0,5,1,no,0,0,0,weapon,0,0x42000, RA_WUGSTRIKE,Warg Strike
2244,9,6,1,0,0x98,0,5,1,no,0,0,0,weapon,0,0x40080, RA_WUGBITE,Warg Bite
2245,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0, RA_TOOTHOFWUG,Tooth of Warg
2246,0,6,4,0,0x2,3:4:5:6:7,5,1,no,0,0x40000,0,weapon,0,0x0, RA_SENSITIVEKEEN,Sensitive Keen
2247,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x42, RA_CAMOUFLAGE,Camouflage
2247,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x80042, RA_CAMOUFLAGE,Camouflage
2248,0,0,0,0,0,0,5,0,no,0,0,0,none,0,0x0, RA_RESEARCHTRAP,Research Trap
2249,3,6,2,3,0x43,2,1,1,no,0,0x80,1,misc,0,0x2000, RA_MAGENTATRAP,Magenta Trap
2250,3,6,2,1,0x43,2,1,1,no,0,0x80,1,misc,0,0x2000, RA_COBALTTRAP,Cobalt Trap
Expand Down
16 changes: 9 additions & 7 deletions db/re/skill_db.txt
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@
// 0x08000 - skill that can be used to target while under SC__MANHOLE effect
// 0x10000 - skill that affects hidden targets
// 0x20000 - skill that affects SC_GLOOMYDAY_SK
// 0x40000 - skill that is affected by SC_DANCEWITHWUG
// 0x80000 - skill blocked by RA_WUGBITE
// 17 Name
// 18 Description
1,0,0,0,0,0,0,9,0,no,0,0,0,none,0,0x0, NV_BASIC,Basic Skill
Expand Down Expand Up @@ -136,7 +138,7 @@
48,-1,8,0,-1,0,0,10,2,no,0,0,0,weapon,0,0x0, TF_DOUBLE,Double Attack
49,0,0,0,0,0,0,10,0,no,0,0,0,weapon,0,0x0, TF_MISS,Improve Dodge
50,1,6,1,0,1,0,10,1,no,0,0,0,weapon,0,0x0, TF_STEAL,Steal
51,1,6,4,0,1,0,10,1,no,0,0,0,none,0,0x4064, TF_HIDING,Hiding
51,1,6,4,0,1,0,10,1,no,0,0,0,none,0,0x84064, TF_HIDING,Hiding
52,-2,6,1,5,0,0,10,1,no,0,0,0,weapon,0,0x0, TF_POISON,Envenom
53,9,6,16,5,0x1,0,1,1,no,0,0,0,weapon,0,0x0, TF_DETOXIFY,Detoxify
//
Expand Down Expand Up @@ -238,7 +240,7 @@
132,0,0,0,0,0,0,5,0,no,0,0,0,weapon,0,0x0, AS_RIGHT,Righthand Mastery
133,0,0,0,0,0,0,5,0,no,0,0,0,weapon,0,0x0, AS_LEFT,Lefthand Mastery
134,0,0,0,0,0,0,10,0,no,0,0,0,weapon,0,0x0, AS_KATAR,Katar Mastery
135,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x60, AS_CLOAKING,Cloaking
135,0,6,4,0,0x1,0,10,1,no,0,0,0,weapon,0,0x80060, AS_CLOAKING,Cloaking
136,1,8,1,-1,0,0,10,-8,no,0,0,0,weapon,0,0x0, AS_SONICBLOW,Sonic Blow
137,3:4:5:6:7,6,1,-1,0x2,1,5,1,no,0,0,0,weapon,0,0x4, AS_GRIMTOOTH,Grimtooth
138,1,6,16,5,0x1,0,10,1,no,0,0x400,0,weapon,0,0x0, AS_ENCHANTPOISON,Enchant Poison
Expand Down Expand Up @@ -959,7 +961,7 @@
2030,-2,6,4,-1,0,0,5,1,no,0,0x200,0,weapon,0,0x0, GC_WEAPONCRUSH,Weapon Crush
2031,1,6,1,-1,0,0,5,1,no,0,0,0,weapon,0,0x0, GC_VENOMPRESSURE,Venom Pressure
2032,5,6,2,0,0x1,0,5,1,yes,0,0,1,none,0,0x0, GC_POISONSMOKE,Poison Smoke
2033,0,6,4,0,0x1,0,5,1,no,0,0,0,weapon,0,0x40, GC_CLOAKINGEXCEED,Cloaking Exceed
2033,0,6,4,0,0x1,0,5,1,no,0,0,0,weapon,0,0x80040, GC_CLOAKINGEXCEED,Cloaking Exceed
2034,0,6,4,-1,0x2,3,1,1,no,0,0,0,weapon,0,0x0, GC_PHANTOMMENACE,Phantom Menace
2035,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x0, GC_HALLUCINATIONWALK,Hallucination Walk
2036,0,6,4,-1,0x2,1:1:1:1:2,5,1,no,0,0,0,weapon,0,0x0, GC_ROLLINGCUTTER,Rolling Cutter
Expand Down Expand Up @@ -1001,12 +1003,12 @@
2239,3,6,2,0,0x42,3,5,1,no,0,0x80,3,misc,0,0x2800, RA_CLUSTERBOMB,Cluster Bomb
2240,0,6,4,0,0,0,1,1,no,0,0,0,none,0,0x0, RA_WUGMASTERY,Warg Mastery
2241,0,6,4,0,0,0,3,1,no,0,0,0,none,0,0x2000, RA_WUGRIDER,Warg Rider
2242,0,6,4,-1,0x42,1,1,1,no,0,0,0,weapon,0,0x2000, RA_WUGDASH,Warg Dash
2243,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x2000, RA_WUGSTRIKE,Warg Strike
2244,9,6,1,0,0x40,0,5,1,no,0,0,0,weapon,0,0x80, RA_WUGBITE,Warg Bite
2242,0,6,4,-1,0x42,1,1,1,no,0,0,0,weapon,0,0x42000, RA_WUGDASH,Warg Dash
2243,9,6,1,0,0x98,0,5,1,no,0,0,0,weapon,0,0x42000, RA_WUGSTRIKE,Warg Strike
2244,9,6,1,0,0x98,0,5,1,no,0,0,0,weapon,0,0x40080, RA_WUGBITE,Warg Bite
2245,0,0,0,0,0,0,10,0,no,0,0,0,none,0,0x0, RA_TOOTHOFWUG,Tooth of Warg
2246,0,6,4,0,0x2,3:4:5:6:7,5,1,no,0,0x40000,0,weapon,0,0x0, RA_SENSITIVEKEEN,Sensitive Keen
2247,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x42, RA_CAMOUFLAGE,Camouflage
2247,0,6,4,0,0x1,0,5,1,no,0,0,0,none,0,0x80042, RA_CAMOUFLAGE,Camouflage
2248,0,0,0,0,0,0,5,0,no,0,0,0,none,0,0x0, RA_RESEARCHTRAP,Research Trap
2249,3,6,2,3,0x43,2,1,1,no,0,0x80,1,misc,0,0x2000, RA_MAGENTATRAP,Magenta Trap
2250,3,6,2,1,0x43,2,1,1,no,0,0x80,1,misc,0,0x2000, RA_COBALTTRAP,Cobalt Trap
Expand Down
45 changes: 26 additions & 19 deletions src/map/battle.c
Original file line number Diff line number Diff line change
Expand Up @@ -2850,6 +2850,21 @@ static struct Damage battle_calc_attack_masteries(struct Damage wd, struct block
#endif
}

switch(skill_id) {
case RA_WUGDASH:
case RA_WUGSTRIKE:
case RA_WUGBITE:
if (sd) {

This comment has been minimized.

Copy link
@Lemongrass3110

Lemongrass3110 Jan 22, 2016

Member

You could have moved that check above the switch. :-)

skill = pc_checkskill(sd, RA_TOOTHOFWUG);

ATK_ADD(wd.damage, wd.damage2, 30 * skill);
#ifdef RENEWAL
ATK_ADD(wd.masteryAtk, wd.masteryAtk2, 30 * skill);
#endif
}
break;
}

if (sc) { // Status change considered as masteries
uint8 i;

Expand Down Expand Up @@ -3749,13 +3764,9 @@ static int battle_calc_attack_skill_ratio(struct Damage wd, struct block_list *s
break;
case RA_WUGDASH:// ATK 300%
skillratio += 200;
if (sc && sc->data[SC_DANCEWITHWUG])
skillratio += 10 * sc->data[SC_DANCEWITHWUG]->val1 * (2 + battle_calc_chorusbonus(sd));
break;
case RA_WUGSTRIKE:
skillratio += -100 + 200 * skill_lv;
if (sc && sc->data[SC_DANCEWITHWUG])
skillratio += 10 * sc->data[SC_DANCEWITHWUG]->val1 * (2 + battle_calc_chorusbonus(sd));
break;
case RA_WUGBITE:
skillratio += 300 + 200 * skill_lv;
Expand Down Expand Up @@ -4249,19 +4260,6 @@ static int64 battle_calc_skill_constant_addition(struct Damage wd, struct block_
atk = 40 * pc_checkskill(sd, RA_RESEARCHTRAP);
break;
#endif
case RA_WUGDASH:
if (sd && sd->weight)
atk = (sd->weight / 8) + (30 * pc_checkskill(sd,RA_TOOTHOFWUG));
if (sc && sc->data[SC_DANCEWITHWUG])
atk += 10 * sc->data[SC_DANCEWITHWUG]->val1 * (2 + battle_calc_chorusbonus(sd));
break;
case RA_WUGSTRIKE:
case RA_WUGBITE:
if(sd)
atk = 30 * pc_checkskill(sd, RA_TOOTHOFWUG);
if (sc && sc->data[SC_DANCEWITHWUG])
atk += 10 * sc->data[SC_DANCEWITHWUG]->val1 * (2 + battle_calc_chorusbonus(sd));
break;
case GC_COUNTERSLASH:
atk = sstatus->agi * 2 + (sd ? sd->status.job_level * 4 : 0);
break;
Expand Down Expand Up @@ -4402,7 +4400,16 @@ struct Damage battle_attack_sc_bonus(struct Damage wd, struct block_list *src, s
ATK_ADDRATE(wd.damage, wd.damage2, sc->data[SC_GLOOMYDAY_SK]->val2);
RE_ALLATK_ADDRATE(wd, sc->data[SC_GLOOMYDAY_SK]->val2);
}

if (sc->data[SC_DANCEWITHWUG]) {
if (inf3&INF3_SC_DANCEWITHWUG) {
ATK_ADDRATE(wd.damage, wd.damage2, sc->data[SC_DANCEWITHWUG]->val1 * 10 * battle_calc_chorusbonus(sd));
RE_ALLATK_ADDRATE(wd, sc->data[SC_DANCEWITHWUG]->val1 * 10 * battle_calc_chorusbonus(sd));
}
ATK_ADDRATE(wd.damage, wd.damage2, sc->data[SC_DANCEWITHWUG]->val1 * 2 * battle_calc_chorusbonus(sd));
#ifdef RENEWAL
ATK_ADDRATE(wd.equipAtk, wd.equipAtk2, sc->data[SC_DANCEWITHWUG]->val1 * 2 * battle_calc_chorusbonus(sd));
#endif
}
if(sc->data[SC_ZENKAI] && sstatus->rhw.ele == sc->data[SC_ZENKAI]->val2) {
ATK_ADD(wd.damage, wd.damage2, 200);
#ifdef RENEWAL
Expand Down Expand Up @@ -5228,7 +5235,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src, struct bl
if (sd) { //monsters, homuns and pets have their damage computed directly
wd.damage = wd.statusAtk + wd.weaponAtk + wd.equipAtk + wd.masteryAtk;
wd.damage2 = wd.statusAtk2 + wd.weaponAtk2 + wd.equipAtk2 + wd.masteryAtk2;
if(wd.flag&BF_LONG) //Long damage rate addition doesn't use weapon + equip attack
if(wd.flag&BF_LONG && (skill_id != RA_WUGBITE && skill_id != RA_WUGSTRIKE)) //Long damage rate addition doesn't use weapon + equip attack
ATK_ADDRATE(wd.damage, wd.damage2, sd->bonus.long_attack_atk_rate);
//Custom fix for "a hole" in renewal attack calculation [exneval]
ATK_ADDRATE(wd.damage, wd.damage2, 6);
Expand Down
3 changes: 3 additions & 0 deletions src/map/skill.c
Original file line number Diff line number Diff line change
Expand Up @@ -20216,6 +20216,9 @@ int skill_block_check(struct block_list *bl, sc_type type , uint16 skill_id) {
case SC_KAGEHUMI:
if( inf3&INF3_KAGEHUMI_BL)
return 1;
case SC_BITE:
if (inf3&INF3_BITE_BLOCK)
return 1;
break;
}

Expand Down
2 changes: 2 additions & 0 deletions src/map/skill.h
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ enum e_skill_inf3 {
INF3_USABLE_MANHOLE = 0x08000, // Skill that can be used to target while under SC__MANHOLE effect
INF3_HIT_HIDING = 0x10000, // Skill that affects hidden targets
INF3_SC_GLOOMYDAY_SK = 0x20000, // Skill that affects SC_GLOOMYDAY_SK
INF3_SC_DANCEWITHWUG = 0x40000, // Skill that is affected by SC_DANCEWITHWUG
INF3_BITE_BLOCK = 0x80000, // Skill blocked by RA_WUGBITE
};

/// Walk intervals at which chase-skills are attempted to be triggered.
Expand Down
1 change: 1 addition & 0 deletions src/map/status.c
Original file line number Diff line number Diff line change
Expand Up @@ -1996,6 +1996,7 @@ bool status_check_skilluse(struct block_list *src, struct block_list *target, ui
(sc->data[SC_MARIONETTE] && skill_id != CG_MARIONETTE) || // Only skill you can use is marionette again to cancel it
(sc->data[SC_MARIONETTE2] && skill_id == CG_MARIONETTE) || // Cannot use marionette if you are being buffed by another
(sc->data[SC_STASIS] && skill_block_check(src, SC_STASIS, skill_id)) ||
(sc->data[SC_BITE] && skill_block_check(src, SC_BITE, skill_id)) ||
(sc->data[SC_KAGEHUMI] && skill_block_check(src, SC_KAGEHUMI, skill_id))
))
return false;
Expand Down

1 comment on commit 8e6a65f

@aleos89
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fixes #763.

Please sign in to comment.