66#include "constants/skills.h"
77
88#define LOCAL_TRACE 0
9+ #define ENABLE_ALL_WTA_HANDLER 1
910
1011STATIC_DECLAR bool WtaHandler_Skill (struct BattleUnit * attacker , struct BattleUnit * defender , struct WtaStatus * status )
1112{
@@ -69,11 +70,11 @@ STATIC_DECLAR bool WtaHandler_Vanilla(struct BattleUnit *attacker, struct Battle
6970 for (it = pr_WeaponTriangleRules ; it -> attackerWeaponType >= 0 ; ++ it ) {
7071 if ((attacker -> weaponType == it -> attackerWeaponType ) && (defender -> weaponType == it -> defenderWeaponType )) {
7172 if (it -> atkBonus > 0 ) {
72- status -> bonus .atk += it -> atkBonus * 2 ;
73- status -> bonus .hit += it -> hitBonus * 2 ;
73+ status -> bonus .atk += it -> atkBonus ;
74+ status -> bonus .hit += it -> hitBonus ;
7475 } else {
75- status -> minus .atk += it -> atkBonus * 2 ;
76- status -> minus .hit += it -> hitBonus * 2 ;
76+ status -> minus .atk += it -> atkBonus ;
77+ status -> minus .hit += it -> hitBonus ;
7778 }
7879 return true;
7980 }
@@ -87,16 +88,22 @@ STATIC_DECLAR void WtaHandler(void)
8788 struct BattleUnit * attacker = & gBattleActor ;
8889 struct BattleUnit * defender = & gBattleTarget ;
8990
91+ /**
92+ * Attacker
93+ */
9094 handled = WtaHandler_Skill (attacker , defender , & gWtaStatus_act );
91- if (!handled )
92- handled = WtaHandler_Skill (defender , attacker , & gWtaStatus_tar );
93- if (!handled )
95+ if (!handled || ENABLE_ALL_WTA_HANDLER )
9496 handled = WtaHandler_Weapon (attacker , defender , & gWtaStatus_act );
95- if (!handled )
96- handled = WtaHandler_Weapon (defender , attacker , & gWtaStatus_tar );
97- if (!handled )
97+ if (!handled || ENABLE_ALL_WTA_HANDLER )
9898 handled = WtaHandler_Vanilla (attacker , defender , & gWtaStatus_act );
99- if (!handled )
99+
100+ /**
101+ * Defender
102+ */
103+ handled = WtaHandler_Skill (defender , attacker , & gWtaStatus_tar );
104+ if (!handled || ENABLE_ALL_WTA_HANDLER )
105+ handled = WtaHandler_Weapon (defender , attacker , & gWtaStatus_tar );
106+ if (!handled || ENABLE_ALL_WTA_HANDLER )
100107 handled = WtaHandler_Vanilla (defender , attacker , & gWtaStatus_tar );
101108}
102109
0 commit comments