diff --git a/P3D/Network/Profiles/GamejoltSave.vb b/P3D/Network/Profiles/GamejoltSave.vb index 2480cff09..de0748b60 100644 --- a/P3D/Network/Profiles/GamejoltSave.vb +++ b/P3D/Network/Profiles/GamejoltSave.vb @@ -613,7 +613,7 @@ Namespace GameJolt Dim data As String = result.Remove(0, 22) data = data.Remove(data.LastIndexOf("""")) - _berries = data.Replace("\""", """") + _berries = data.Replace("\""", """").Replace("}{", "}" & Environment.NewLine & "{") Else _berries = GetBerryData() End If @@ -947,8 +947,11 @@ Namespace GameJolt If File.Exists(GameModeManager.GetContentFilePath("Data\BerryData.dat")) Then Dim Berries() As String = System.IO.File.ReadAllLines(GameModeManager.GetContentFilePath("Data\BerryData.dat")) - For Each line In Berries - s &= line + For i = 0 To Berries.Count - 1 + s &= Berries(i) + If i < Berries.Count - 1 Then + s &= Environment.NewLine + End If Next Else s = "{route29.dat|13,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine & diff --git a/P3D/Screens/MainMenu/NewNewGameScreen.vb b/P3D/Screens/MainMenu/NewNewGameScreen.vb index 03d7ee8f5..5893bcc81 100644 --- a/P3D/Screens/MainMenu/NewNewGameScreen.vb +++ b/P3D/Screens/MainMenu/NewNewGameScreen.vb @@ -170,6 +170,7 @@ Core.Player.startRiding = False Core.Player.startRotation = CSng(MathHelper.Pi * (rot / 2)) + Core.Player.PokedexData = Pokedex.NewPokedex() Core.Player.BerryData = CreateBerryData() Core.Player.AddVisitedMap(map) Core.Player.SaveCreated = GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION @@ -193,8 +194,11 @@ If File.Exists(GameModeManager.GetContentFilePath("Data\BerryData.dat")) Then Dim Berries() As String = System.IO.File.ReadAllLines(GameModeManager.GetContentFilePath("Data\BerryData.dat")) - For Each line In Berries - s &= line + For i = 0 To Berries.Count - 1 + s &= Berries(i) + If i < Berries.Count - 1 Then + s &= Environment.NewLine + End If Next Else s = "{route29.dat|13,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine & diff --git a/P3D/Screens/NewGameScreen.vb b/P3D/Screens/NewGameScreen.vb index 56b86e832..bef061c30 100644 --- a/P3D/Screens/NewGameScreen.vb +++ b/P3D/Screens/NewGameScreen.vb @@ -446,8 +446,11 @@ If File.Exists(GameModeManager.GetContentFilePath("Data\BerryData.dat")) Then Dim Berries() As String = System.IO.File.ReadAllLines(GameModeManager.GetContentFilePath("Data\BerryData.dat")) - For Each line In Berries - s &= line + For i = 0 To Berries.Count - 1 + s &= Berries(i) + If i < Berries.Count - 1 Then + s &= Environment.NewLine + End If Next Else s = "{route29.dat|13,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &