More work on refactor to interfaces
All checks were successful
Build / Build (push) Successful in 50s
All checks were successful
Build / Build (push) Successful in 50s
This commit is contained in:
@@ -6,7 +6,7 @@ namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
|
||||
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Water_Bubble_(Ability)">Bulbapedia - Water Bubble</see>
|
||||
/// </summary>
|
||||
[Script(ScriptCategory.Ability, "water_bubble")]
|
||||
public class WaterBubble : Script
|
||||
public class WaterBubble : Script, IScriptChangeIncomingMoveDamage, IScriptChangeMoveDamage
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override void PreventStatusChange(IPokemon pokemon, StringKey status, bool selfInflicted,
|
||||
@@ -17,14 +17,14 @@ public class WaterBubble : Script
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void ChangeIncomingMoveDamage(IExecutingMove move, IPokemon target, byte hit, ref uint damage)
|
||||
public void ChangeIncomingMoveDamage(IExecutingMove move, IPokemon target, byte hit, ref uint damage)
|
||||
{
|
||||
if (move.GetHitData(target, hit).Type?.Name == "fire")
|
||||
damage /= 2;
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void ChangeMoveDamage(IExecutingMove move, IPokemon target, byte hit, ref uint damage)
|
||||
public void ChangeMoveDamage(IExecutingMove move, IPokemon target, byte hit, ref uint damage)
|
||||
{
|
||||
if (move.GetHitData(target, hit).Type?.Name == "water")
|
||||
damage *= 2;
|
||||
|
||||
Reference in New Issue
Block a user