Adds more abilities
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
namespace PkmnLib.Plugin.Gen7.Scripts.Abilities;
|
||||
|
||||
/// <summary>
|
||||
/// Compound Eyes is an ability that increases the accuracy of the Pokémon's moves by 30%.
|
||||
/// This applies to all moves used by the Pokémon, making it particularly effective with low-accuracy moves.
|
||||
///
|
||||
/// <see href="https://bulbapedia.bulbagarden.net/wiki/Compound_Eyes_(Ability)">Bulbapedia - Compound Eyes</see>
|
||||
/// </summary>
|
||||
[Script(ScriptCategory.Ability, "compound_eyes")]
|
||||
public class CompoundEyes : Script
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public override void ChangeAccuracy(IExecutingMove move, IPokemon target, byte hit, ref int modifiedAccuracy)
|
||||
{
|
||||
move.Battle.EventHook.Invoke(new AbilityTriggerEvent(move.User));
|
||||
modifiedAccuracy = (int)(modifiedAccuracy * 1.3f);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user