Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions src/map/battle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4862,22 +4862,7 @@ static int32 battle_calc_attack_skill_ratio(struct Damage* wd, block_list *src,b
skillratio += 100 + 100 * skill_lv;
#endif
break;
case LK_HEADCRUSH:
skillratio += 40 * skill_lv;
break;
case LK_JOINTBEAT:
skillratio += 10 * skill_lv - 50;
if (wd->miscflag & BREAK_NECK || (tsc && tsc->getSCE(SC_JOINTBEAT) && tsc->getSCE(SC_JOINTBEAT)->val2 & BREAK_NECK)) // The 2x damage is only for the BREAK_NECK ailment.
skillratio *= 2;
break;
#ifdef RENEWAL
// Renewal: skill ratio applies to entire damage [helvetica]
case LK_SPIRALPIERCE:
skillratio += 50 + 50 * skill_lv;
RE_LVL_DMOD(100);
if (sc && sc->getSCE(SC_CHARGINGPIERCE_COUNT) && sc->getSCE(SC_CHARGINGPIERCE_COUNT)->val1 >= 10)
skillratio *= 2;
break;
case ML_SPIRALPIERCE:
skillratio += 50 + 50 * skill_lv;
RE_LVL_DMOD(100);
Expand Down
8 changes: 8 additions & 0 deletions src/map/map-server-generator.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,7 @@
<ClInclude Include="skills/swordman/magnum.hpp" />
<ClInclude Include="skills/swordman/pierce.hpp" />
<ClInclude Include="skills/swordman/provoke.hpp" />
<ClInclude Include="skills/swordman/relax.hpp" />
<ClInclude Include="skills/swordman/resistantsouls.hpp" />
<ClInclude Include="skills/swordman/sacrifice.hpp" />
<ClInclude Include="skills/swordman/selfprovoke.hpp" />
Expand All @@ -391,6 +392,9 @@
<ClInclude Include="skills/swordman/smite.hpp" />
<ClInclude Include="skills/swordman/spearboomerang.hpp" />
<ClInclude Include="skills/swordman/spearstab.hpp" />
<ClInclude Include="skills/swordman/spiralpierce.hpp" />
<ClInclude Include="skills/swordman/traumaticblow.hpp" />
<ClInclude Include="skills/swordman/vitalstrike.hpp" />
<ClInclude Include="skills/taekwon/counter.hpp" />
<ClInclude Include="skills/taekwon/downkick.hpp" />
<ClInclude Include="skills/taekwon/eska.hpp" />
Expand Down Expand Up @@ -651,6 +655,7 @@
<ClCompile Include="skills/swordman/magnum.cpp" />
<ClCompile Include="skills/swordman/pierce.cpp" />
<ClCompile Include="skills/swordman/provoke.cpp" />
<ClCompile Include="skills/swordman/relax.cpp" />
<ClCompile Include="skills/swordman/resistantsouls.cpp" />
<ClCompile Include="skills/swordman/sacrifice.cpp" />
<ClCompile Include="skills/swordman/selfprovoke.cpp" />
Expand All @@ -660,6 +665,9 @@
<ClCompile Include="skills/swordman/smite.cpp" />
<ClCompile Include="skills/swordman/spearboomerang.cpp" />
<ClCompile Include="skills/swordman/spearstab.cpp" />
<ClCompile Include="skills/swordman/spiralpierce.cpp" />
<ClCompile Include="skills/swordman/traumaticblow.cpp" />
<ClCompile Include="skills/swordman/vitalstrike.cpp" />
<ClCompile Include="skills/taekwon/counter.cpp" />
<ClCompile Include="skills/taekwon/downkick.cpp" />
<ClCompile Include="skills/taekwon/eska.cpp" />
Expand Down
24 changes: 24 additions & 0 deletions src/map/map-server-generator.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -795,6 +795,9 @@
<ClInclude Include="skills/swordman/provoke.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/relax.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/resistantsouls.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
Expand Down Expand Up @@ -822,6 +825,15 @@
<ClInclude Include="skills/swordman/spearstab.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/spiralpierce.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/traumaticblow.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/vitalstrike.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/taekwon/counter.hpp">
<Filter>Header Files\Skills\Taekwon</Filter>
</ClInclude>
Expand Down Expand Up @@ -1460,6 +1472,9 @@
<ClCompile Include="skills/swordman/provoke.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/relax.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/resistantsouls.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
Expand Down Expand Up @@ -1487,6 +1502,15 @@
<ClCompile Include="skills/swordman/spearstab.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/spiralpierce.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/traumaticblow.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/vitalstrike.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/taekwon/counter.cpp">
<Filter>Source Files\Skills\Taekwon</Filter>
</ClCompile>
Expand Down
8 changes: 8 additions & 0 deletions src/map/map-server.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,7 @@
<ClInclude Include="skills/swordman/magnum.hpp" />
<ClInclude Include="skills/swordman/pierce.hpp" />
<ClInclude Include="skills/swordman/provoke.hpp" />
<ClInclude Include="skills/swordman/relax.hpp" />
<ClInclude Include="skills/swordman/resistantsouls.hpp" />
<ClInclude Include="skills/swordman/sacrifice.hpp" />
<ClInclude Include="skills/swordman/selfprovoke.hpp" />
Expand All @@ -391,6 +392,9 @@
<ClInclude Include="skills/swordman/smite.hpp" />
<ClInclude Include="skills/swordman/spearboomerang.hpp" />
<ClInclude Include="skills/swordman/spearstab.hpp" />
<ClInclude Include="skills/swordman/spiralpierce.hpp" />
<ClInclude Include="skills/swordman/traumaticblow.hpp" />
<ClInclude Include="skills/swordman/vitalstrike.hpp" />
<ClInclude Include="skills/taekwon/counter.hpp" />
<ClInclude Include="skills/taekwon/downkick.hpp" />
<ClInclude Include="skills/taekwon/eska.hpp" />
Expand Down Expand Up @@ -651,6 +655,7 @@
<ClCompile Include="skills/swordman/magnum.cpp" />
<ClCompile Include="skills/swordman/pierce.cpp" />
<ClCompile Include="skills/swordman/provoke.cpp" />
<ClCompile Include="skills/swordman/relax.cpp" />
<ClCompile Include="skills/swordman/resistantsouls.cpp" />
<ClCompile Include="skills/swordman/sacrifice.cpp" />
<ClCompile Include="skills/swordman/selfprovoke.cpp" />
Expand All @@ -660,6 +665,9 @@
<ClCompile Include="skills/swordman/smite.cpp" />
<ClCompile Include="skills/swordman/spearboomerang.cpp" />
<ClCompile Include="skills/swordman/spearstab.cpp" />
<ClCompile Include="skills/swordman/spiralpierce.cpp" />
<ClCompile Include="skills/swordman/traumaticblow.cpp" />
<ClCompile Include="skills/swordman/vitalstrike.cpp" />
<ClCompile Include="skills/taekwon/counter.cpp" />
<ClCompile Include="skills/taekwon/downkick.cpp" />
<ClCompile Include="skills/taekwon/eska.cpp" />
Expand Down
24 changes: 24 additions & 0 deletions src/map/map-server.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -795,6 +795,9 @@
<ClInclude Include="skills/swordman/provoke.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/relax.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/resistantsouls.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
Expand Down Expand Up @@ -822,6 +825,15 @@
<ClInclude Include="skills/swordman/spearstab.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/spiralpierce.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/traumaticblow.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/swordman/vitalstrike.hpp">
<Filter>Header Files\Skills\Swordman</Filter>
</ClInclude>
<ClInclude Include="skills/taekwon/counter.hpp">
<Filter>Header Files\Skills\Taekwon</Filter>
</ClInclude>
Expand Down Expand Up @@ -1460,6 +1472,9 @@
<ClCompile Include="skills/swordman/provoke.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/relax.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/resistantsouls.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
Expand Down Expand Up @@ -1487,6 +1502,15 @@
<ClCompile Include="skills/swordman/spearstab.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/spiralpierce.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/traumaticblow.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/swordman/vitalstrike.cpp">
<Filter>Source Files\Skills\Swordman</Filter>
</ClCompile>
<ClCompile Include="skills/taekwon/counter.cpp">
<Filter>Source Files\Skills\Taekwon</Filter>
</ClCompile>
Expand Down
29 changes: 0 additions & 29 deletions src/map/skill.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1572,7 +1572,6 @@ int32 skill_additional_effect( block_list* src, block_list *bl, uint16 skill_id,
}
break;

case LK_SPIRALPIERCE:
case ML_SPIRALPIERCE:
case HN_SPIRAL_PIERCE_MAX:
if( dstsd || ( dstmd && !status_bl_has_mode(bl,MD_STATUSIMMUNE) ) ) //Does not work on status immune
Expand All @@ -1584,11 +1583,6 @@ int32 skill_additional_effect( block_list* src, block_list *bl, uint16 skill_id,
sc_start(src,bl,SC_BLIND,100,skill_lv,skill_get_time2(skill_id,skill_lv));
break;

case LK_HEADCRUSH: //Headcrush has chance of causing Bleeding status, except on demon and undead element
if (!(battle_check_undead(tstatus->race, tstatus->def_ele) || tstatus->race == RC_DEMON))
sc_start2(src,bl, SC_BLEEDING,50, skill_lv, src->id, skill_get_time2(skill_id,skill_lv));
break;

case HW_NAPALMVULCAN:
case HN_NAPALM_VULCAN_STRIKE:
sc_start(src,bl,SC_CURSE,5*skill_lv,skill_lv,skill_get_time2(skill_id,skill_lv));
Expand Down Expand Up @@ -5120,23 +5114,6 @@ int32 skill_castend_damage_id (block_list* src, block_list *bl, uint16 skill_id,
skill_attack(BF_WEAPON,src,src,bl,skill_id,skill_lv,tick,flag|SD_ANIMATION);
break;

case LK_HEADCRUSH:
if (status_get_class_(bl) == CLASS_BOSS) {
if (sd)
clif_skill_fail( *sd, skill_id );
break;
}
skill_attack(BF_WEAPON, src, src, bl, skill_id, skill_lv, tick, flag);
break;

case LK_JOINTBEAT:
flag = 1 << rnd() % 6;
if (flag != BREAK_NECK && tsc && tsc->getSCE(SC_JOINTBEAT) && tsc->getSCE(SC_JOINTBEAT)->val2 & BREAK_NECK)
flag = BREAK_NECK; // Target should always receive double damage if neck is already broken
if (skill_attack(BF_WEAPON, src, src, bl, skill_id, skill_lv, tick, flag))
status_change_start(src, bl, SC_JOINTBEAT, (50 * (skill_lv + 1) - (270 * tstatus->str) / 100) * 10, skill_lv, flag & BREAK_FLAGS, src->id, 0, skill_get_time2(skill_id, skill_lv), SCSTART_NONE);
break;

case MO_COMBOFINISH:
if (!(flag&1) && sc && sc->getSCE(SC_SPIRIT) && sc->getSCE(SC_SPIRIT)->val2 == SL_MONK)
{ //Becomes a splash attack when Soul Linked.
Expand Down Expand Up @@ -8040,12 +8017,6 @@ int32 skill_castend_nodamage_id (block_list *src, block_list *bl, uint16 skill_i
break;
*/

case LK_TENSIONRELAX:
clif_skill_nodamage(src,*bl,skill_id,skill_lv,
sc_start4(src,bl,type,100,skill_lv,0,0,skill_get_time2(skill_id,skill_lv),
skill_get_time(skill_id,skill_lv)));
break;

case MER_PROVOKE:
if( status_has_mode(tstatus,MD_STATUSIMMUNE) || battle_check_undead(tstatus->race,tstatus->def_ele) ) {
return 1;
Expand Down
18 changes: 18 additions & 0 deletions src/map/skills/swordman/relax.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
// For more information, see LICENCE in the main folder

#include "relax.hpp"

#include "map/clif.hpp"
#include "map/status.hpp"

SkillRelax::SkillRelax() : SkillImpl(LK_TENSIONRELAX) {
}

void SkillRelax::castendNoDamageId(block_list *src, block_list *target, uint16 skill_lv, t_tick tick, int32& flag) const {
sc_type type = skill_get_sc(getSkillId());

clif_skill_nodamage(src,*target,getSkillId(),skill_lv,
sc_start4(src,target,type,100,skill_lv,0,0,skill_get_time2(getSkillId(),skill_lv),
skill_get_time(getSkillId(),skill_lv)));
}
13 changes: 13 additions & 0 deletions src/map/skills/swordman/relax.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
// For more information, see LICENCE in the main folder

#pragma once

#include "../skill_impl.hpp"

class SkillRelax : public SkillImpl {
public:
SkillRelax();

void castendNoDamageId(block_list *src, block_list *target, uint16 skill_lv, t_tick tick, int32& flag) const override;
};
12 changes: 11 additions & 1 deletion src/map/skills/swordman/skill_factory_swordman.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include "magnum.hpp"
#include "pierce.hpp"
#include "provoke.hpp"
#include "relax.hpp"
#include "resistantsouls.hpp"
#include "sacrifice.hpp"
#include "selfprovoke.hpp"
Expand All @@ -24,6 +25,9 @@
#include "smite.hpp"
#include "spearboomerang.hpp"
#include "spearstab.hpp"
#include "spiralpierce.hpp"
#include "traumaticblow.hpp"
#include "vitalstrike.hpp"

std::unique_ptr<const SkillImpl> SkillFactorySwordman::create(const e_skill skill_id) const {
switch( skill_id ){
Expand Down Expand Up @@ -99,10 +103,16 @@ std::unique_ptr<const SkillImpl> SkillFactorySwordman::create(const e_skill skil
return std::make_unique<StatusSkillImpl>(skill_id);
case LK_CONCENTRATION:
return std::make_unique<StatusSkillImpl>(skill_id);
case LK_HEADCRUSH:
return std::make_unique<SkillTraumaticBlow>();
case LK_JOINTBEAT:
return std::make_unique<SkillVitalStrike>();
case LK_PARRYING:
return std::make_unique<StatusSkillImpl>(skill_id);
case LK_SPIRALPIERCE:
return std::make_unique<WeaponSkillImpl>(skill_id);
return std::make_unique<SkillSpiralPierce>();
case LK_TENSIONRELAX:
return std::make_unique<SkillRelax>();
case PA_SACRIFICE:
return std::make_unique<WeaponSkillImpl>(skill_id);
case PA_SHIELDCHAIN:
Expand Down
33 changes: 33 additions & 0 deletions src/map/skills/swordman/spiralpierce.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
// Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
// For more information, see LICENCE in the main folder

#include "spiralpierce.hpp"

#include <config/const.hpp>
#include <config/core.hpp>

#include "map/mob.hpp"
#include "map/pc.hpp"
#include "map/status.hpp"

SkillSpiralPierce::SkillSpiralPierce() : WeaponSkillImpl(LK_SPIRALPIERCE) {
}

void SkillSpiralPierce::calculateSkillRatio(const Damage *wd, const block_list *src, const block_list *target, uint16 skill_lv, int32 &skillratio, int32 mflag) const {
#ifdef RENEWAL
const status_change *sc = status_get_sc(src);

skillratio += 50 + 50 * skill_lv;
RE_LVL_DMOD(100);
if (sc && sc->getSCE(SC_CHARGINGPIERCE_COUNT) && sc->getSCE(SC_CHARGINGPIERCE_COUNT)->val1 >= 10)
skillratio *= 2;
#endif
}

void SkillSpiralPierce::applyAdditionalEffects(block_list *src, block_list *target, uint16 skill_lv, t_tick tick, int32 attack_type, enum damage_lv dmg_lv) const {
map_session_data *dstsd = BL_CAST(BL_PC, target);
mob_data* dstmd = BL_CAST(BL_MOB, target);

if( dstsd || ( dstmd && !status_bl_has_mode(target,MD_STATUSIMMUNE) ) ) //Does not work on status immune
sc_start(src,target,SC_ANKLE,100,0,skill_get_time2(getSkillId(),skill_lv));
}
14 changes: 14 additions & 0 deletions src/map/skills/swordman/spiralpierce.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
// For more information, see LICENCE in the main folder

#pragma once

#include "../weapon_skill_impl.hpp"

class SkillSpiralPierce : public WeaponSkillImpl {
public:
SkillSpiralPierce();

void applyAdditionalEffects(block_list* src, block_list* target, uint16 skill_lv, t_tick tick, int32 attack_type, enum damage_lv dmg_lv) const override;
void calculateSkillRatio(const Damage *wd, const block_list *src, const block_list *target, uint16 skill_lv, int32 &skillratio, int32 mflag) const override;
};
Loading
Loading