diff --git a/P3D/Battle/BattleSystemV2/Battle.vb b/P3D/Battle/BattleSystemV2/Battle.vb index dad5bf0ee..692a0c467 100644 --- a/P3D/Battle/BattleSystemV2/Battle.vb +++ b/P3D/Battle/BattleSystemV2/Battle.vb @@ -569,7 +569,7 @@ BattleScreen.BattleQuery.Add(New PlaySoundQueryObject("Battle\Effects\MegaEvolution", False)) End If BattleScreen.BattleQuery.Add(New ToggleEntityQueryObject(own, ToggleEntityQueryObject.BattleEntities.OwnPokemon, PokemonForms.GetOverworldSpriteName(p), 0, 1, -1, -1)) - BattleScreen.BattleQuery.Add(New TextQueryObject(_base & " has Mega Evolved!")) + BattleScreen.BattleQuery.Add(New TextQueryObject(_base & " has Mega Evolved into " & p.GetName(True))) TriggerAbilityEffect(BattleScreen, own) End If End Sub @@ -5099,7 +5099,7 @@ 'Apply new image to sprite: BattleScreen.BattleQuery.Add(New ToggleEntityQueryObject(own, ToggleEntityQueryObject.BattleEntities.OwnPokemon, PokemonForms.GetOverworldSpriteName(p), 0, 1, -1, -1)) - BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " transformed into " & op.OriginalName & "!")) + BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " transformed into " & op.GetName & "!")) Else 'Fails BattleScreen.BattleQuery.Add(New TextQueryObject("imposter failed!")) diff --git a/P3D/Network/GameJolt/GTS/GTSInboxScreen.vb b/P3D/Network/GameJolt/GTS/GTSInboxScreen.vb index b4ed7e0da..80733f04f 100644 --- a/P3D/Network/GameJolt/GTS/GTSInboxScreen.vb +++ b/P3D/Network/GameJolt/GTS/GTSInboxScreen.vb @@ -254,9 +254,9 @@ 'Pokemon image/data: Core.SpriteBatch.Draw(D.Pokemon.GetTexture(True), New Rectangle(500, 164, MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> D.Pokemon.OriginalName Then + If D.Pokemon.GetDisplayName() <> D.Pokemon.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.OriginalName, New Vector2(640, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.GetName, New Vector2(640, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 205), Color.Black) End If diff --git a/P3D/Network/GameJolt/GTS/GTSSearchScreen.vb b/P3D/Network/GameJolt/GTS/GTSSearchScreen.vb index 7987a1603..d9161d611 100644 --- a/P3D/Network/GameJolt/GTS/GTSSearchScreen.vb +++ b/P3D/Network/GameJolt/GTS/GTSSearchScreen.vb @@ -157,9 +157,9 @@ 'Pokemon image/data: Core.SpriteBatch.Draw(D.Pokemon.GetTexture(True), New Rectangle(500, 164, MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> D.Pokemon.OriginalName Then + If D.Pokemon.GetDisplayName() <> D.Pokemon.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.OriginalName, New Vector2(640, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.GetName, New Vector2(640, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 205), Color.Black) End If @@ -183,9 +183,9 @@ Core.SpriteBatch.Draw(p.GetTexture(True), New Rectangle(800, 164, MathHelper.Min(CInt(p.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(p.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> p.OriginalName Then + If D.Pokemon.GetDisplayName() <> p.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & p.OriginalName, New Vector2(940, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & p.GetName, New Vector2(940, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 205), Color.Black) End If @@ -614,7 +614,7 @@ For Each file As String In d Dim fileName As String = System.IO.Path.GetFileNameWithoutExtension(file) If StringHelper.IsNumeric(fileName) = True Then - If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.POKEMONCOUNT Then + If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.PokemonMaxCount Then If GTSMainScreen.GTSPokemon.Contains(CInt(fileName)) = True Then fileList.Add(CInt(fileName)) End If @@ -627,7 +627,7 @@ If index <= fileList.Count - 1 Then Dim fileName As Integer = fileList(index) Dim p As Pokemon = Pokemon.GetPokemonByID(fileName) - CurrentPokemon.Add(p.Number, p.OriginalName) + CurrentPokemon.Add(p.Number, p.GetName) SpriteList.Add(p.GetMenuTexture()) index += 1 Else diff --git a/P3D/Network/GameJolt/GTS/GTSSetupScreen.vb b/P3D/Network/GameJolt/GTS/GTSSetupScreen.vb index c571616f0..43a22188a 100644 --- a/P3D/Network/GameJolt/GTS/GTSSetupScreen.vb +++ b/P3D/Network/GameJolt/GTS/GTSSetupScreen.vb @@ -88,9 +88,9 @@ 'Pokemon image/data: Core.SpriteBatch.Draw(D.Pokemon.GetTexture(True), New Rectangle(500, 164, MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> D.Pokemon.OriginalName Then + If D.Pokemon.GetDisplayName() <> D.Pokemon.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.OriginalName, New Vector2(640, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.GetName, New Vector2(640, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(630, 205), Color.Black) End If @@ -115,9 +115,9 @@ Core.SpriteBatch.Draw(p.GetTexture(True), New Rectangle(800, 164, MathHelper.Min(CInt(p.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(p.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> p.OriginalName Then + If D.Pokemon.GetDisplayName() <> p.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & p.OriginalName, New Vector2(940, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & p.GetName, New Vector2(940, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 205), Color.Black) End If @@ -439,9 +439,9 @@ If Not D.Pokemon Is Nothing Then Core.SpriteBatch.Draw(D.Pokemon.GetTexture(True), New Rectangle(50, 120, MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> D.Pokemon.OriginalName Then + If D.Pokemon.GetDisplayName() <> D.Pokemon.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(180, 146), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.OriginalName, New Vector2(190, 176), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.GetName, New Vector2(190, 176), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(180, 161), Color.Black) End If @@ -497,7 +497,7 @@ Dim p As Pokemon = TempPokemon Core.SpriteBatch.Draw(p.GetTexture(True), New Rectangle(800, 120, MathHelper.Min(CInt(p.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(p.GetTexture(True).Height * 2), 256)), Color.White) - Core.SpriteBatch.DrawString(FontManager.MainFont, p.OriginalName, New Vector2(180 + 750, 176), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetName, New Vector2(180 + 750, 176), Color.Black) 'Stars: GTSMainScreen.DrawStars(p.TradeValue, New Vector2(930, 222)) @@ -888,7 +888,7 @@ For Each file As String In d Dim fileName As String = System.IO.Path.GetFileNameWithoutExtension(file) If StringHelper.IsNumeric(fileName) = True Then - If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.POKEMONCOUNT Then + If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.PokemonMaxCount Then If GTSMainScreen.GTSPokemon.Contains(CInt(fileName)) = True Then fileList.Add(CInt(fileName)) End If @@ -901,7 +901,7 @@ If index <= fileList.Count - 1 Then Dim fileName As Integer = fileList(index) Dim p As Pokemon = Pokemon.GetPokemonByID(fileName) - CurrentPokemon.Add(p.Number, p.OriginalName) + CurrentPokemon.Add(p.Number, p.GetName) SpriteList.Add(p.GetMenuTexture()) index += 1 Else diff --git a/P3D/Network/GameJolt/GTS/GTSTradeScreen.vb b/P3D/Network/GameJolt/GTS/GTSTradeScreen.vb index 4c926ab74..88ca71d2e 100644 --- a/P3D/Network/GameJolt/GTS/GTSTradeScreen.vb +++ b/P3D/Network/GameJolt/GTS/GTSTradeScreen.vb @@ -132,9 +132,9 @@ 'Pokemon image/data: Core.SpriteBatch.Draw(P.GetTexture(True), New Rectangle(100 + OwnX, 164, MathHelper.Min(CInt(P.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(P.GetTexture(True).Height * 2), 256)), Color.White) - If P.GetDisplayName() <> P.OriginalName Then + If P.GetDisplayName() <> P.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, P.GetDisplayName(), New Vector2(230 + OwnX, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & P.OriginalName, New Vector2(240 + OwnX, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & P.GetName, New Vector2(240 + OwnX, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, P.GetDisplayName(), New Vector2(230 + OwnX, 205), Color.Black) End If @@ -189,9 +189,9 @@ 'Pokemon image/data: Core.SpriteBatch.Draw(D.Pokemon.GetTexture(True), New Rectangle(100 + OppX, 164, MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(D.Pokemon.GetTexture(True).Height * 2), 256)), Color.White) - If D.Pokemon.GetDisplayName() <> D.Pokemon.OriginalName Then + If D.Pokemon.GetDisplayName() <> D.Pokemon.GetName Then Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(230 + OppX, 190), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.OriginalName, New Vector2(240 + OppX, 220), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "/" & D.Pokemon.GetName, New Vector2(240 + OppX, 220), Color.Black) Else Core.SpriteBatch.DrawString(FontManager.MainFont, D.Pokemon.GetDisplayName(), New Vector2(230 + OppX, 205), Color.Black) End If diff --git a/P3D/Pokemon/Attacks/Normal/ReflectType.vb b/P3D/Pokemon/Attacks/Normal/ReflectType.vb index 4d6017b13..23b9a42c7 100644 --- a/P3D/Pokemon/Attacks/Normal/ReflectType.vb +++ b/P3D/Pokemon/Attacks/Normal/ReflectType.vb @@ -67,7 +67,7 @@ p.OriginalType2 = New Element(p.Type2.Type) p.Type1 = New Element(op.Type1.Type) p.Type2 = New Element(op.Type2.Type) - BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & "'s type changed to match " & op.OriginalName & "'s!")) + BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & "'s type changed to match " & op.GetDisplayName & "'s!")) End Sub End Class diff --git a/P3D/Pokemon/Attacks/Normal/Transform.vb b/P3D/Pokemon/Attacks/Normal/Transform.vb index 27de8723b..c7f755975 100644 --- a/P3D/Pokemon/Attacks/Normal/Transform.vb +++ b/P3D/Pokemon/Attacks/Normal/Transform.vb @@ -113,7 +113,7 @@ 'Apply new image to sprite: BattleScreen.BattleQuery.Add(New ToggleEntityQueryObject(own, ToggleEntityQueryObject.BattleEntities.OwnPokemon, PokemonForms.GetOverworldSpriteName(p), 0, 1, -1, -1)) - BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " transformed into " & op.OriginalName & "!")) + BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " transformed into " & op.GetName & "!")) Else 'Fails BattleScreen.BattleQuery.Add(New TextQueryObject(Me.Name & " failed!")) diff --git a/P3D/Pokemon/Items/KeyItems/GoodRod.vb b/P3D/Pokemon/Items/KeyItems/GoodRod.vb index f98c6f99c..64f4ccb41 100644 --- a/P3D/Pokemon/Items/KeyItems/GoodRod.vb +++ b/P3D/Pokemon/Items/KeyItems/GoodRod.vb @@ -67,7 +67,7 @@ Namespace Items.KeyItems "@Level.Update" & Environment.NewLine & "@pokemon.cry(" & PokemonID & ")" & Environment.NewLine & "@level.wait(50)" & Environment.NewLine & - "@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine & + "@text.show(The wild " & p.GetName & "~attacked!)" & Environment.NewLine & "@npc.remove(1337)" & Environment.NewLine & "@battle.setvar(divebattle,true)" & Environment.NewLine & "@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine & diff --git a/P3D/Pokemon/Items/KeyItems/OldRod.vb b/P3D/Pokemon/Items/KeyItems/OldRod.vb index 1b42a3f0e..99ed57162 100644 --- a/P3D/Pokemon/Items/KeyItems/OldRod.vb +++ b/P3D/Pokemon/Items/KeyItems/OldRod.vb @@ -67,7 +67,7 @@ Namespace Items.KeyItems "@Level.Update" & Environment.NewLine & "@pokemon.cry(" & PokemonID & ")" & Environment.NewLine & "@level.wait(50)" & Environment.NewLine & - "@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine & + "@text.show(The wild " & p.GetName & "~attacked!)" & Environment.NewLine & "@npc.remove(1337)" & Environment.NewLine & "@battle.setvar(divebattle,true)" & Environment.NewLine & "@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine & diff --git a/P3D/Pokemon/Items/KeyItems/SuperRod.vb b/P3D/Pokemon/Items/KeyItems/SuperRod.vb index a8b899057..e45767b4f 100644 --- a/P3D/Pokemon/Items/KeyItems/SuperRod.vb +++ b/P3D/Pokemon/Items/KeyItems/SuperRod.vb @@ -67,7 +67,7 @@ Namespace Items.KeyItems "@Level.Update" & Environment.NewLine & "@pokemon.cry(" & PokemonID & ")" & Environment.NewLine & "@level.wait(50)" & Environment.NewLine & - "@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine & + "@text.show(The wild " & p.GetName & "~attacked!)" & Environment.NewLine & "@npc.remove(1337)" & Environment.NewLine & "@battle.setvar(divebattle,true)" & Environment.NewLine & "@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine & diff --git a/P3D/Pokemon/Monster/Pokemon.vb b/P3D/Pokemon/Monster/Pokemon.vb index 6214d097d..24f62c467 100644 --- a/P3D/Pokemon/Monster/Pokemon.vb +++ b/P3D/Pokemon/Monster/Pokemon.vb @@ -2296,12 +2296,12 @@ Public Class Pokemon ''' Returns the Display Name of this Pokémon. ''' ''' Returns "Egg" when the Pokémon is in an egg. Returns the properly translated name if it exists. Returns the nickname if set. - Public Function GetDisplayName() As String + Public Function GetDisplayName(Optional ByVal GetFormName As Boolean = False) As String If Me.EggSteps > 0 Then Return "Egg" Else If Me.NickName = "" Then - If PokemonForms.GetFormName(Me) <> "" Then + If GetFormName = True AndAlso PokemonForms.GetFormName(Me) <> "" Then Dim FormName As String = PokemonForms.GetFormName(Me) If Localization.TokenExists("pokemon_name_" & FormName) = True Then Return Localization.GetString("pokemon_name_" & FormName) @@ -2324,8 +2324,8 @@ Public Class Pokemon ''' ''' Returns the properly translated name of a Pokémon if defined in the language files. ''' - Public Function GetName() As String - If PokemonForms.GetFormName(Me) <> "" Then + Public Function GetName(Optional ByVal GetFormName As Boolean = False) As String + If GetFormName = True AndAlso PokemonForms.GetFormName(Me) <> "" Then Dim FormName As String = PokemonForms.GetFormName(Me) If Localization.TokenExists("pokemon_name_" & FormName) = True Then Return Localization.GetString("pokemon_name_" & FormName) diff --git a/P3D/Screens/Inventory/PokegearScreen.vb b/P3D/Screens/Inventory/PokegearScreen.vb index 384621abe..33192dfca 100644 --- a/P3D/Screens/Inventory/PokegearScreen.vb +++ b/P3D/Screens/Inventory/PokegearScreen.vb @@ -1768,8 +1768,8 @@ Dim chosenID As Integer = -1 Dim chosenAD As String = "" - While chosenID = -1 And triedIDs.Count < Pokedex.PokemonCount - Dim ID As Integer = Core.Random.Next(1, Pokedex.PokemonCount + 1) + While chosenID = -1 And triedIDs.Count < Pokedex.PokemonMaxCount + Dim ID As Integer = Core.Random.Next(1, Pokedex.PokemonMaxCount + 1) If triedIDs.Contains(ID) = False Then If Pokedex.GetEntryType(Core.Player.PokedexData, Pokedex.PokemonIDs(ID)) < 2 Then triedIDs.Add(ID) diff --git a/P3D/Screens/PC/StorageSystemScreen.vb b/P3D/Screens/PC/StorageSystemScreen.vb index 28011a61f..0a06dee0a 100644 --- a/P3D/Screens/PC/StorageSystemScreen.vb +++ b/P3D/Screens/PC/StorageSystemScreen.vb @@ -1347,7 +1347,7 @@ Public Class StorageSystemScreen itemString = p.Item.Name End If - Dim nameString As String = p.GetDisplayName() & "/" & p.OriginalName + Dim nameString As String = p.GetDisplayName() & "/" & p.GetName If p.NickName = "" Then nameString = p.GetDisplayName() End If diff --git a/P3D/Screens/Pokedex/PokedexScreen.vb b/P3D/Screens/Pokedex/PokedexScreen.vb index ca306ada0..35c92b067 100644 --- a/P3D/Screens/Pokedex/PokedexScreen.vb +++ b/P3D/Screens/Pokedex/PokedexScreen.vb @@ -455,7 +455,7 @@ Public Class PokedexScreen For Each F As Filter In Me.Filters Select Case F.FilterType Case FilterType.Name - If p.GetName().ToUpper().StartsWith(F.FilterValue.ToUpper()) = False Then + If p.GetName(True).ToUpper().StartsWith(F.FilterValue.ToUpper()) = False Then valid = False Exit For End If @@ -502,9 +502,9 @@ Public Class PokedexScreen End If Case OrderType.Alphabetically If Me.ReverseOrder = True Then - Me.PokemonList = (From p As Pokemon In Me.PokemonList Order By p.GetName() Descending).ToList() + Me.PokemonList = (From p As Pokemon In Me.PokemonList Order By p.GetName(True) Descending).ToList() Else - Me.PokemonList = (From p As Pokemon In Me.PokemonList Order By p.GetName() Ascending).ToList() + Me.PokemonList = (From p As Pokemon In Me.PokemonList Order By p.GetName(True) Ascending).ToList() End If Case OrderType.Weigth If Me.ReverseOrder = True Then @@ -698,7 +698,7 @@ Public Class PokedexScreen If entryType = 0 Then Core.SpriteBatch.DrawString(FontManager.MainFont, "???" & Environment.NewLine & Environment.NewLine & "No. " & no, New Vector2(864, 200), Color.White) Else - Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetName() & Environment.NewLine & Environment.NewLine & "No. " & no, New Vector2(864, 200), Color.White) + Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetName(True) & Environment.NewLine & Environment.NewLine & "No. " & no, New Vector2(864, 200), Color.White) Core.SpriteBatch.Draw(p.GetTexture(True), New Rectangle(CInt(680 - p.GetTexture(True).Width / 4), CInt(140 - p.GetTexture(True).Height / 4), MathHelper.Min(CInt(p.GetTexture(True).Width * 2), 256), MathHelper.Min(CInt(p.GetTexture(True).Height * 2), 256)), Color.White) Core.SpriteBatch.DrawString(FontManager.MainFont, "SPECIES", New Vector2(680, 310), Color.Black) @@ -1366,6 +1366,7 @@ Public Class PokedexViewScreen End Sub Private Sub LoadPokemonData(ByVal newDexIndex As Integer, Optional ByVal newPokemon As Pokemon = Nothing, Optional playCry As Boolean = False) + Dim oldCry As String = PokemonForms.GetCrySuffix(Me.Pokemon) If newPokemon IsNot Nothing Then EvolutionLineConnections.Clear() Me.Pokemon = newPokemon @@ -1395,7 +1396,7 @@ Public Class PokedexViewScreen Me.FillHabitats() Me.FillEvolutionGrid() - If playCry = True Then + If playCry = True AndAlso oldCry <> PokemonForms.GetCrySuffix(Me.Pokemon) Then Dim crySuffix As String = PokemonForms.GetCrySuffix(Me.Pokemon) SoundManager.PlayPokemonCry(Pokemon.Number, crySuffix) End If @@ -1620,7 +1621,7 @@ Public Class PokedexViewScreen Dim pokeTexture = Pokemon.GetMenuTexture() Dim pokeTextureScale As Vector2 = New Vector2(CSng(32 / pokeTexture.Width * 2), CSng(32 / pokeTexture.Height * 2)) Core.SpriteBatch.Draw(pokeTexture, New Rectangle(28, 20, CInt(pokeTexture.Width * pokeTextureScale.X), CInt(pokeTexture.Height * pokeTextureScale.Y)), Color.White) - Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.GetName(), New Vector2(100, 36), Color.Black, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F) + Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.GetName(True), New Vector2(100, 36), Color.Black, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F) If EntryType = 1 Then Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokedexhabitat", New Rectangle(160, 170, 10, 10), ""), New Rectangle(64 * 6 + 40, 42, 20, 20), Color.White) @@ -1637,6 +1638,10 @@ Public Class PokedexViewScreen End If End If + If Me.Forms.Count > 1 Then + Core.SpriteBatch.DrawString(FontManager.MainFont, "Press [Shift] to switch forms", New Vector2(960, 36), Color.Black, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F) + End If + Select Case Me.Page Case 0 Core.SpriteBatch.DrawString(FontManager.MainFont, "Details", New Vector2(480, 36), Color.Black, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F) @@ -1673,9 +1678,9 @@ Public Class PokedexViewScreen If mLineLength = 100 Then If EntryType > 1 Then - Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Height & " m", New Vector2(mV.X + 250, mV.Y - 152), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Weight & " kg", New Vector2(mV.X + 250, mV.Y + 128), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Species, New Vector2(mV.X - 248 - FontManager.MainFont.MeasureString(Pokemon.PokedexEntry.Species).X, mV.Y - 152), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Height & " m", New Vector2(CInt(mV.X + 250), CInt(mV.Y - 152)), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Weight & " kg", New Vector2(CInt(mV.X + 250), CInt(mV.Y + 128)), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Species, New Vector2(CInt(mV.X - 248 - FontManager.MainFont.MeasureString(Pokemon.PokedexEntry.Species).X), CInt(mV.Y - 152)), Color.Black) If Pokemon.Type2.Type <> Element.Types.Blank Then Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\Types"), New Rectangle(CInt(mV.X - 450), CInt(mV.Y + 123), 96, 32), Pokemon.Type1.GetElementImage(), Color.White) Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\Types"), New Rectangle(CInt(mV.X - 350), CInt(mV.Y + 123), 96, 32), Pokemon.Type2.GetElementImage(), Color.White) @@ -1687,10 +1692,10 @@ Public Class PokedexViewScreen Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.PokedexEntry.Text.CropStringToWidth(FontManager.MainFont, 720), New Vector2(CInt(mV.X - FontManager.MainFont.MeasureString(Pokemon.PokedexEntry.Text.CropStringToWidth(FontManager.MainFont, 720)).X / 2), CInt(mV.Y + 192)), Color.Black) Else - Core.SpriteBatch.DrawString(FontManager.MainFont, "??? m", New Vector2(mV.X + 250, mV.Y - 152), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "??? kg", New Vector2(mV.X + 250, mV.Y + 128), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "??? Pokémon", New Vector2(mV.X - 248 - FontManager.MainFont.MeasureString("??? Pokémon").X, mV.Y - 152), Color.Black) - Core.SpriteBatch.DrawString(FontManager.MainFont, "???", New Vector2(mV.X - 248 - FontManager.MainFont.MeasureString("???").X, mV.Y + 128), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "??? m", New Vector2(CInt(mV.X + 250), CInt(mV.Y - 152)), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "??? kg", New Vector2(CInt(mV.X + 250), CInt(mV.Y + 128)), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "??? Pokémon", New Vector2(CInt(mV.X - 248 - FontManager.MainFont.MeasureString("??? Pokémon").X), CInt(mV.Y - 152)), Color.Black) + Core.SpriteBatch.DrawString(FontManager.MainFont, "???", New Vector2(CInt(mV.X - 248 - FontManager.MainFont.MeasureString("???").X), CInt(mV.Y + 128)), Color.Black) End If End If End If @@ -1750,7 +1755,7 @@ Public Class PokedexViewScreen Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2) - 202, CInt(Core.windowSize.Height / 2 - 45), 404, 90), New Color(42, 167, 198, 150)) Canvas.DrawGradient(New Rectangle(CInt(Core.windowSize.Width / 2) + 202, CInt(Core.windowSize.Height / 2 - 45), 80, 90), New Color(42, 167, 198, 150), New Color(84, 198, 216), True, -1) - Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.GetName() & " doesn't evolve.", New Vector2(CInt(Core.windowSize.Width / 2) - CInt(FontManager.MainFont.MeasureString(Pokemon.GetName() & " doesn't evolve.").X / 2), CInt(Core.windowSize.Height / 2 - 15)), Color.White) + Core.SpriteBatch.DrawString(FontManager.MainFont, Pokemon.GetName(True) & " doesn't evolve.", New Vector2(CInt(Core.windowSize.Width / 2) - CInt(FontManager.MainFont.MeasureString(Pokemon.GetName(True) & " doesn't evolve.").X / 2), CInt(Core.windowSize.Height / 2 - 15)), Color.White) Else Dim connectionLines As New List(Of String) Dim centerVector As Vector2 = Core.GetMiddlePosition(New Size(CInt(64 * scale), CInt(64 * scale))) @@ -1817,8 +1822,8 @@ Public Class PokedexViewScreen Dim pokeTextureScale As Vector2 = New Vector2(CSng(32 / pokeTexture.Width * 2), CSng(32 / pokeTexture.Height * 2)) If Pokedex.GetEntryType(Core.Player.PokedexData, dexID) <> 0 Then - Core.SpriteBatch.DrawString(FontManager.MainFont, pokemon.GetName(), New Vector2(CInt(centerVector.X + (position.X * (64 * scale)) + CInt(pokeTexture.Width * pokeTextureScale.X / 2 * scale) - (FontManager.MainFont.MeasureString(pokemon.GetName()).X / 2 * CSng(scale / 2)) + 2), CInt(centerVector.Y + position.Y * (48 * scale) + (64 * scale)) + 2), Color.Black, 0.0F, Vector2.Zero, CInt(scale / 2), SpriteEffects.None, 0.0F) - Core.SpriteBatch.DrawString(FontManager.MainFont, pokemon.GetName(), New Vector2(CInt(centerVector.X + (position.X * (64 * scale)) + CInt(pokeTexture.Width * pokeTextureScale.X / 2 * scale) - (FontManager.MainFont.MeasureString(pokemon.GetName()).X / 2 * CSng(scale / 2))), CInt(centerVector.Y + position.Y * (48 * scale) + (64 * scale))), Color.White, 0.0F, Vector2.Zero, CInt(scale / 2), SpriteEffects.None, 0.0F) + Core.SpriteBatch.DrawString(FontManager.MainFont, pokemon.GetName(True), New Vector2(CInt(centerVector.X + (position.X * (64 * scale)) + CInt(pokeTexture.Width * pokeTextureScale.X / 2 * scale) - (FontManager.MainFont.MeasureString(pokemon.GetName(True)).X / 2 * CSng(scale / 2)) + 2), CInt(centerVector.Y + position.Y * (48 * scale) + (64 * scale)) + 2), Color.Black, 0.0F, Vector2.Zero, CInt(scale / 2), SpriteEffects.None, 0.0F) + Core.SpriteBatch.DrawString(FontManager.MainFont, pokemon.GetName(True), New Vector2(CInt(centerVector.X + (position.X * (64 * scale)) + CInt(pokeTexture.Width * pokeTextureScale.X / 2 * scale) - (FontManager.MainFont.MeasureString(pokemon.GetName(True)).X / 2 * CSng(scale / 2))), CInt(centerVector.Y + position.Y * (48 * scale) + (64 * scale))), Color.White, 0.0F, Vector2.Zero, CInt(scale / 2), SpriteEffects.None, 0.0F) End If End If Next diff --git a/P3D/World/ActionScript/Script.vb b/P3D/World/ActionScript/Script.vb index 348389ec3..c7590afb6 100644 --- a/P3D/World/ActionScript/Script.vb +++ b/P3D/World/ActionScript/Script.vb @@ -319,7 +319,7 @@ Core.Player.AddPoints(10, "Traded with NPC.") SoundManager.PlaySound("success_small") - Screen.TextBox.Show(message1 & "*" & Core.Player.Name & " traded~" & oppPokemon.OriginalName & " for~" & ownPokemon.OriginalName & "!", {}, False, False) + Screen.TextBox.Show(message1 & "*" & Core.Player.Name & " traded~" & oppPokemon.GetName & " for~" & ownPokemon.GetName & "!", {}, False, False) Else Screen.TextBox.Show(message2, {}, False, False) End If