P3D-Legacy/P3D/Pokemon/Attacks/Fairy/PlayRough.vb

73 lines
2.4 KiB
VB.net
Raw Normal View History

2016-09-07 18:50:38 +02:00
Namespace BattleSystem.Moves.Fairy
Public Class PlayRough
Inherits Attack
Public Sub New()
'#Definitions
Me.Type = New Element(Element.Types.Fairy)
Me.ID = 583
Me.OriginalPP = 10
Me.CurrentPP = 10
Me.MaxPP = 10
Me.Power = 90
Me.Accuracy = 90
Me.Category = Categories.Physical
Me.ContestCategory = ContestCategories.Beauty
2022-12-04 20:11:29 +01:00
Me.Name = Localization.GetString("move_name_" & Me.ID,"Play Rough")
2016-09-07 18:50:38 +02:00
Me.Description = "The user plays rough with the target and attacks it. This may also lower the target's Attack stat."
Me.CriticalChance = 1
Me.IsHMMove = False
Me.Target = Targets.OneAdjacentTarget
Me.Priority = 0
Me.TimesToAttack = 1
'#End
'#SpecialDefinitions
Me.MakesContact = True
Me.ProtectAffected = True
Me.MagicCoatAffected = False
Me.SnatchAffected = False
Me.MirrorMoveAffected = True
Me.KingsrockAffected = True
Me.CounterAffected = False
Me.DisabledWhileGravity = False
Me.UseEffectiveness = True
Me.ImmunityAffected = True
Me.RemovesFrozen = False
Me.HasSecondaryEffect = True
Me.IsHealingMove = False
Me.IsRecoilMove = False
Me.IsPunchingMove = False
Me.IsDamagingMove = True
Me.IsProtectMove = False
Me.IsSoundMove = False
Me.IsAffectedBySubstitute = True
Me.IsOneHitKOMove = False
Me.IsWonderGuardAffected = True
'#End
Me.EffectChances.Add(10)
End Sub
Public Overrides Sub MoveHits(own As Boolean, BattleScreen As BattleScreen)
Dim p As Pokemon = BattleScreen.OwnPokemon
Dim op As Pokemon = BattleScreen.OppPokemon
If own = False Then
p = BattleScreen.OppPokemon
op = BattleScreen.OwnPokemon
End If
Dim chance As Integer = GetEffectChance(0, own, BattleScreen)
If Core.Random.Next(0, 100) < chance Then
BattleScreen.Battle.LowerStat(Not own, own, BattleScreen, "Attack", 1, "", "move:playrough")
End If
End Sub
End Class
End Namespace