Implemented Rage Fist attack

This commit is contained in:
JappaWakka 2023-12-03 19:34:24 +01:00
parent bc8ad24353
commit d9c26c8550
6 changed files with 98 additions and 1 deletions

View File

@ -2197,6 +2197,9 @@
If BattleScreen.FieldEffects.OppBideCounter > 0 Then
BattleScreen.FieldEffects.OppBideDamage += didDamage
End If
If BattleScreen.FieldEffects.OppRageFistPower < 350 Then
BattleScreen.FieldEffects.OppRageFistPower += 50
End If
Else
Dim didDamage As Integer = Damage
If didDamage > op.HP Then
@ -2208,6 +2211,9 @@
If BattleScreen.FieldEffects.OwnBideCounter > 0 Then
BattleScreen.FieldEffects.OwnBideDamage += didDamage
End If
If BattleScreen.FieldEffects.OwnRageFistPower < 350 Then
BattleScreen.FieldEffects.OwnRageFistPower += 50
End If
End If
End If

View File

@ -1420,6 +1420,10 @@ nextIndex:
End If
End If
Next
FieldEffects.OwnRageFistPower = 0
FieldEffects.OppRageFistPower = 0
Else
For Each p As Pokemon In Core.Player.Pokemons
If IsRemoteBattle = True Then
@ -1453,6 +1457,10 @@ nextIndex:
End If
p.ResetTemp()
Next
FieldEffects.OwnRageFistPower = 0
FieldEffects.OppRageFistPower = 0
ResetVars()
Core.SetScreen(New TransitionScreen(Me, New BlackOutScreen(Me), Color.Black, False))
End If

View File

@ -64,6 +64,7 @@
Public OwnLockOn As Integer = 0 'Counter for the moves lock-on and mind reader
Public OwnBideCounter As Integer = 0 'Counter for the Bide move
Public OwnBideDamage As Integer = 0 'Half of the damage dealt by bide
Public OwnRageFistPower As Integer = 0 'how much the Power of the attack Rage Fist increases
Public OwnLansatBerry As Integer = 0 'Raise critical hit ration when Lansat got eaten
Public OwnCustapBerry As Integer = 0 'Raises the attack speed once when Custap got eaten
Public OwnTrappedCounter As Integer = 0 'If the pokemon is trapped (for example by Spider Web), this is =1
@ -203,6 +204,7 @@
Public OppSolarBlade As Integer = 0
Public OppLockOn As Integer = 0
Public OppBideCounter As Integer = 0
Public OppRageFistPower As Integer = 0
Public OppBideDamage As Integer = 0
Public OppLansatBerry As Integer = 0
Public OppCustapBerry As Integer = 0

View File

@ -28795,6 +28795,7 @@
<Compile Include="Pokemon\Attacks\Ghost\PhantomForce.vb" />
<Compile Include="Pokemon\Attacks\Ghost\ShadowBone.vb" />
<Compile Include="Pokemon\Attacks\Ghost\ShadowForce.vb" />
<Compile Include="Pokemon\Attacks\Ghost\RageFist.vb" />
<Compile Include="Pokemon\Attacks\Ghost\SpiritShackle.vb" />
<Compile Include="Pokemon\Attacks\Grass\Leafage.vb" />
<Compile Include="Pokemon\Attacks\Grass\GrassyTerrain.vb" />

View File

@ -1875,7 +1875,9 @@
'returnMove = New Moves.Dragon.Eternabeam()
Case 796
returnMove = New Moves.Steel.SteelBeam()
'Case 797
Case 797
returnMove = New Moves.Ghost.RageFist()
'Case 798
'Blank
Case 999
If GameController.IS_DEBUG_ACTIVE = True Or Core.Player.SandBoxMode = True Then

View File

@ -0,0 +1,78 @@
Namespace BattleSystem.Moves.Ghost
Public Class RageFist
Inherits Attack
Public Sub New()
'#Definitions
Me.Type = New Element(Element.Types.Ghost)
Me.ID = 797
Me.OriginalPP = 10
Me.CurrentPP = 10
Me.MaxPP = 10
Me.Power = 50
Me.Accuracy = 100
Me.Category = Categories.Physical
Me.ContestCategory = ContestCategories.Tough
Me.Name = Localization.GetString("move_name_" & Me.ID, "Rage Fist")
Me.Description = "The user converts its rage into energy to attack. The more times the user has been hit by attacks, the greater the move's power."
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.DisabledWhileGravity = False
Me.UseEffectiveness = True
Me.ImmunityAffected = True
Me.RemovesOwnFrozen = False
Me.HasSecondaryEffect = False
Me.IsHealingMove = False
Me.IsRecoilMove = False
Me.IsPunchingMove = True
Me.IsDamagingMove = True
Me.IsProtectMove = False
Me.IsAffectedBySubstitute = True
Me.IsOneHitKOMove = False
Me.IsWonderGuardAffected = True
'#End
Me.AIField1 = AIField.Damage
Me.AIField2 = AIField.Nothing
End Sub
Public Overrides Function GetBasePower(ByVal own As Boolean, ByVal BattleScreen As BattleScreen) As Integer
If own = True Then
Return Me.Power + BattleScreen.FieldEffects.OwnRageFistPower
Else
Return Me.Power + BattleScreen.FieldEffects.OppRageFistPower
End If
End Function
Public Overrides Sub HurtItselfInConfusion(ByVal own As Boolean, ByVal BattleScreen As BattleScreen)
If own = True Then
If BattleScreen.FieldEffects.OwnRageFistPower < 350 Then
BattleScreen.FieldEffects.OwnRageFistPower += 50
End If
Else
If BattleScreen.FieldEffects.OppRageFistPower < 350 Then
BattleScreen.FieldEffects.OppRageFistPower += 50
End If
End If
End Sub
End Class
End Namespace