PkmnLib.NET/Plugins/PkmnLib.Plugin.Gen7/Scripts/Moves/GenesisSupernova.cs

17 lines
490 B
C#

using PkmnLib.Plugin.Gen7.Scripts.Terrain;
namespace PkmnLib.Plugin.Gen7.Scripts.Moves;
[Script(ScriptCategory.Move, "genesis_supernova")]
public class GenesisSupernova : Script
{
/// <inheritdoc />
public override void OnSecondaryEffect(IExecutingMove move, IPokemon target, byte hit)
{
var battleData = move.User.BattleData;
if (battleData == null)
return;
battleData.Battle.SetTerrain(ScriptUtils.ResolveName<PsychicTerrain>());
}
}