Changed repel items.
This commit is contained in:
parent
9289cd143a
commit
00cedf786e
|
@ -1389,6 +1389,7 @@
|
|||
<Compile Include="Pokemon\Items\Plates\ZapPlate.vb" />
|
||||
<Compile Include="Pokemon\Items\Repels\MaxRepel.vb" />
|
||||
<Compile Include="Pokemon\Items\Repels\Repel.vb" />
|
||||
<Compile Include="Pokemon\Items\Repels\RepelItem.vb" />
|
||||
<Compile Include="Pokemon\Items\Repels\SuperRepel.vb" />
|
||||
<Compile Include="Pokemon\Items\Standard\AbilityCapsule.vb" />
|
||||
<Compile Include="Pokemon\Items\Standard\AmuletCoin.vb" />
|
||||
|
|
|
@ -3,29 +3,14 @@ Namespace Items.Repels
|
|||
<Item(43, "Max Repel")>
|
||||
Public Class MaxRepel
|
||||
|
||||
Inherits Item
|
||||
Inherits RepelItem
|
||||
|
||||
Public Overrides ReadOnly Property Description As String = "An item that prevents any low-level wild Pokémon from jumping out at you for 250 steps after its use."
|
||||
Public Overrides ReadOnly Property PokeDollarPrice As Integer = 700
|
||||
Public Overrides ReadOnly Property RepelSteps As Integer = 250
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New("Max Repel", 700, ItemTypes.Standard, 43, 1, 0, New Rectangle(456, 24, 24, 24), "An item that prevents any low-level wild Pokémon from jumping out at you for 250 steps after its use.")
|
||||
|
||||
Me._canBeHold = True
|
||||
Me._canBeTraded = True
|
||||
Me._canBeUsed = True
|
||||
Me._canBeUsedInBattle = False
|
||||
End Sub
|
||||
|
||||
Public Overrides Sub Use()
|
||||
If Core.Player.RepelSteps <= 0 Then
|
||||
Core.Player.Inventory.RemoveItem(Me.ID, 1)
|
||||
Player.Temp.LastUsedRepel = Me.ID
|
||||
|
||||
SoundManager.PlaySound("repel_use", False)
|
||||
Screen.TextBox.Show(Core.Player.Name & " used a~" & Me.Name, {}, True, True)
|
||||
Core.Player.RepelSteps = 250
|
||||
PlayerStatistics.Track("[42]Repels used", 1)
|
||||
Else
|
||||
Screen.TextBox.Show("The Repel is still~in effect.", {}, True, True)
|
||||
End If
|
||||
_textureRectangle = New Rectangle(456, 24, 24, 24)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
|
|
@ -3,29 +3,14 @@ Namespace Items.Repels
|
|||
<Item(20, "Repel")>
|
||||
Public Class Repel
|
||||
|
||||
Inherits Item
|
||||
Inherits RepelItem
|
||||
|
||||
Public Overrides ReadOnly Property Description As String = "An item that prevents any low-level wild Pokémon from jumping out at you for 100 steps after its use."
|
||||
Public Overrides ReadOnly Property PokeDollarPrice As Integer = 350
|
||||
Public Overrides ReadOnly Property RepelSteps As Integer = 100
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New("Repel", 350, ItemTypes.Standard, 20, 1, 0, New Rectangle(432, 0, 24, 24), "An item that prevents any low-level wild Pokémon from jumping out at you for 100 steps after its use.")
|
||||
|
||||
Me._canBeHold = True
|
||||
Me._canBeTraded = True
|
||||
Me._canBeUsed = True
|
||||
Me._canBeUsedInBattle = False
|
||||
End Sub
|
||||
|
||||
Public Overrides Sub Use()
|
||||
If Core.Player.RepelSteps <= 0 Then
|
||||
Core.Player.Inventory.RemoveItem(Me.ID, 1)
|
||||
Player.Temp.LastUsedRepel = Me.ID
|
||||
|
||||
SoundManager.PlaySound("repel_use", False)
|
||||
Screen.TextBox.Show(Core.Player.Name & " used a~" & Me.Name, {}, True, True)
|
||||
Core.Player.RepelSteps = 100
|
||||
PlayerStatistics.Track("[42]Repels used", 1)
|
||||
Else
|
||||
Screen.TextBox.Show("The Repel is still~in effect.", {}, True, True)
|
||||
End If
|
||||
_textureRectangle = New Rectangle(432, 0, 24, 24)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
Namespace Items.Repels
|
||||
|
||||
Public MustInherit Class RepelItem
|
||||
|
||||
Inherits Item
|
||||
|
||||
Public Overrides ReadOnly Property CanBeUsedInBattle As Boolean = False
|
||||
|
||||
Public MustOverride ReadOnly Property RepelSteps As Integer
|
||||
|
||||
Public Overrides Sub Use()
|
||||
If Core.Player.RepelSteps <= 0 Then
|
||||
Core.Player.Inventory.RemoveItem(ID, 1)
|
||||
Player.Temp.LastUsedRepel = ID
|
||||
|
||||
SoundManager.PlaySound("repel_use", False)
|
||||
Screen.TextBox.Show(Core.Player.Name & " used a~" & Name, {}, True, True)
|
||||
Core.Player.RepelSteps = RepelSteps
|
||||
PlayerStatistics.Track("[42]Repels used", 1)
|
||||
Else
|
||||
Screen.TextBox.Show("The Repel is still~in effect.", {}, True, True)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
End Namespace
|
|
@ -3,29 +3,14 @@ Namespace Items.Repels
|
|||
<Item(42, "Super Repel")>
|
||||
Public Class SuperRepel
|
||||
|
||||
Inherits Item
|
||||
Inherits RepelItem
|
||||
|
||||
Public Overrides ReadOnly Property Description As String = "An item that prevents any low-level wild Pokémon from jumping out at you for 200 steps after its use."
|
||||
Public Overrides ReadOnly Property PokeDollarPrice As Integer = 500
|
||||
Public Overrides ReadOnly Property RepelSteps As Integer = 200
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New("Super Repel", 500, ItemTypes.Standard, 42, 1, 0, New Rectangle(432, 24, 24, 24), "An item that prevents any low-level wild Pokémon from jumping out at you for 200 steps after its use.")
|
||||
|
||||
Me._canBeHold = True
|
||||
Me._canBeTraded = True
|
||||
Me._canBeUsed = True
|
||||
Me._canBeUsedInBattle = False
|
||||
End Sub
|
||||
|
||||
Public Overrides Sub Use()
|
||||
If Core.Player.RepelSteps <= 0 Then
|
||||
Core.Player.Inventory.RemoveItem(Me.ID, 1)
|
||||
Player.Temp.LastUsedRepel = Me.ID
|
||||
|
||||
SoundManager.PlaySound("repel_use", False)
|
||||
Screen.TextBox.Show(Core.Player.Name & " used a~" & Me.Name, {}, True, True)
|
||||
Core.Player.RepelSteps = 200
|
||||
PlayerStatistics.Track("[42]Repels used", 1)
|
||||
Else
|
||||
Screen.TextBox.Show("The Repel is still~in effect.", {}, True, True)
|
||||
End If
|
||||
_textureRectangle = New Rectangle(432, 24, 24, 24)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
|
Loading…
Reference in New Issue