Fix for Trick and Recycle
This commit is contained in:
parent
678cd35fde
commit
cdccbfcc67
|
@ -1250,14 +1250,15 @@ nextIndex:
|
|||
Core.Player.Inventory.AddItem(p.OriginalItem.ID, 1)
|
||||
SoundManager.PlaySound("item_found", True)
|
||||
Screen.TextBox.Show(Core.Player.Name & " found~" & p.OriginalItem.Name & "!*" & Core.Player.Inventory.GetMessageReceive(p.OriginalItem, 1))
|
||||
p.OriginalItem = Nothing
|
||||
Else
|
||||
p.Item = P3D.Item.GetItemByID(p.OriginalItem.ID)
|
||||
p.Item.AdditionalData = p.OriginalItem.AdditionalData
|
||||
Screen.TextBox.Show(Core.Player.Name & " found~" & p.OriginalItem.Name & "*and gave it back to~" & p.GetDisplayName)
|
||||
End If
|
||||
p.OriginalItem = Nothing
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
p.ResetTemp()
|
||||
Next
|
||||
|
||||
|
@ -1310,15 +1311,16 @@ nextIndex:
|
|||
If p.Item IsNot Nothing Then
|
||||
Core.Player.Inventory.AddItem(p.OriginalItem.ID, 1)
|
||||
SoundManager.PlaySound("item_found", True)
|
||||
Screen.TextBox.Show(Core.Player.Name & " found~" & p.originalItem.Name & "!*" & Core.Player.Inventory.GetMessageReceive(p.originalItem, 1))
|
||||
Screen.TextBox.Show(Core.Player.Name & " found~" & p.OriginalItem.Name & "!*" & Core.Player.Inventory.GetMessageReceive(p.OriginalItem, 1))
|
||||
p.OriginalItem = Nothing
|
||||
Else
|
||||
p.Item = P3D.Item.GetItemByID(p.OriginalItem.ID)
|
||||
p.Item.AdditionalData = p.OriginalItem.AdditionalData
|
||||
Screen.TextBox.Show(Core.Player.Name & " found~" & p.OriginalItem.Name & "*and gave it back to~" & p.GetDisplayName)
|
||||
End If
|
||||
p.OriginalItem = Nothing
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
p.ResetTemp()
|
||||
Next
|
||||
ResetVars()
|
||||
|
|
|
@ -58,9 +58,11 @@
|
|||
Public Overrides Sub MoveHits(own As Boolean, BattleScreen As BattleScreen)
|
||||
If own = True Then
|
||||
Dim p As Pokemon = BattleScreen.OwnPokemon
|
||||
|
||||
If Not BattleScreen.FieldEffects.OwnConsumedItem Is Nothing Then
|
||||
p.Item = BattleScreen.FieldEffects.OwnConsumedItem
|
||||
If p.OriginalItem IsNot Nothing Then
|
||||
p.OriginalItem = Nothing
|
||||
End If
|
||||
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " found one " & p.Item.Name & "!"))
|
||||
Else
|
||||
BattleScreen.BattleQuery.Add(New TextQueryObject("Recycle failed!"))
|
||||
|
@ -70,6 +72,9 @@
|
|||
|
||||
If Not BattleScreen.FieldEffects.OppConsumedItem Is Nothing Then
|
||||
p.Item = BattleScreen.FieldEffects.OppConsumedItem
|
||||
If p.OriginalItem IsNot Nothing Then
|
||||
p.OriginalItem = Nothing
|
||||
End If
|
||||
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " found one " & p.Item.Name & "!"))
|
||||
Else
|
||||
BattleScreen.BattleQuery.Add(New TextQueryObject("Recycle failed!"))
|
||||
|
|
|
@ -107,10 +107,14 @@ Namespace BattleSystem.Moves.Psychic
|
|||
Dim i1 As Item = Nothing
|
||||
Dim i2 As Item = Nothing
|
||||
If own = True Then
|
||||
If p.Item IsNot Nothing Then
|
||||
p.OriginalItem = p.Item
|
||||
End If
|
||||
Else
|
||||
If op.Item IsNot Nothing Then
|
||||
op.OriginalItem = op.Item
|
||||
End If
|
||||
End If
|
||||
If p.Item IsNot Nothing Then
|
||||
i1 = p.Item
|
||||
End If
|
||||
|
|
Loading…
Reference in New Issue