Bunch more moves, changes in how additional information for items works.
This commit is contained in:
19
Plugins/PkmnLib.Plugin.Gen7/Scripts/Side/MatBlockEffect.cs
Normal file
19
Plugins/PkmnLib.Plugin.Gen7/Scripts/Side/MatBlockEffect.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using PkmnLib.Static.Moves;
|
||||
|
||||
namespace PkmnLib.Plugin.Gen7.Scripts.Side;
|
||||
|
||||
public class MatBlockEffect : Script
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override void BlockIncomingHit(IExecutingMove executingMove, IPokemon target, byte hitIndex, ref bool block)
|
||||
{
|
||||
if (executingMove.UseMove.Category != MoveCategory.Status)
|
||||
block = true;
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void OnEndTurn(IBattle battle)
|
||||
{
|
||||
RemoveSelf();
|
||||
}
|
||||
}
|
||||
15
Plugins/PkmnLib.Plugin.Gen7/Scripts/Side/MistEffect.cs
Normal file
15
Plugins/PkmnLib.Plugin.Gen7/Scripts/Side/MistEffect.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using PkmnLib.Static;
|
||||
|
||||
namespace PkmnLib.Plugin.Gen7.Scripts.Side;
|
||||
|
||||
[Script(ScriptCategory.Side, "mist")]
|
||||
public class MistEffect : Script
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override void PreventStatBoostChange(IPokemon target, Statistic stat, sbyte amount, bool selfInflicted,
|
||||
ref bool prevent)
|
||||
{
|
||||
if (amount < 0)
|
||||
prevent = true;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user