Replace all functions from Microsoft.VisualBasic

This commit is contained in:
nilllzz 2018-01-07 18:01:32 +01:00
parent 483284e3c6
commit a353d53236
115 changed files with 1159 additions and 1091 deletions

View File

@ -41,14 +41,36 @@
<DebugType>none</DebugType>
<UseVSHostingProcess>false</UseVSHostingProcess>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
<NoWarn>
</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'Release'">
<NoWarn>
</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'ReleaseNoContent'">
<NoWarn>
</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'DebugNoContent'">
<NoWarn>
</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<Import Include="System.Text" />
<Reference Include="System" />
<Reference Include="System.Drawing" />
<Reference Include="System.Management" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Import Include="Microsoft.VisualBasic" />
<Import Include="System.Collections.Generic" />
<Import Include="System.Diagnostics" />
<Import Include="System.Linq" />
@ -11111,6 +11133,7 @@
<Compile Include="HelperClasses\Localization.vb" />
<Compile Include="HelperClasses\PlayerStatistics.vb" />
<Compile Include="HelperClasses\Size.vb" />
<Compile Include="HelperClasses\StringHelper.vb" />
<Compile Include="HelperClasses\TimeHelpers.vb" />
<Compile Include="Input\ControllerHandler.vb" />
<Compile Include="Input\Controls.vb" />

View File

@ -1284,7 +1284,7 @@
If p.Status = Pokemon.StatusProblems.Paralyzed Then
If Core.Random.Next(0, 4) = 0 Then
BattleScreen.BattleQuery.Add(New PlaySoundQueryObject("Battle\Effects\effect_thundershock2", False))
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is fully paralyzed!" & vbNewLine & "It cannot move!"))
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is fully paralyzed!" & Environment.NewLine & "It cannot move!"))
Exit Sub
End If
End If
@ -2600,12 +2600,12 @@
BattleScreen.BattleQuery.Add(New PlaySoundQueryObject("Battle\Effects\effect_thundershock2", False))
Select Case message
Case "" 'Print default message only
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is paralyzed!" & vbNewLine & "It can't move!"))
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is paralyzed!" & Environment.NewLine & "It can't move!"))
Case "-1" 'Print no message at all
'Do nothing
Case Else 'Print message given in 'message'
BattleScreen.BattleQuery.Add(New TextQueryObject(message))
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is paralyzed!" & vbNewLine & "It can't move!"))
BattleScreen.BattleQuery.Add(New TextQueryObject(p.GetDisplayName() & " is paralyzed!" & Environment.NewLine & "It can't move!"))
End Select
If p.Ability.Name.ToLower() = "synchronize" AndAlso from <> own Then
Me.InflictParalysis(Not own, Not own, BattleScreen, "Synchronize passed over the paralysis.", "synchronize")
@ -3000,7 +3000,7 @@
If p.Ability.Name.ToLower() = "contrary" And BattleScreen.FieldEffects.CanUseAbility(own, BattleScreen) = True Then
If cause <> "contrary" Then
Return LowerStat(own, own, BattleScreen, Stat, val, message & vbNewLine & "Contrary reverted the stat change!", "contrary")
Return LowerStat(own, own, BattleScreen, Stat, val, message & Environment.NewLine & "Contrary reverted the stat change!", "contrary")
End If
End If
@ -3217,7 +3217,7 @@
If p.Ability.Name.ToLower() = "contrary" And BattleScreen.FieldEffects.CanUseAbility(own, BattleScreen) = True Then
If cause <> "contrary" Then
Return RaiseStat(own, own, BattleScreen, Stat, val, message & vbNewLine & "Contrary reverted the stat change!", "contrary")
Return RaiseStat(own, own, BattleScreen, Stat, val, message & Environment.NewLine & "Contrary reverted the stat change!", "contrary")
End If
End If
@ -4496,22 +4496,22 @@
Dim usedMentalHerb As Boolean = False
If .OwnPokemon.HasVolatileStatus(Pokemon.VolatileStatus.Infatuation) = True Then
.OwnPokemon.RemoveVolatileStatus(Pokemon.VolatileStatus.Infatuation)
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the infatuation" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the infatuation" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OwnTaunt > 0 Then
.FieldEffects.OwnTaunt = 0
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the taunt" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the taunt" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OwnEncore > 0 Then
.FieldEffects.OwnEncore = 0
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the encore" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the encore" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OwnTorment > 0 Then
.FieldEffects.OwnTorment = 0
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the torment" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OwnPokemon.GetDisplayName() & " got healed from the torment" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
'Remove disable
@ -5230,22 +5230,22 @@
Dim usedMentalHerb As Boolean = False
If .OppPokemon.HasVolatileStatus(Pokemon.VolatileStatus.Infatuation) = True Then
.OppPokemon.RemoveVolatileStatus(Pokemon.VolatileStatus.Infatuation)
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the infatuation" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the infatuation" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OppTaunt > 0 Then
.FieldEffects.OppTaunt = 0
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the taunt" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the taunt" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OppEncore > 0 Then
.FieldEffects.OppEncore = 0
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the encore" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the encore" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
If .FieldEffects.OppTorment > 0 Then
.FieldEffects.OppTorment = 0
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the torment" & vbNewLine & "due to Mental Herb!"))
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " got healed from the torment" & Environment.NewLine & "due to Mental Herb!"))
usedMentalHerb = True
End If
'Remove disable
@ -5286,7 +5286,7 @@
End If
End With
If hasNegativeStats = True Then
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " negative stats got healed" & vbNewLine & "due to White Herb!"))
.BattleQuery.Add(New TextQueryObject(.OppPokemon.GetDisplayName() & " negative stats got healed" & Environment.NewLine & "due to White Herb!"))
.OppPokemon.Item = Nothing
End If
End If

View File

@ -84,7 +84,7 @@
Public BattleMapOffset As New Vector3(0)
Public Overrides Function GetScreenStatus() As String
Dim pokemonString As String = "OwnPokemon=OWNEMPTY" & vbNewLine &
Dim pokemonString As String = "OwnPokemon=OWNEMPTY" & Environment.NewLine &
"OppPokemon=OPPEMPTY"
If Not Me.OwnPokemon Is Nothing Then
@ -98,14 +98,14 @@
"; CanReceiveEXP=" & CanReceiveEXP.ToString() & "; RoamingBattle=" & RoamingBattle.ToString() & "; CanUseItems=" & CanUseItems.ToString() &
"; DiveBattle=" & DiveBattle.ToString() & "; TempPokeFile=" & TempPokeFile & "; IsInverseBattle=" & IsInverseBattle.ToString()
Dim s As String = "BattleMode=" & Me.BattleMode.ToString() & vbNewLine &
"IsTrainerBattle=" & Me.IsTrainerBattle.ToString() & vbNewLine &
"IsPVPBattle=" & Me.IsPVPBattle.ToString() & vbNewLine &
"LoadedBattleMap=" & Level.LevelFile & vbNewLine &
pokemonString & vbNewLine &
values & vbNewLine &
"IsRemoteBattle=" & Me.IsRemoteBattle.ToString() & vbNewLine &
"IsHost=" & Me.IsHost.ToString() & vbNewLine &
Dim s As String = "BattleMode=" & Me.BattleMode.ToString() & Environment.NewLine &
"IsTrainerBattle=" & Me.IsTrainerBattle.ToString() & Environment.NewLine &
"IsPVPBattle=" & Me.IsPVPBattle.ToString() & Environment.NewLine &
"LoadedBattleMap=" & Level.LevelFile & Environment.NewLine &
pokemonString & Environment.NewLine &
values & Environment.NewLine &
"IsRemoteBattle=" & Me.IsRemoteBattle.ToString() & Environment.NewLine &
"IsHost=" & Me.IsHost.ToString() & Environment.NewLine &
"MenuVisible=" & BattleMenu.Visible.ToString()
Return s
@ -713,7 +713,7 @@
BattleScreen.CanRun = False
BattleScreen.CanUseItems = False
PVPLobbyScreen.StoppedBattle = True
PVPLobbyScreen.DisconnectMessage = "The battle has ended." & vbNewLine & vbNewLine & "Press any key to exit."
PVPLobbyScreen.DisconnectMessage = "The battle has ended." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
PVPLobbyScreen.ScreenState = PVPLobbyScreen.ScreenStates.Stopped
InitializeTrainer(PVPTrainer, OverworldScreen, 0)
Me.CanBePaused = False
@ -861,7 +861,7 @@ nextIndex:
BattleQuery.Add(FocusBattle())
BattleQuery.Insert(0, New ToggleMenuQueryObject(True))
If IsNumeric(lockArgument) = True Then
If StringHelper.IsNumeric(lockArgument) = True Then
SendClientCommand("MOVE|" & CStr(CInt(lockArgument)))
Else
SendClientCommand("TEXT|" & lockArgument)
@ -1296,7 +1296,7 @@ nextIndex:
Next
If partnerOnServer = False Then
PVPLobbyScreen.StoppedBattle = True
PVPLobbyScreen.DisconnectMessage = "The other player disconnected." & vbNewLine & vbNewLine & "Press any key to exit."
PVPLobbyScreen.DisconnectMessage = "The other player disconnected." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
PVPLobbyScreen.ScreenState = PVPLobbyScreen.ScreenStates.Stopped
Battle.Won = True
EndBattle(False)
@ -1305,7 +1305,7 @@ nextIndex:
End If
Else
PVPLobbyScreen.StoppedBattle = True
PVPLobbyScreen.DisconnectMessage = "You got disconnected from the server." & vbNewLine & vbNewLine & "Press any key to exit."
PVPLobbyScreen.DisconnectMessage = "You got disconnected from the server." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
PVPLobbyScreen.ScreenState = PVPLobbyScreen.ScreenStates.Stopped
Battle.Won = False
EndBattle(False)
@ -1344,7 +1344,7 @@ nextIndex:
If Directory.Exists(GameController.GamePath & "\PvP Log\") = False Then
Directory.CreateDirectory(GameController.GamePath & "\PvP Log\")
End If
Dim shownData As String = data.Replace("}{", "}" & vbNewLine & "{").Replace("}|{", "}|" & vbNewLine & vbNewLine & "{")
Dim shownData As String = data.Replace("}{", "}" & Environment.NewLine & "{").Replace("}|{", "}|" & Environment.NewLine & Environment.NewLine & "{")
IO.File.WriteAllText(GameController.GamePath & "\PvP Log\HostEndRoundData.dat", shownData)
End If
'Converts the single string received as data into a list of string
@ -1429,7 +1429,7 @@ nextIndex:
If Directory.Exists(GameController.GamePath & "\PvP Log\") = False Then
Directory.CreateDirectory(GameController.GamePath & "\PvP Log\")
End If
Dim shownData As String = data.Replace("}{", "}" & vbNewLine & "{").Replace("}|{", "}|" & vbNewLine & vbNewLine & "{")
Dim shownData As String = data.Replace("}{", "}" & Environment.NewLine & "{").Replace("}|{", "}|" & Environment.NewLine & Environment.NewLine & "{")
IO.File.WriteAllText(GameController.GamePath & "\PvP Log\HostData.dat", shownData)
End If
End If
@ -1490,7 +1490,7 @@ nextIndex:
If Directory.Exists(GameController.GamePath & "\PvP Log\") = False Then
Directory.CreateDirectory(GameController.GamePath & "\PvP Log\")
End If
Dim shownData As String = data.Replace("}{", "}" & vbNewLine & "{").Replace("}|{", "}|" & vbNewLine & vbNewLine & "{")
Dim shownData As String = data.Replace("}{", "}" & Environment.NewLine & "{").Replace("}|{", "}|" & Environment.NewLine & Environment.NewLine & "{")
IO.File.WriteAllText(GameController.GamePath & "\PvP Log\ClientCommand.dat", shownData)
End If
@ -1544,7 +1544,7 @@ nextIndex:
If Directory.Exists(GameController.GamePath & "\PvP Log\") = False Then
Directory.CreateDirectory(GameController.GamePath & "\PvP Log\")
End If
Dim shownData As String = d.Replace("}{", "}" & vbNewLine & "{").Replace("}|{", "}|" & vbNewLine & vbNewLine & "{")
Dim shownData As String = d.Replace("}{", "}" & Environment.NewLine & "{").Replace("}|{", "}|" & Environment.NewLine & Environment.NewLine & "{")
IO.File.WriteAllText(GameController.GamePath & "\PvP Log\SentEndRoundData.dat", shownData)
End If
Logger.Debug("[Battle]: Sent End Round data")
@ -1577,7 +1577,7 @@ nextIndex:
If Directory.Exists(GameController.GamePath & "\PvP Log\") = False Then
Directory.CreateDirectory(GameController.GamePath & "\PvP Log\")
End If
Dim shownData As String = d.Replace("}{", "}" & vbNewLine & "{").Replace("}|{", "}|" & vbNewLine & vbNewLine & "{")
Dim shownData As String = d.Replace("}{", "}" & Environment.NewLine & "{").Replace("}|{", "}|" & Environment.NewLine & Environment.NewLine & "{")
IO.File.WriteAllText(GameController.GamePath & "\PvP Log\SentHostQuery.dat", shownData)
End If
Core.ServersManager.ServerConnection.SendPackage(New Servers.Package(Servers.Package.PackageTypes.BattleHostData, Core.ServersManager.ID, Servers.Package.ProtocolTypes.TCP, {PartnerNetworkID.ToString(), d}.ToList()))

View File

@ -97,11 +97,11 @@
Public Shared Shadows Function FromString(ByVal input As String) As QueryObject
Dim d() As String = input.Split(CChar("|"))
Return New TextQueryObject(d(0).Replace("*", vbNewLine), New Color(CInt(d(1)), CInt(d(2)), CInt(d(3))))
Return New TextQueryObject(d(0).Replace("*", Environment.NewLine), New Color(CInt(d(1)), CInt(d(2)), CInt(d(3))))
End Function
Public Overrides Function ToString() As String
Dim s As String = Me._text.Replace(vbNewLine, "*") & "|" &
Dim s As String = Me._text.Replace(Environment.NewLine, "*") & "|" &
Me._textColor.R & "|" & Me._textColor.G & "|" & Me._textColor.B
Return "{TEXT|" & s & "}"

View File

@ -343,7 +343,7 @@ Public Class Trainer
Me.VSImageOrigin = "battlefrontier"
Me.VSImageSize = New Size(275, 275)
Case Else
If IsNumeric(vsType) = True Then
If StringHelper.IsNumeric(vsType) = True Then
If CInt(vsType) > 11 Then
Dim x As Integer = CInt(vsType)
Dim y As Integer = 0
@ -381,7 +381,7 @@ Public Class Trainer
Case "11"
Me.BarImagePosition = New Vector2(1, 5)
Case Else
If IsNumeric(barType) = True Then
If StringHelper.IsNumeric(barType) = True Then
If CInt(barType) > 11 Then
Dim x As Integer = CInt(barType)
Dim y As Integer = 0

View File

@ -92,10 +92,10 @@
Case "windowsize"
If value.Contains(",") = True Then
Dim arg() As String = value.Split(CChar(","))
If IsNumeric(arg(0)) = True Then
If StringHelper.IsNumeric(arg(0)) = True Then
Me.WindowSize.X = CSng(arg(0).Replace(".", GameController.DecSeparator)).Clamp(1, 4096)
End If
If IsNumeric(arg(1)) = True Then
If StringHelper.IsNumeric(arg(1)) = True Then
Me.WindowSize.Y = CSng(arg(1).Replace(".", GameController.DecSeparator)).Clamp(1, 4096)
End If
End If
@ -132,27 +132,27 @@
Next
End If
Dim Data As String = "Music|" & CInt(MusicManager.MasterVolume * 100) & vbNewLine &
"Sound|" & CInt(SoundManager.Volume * 100) & vbNewLine &
"Muted|" & mutedString & vbNewLine &
"RenderDistance|" & Me.RenderDistance.ToString() & vbNewLine &
"ShowDebug|" & showDebugString & vbNewLine &
"ShowBoundingBoxes|" & Entity.drawViewBox.ToNumberString() & vbNewLine &
"ShowDebugConsole|" & Logger.DisplayLog.ToNumberString() & vbNewLine &
"ShowGUI|" & Me.ShowGUI.ToNumberString() & vbNewLine &
"GraphicStyle|" & Me.GraphicStyle.ToString() & vbNewLine &
"LoadOffsetMaps|" & Me.LoadOffsetMaps.ToString() & vbNewLine &
"Language|" & Localization.LanguageSuffix & vbNewLine &
"ViewBobbing|" & Me.ViewBobbing.ToNumberString() & vbNewLine &
"GamePadEnabled|" & Me.GamePadEnabled.ToNumberString() & vbNewLine &
"LightningEnabled|" & Me.LightingEnabled.ToNumberString() & vbNewLine &
"StartedOfflineGame|" & Me.StartedOfflineGame.ToNumberString() & vbNewLine &
"PreferMultiSampling|" & Core.GraphicsManager.PreferMultiSampling.ToNumberString() & vbNewLine &
"ContentPacks|" & ContentPackString & vbNewLine &
"WindowSize|" & Core.windowSize.Width.ToString() & "," & Core.windowSize.Height.ToString().Replace(GameController.DecSeparator, ".") & vbNewLine &
"ForceMusic|" & Me.ForceMusic.ToNumberString() & vbNewLine &
"MaxOffsetLevel|" & Me.MaxOffsetLevel.ToString() & vbNewLine &
"UpdateDisabled|" & Me.UpdateDisabled.ToNumberString() & vbNewLine &
Dim Data As String = "Music|" & CInt(MusicManager.MasterVolume * 100) & Environment.NewLine &
"Sound|" & CInt(SoundManager.Volume * 100) & Environment.NewLine &
"Muted|" & mutedString & Environment.NewLine &
"RenderDistance|" & Me.RenderDistance.ToString() & Environment.NewLine &
"ShowDebug|" & showDebugString & Environment.NewLine &
"ShowBoundingBoxes|" & Entity.drawViewBox.ToNumberString() & Environment.NewLine &
"ShowDebugConsole|" & Logger.DisplayLog.ToNumberString() & Environment.NewLine &
"ShowGUI|" & Me.ShowGUI.ToNumberString() & Environment.NewLine &
"GraphicStyle|" & Me.GraphicStyle.ToString() & Environment.NewLine &
"LoadOffsetMaps|" & Me.LoadOffsetMaps.ToString() & Environment.NewLine &
"Language|" & Localization.LanguageSuffix & Environment.NewLine &
"ViewBobbing|" & Me.ViewBobbing.ToNumberString() & Environment.NewLine &
"GamePadEnabled|" & Me.GamePadEnabled.ToNumberString() & Environment.NewLine &
"LightningEnabled|" & Me.LightingEnabled.ToNumberString() & Environment.NewLine &
"StartedOfflineGame|" & Me.StartedOfflineGame.ToNumberString() & Environment.NewLine &
"PreferMultiSampling|" & Core.GraphicsManager.PreferMultiSampling.ToNumberString() & Environment.NewLine &
"ContentPacks|" & ContentPackString & Environment.NewLine &
"WindowSize|" & Core.windowSize.Width.ToString() & "," & Core.windowSize.Height.ToString().Replace(GameController.DecSeparator, ".") & Environment.NewLine &
"ForceMusic|" & Me.ForceMusic.ToNumberString() & Environment.NewLine &
"MaxOffsetLevel|" & Me.MaxOffsetLevel.ToString() & Environment.NewLine &
"UpdateDisabled|" & Me.UpdateDisabled.ToNumberString() & Environment.NewLine &
"Extras|" & String.Join(";", Me.Extras)
File.WriteAllText(GameController.GamePath & "\Save\options.dat", Data)
@ -163,27 +163,27 @@
End Sub
Private Sub CreateOptions()
Dim s As String = "Music|50" & vbNewLine &
"Sound|50" & vbNewLine &
"Muted|0" & vbNewLine &
"RenderDistance|2" & vbNewLine &
"ShowDebug|0" & vbNewLine &
"ShowBoundingBoxes|0" & vbNewLine &
"ShowDebugConsole|0" & vbNewLine &
"ShowGUI|1" & vbNewLine &
"GraphicStyle|1" & vbNewLine &
"LoadOffsetMaps|10" & vbNewLine &
"Language|en" & vbNewLine &
"ViewBobbing|1" & vbNewLine &
"GamePadEnabled|1" & vbNewLine &
"LightningEnabled|1" & vbNewLine &
"StartedOfflineGame|0" & vbNewLine &
"PreferMultiSampling|1" & vbNewLine &
"ContentPacks|" & vbNewLine &
"WindowSize|1200,680" & vbNewLine &
"ForceMusic|0" & vbNewLine &
"MaxOffsetLevel|0" & vbNewLine &
"UpdateDisabled|0" & vbNewLine &
Dim s As String = "Music|50" & Environment.NewLine &
"Sound|50" & Environment.NewLine &
"Muted|0" & Environment.NewLine &
"RenderDistance|2" & Environment.NewLine &
"ShowDebug|0" & Environment.NewLine &
"ShowBoundingBoxes|0" & Environment.NewLine &
"ShowDebugConsole|0" & Environment.NewLine &
"ShowGUI|1" & Environment.NewLine &
"GraphicStyle|1" & Environment.NewLine &
"LoadOffsetMaps|10" & Environment.NewLine &
"Language|en" & Environment.NewLine &
"ViewBobbing|1" & Environment.NewLine &
"GamePadEnabled|1" & Environment.NewLine &
"LightningEnabled|1" & Environment.NewLine &
"StartedOfflineGame|0" & Environment.NewLine &
"PreferMultiSampling|1" & Environment.NewLine &
"ContentPacks|" & Environment.NewLine &
"WindowSize|1200,680" & Environment.NewLine &
"ForceMusic|0" & Environment.NewLine &
"MaxOffsetLevel|0" & Environment.NewLine &
"UpdateDisabled|0" & Environment.NewLine &
"Extras|"
File.WriteAllText(GameController.GamePath & "\Save\options.dat", s)

View File

@ -9,7 +9,7 @@
#End Region
Public Shared Sub Render(ByVal box As BoundingBox, ByVal graphicsDevice As GraphicsDevice, ByVal view As Matrix, ByVal projection As Matrix, ByVal color As Color)
If IsNothing(effect) = True Then
If effect Is Nothing Then
effect = New BasicEffect(graphicsDevice)
effect.VertexColorEnabled = True
effect.LightingEnabled = False
@ -32,7 +32,7 @@
End Sub
Public Shared Sub Render(ByVal frustum As BoundingFrustum, ByVal graphicsDevice As GraphicsDevice, ByVal view As Matrix, ByVal projection As Matrix, ByVal color As Color)
If IsNothing(effect) = True Then
If effect Is Nothing Then
effect = New BasicEffect(graphicsDevice)
effect.VertexColorEnabled = True
effect.LightingEnabled = False

View File

@ -23,9 +23,9 @@
End If
End If
Dim s As String = GameController.GAMENAME & " " & GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION & " / FPS: " & Math.Round(Core.GameInstance.FPSMonitor.Value, 0) & isDebugString & vbNewLine &
Screen.Camera.Position.ToString() & thirdPersonString & vbNewLine & Screen.Camera.Yaw & "; " & Screen.Camera.Pitch & vbNewLine &
"E: " & _drawnVertices.ToString() & "/" & _maxVertices.ToString() & vbNewLine &
Dim s As String = GameController.GAMENAME & " " & GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION & " / FPS: " & Math.Round(Core.GameInstance.FPSMonitor.Value, 0) & isDebugString & Environment.NewLine &
Screen.Camera.Position.ToString() & thirdPersonString & Environment.NewLine & Screen.Camera.Yaw & "; " & Screen.Camera.Pitch & Environment.NewLine &
"E: " & _drawnVertices.ToString() & "/" & _maxVertices.ToString() & Environment.NewLine &
"C: " & _maxDistance.ToString() & " A: " & ActionscriptActive.ToString()
If Core.GameOptions.ContentPackNames.Count() > 0 Then
@ -37,7 +37,7 @@
contentPackString &= ContentPackName
Next
contentPackString = "Loaded ContentPacks: " & contentPackString
s &= vbNewLine & contentPackString
s &= Environment.NewLine & contentPackString
End If
Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, s, New Vector2(7, 7), Color.Black)

View File

@ -19,10 +19,10 @@ Public Class DotNetVersion
Dim install As String = versionKey.GetValue("Install", "").ToString()
If install = "" Then
'no install info, ust be later
output &= versionKeyName & " " & name & vbNewLine
output &= versionKeyName & " " & name & Environment.NewLine
Else
If sp <> "" AndAlso install = "1" Then
output &= versionKeyName & " " & name & " SP" & sp & vbNewLine
output &= versionKeyName & " " & name & " SP" & sp & Environment.NewLine
End If
End If
If name <> "" Then
@ -37,12 +37,12 @@ Public Class DotNetVersion
install = subKey.GetValue("Install", "").ToString()
If install = "" Then
'no install info, ust be later
output &= versionKeyName & " " & name & vbNewLine
output &= versionKeyName & " " & name & Environment.NewLine
Else
If sp <> "" AndAlso install = "1" Then
output &= " " & subKeyName & " " & name & " SP" & sp & vbNewLine
output &= " " & subKeyName & " " & name & " SP" & sp & Environment.NewLine
ElseIf install = "1" Then
output &= " " & subKeyName & " " & name & vbNewLine
output &= " " & subKeyName & " " & name & Environment.NewLine
End If
End If
Next

View File

@ -1,4 +1,5 @@
Imports System.Management
Imports System.Windows.Forms
Public Class Logger
@ -64,7 +65,7 @@ Public Class Logger
If Log = "" Then
Log = LogString
Else
Log &= vbNewLine & LogString
Log &= Environment.NewLine & LogString
End If
IO.File.WriteAllText(GameController.GamePath & "\log.dat", Log)
@ -75,7 +76,7 @@ Public Class Logger
Try
Dim w32ErrorCode As Integer = -1
Dim w32 = TryCast(ex, ComponentModel.Win32Exception)
Dim w32 = TryCast(ex, System.ComponentModel.Win32Exception)
If w32 IsNot Nothing Then
w32ErrorCode = w32.ErrorCode
End If
@ -147,19 +148,19 @@ Public Class Logger
IsSandboxMode = Core.Player.SandBoxMode.ToString()
End If
Dim gameInformation As String = GameController.GAMENAME & " " & GameController.GAMEDEVELOPMENTSTAGE & " version: " & GameController.GAMEVERSION & " (" & GameController.RELEASEVERSION & ")" & vbNewLine &
"Content Packs: " & ContentPacks & vbNewLine &
"Active GameMode: " & GameMode & vbNewLine &
OnlineInformation & vbNewLine &
"Playing on Servers: " & ServerInfo & vbNewLine &
"Game Environment: " & GameEnvironment & vbNewLine &
ScriptInfo & vbNewLine &
"File Validation: " & Security.FileValidation.IsValid(True).ToString() & vbNewLine &
Dim gameInformation As String = GameController.GAMENAME & " " & GameController.GAMEDEVELOPMENTSTAGE & " version: " & GameController.GAMEVERSION & " (" & GameController.RELEASEVERSION & ")" & Environment.NewLine &
"Content Packs: " & ContentPacks & Environment.NewLine &
"Active GameMode: " & GameMode & Environment.NewLine &
OnlineInformation & Environment.NewLine &
"Playing on Servers: " & ServerInfo & Environment.NewLine &
"Game Environment: " & GameEnvironment & Environment.NewLine &
ScriptInfo & Environment.NewLine &
"File Validation: " & Security.FileValidation.IsValid(True).ToString() & Environment.NewLine &
"Sandboxmode: " & IsSandboxMode
Dim ScreenState As String = "[Screen state object not available]"
If Not CurrentScreen Is Nothing Then
ScreenState = "Screen state for the current screen (" & CurrentScreen.Identification.ToString() & ")" & vbNewLine & vbNewLine &
ScreenState = "Screen state for the current screen (" & CurrentScreen.Identification.ToString() & ")" & Environment.NewLine & Environment.NewLine &
CurrentScreen.GetScreenStatus()
End If
@ -168,12 +169,12 @@ Public Class Logger
architectureString = "64 Bit"
End If
Dim specs As String = "Operating system: " & My.Computer.Info.OSFullName & " [" & My.Computer.Info.OSVersion & "]" & vbNewLine &
"Core architecture: " & architectureString & vbNewLine &
"System time: " & My.Computer.Clock.LocalTime.ToString() & vbNewLine &
"System language: " & Globalization.CultureInfo.CurrentCulture.EnglishName & "(" & Globalization.CultureInfo.CurrentCulture.ThreeLetterWindowsLanguageName & ") / Loaded game language: " & Localization.LanguageSuffix & vbNewLine &
"Decimal separator: " & GameController.DecSeparator & vbNewLine &
"Available physical memory: " & Math.Round((My.Computer.Info.TotalPhysicalMemory / Math.Pow(1024, 3)), 2).ToString() & " Gigabyte" & vbNewLine &
Dim specs As String = "Operating system: " & My.Computer.Info.OSFullName & " [" & My.Computer.Info.OSVersion & "]" & Environment.NewLine &
"Core architecture: " & architectureString & Environment.NewLine &
"System time: " & My.Computer.Clock.LocalTime.ToString() & Environment.NewLine &
"System language: " & Globalization.CultureInfo.CurrentCulture.EnglishName & "(" & Globalization.CultureInfo.CurrentCulture.ThreeLetterWindowsLanguageName & ") / Loaded game language: " & Localization.LanguageSuffix & Environment.NewLine &
"Decimal separator: " & GameController.DecSeparator & Environment.NewLine &
"Available physical memory: " & Math.Round((My.Computer.Info.TotalPhysicalMemory / Math.Pow(1024, 3)), 2).ToString() & " Gigabyte" & Environment.NewLine &
"Available logical processors: " & Environment.ProcessorCount.ToString()
Dim innerException As String = "NOTHING"
@ -207,7 +208,7 @@ Public Class Logger
data = ""
For i = 0 To ex.Data.Count - 1
If data <> "" Then
data &= vbNewLine
data &= Environment.NewLine
End If
data &= "[" & ex.Data.Keys(i).ToString() & ": """ & ex.Data.Values(i).ToString() & """]"
Next
@ -220,47 +221,49 @@ Public Class Logger
Dim screenDump As String = objDump.Dump
Dim content As String =
"Kolben Games Crash Log V " & LOGVERSION & vbNewLine &
GameController.GAMENAME & " has crashed!" & vbNewLine &
"// " & ErrorHeaders(Random.Next(0, ErrorHeaders.Length)) & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"Game information:" & vbNewLine & vbNewLine &
gameInformation & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
ScreenState & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"System specifications:" & vbNewLine & vbNewLine &
specs & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
".Net installation information:" & vbNewLine & vbNewLine &
DotNetVersion.GetInstalled() & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
GetGraphicsCardInformation() & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"Error information:" & vbNewLine &
vbNewLine & "Message: " & message &
vbNewLine & "InnerException: " & innerException &
vbNewLine & "BaseException: " & BaseException.Message &
vbNewLine & "HelpLink: " & helpLink &
vbNewLine & "Data: " & data &
vbNewLine & "Source: " & source &
vbNewLine & "Win32 Errorcode: " & w32ErrorCode.ToString() & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
informationItem.ToString() & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"CallStack: " & vbNewLine & vbNewLine &
StackTrace & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"Enviornment dump: " & vbNewLine & vbNewLine &
screenDump & vbNewLine & vbNewLine &
CRASHLOGSEPARATOR & vbNewLine & vbNewLine &
"You should report this error." & vbNewLine & vbNewLine & "Go to ""http://pokemon3d.net/forum/forums/6/create-thread"" to report this crash there."
"Kolben Games Crash Log V " & LOGVERSION & Environment.NewLine &
GameController.GAMENAME & " has crashed!" & Environment.NewLine &
"// " & ErrorHeaders(Random.Next(0, ErrorHeaders.Length)) & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"Game information:" & Environment.NewLine & Environment.NewLine &
gameInformation & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
ScreenState & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"System specifications:" & Environment.NewLine & Environment.NewLine &
specs & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
".Net installation information:" & Environment.NewLine & Environment.NewLine &
DotNetVersion.GetInstalled() & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
GetGraphicsCardInformation() & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"Error information:" & Environment.NewLine &
Environment.NewLine & "Message: " & message &
Environment.NewLine & "InnerException: " & innerException &
Environment.NewLine & "BaseException: " & BaseException.Message &
Environment.NewLine & "HelpLink: " & helpLink &
Environment.NewLine & "Data: " & data &
Environment.NewLine & "Source: " & source &
Environment.NewLine & "Win32 Errorcode: " & w32ErrorCode.ToString() & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
informationItem.ToString() & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"CallStack: " & Environment.NewLine & Environment.NewLine &
StackTrace & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"Enviornment dump: " & Environment.NewLine & Environment.NewLine &
screenDump & Environment.NewLine & Environment.NewLine &
CRASHLOGSEPARATOR & Environment.NewLine & Environment.NewLine &
"You should report this error." & Environment.NewLine & Environment.NewLine & "Go to ""http://pokemon3d.net/forum/forums/6/create-thread"" to report this crash there."
IO.File.WriteAllText(GameController.GamePath & "\" & logName, content)
MsgBox(GameController.GAMENAME & " has crashed!" & vbNewLine & "---------------------------" & vbNewLine & vbNewLine & "Here is further information:" &
vbNewLine & "Message: " & ex.Message &
vbNewLine & vbNewLine & "You should report this error. When you do this, please attach the crash log to the report. You can find the file in your ""Pokemon"" folder." & vbNewLine & vbNewLine & "The name of the file is: """ & logName & """.", MsgBoxStyle.Critical, "Pokémon3D crashed!")
MessageBox.Show(GameController.GAMENAME & " has crashed!" & Environment.NewLine & "---------------------------" & Environment.NewLine & Environment.NewLine & "Here is further information:" &
Environment.NewLine & "Message: " & ex.Message &
Environment.NewLine & Environment.NewLine & "You should report this error. When you do this, please attach the crash log to the report. You can find the file in your ""Pokemon"" folder." & Environment.NewLine & Environment.NewLine & "The name of the file is: """ & logName & """.",
"Pokémon3D crashed!", MessageBoxButtons.OK, MessageBoxIcon.Error)
Process.Start("explorer.exe", "/select,""" & GameController.GamePath & "\" & logName & """")
@ -272,7 +275,7 @@ Public Class Logger
"""CODESOURCE_" & ex.Source & """ " &
"""TOPSTACK_" & ErrorInformation.GetStackItem(ex.StackTrace, 0) & """"
Catch exs As Exception
MsgBox(exs.Message & vbNewLine & exs.StackTrace)
MessageBox.Show(exs.Message & Environment.NewLine & exs.StackTrace)
End Try
Return ""
@ -301,7 +304,7 @@ Public Class Logger
End While
End If
Diagnostics.Debug.Print(stackOutput & vbTab & "| " & message)
Diagnostics.Debug.Print(stackOutput & StringHelper.Tab & "| " & message)
History.Add("(" & GetLogTime(Date.Now) & ") " & message)
End Sub
@ -376,8 +379,8 @@ Public Class Logger
End Try
Next
Return "Graphics Card information:" & vbNewLine & vbNewLine &
"[CardName(s): """ & CardName & """]" & vbNewLine &
Return "Graphics Card information:" & Environment.NewLine & Environment.NewLine &
"[CardName(s): """ & CardName & """]" & Environment.NewLine &
"[CardRAM(s) : """ & CardRAM & """]"
End Function
@ -510,10 +513,10 @@ analyzeStack:
ErrorType = "NaN"
End If
Dim s As String = "Error solution:" & vbNewLine & "(The provided solution might not work for your problem)" & vbNewLine & vbNewLine &
"Error ID: " & ErrorID & vbNewLine &
"Error Type: " & ErrorType & vbNewLine &
"Error Description: " & ErrorDescription & vbNewLine &
Dim s As String = "Error solution:" & Environment.NewLine & "(The provided solution might not work for your problem)" & Environment.NewLine & Environment.NewLine &
"Error ID: " & ErrorID & Environment.NewLine &
"Error Type: " & ErrorType & Environment.NewLine &
"Error Description: " & ErrorDescription & Environment.NewLine &
"Error Solution: " & ErrorSolution
Return s
End Function

View File

@ -16,13 +16,13 @@ Public Class ObjectDump
Dim properties() As PropertyInfo = sender.GetType().GetProperties(BindingFlags.Public Or BindingFlags.NonPublic Or BindingFlags.Instance Or BindingFlags.Static)
Dump =
"--------------------------------------------------" & vbNewLine &
"Generated Fields:" & vbNewLine &
"--------------------------------------------------" & vbNewLine
"--------------------------------------------------" & Environment.NewLine &
"Generated Fields:" & Environment.NewLine &
"--------------------------------------------------" & Environment.NewLine
For Each field As FieldInfo In fields
If Dump <> "" Then
Dump &= vbNewLine
Dump &= Environment.NewLine
End If
Dim fieldAccessToken As String = ""
@ -64,15 +64,15 @@ Public Class ObjectDump
Dump &= fieldAccessToken & fieldNameToken & " As " & fieldTypeToken & " = " & fieldValueToken
Next
Dump &= vbNewLine & vbNewLine &
"--------------------------------------------------" & vbNewLine &
"Generated Property:" & vbNewLine &
"--------------------------------------------------" & vbNewLine
Dump &= Environment.NewLine & Environment.NewLine &
"--------------------------------------------------" & Environment.NewLine &
"Generated Property:" & Environment.NewLine &
"--------------------------------------------------" & Environment.NewLine
For Each [property] As PropertyInfo In properties
If [property].CanRead Then
If Dump <> "" Then
Dump &= vbNewLine
Dump &= Environment.NewLine
End If
Dim propertyNameToken As String = ""

View File

@ -67,7 +67,7 @@
Dim PickDate As Date = New Date(CInt(d(0)), CInt(d(1)), CInt(d(2)), CInt(d(3)), CInt(d(4)), CInt(d(5)))
Dim diff As Integer = CInt(DateDiff(DateInterval.Hour, PickDate, Date.Now))
Dim diff As Integer = (Date.Now - PickDate).Hours
Dim hasToDiff As Integer = 24
If Game.World.CurrentSeason = Game.World.Seasons.Winter Or Game.World.CurrentSeason = Game.World.Seasons.Fall Then
@ -91,7 +91,7 @@
Core.Player.ApricornData = ""
For Each Apricorn As String In ApricornsData
If Core.Player.ApricornData <> "" Then
Core.Player.ApricornData &= vbNewLine
Core.Player.ApricornData &= Environment.NewLine
End If
Core.Player.ApricornData &= Apricorn
Next
@ -157,7 +157,7 @@
"}"
If Core.Player.ApricornData <> "" Then
Core.Player.ApricornData &= vbNewLine
Core.Player.ApricornData &= Environment.NewLine
End If
Core.Player.ApricornData &= s

View File

@ -48,8 +48,7 @@
NewTexture()
Else
With My.Computer.Clock.LocalTime
Dim cD As New Date(.Year, .Month, .Day, .TimeOfDay.Hours, .TimeOfDay.Minutes, .TimeOfDay.Seconds)
Dim diff As Integer = CInt(DateDiff(DateInterval.Second, d, cD))
Dim diff As Integer = (Date.Now - d).Seconds
Grow += diff
@ -72,7 +71,7 @@
Me.LastUpdateDate = Date.Now
End If
Dim diff As Integer = CInt(DateDiff(DateInterval.Second, LastUpdateDate, Date.Now))
Dim diff As Integer = (Date.Now - LastUpdateDate).Seconds
If diff > 0 Then
Me.Grow += diff
@ -217,7 +216,7 @@
If Berry <> "" Then
If Berry.ToLower().StartsWith("{" & Screen.Level.LevelFile.ToLower() & "|" & (Me.Position.X & "," & Me.Position.Y & "," & Me.Position.Z).ToLower() & "|") = False Then
If OutData <> "" Then
OutData &= vbNewLine
OutData &= Environment.NewLine
End If
OutData &= Berry
End If
@ -243,7 +242,7 @@
Dim OldData As String = Core.Player.BerryData
If OldData <> "" Then
OldData &= vbNewLine
OldData &= Environment.NewLine
End If
OldData &= Data
@ -330,7 +329,7 @@
Dim OldData As String = Core.Player.BerryData
If OldData <> "" Then
OldData &= vbNewLine
OldData &= Environment.NewLine
End If
OldData &= Data

View File

@ -62,9 +62,9 @@
Me.CanBeRemoved = True
Dim s As String =
"version=2" & vbNewLine &
"@text.show(" & Text & ")" & vbNewLine &
"@sound.play(destroy,0)" & vbNewLine &
"version=2" & Environment.NewLine &
"@text.show(" & Text & ")" & Environment.NewLine &
"@sound.play(destroy,0)" & Environment.NewLine &
":end"
PlayerStatistics.Track("Cut used", 1)

View File

@ -54,43 +54,43 @@
If result = 0 Then
If diveUp = 0 Then
'Down
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & vbNewLine &
"@screen.fadeout" & vbNewLine &
"@player.warp(" & Me.AdditionalValue & ")" & vbNewLine &
"@level.update" & vbNewLine &
"@player.setmovement(0,-0.5,0)" & vbNewLine &
"@screen.fadein" & vbNewLine &
"@player.move(8)" & vbNewLine &
"@player.resetmovement" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & Environment.NewLine &
"@screen.fadeout" & Environment.NewLine &
"@player.warp(" & Me.AdditionalValue & ")" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@player.setmovement(0,-0.5,0)" & Environment.NewLine &
"@screen.fadein" & Environment.NewLine &
"@player.move(8)" & Environment.NewLine &
"@player.resetmovement" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
ElseIf diveUp = 1 Then
'Up
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & vbNewLine &
"@player.setmovement(0,0.5,0)" & vbNewLine &
"@player.move(8)" & vbNewLine &
"@player.resetmovement" & vbNewLine &
"@screen.fadeout" & vbNewLine &
"@player.warp(" & Me.AdditionalValue & ")" & vbNewLine &
"@level.update" & vbNewLine &
"@screen.fadein" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & Environment.NewLine &
"@player.setmovement(0,0.5,0)" & Environment.NewLine &
"@player.move(8)" & Environment.NewLine &
"@player.resetmovement" & Environment.NewLine &
"@screen.fadeout" & Environment.NewLine &
"@player.warp(" & Me.AdditionalValue & ")" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@screen.fadein" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
ElseIf diveUp = 2 Then
'Up
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & vbNewLine &
"@player.setmovement(0,0.5,0)" & vbNewLine &
"@player.move(6)" & vbNewLine &
"@player.resetmovement" & vbNewLine &
"@screen.fadeout" & vbNewLine &
"@player.warp(" & Me.AdditionalValue & ")" & vbNewLine &
"@level.update" & vbNewLine &
"@screen.fadein" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & GetDivePokemon() & "~used Dive!)" & Environment.NewLine &
"@player.setmovement(0,0.5,0)" & Environment.NewLine &
"@player.move(6)" & Environment.NewLine &
"@player.resetmovement" & Environment.NewLine &
"@screen.fadeout" & Environment.NewLine &
"@player.warp(" & Me.AdditionalValue & ")" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@screen.fadein" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)

View File

@ -57,20 +57,20 @@
Dim spawnedPokemon As Pokemon = Spawner.GetPokemon(Screen.Level.LevelFile, Spawner.EncounterMethods.Headbutt, False)
If spawnedPokemon Is Nothing Then
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Headbutt!)" & vbNewLine &
"@sound.play(destroy,0)" & vbNewLine &
"@level.wait(20)" & vbNewLine &
"@text.show(Nothing happened...)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Headbutt!)" & Environment.NewLine &
"@sound.play(destroy,0)" & Environment.NewLine &
"@level.wait(20)" & Environment.NewLine &
"@text.show(Nothing happened...)" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
Else
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Headbutt!)" & vbNewLine &
"@sound.play(destroy,0)" & vbNewLine &
"@level.wait(20)" & vbNewLine &
"@text.show(A wild Pokémon~appeared!)" & vbNewLine &
"@battle.wild(" & spawnedPokemon.Number & "," & spawnedPokemon.Level & ")" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Headbutt!)" & Environment.NewLine &
"@sound.play(destroy,0)" & Environment.NewLine &
"@level.wait(20)" & Environment.NewLine &
"@text.show(A wild Pokémon~appeared!)" & Environment.NewLine &
"@battle.wild(" & spawnedPokemon.Number & "," & spawnedPokemon.Level & ")" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
End If

View File

@ -112,19 +112,19 @@
Screen.Level.OwnPlayer.Texture = RockClimbPokemon.GetOverworldTexture()
Screen.Level.OwnPlayer.ChangeTexture()
Dim s As String = "version=2" & vbNewLine &
"@pokemon.cry(" & RockClimbPokemon.Number & ")" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",1," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",0," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.move(1)" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.wearskin(" & tempSkin & ")" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@pokemon.cry(" & RockClimbPokemon.Number & ")" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",1," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",0," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.move(1)" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.wearskin(" & tempSkin & ")" & Environment.NewLine
If Not Me.TempScriptEntity Is Nothing Then
s &= GetScriptStartLine(Me.TempScriptEntity) & vbNewLine
s &= GetScriptStartLine(Me.TempScriptEntity) & Environment.NewLine
Me.TempScriptEntity = Nothing
End If
@ -185,17 +185,17 @@
Screen.Level.OwnPlayer.Texture = RockClimbPokemon.GetOverworldTexture()
Screen.Level.OwnPlayer.ChangeTexture()
Dim s As String = "version=2" & vbNewLine &
"@pokemon.cry(" & RockClimbPokemon.Number & ")" & vbNewLine &
"@player.move(1)" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",-1," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.wearskin(" & tempSkin & ")" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@pokemon.cry(" & RockClimbPokemon.Number & ")" & Environment.NewLine &
"@player.move(1)" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",-1," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.wearskin(" & tempSkin & ")" & Environment.NewLine
If Not Me.TempScriptEntity Is Nothing Then
s &= GetScriptStartLine(Me.TempScriptEntity) & vbNewLine
s &= GetScriptStartLine(Me.TempScriptEntity) & Environment.NewLine
Me.TempScriptEntity = Nothing
End If

View File

@ -31,10 +31,10 @@
If Me.Position.X = Screen.Camera.Position.X And CInt(Me.Position.Y) = CInt(Screen.Camera.Position.Y) And Me.Position.Z = Screen.Camera.Position.Z Then
Dim steps As Integer = GetSteps()
Dim s As String = "version=2" & vbNewLine &
"@player.move(0)" & vbNewLine &
"@player.turnto(" & Me.RotateTo.ToString() & ")" & vbNewLine &
"@player.move(" & steps & ")" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@player.move(0)" & Environment.NewLine &
"@player.turnto(" & Me.RotateTo.ToString() & ")" & Environment.NewLine &
"@player.move(" & steps & ")" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)

View File

@ -43,7 +43,7 @@
Case 1
oScreen.ActionScript.StartScript(Me.AdditionalValue, 0)
Case 2
oScreen.ActionScript.StartScript(Me.AdditionalValue.Replace("<br>", vbNewLine), 2)
oScreen.ActionScript.StartScript(Me.AdditionalValue.Replace("<br>", Environment.NewLine), 2)
Case Else
oScreen.ActionScript.StartScript(Me.AdditionalValue, 1)
End Select

View File

@ -46,16 +46,16 @@
Screen.Level.OverworldPokemon.Visible = False
Screen.Level.OverworldPokemon.warped = True
Dim s As String = "version=2" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",1," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",0," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.move(1)" & vbNewLine &
"@pokemon.hide" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",1," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",0," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.move(1)" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine
If Not Me.TempScriptEntity Is Nothing Then
s &= GetScriptStartLine(Me.TempScriptEntity) & vbNewLine
s &= GetScriptStartLine(Me.TempScriptEntity) & Environment.NewLine
Me.TempScriptEntity = Nothing
End If
@ -131,14 +131,14 @@
Screen.Level.OverworldPokemon.Visible = False
Screen.Level.OverworldPokemon.warped = True
Dim s As String = "version=2" & vbNewLine &
"@player.move(1)" & vbNewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",-1," & Screen.Camera.GetMoveDirection().Z & ")" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@player.move(1)" & Environment.NewLine &
"@player.setmovement(" & Screen.Camera.GetMoveDirection().X & ",-1," & Screen.Camera.GetMoveDirection().Z & ")" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine
If Not Me.TempScriptEntity Is Nothing Then
s &= GetScriptStartLine(Me.TempScriptEntity) & vbNewLine
s &= GetScriptStartLine(Me.TempScriptEntity) & Environment.NewLine
Me.TempScriptEntity = Nothing
End If

View File

@ -55,36 +55,36 @@
If Core.Random.Next(0, 100) < 20 Then
spawnedPokemon = Spawner.GetPokemon(Screen.Level.LevelFile, Spawner.EncounterMethods.RockSmash, False)
If spawnedPokemon Is Nothing Then
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Rock Smash!)" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Rock Smash!)" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
Else
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Rock Smash!)" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
"@level.update" & vbNewLine &
"@text.show(A wild Pokémon~appeared!)" & vbNewLine &
"@battle.wild(" & spawnedPokemon.Number & "," & spawnedPokemon.Level & ")" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Rock Smash!)" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@text.show(A wild Pokémon~appeared!)" & Environment.NewLine &
"@battle.wild(" & spawnedPokemon.Number & "," & spawnedPokemon.Level & ")" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
End If
Else
If Core.Random.Next(0, 100) < 20 Then
Dim ItemID As Integer = GetItemID()
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Rock Smash!)" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
"@level.update" & vbNewLine &
"@item.give(" & ItemID & ",1)" & vbNewLine &
"@item.messagegive(" & ItemID & ",1)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Rock Smash!)" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@item.give(" & ItemID & ",1)" & Environment.NewLine &
"@item.messagegive(" & ItemID & ",1)" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
Else
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & pName & " used~Rock Smash!)" & vbNewLine &
"@sound.play(destroy)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & pName & " used~Rock Smash!)" & Environment.NewLine &
"@sound.play(destroy)" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
End If

View File

@ -30,7 +30,7 @@
If r.StartsWith("ACTIVATOR_REMOVE_STRENGTH_ROCK_" & Screen.Level.LevelFile & "_") = True Then
Dim RemoveID As String = r.Remove(0, ("ACTIVATOR_REMOVE_STRENGTHT_ROCK_" & Screen.Level.LevelFile & "_").Length - 1)
For Each sRock As Entity In Screen.Level.Entities
If sRock.EntityID = "StrengthRock" And IsNumeric(sRock.ID) = True Then
If sRock.EntityID = "StrengthRock" Then
If sRock.ID = CInt(RemoveID) Then
sRock.CanBeRemoved = True
End If

View File

@ -17,7 +17,7 @@
Me.Rotation.Y = randomValue
End Select
If IsNumeric(Me.AdditionalValue) = True Then
If StringHelper.IsNumeric(Me.AdditionalValue) = True Then
Me.TurningSpeed = CSng(CInt(Me.AdditionalValue) / 100)
End If
Me.CreateWorldEveryFrame = True

View File

@ -75,7 +75,10 @@
Dim z As String = link.GetSplit(3)
Dim l As String = link.GetSplit(4)
If IsNumeric(x) = True And IsNumeric(y) = True And IsNumeric(z) = True And IsNumeric(l) = True Then
If StringHelper.IsNumeric(x) = True And
StringHelper.IsNumeric(y) = True And
StringHelper.IsNumeric(z) = True And
StringHelper.IsNumeric(l) = True Then
Return True
Else
CallError("Position values are not numeric.")

View File

@ -207,13 +207,13 @@
End If
End While
s = "version=2" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.move(2)" & vbNewLine &
"@player.setmovement(0,-1,0)" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine &
s = "version=2" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.move(2)" & Environment.NewLine &
"@player.setmovement(0,-1,0)" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
@ -259,14 +259,14 @@
Screen.Camera.PlannedMovement = New Vector3(0, 1, 0)
s = "version=2" & vbNewLine &
"@pokemon.cry(" & pNumber & ")" & vbNewLine &
"@sound.play(select)" & vbNewLine &
"@text.show(" & pName & " used~Waterfall.)" & vbNewLine &
"@player.move(" & Steps & ")" & vbNewLine &
"@pokemon.hide" & vbNewLine &
"@player.move(2)" & vbNewLine &
"@pokemon.hide" & vbNewLine &
s = "version=2" & Environment.NewLine &
"@pokemon.cry(" & pNumber & ")" & Environment.NewLine &
"@sound.play(select)" & Environment.NewLine &
"@text.show(" & pName & " used~Waterfall.)" & Environment.NewLine &
"@player.move(" & Steps & ")" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
"@player.move(2)" & Environment.NewLine &
"@pokemon.hide" & Environment.NewLine &
":end"
PlayerStatistics.Track("Waterfall used", 1)

View File

@ -106,7 +106,7 @@
If UseTextureID.StartsWith("Pokemon\Overworld\") = True Then
texturePath = ""
HasPokemonTexture = True
If IsNumeric(TextureID) = True Then
If StringHelper.IsNumeric(TextureID) = True Then
PokemonAddition = PokemonForms.GetDefaultOverworldSpriteAddition(CInt(TextureID))
End If
End If
@ -165,7 +165,7 @@
If Core.Player.NPCData = "" Then
Core.Player.NPCData = Data
Else
Core.Player.NPCData &= vbNewLine & Data
Core.Player.NPCData &= Environment.NewLine & Data
End If
End Sub
@ -182,7 +182,7 @@
Data = ""
For i = 0 To NData.Count - 1
If i <> 0 Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Data &= NData(i)
@ -286,7 +286,7 @@
Case 1
oScreen.ActionScript.StartScript(Me.AdditionalValue, 0)
Case 3
oScreen.ActionScript.StartScript(Me.AdditionalValue.Replace("<br>", vbNewLine), 2)
oScreen.ActionScript.StartScript(Me.AdditionalValue.Replace("<br>", Environment.NewLine), 2)
Case Else
oScreen.ActionScript.StartScript(Me.AdditionalValue, 0)
End Select
@ -394,23 +394,23 @@
offset.X = 0.01F
End Select
Dim s As String = "version=2" & vbNewLine &
"@player.turn(" & turns & ")" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@player.turn(" & turns & ")" & Environment.NewLine
With CType(Screen.Camera, OverworldCamera)
If CType(Screen.Camera, OverworldCamera).ThirdPerson = True And IsOnScreen() = False Then
s &= "@camera.setfocus(npc," & Me.NPCID & ")" & vbNewLine
s &= "@camera.setfocus(npc," & Me.NPCID & ")" & Environment.NewLine
Dim cPosition = .ThirdPersonOffset.X.ToString() & "," & .ThirdPersonOffset.Y.ToString() & "," & .ThirdPersonOffset.Z.ToString()
s &= "@entity.showmessagebulb(1|" & Me.Position.X + offset.X & "|" & Me.Position.Y + 0.7F & "|" & Me.Position.Z + offset.Y & ")" & vbNewLine &
"@npc.move(" & Me.NPCID & "," & distance - 1 & ")" & vbNewLine &
"@camera.resetfocus" & vbNewLine &
"@camera.setposition(" & cPosition & ")" & vbNewLine &
"@script.start(" & Me.AdditionalValue & ")" & vbNewLine &
s &= "@entity.showmessagebulb(1|" & Me.Position.X + offset.X & "|" & Me.Position.Y + 0.7F & "|" & Me.Position.Z + offset.Y & ")" & Environment.NewLine &
"@npc.move(" & Me.NPCID & "," & distance - 1 & ")" & Environment.NewLine &
"@camera.resetfocus" & Environment.NewLine &
"@camera.setposition(" & cPosition & ")" & Environment.NewLine &
"@script.start(" & Me.AdditionalValue & ")" & Environment.NewLine &
":end"
Else
s &= "@entity.showmessagebulb(1|" & Me.Position.X + offset.X & "|" & Me.Position.Y + 0.7F & "|" & Me.Position.Z + offset.Y & ")" & vbNewLine &
"@npc.move(" & Me.NPCID & "," & distance - 1 & ")" & vbNewLine &
"@script.start(" & Me.AdditionalValue & ")" & vbNewLine &
s &= "@entity.showmessagebulb(1|" & Me.Position.X + offset.X & "|" & Me.Position.Y + 0.7F & "|" & Me.Position.Z + offset.Y & ")" & Environment.NewLine &
"@npc.move(" & Me.NPCID & "," & distance - 1 & ")" & Environment.NewLine &
"@script.start(" & Me.AdditionalValue & ")" & Environment.NewLine &
":end"
End If
End With
@ -448,8 +448,8 @@
MyBase.Update()
End Sub
Protected Overrides Function CalculateCameraDistance(CPosition As Vector3) as Single
Return MyBase.CalculateCameraDistance(CPosition) - 0.2f
Protected Overrides Function CalculateCameraDistance(CPosition As Vector3) As Single
Return MyBase.CalculateCameraDistance(CPosition) - 0.2F
End Function
Public Overrides Sub UpdateEntity()

View File

@ -36,12 +36,12 @@
Dim texturePath As String = "Textures\NPC\"
Dim isPokemon As Boolean = False
If TextureID.StartsWith("[POKEMON|N]") = True Or TextureID.StartsWith("[Pokémon|N]") = True Then
If TextureID.StartsWith("[POKEMON|N]") Or TextureID.StartsWith("[Pokémon|N]") Then
TextureID = TextureID.Remove(0, 11)
isPokemon = True
texturePath = "Pokemon\Overworld\Normal\"
HasPokemonTexture = True
ElseIf TextureID.StartsWith("[POKEMON|S]") = True Or TextureID.StartsWith("[Pokémon|S]") = True Then
ElseIf TextureID.StartsWith("[POKEMON|S]") Or TextureID.StartsWith("[Pokémon|S]") Then
TextureID = TextureID.Remove(0, 11)
isPokemon = True
texturePath = "Pokemon\Overworld\Shiny\"
@ -49,17 +49,17 @@
End If
Dim PokemonAddition As String = ""
If IsNumeric(TextureID) = True And texturePath.StartsWith("Pokemon\Overworld\") = True Then
If StringHelper.IsNumeric(TextureID) And texturePath.StartsWith("Pokemon\Overworld\") Then
PokemonAddition = PokemonForms.GetDefaultOverworldSpriteAddition(CInt(TextureID))
End If
If Core.Player.IsGameJoltSave = True Then
If Core.Player.IsGameJoltSave Then
If texturePath & TextureID & PokemonAddition = "Textures\NPC\" & GameJolt.Emblem.GetPlayerSpriteFile(GameJolt.Emblem.GetPlayerLevel(Core.GameJoltSave.Points), Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Gender) Then
UseGameJoltID = True
End If
End If
If UseGameJoltID = True And Core.Player.IsGameJoltSave = True And GameJolt.API.LoggedIn = True AndAlso Not GameJolt.Emblem.GetOnlineSprite(Core.GameJoltSave.GameJoltID) Is Nothing Then
If UseGameJoltID And Core.Player.IsGameJoltSave And GameJolt.API.LoggedIn AndAlso Not GameJolt.Emblem.GetOnlineSprite(Core.GameJoltSave.GameJoltID) Is Nothing Then
Logger.Debug("Change player texture to the online sprite.")
Me.Texture = GameJolt.Emblem.GetOnlineSprite(Core.GameJoltSave.GameJoltID)
UsingGameJoltTexture = True
@ -71,8 +71,8 @@
End If
End Sub
Protected Overrides Function CalculateCameraDistance(CPosition As Vector3) as Single
Return MyBase.CalculateCameraDistance(CPosition) - 0.2f
Protected Overrides Function CalculateCameraDistance(CPosition As Vector3) As Single
Return MyBase.CalculateCameraDistance(CPosition) - 0.2F
End Function
Public Overrides Sub UpdateEntity()

View File

@ -36,7 +36,7 @@
Dim s As String = ""
For i = 0 To Statistics.Count - 1
If s <> "" Then
s &= vbNewLine
s &= Environment.NewLine
End If
s &= Statistics.Keys(i) & "," & Statistics.Values(i).ToString()
Next

View File

@ -0,0 +1,42 @@
Public Class StringHelper
Private Sub New()
Throw New InvalidOperationException("Cannot initialize static class.")
End Sub
Public Shared Function GetChar(charCode As Integer) As Char
Return Char.ConvertFromUtf32(charCode)(0)
End Function
Public Shared ReadOnly Property Tab() As Char
Get
Return GetChar(9)
End Get
End Property
Public Shared ReadOnly Property LineFeed() As Char
Get
Return GetChar(10)
End Get
End Property
Public Shared ReadOnly Property CrLf() As String
Get
Return GetChar(13) + LineFeed
End Get
End Property
Public Shared Function IsNumeric(obj As Object) As Boolean
If TypeOf obj Is String Then
Return IsNumeric(CStr(obj))
End If
Return Microsoft.VisualBasic.IsNumeric(obj)
End Function
Public Shared Function IsNumeric(str As String) As Boolean
Dim discard As Decimal
Return Decimal.TryParse(str, Globalization.NumberStyles.Float, Globalization.NumberFormatInfo.CurrentInfo, discard)
End Function
End Class

View File

@ -28,7 +28,7 @@ Public Class TimeHelpers
Public Shared Function GetCurrentPlayTime() As TimeSpan
Dim PTime As TimeSpan = Core.Player.PlayTime
Dim diff As Integer = CInt(DateDiff(DateInterval.Second, Core.Player.GameStart, Date.Now))
Dim diff As Integer = (Date.Now - Core.Player.GameStart).Seconds
PTime += ConvertSecondToTime(diff)
Return PTime

View File

@ -231,30 +231,30 @@ Public Class KeyBindings
Public Shared Sub CreateKeySave(ByVal force As Boolean)
If IO.Directory.Exists(GameController.GamePath & "\Save") = True Then
If IO.File.Exists(GameController.GamePath & "\Save\Keyboard.dat") = False Or force = True Then
Dim s As String = "[ForwardMove]=W" & vbNewLine &
"[LeftMove]=" & GetKeyName(Keys.A) & vbNewLine &
"[BackwardMove]=" & GetKeyName(Keys.S) & vbNewLine &
"[RightMove]=" & GetKeyName(Keys.D) & vbNewLine &
"[Inventory]=" & GetKeyName(Keys.E) & vbNewLine &
"[Chat]=" & GetKeyName(Keys.T) & vbNewLine &
"[Special]=" & GetKeyName(Keys.Q) & vbNewLine &
"[MuteMusic]=" & GetKeyName(Keys.M) & vbNewLine &
"[Up]=" & GetKeyName(Keys.Up) & vbNewLine &
"[Down]=" & GetKeyName(Keys.Down) & vbNewLine &
"[Left]=" & GetKeyName(Keys.Left) & vbNewLine &
"[Right]=" & GetKeyName(Keys.Right) & vbNewLine &
"[CameraLock]=" & GetKeyName(Keys.C) & vbNewLine &
"[GUIControl]=" & GetKeyName(Keys.F1) & vbNewLine &
"[ScreenShot]=" & GetKeyName(Keys.F2) & vbNewLine &
"[DebugControl]=" & GetKeyName(Keys.F3) & vbNewLine &
"[LightKey]=" & GetKeyName(Keys.F4) & vbNewLine &
"[PerspectiveSwitch]=" & GetKeyName(Keys.F5) & vbNewLine &
"[FullScreen]=" & GetKeyName(Keys.F11) & vbNewLine &
"[Enter1]=" & GetKeyName(Keys.Enter) & vbNewLine &
"[Enter2]=" & GetKeyName(Keys.Space) & vbNewLine &
"[Back1]=" & GetKeyName(Keys.E) & vbNewLine &
"[Back2]=" & GetKeyName(Keys.E) & vbNewLine &
"[Escape]=" & GetKeyName(Keys.Escape) & vbNewLine &
Dim s As String = "[ForwardMove]=W" & Environment.NewLine &
"[LeftMove]=" & GetKeyName(Keys.A) & Environment.NewLine &
"[BackwardMove]=" & GetKeyName(Keys.S) & Environment.NewLine &
"[RightMove]=" & GetKeyName(Keys.D) & Environment.NewLine &
"[Inventory]=" & GetKeyName(Keys.E) & Environment.NewLine &
"[Chat]=" & GetKeyName(Keys.T) & Environment.NewLine &
"[Special]=" & GetKeyName(Keys.Q) & Environment.NewLine &
"[MuteMusic]=" & GetKeyName(Keys.M) & Environment.NewLine &
"[Up]=" & GetKeyName(Keys.Up) & Environment.NewLine &
"[Down]=" & GetKeyName(Keys.Down) & Environment.NewLine &
"[Left]=" & GetKeyName(Keys.Left) & Environment.NewLine &
"[Right]=" & GetKeyName(Keys.Right) & Environment.NewLine &
"[CameraLock]=" & GetKeyName(Keys.C) & Environment.NewLine &
"[GUIControl]=" & GetKeyName(Keys.F1) & Environment.NewLine &
"[ScreenShot]=" & GetKeyName(Keys.F2) & Environment.NewLine &
"[DebugControl]=" & GetKeyName(Keys.F3) & Environment.NewLine &
"[LightKey]=" & GetKeyName(Keys.F4) & Environment.NewLine &
"[PerspectiveSwitch]=" & GetKeyName(Keys.F5) & Environment.NewLine &
"[FullScreen]=" & GetKeyName(Keys.F11) & Environment.NewLine &
"[Enter1]=" & GetKeyName(Keys.Enter) & Environment.NewLine &
"[Enter2]=" & GetKeyName(Keys.Space) & Environment.NewLine &
"[Back1]=" & GetKeyName(Keys.E) & Environment.NewLine &
"[Back2]=" & GetKeyName(Keys.E) & Environment.NewLine &
"[Escape]=" & GetKeyName(Keys.Escape) & Environment.NewLine &
"[OnlineStatus]=" & GetKeyName(Keys.Tab)
IO.File.WriteAllText(GameController.GamePath & "\Save\Keyboard.dat", s)
End If
@ -266,30 +266,30 @@ Public Class KeyBindings
''' </summary>
Public Shared Sub SaveKeys()
If IO.Directory.Exists(GameController.GamePath & "\Save") = True Then
Dim s As String = "[ForwardMove]=" & GetKeyName(ForwardMoveKey) & vbNewLine &
"[LeftMove]=" & GetKeyName(LeftMoveKey) & vbNewLine &
"[BackwardMove]=" & GetKeyName(BackwardMoveKey) & vbNewLine &
"[RightMove]=" & GetKeyName(RightMoveKey) & vbNewLine &
"[Inventory]=" & GetKeyName(OpenInventoryKey) & vbNewLine &
"[Chat]=" & GetKeyName(ChatKey) & vbNewLine &
"[Special]=" & GetKeyName(SpecialKey) & vbNewLine &
"[MuteMusic]=" & GetKeyName(MuteMusicKey) & vbNewLine &
"[Up]=" & GetKeyName(UpKey) & vbNewLine &
"[Down]=" & GetKeyName(DownKey) & vbNewLine &
"[Left]=" & GetKeyName(LeftKey) & vbNewLine &
"[Right]=" & GetKeyName(RightKey) & vbNewLine &
"[CameraLock]=" & GetKeyName(CameraLockKey) & vbNewLine &
"[GUIControl]=" & GetKeyName(GUIControlKey) & vbNewLine &
"[ScreenShot]=" & GetKeyName(ScreenshotKey) & vbNewLine &
"[DebugControl]=" & GetKeyName(DebugKey) & vbNewLine &
"[LightKey]=" & GetKeyName(LightKey) & vbNewLine &
"[PerspectiveSwitch]=" & GetKeyName(PerspectiveSwitchKey) & vbNewLine &
"[FullScreen]=" & GetKeyName(FullScreenKey) & vbNewLine &
"[Enter1]=" & GetKeyName(EnterKey1) & vbNewLine &
"[Enter2]=" & GetKeyName(EnterKey2) & vbNewLine &
"[Back1]=" & GetKeyName(BackKey1) & vbNewLine &
"[Back2]=" & GetKeyName(BackKey2) & vbNewLine &
"[Escape]=" & GetKeyName(EscapeKey) & vbNewLine &
Dim s As String = "[ForwardMove]=" & GetKeyName(ForwardMoveKey) & Environment.NewLine &
"[LeftMove]=" & GetKeyName(LeftMoveKey) & Environment.NewLine &
"[BackwardMove]=" & GetKeyName(BackwardMoveKey) & Environment.NewLine &
"[RightMove]=" & GetKeyName(RightMoveKey) & Environment.NewLine &
"[Inventory]=" & GetKeyName(OpenInventoryKey) & Environment.NewLine &
"[Chat]=" & GetKeyName(ChatKey) & Environment.NewLine &
"[Special]=" & GetKeyName(SpecialKey) & Environment.NewLine &
"[MuteMusic]=" & GetKeyName(MuteMusicKey) & Environment.NewLine &
"[Up]=" & GetKeyName(UpKey) & Environment.NewLine &
"[Down]=" & GetKeyName(DownKey) & Environment.NewLine &
"[Left]=" & GetKeyName(LeftKey) & Environment.NewLine &
"[Right]=" & GetKeyName(RightKey) & Environment.NewLine &
"[CameraLock]=" & GetKeyName(CameraLockKey) & Environment.NewLine &
"[GUIControl]=" & GetKeyName(GUIControlKey) & Environment.NewLine &
"[ScreenShot]=" & GetKeyName(ScreenshotKey) & Environment.NewLine &
"[DebugControl]=" & GetKeyName(DebugKey) & Environment.NewLine &
"[LightKey]=" & GetKeyName(LightKey) & Environment.NewLine &
"[PerspectiveSwitch]=" & GetKeyName(PerspectiveSwitchKey) & Environment.NewLine &
"[FullScreen]=" & GetKeyName(FullScreenKey) & Environment.NewLine &
"[Enter1]=" & GetKeyName(EnterKey1) & Environment.NewLine &
"[Enter2]=" & GetKeyName(EnterKey2) & Environment.NewLine &
"[Back1]=" & GetKeyName(BackKey1) & Environment.NewLine &
"[Back2]=" & GetKeyName(BackKey2) & Environment.NewLine &
"[Escape]=" & GetKeyName(EscapeKey) & Environment.NewLine &
"[OnlineStatus]=" & GetKeyName(OnlineStatusKey)
IO.File.WriteAllText(GameController.GamePath & "\Save\Keyboard.dat", s)
@ -314,7 +314,7 @@ Public Class KeyBindings
For Each Key As Keys In Keys
If Key = Input.Keys.V And KeyBoardHandler.KeyPressed(Input.Keys.V) = True And (KeyBoardHandler.KeyDown(Input.Keys.LeftControl) = True Or KeyBoardHandler.KeyDown(Input.Keys.RightControl) = True) = True Then
If Windows.Forms.Clipboard.ContainsText() = True Then
Dim t As String = Windows.Forms.Clipboard.GetText().Replace(vbNewLine, " ")
Dim t As String = Windows.Forms.Clipboard.GetText().Replace(Environment.NewLine, " ")
Text &= Windows.Forms.Clipboard.GetText()
End If

View File

@ -81,7 +81,7 @@ Public Class KeyboardInput
'Check for Ctrl+V
If k = Keys.V And KeyBoardHandler.KeyPressed(Keys.V) = True And Controls.CtrlPressed() = True Then
If System.Windows.Forms.Clipboard.ContainsText() = True Then
Dim pasteText As String = System.Windows.Forms.Clipboard.GetText().Replace(vbNewLine, "")
Dim pasteText As String = System.Windows.Forms.Clipboard.GetText().Replace(Environment.NewLine, "")
Me.AppendString(CurrentText, pasteText, CarretPosition)
End If

View File

@ -102,7 +102,7 @@ Module Extensions
Dim s As String = ""
For i = 0 To Array.Length - 1
If i <> 0 Then
s &= vbNewLine
s &= Environment.NewLine
End If
s &= Array(i).ToString()
@ -133,7 +133,7 @@ Module Extensions
<Extension()>
Public Function ToArray(ByVal s As String, ByVal Seperator As String) As String()
Return s.Replace(vbNewLine, Seperator).Split(CChar(Seperator))
Return s.Replace(Environment.NewLine, Seperator).Split(CChar(Seperator))
End Function
<Extension()>
@ -199,7 +199,7 @@ Module Extensions
Dim newText As String = ""
While fulltext.Length > 0
If (font.MeasureString(newText & fulltext(0).ToString()).X * scale) > width Then
newText &= vbNewLine
newText &= Environment.NewLine
newText &= fulltext(0).ToString()
fulltext.Remove(0, 1)
Else
@ -216,12 +216,12 @@ Module Extensions
Dim currentWord As String = ""
While fulltext.Length > 0
If fulltext.StartsWith(vbNewLine) = True Then
If fulltext.StartsWith(Environment.NewLine) = True Then
If currentLine <> "" Then
currentLine &= " "
End If
currentLine &= currentWord
output &= currentLine & vbNewLine
output &= currentLine & Environment.NewLine
currentLine = ""
currentWord = ""
fulltext = fulltext.Remove(0, 2)
@ -236,11 +236,11 @@ Module Extensions
currentWord &= fulltext(0)
If (font.MeasureString(currentLine & currentWord).X * scale) >= width Then
If currentLine = "" Then
output &= currentWord & vbNewLine
output &= currentWord & Environment.NewLine
currentWord = ""
currentLine = ""
Else
output &= currentLine & vbNewLine
output &= currentLine & Environment.NewLine
currentLine = ""
End If
End If
@ -313,7 +313,7 @@ Module Extensions
<Extension()>
Public Function SplitAtNewline(ByVal s As String) As String()
If s.Contains("§") = False Then
Return s.Replace(vbNewLine, "§").Replace(vbLf, "§").Split(CChar("§"))
Return s.Replace(StringHelper.CrLf, "§").Replace(StringHelper.LineFeed, "§").Split(CChar("§"))
Else
Dim Data As New List(Of String)
@ -323,7 +323,7 @@ Module Extensions
Dim i As Integer = 0
While s <> "" And i < s.Length
If s.Substring(i).StartsWith(vbNewLine) = False Or s.Substring(i).StartsWith(vbLf) = False Then
If s.Substring(i).StartsWith(StringHelper.CrLf) = False Or s.Substring(i).StartsWith(StringHelper.LineFeed) = False Then
i += 1
Else
Data.Add(s.Substring(0, i))

View File

@ -199,7 +199,7 @@
If s.Identification = Screen.Identifications.OverworldScreen Then
If testForScript = False Then
CType(s, OverworldScreen).ActionScript.StartScript("version=2" & vbNewLine & text & vbNewLine & ":end", 2, False)
CType(s, OverworldScreen).ActionScript.StartScript("version=2" & Environment.NewLine & text & Environment.NewLine & ":end", 2, False)
End If
Return text

View File

@ -115,7 +115,7 @@ Public Class ChatScreen
End If
If KeyBoardHandler.KeyPressed(Keys.V) = True Then
If System.Windows.Forms.Clipboard.ContainsText() = True Then
Dim t As String = System.Windows.Forms.Clipboard.GetText().Replace(vbNewLine, " ")
Dim t As String = System.Windows.Forms.Clipboard.GetText().Replace(Environment.NewLine, " ")
inputText &= t
End If
@ -512,7 +512,7 @@ Public Class ChatScreen
Dim preIndex As Integer = 0
For Each index As Integer In SplitIndicies
If dispLine <> "" Then
dispLine &= vbNewLine
dispLine &= Environment.NewLine
End If
If index - preIndex > line.Length - preIndex Then
dispLine &= line.Substring(preIndex)
@ -562,7 +562,7 @@ Public Class ChatScreen
Dim preIndex As Integer = 0
For Each index As Integer In SplitIndicies
If dispLine <> "" Then
dispLine &= vbNewLine
dispLine &= Environment.NewLine
End If
If index - preIndex > line.Length - preIndex Then
dispLine &= line.Substring(preIndex)
@ -850,7 +850,7 @@ Public Class ChatScreen
Dim preIndex As Integer = 0
For Each index As Integer In SplitIndicies
If dispLine <> "" Then
dispLine &= vbNewLine
dispLine &= Environment.NewLine
End If
If index - preIndex > line.Length - preIndex Then
dispLine &= line.Substring(preIndex)

View File

@ -25,11 +25,11 @@
''' <param name="data">The data to work with.</param>
Public Shared Function HandleData(ByVal data As String) As List(Of JoltValue)
'Old system:
If data.Contains("data:""" & vbNewLine) = True Then
data = data.Replace("data:""" & vbNewLine, "data:""")
If data.Contains("data:""" & Environment.NewLine) = True Then
data = data.Replace("data:""" & Environment.NewLine, "data:""")
End If
Dim arg() As String = {vbCrLf, vbLf}
Dim arg() As String = {StringHelper.CrLf, StringHelper.LineFeed}
Dim list As List(Of String) = data.Split(arg, StringSplitOptions.None).ToList()
Dim joltList As New List(Of JoltValue)

View File

@ -256,11 +256,11 @@
Core.SpriteBatch.Draw(D.Pokemon.Item.Texture, New Rectangle(882, 314, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & vbNewLine & vbNewLine &
"Gender: " & D.Pokemon.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & vbNewLine & vbNewLine &
"Item: " & ItemString & vbNewLine & vbNewLine &
"Message: " & vbNewLine & D.Message, New Vector2(830, 200), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & D.Pokemon.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString & Environment.NewLine & Environment.NewLine &
"Message: " & Environment.NewLine & D.Message, New Vector2(830, 200), Color.Black)
'Stars:
@ -281,7 +281,7 @@
End If
'To:
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, "To:", New Vector2(516, 360), Color.Black)
Dim ownEmblem As Emblem = New Emblem(API.username, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Points, Core.GameJoltSave.Gender, Core.GameJoltSave.Emblem)

View File

@ -170,9 +170,9 @@
Core.SpriteBatch.Draw(D.Pokemon.Item.Texture, New Rectangle(575, 478, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & vbNewLine & vbNewLine &
"Gender: " & D.Pokemon.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & D.Pokemon.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString, New Vector2(524, 360), Color.Black)
'Stars:
@ -190,9 +190,9 @@
Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 205), Color.Black)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request:" & vbNewLine & vbNewLine &
"Number: " & D.RequestID & vbNewLine & vbNewLine &
"Level: " & D.RequestLevel & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request:" & Environment.NewLine & Environment.NewLine &
"Number: " & D.RequestID & Environment.NewLine & Environment.NewLine &
"Level: " & D.RequestLevel & Environment.NewLine & Environment.NewLine &
"Gender: " & D.RequestGender, New Vector2(824, 360), Color.Black)
'Stars:
@ -372,7 +372,7 @@
Dim Item As API.JoltValue = l(i)
If Item.Name.ToLower() = "key" Then
If BufferList.ContainsKey(Item.Value) = True Then
GotData("success:""true""" & vbNewLine & "data:""" & BufferList(Item.Value) & """")
GotData("success:""true""" & Environment.NewLine & "data:""" & BufferList(Item.Value) & """")
Else
Dim APICall As New APICall(AddressOf GotData)
APICall.GetStorageData(Item.Value, False)
@ -601,7 +601,7 @@
Dim d As List(Of String) = System.IO.Directory.GetFiles(GameController.GamePath & "\Content\Pokemon\Data\").ToList()
For Each file As String In d
Dim fileName As String = System.IO.Path.GetFileNameWithoutExtension(file)
If IsNumeric(fileName) = True Then
If StringHelper.IsNumeric(fileName) = True Then
If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.POKEMONCOUNT Then
If GTSMainScreen.GTSPokemon.Contains(CInt(fileName)) = True Then
fileList.Add(CInt(fileName))

View File

@ -101,11 +101,11 @@
Core.SpriteBatch.Draw(D.Pokemon.Item.Texture, New Rectangle(882, 314, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & vbNewLine & vbNewLine &
"Gender: " & D.Pokemon.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & vbNewLine & vbNewLine &
"Item: " & ItemString & vbNewLine & vbNewLine &
"Message: " & vbNewLine & D.Message, New Vector2(524, 360), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & D.Pokemon.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString & Environment.NewLine & Environment.NewLine &
"Message: " & Environment.NewLine & D.Message, New Vector2(524, 360), Color.Black)
'Stars:
GTSMainScreen.DrawStars(D.Pokemon.TradeValue, New Vector2(630, 256))
@ -122,16 +122,16 @@
Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(930, 205), Color.Black)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request:" & vbNewLine & vbNewLine &
"Number: " & D.RequestID & vbNewLine & vbNewLine &
"Level: " & D.RequestLevel & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request:" & Environment.NewLine & Environment.NewLine &
"Number: " & D.RequestID & Environment.NewLine & Environment.NewLine &
"Level: " & D.RequestLevel & Environment.NewLine & Environment.NewLine &
"Gender: " & D.RequestGender, New Vector2(824, 360), Color.Black)
'Stars:
GTSMainScreen.DrawStars(p.TradeValue, New Vector2(930, 256))
'From:
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, "From:", New Vector2(516, 320), Color.Black)
Dim ownEmblem As Emblem = New Emblem(API.username, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Points, Core.GameJoltSave.Gender, Core.GameJoltSave.Emblem)
@ -330,7 +330,7 @@
For Each Item As API.JoltValue In l
If Item.Name.ToLower() = "key" Then
If BufferList.ContainsKey(Item.Value) = True Then
GotData("success:""true""" & vbNewLine & "data:""" & BufferList(Item.Value) & """")
GotData("success:""true""" & Environment.NewLine & "data:""" & BufferList(Item.Value) & """")
Else
Dim APICall As New APICall(AddressOf GotData)
APICall.GetStorageData(Item.Value, False)
@ -446,9 +446,9 @@
Core.SpriteBatch.Draw(D.Pokemon.Item.Texture, New Rectangle(124, 475, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & vbNewLine & vbNewLine &
"Gender: " & D.Pokemon.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & D.Pokemon.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString, New Vector2(74, 356), Color.Black)
'Stars:
@ -463,7 +463,7 @@
Core.SpriteBatch.DrawString(FontManager.MainFont, "Request:", New Vector2(420, 140), Color.Black)
If IsNumeric(D.RequestID) = True Then
If StringHelper.IsNumeric(D.RequestID) = True Then
DrawFilter(New Vector2(420, 200), 4, "Pokémon:", Pokemon.GetPokemonByID(CInt(D.RequestID)).GetDisplayName() & " (" & D.RequestID & ")")
Else
DrawFilter(New Vector2(420, 200), 4, "Pokémon:", "")
@ -483,7 +483,7 @@
DrawFilter(New Vector2(600, 280), 4, "To (" & D.ToUserID & "):", RecipientName)
End If
If IsNumeric(D.RequestID) = True Then
If StringHelper.IsNumeric(D.RequestID) = True Then
If CInt(D.RequestID) > 0 Then
If TempPokemon Is Nothing OrElse TempPokemon.Number <> CInt(D.RequestID) Then
TempPokemon = Pokemon.GetPokemonByID(CInt(D.RequestID))
@ -532,7 +532,7 @@
If NewTrade = True Then
If IsPresent() = True Then
If Not ToEmblem Is Nothing And Not D.Pokemon Is Nothing Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You will send " & D.Pokemon.GetDisplayName() & " to " & vbNewLine & ToEmblem.Username & " and you cannot get it back!", New Vector2(480, 495), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You will send " & D.Pokemon.GetDisplayName() & " to " & Environment.NewLine & ToEmblem.Username & " and you cannot get it back!", New Vector2(480, 495), Color.Black)
End If
DrawButton(New Vector2(480, 540), "Send", 3)
Else
@ -879,7 +879,7 @@
Dim d As List(Of String) = System.IO.Directory.GetFiles(GameController.GamePath & "\Content\Pokemon\Data\").ToList()
For Each file As String In d
Dim fileName As String = System.IO.Path.GetFileNameWithoutExtension(file)
If IsNumeric(fileName) = True Then
If StringHelper.IsNumeric(fileName) = True Then
If CInt(fileName) > 0 And CInt(fileName) <= Pokedex.POKEMONCOUNT Then
If GTSMainScreen.GTSPokemon.Contains(CInt(fileName)) = True Then
fileList.Add(CInt(fileName))

View File

@ -104,7 +104,7 @@
Canvas.DrawRectangle(New Rectangle(100 + OwnX, 160, 400, 450), New Color(255, 255, 255, 150))
'User:
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
Dim ownEmblem As Emblem = New Emblem(API.username, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Points, Core.GameJoltSave.Gender, Core.GameJoltSave.Emblem)
Dim SpriteSize As New Size(CInt(ownEmblem.SpriteTexture.Width / 3), CInt(ownEmblem.SpriteTexture.Height / 4))
@ -142,9 +142,9 @@
Core.SpriteBatch.Draw(P.Item.Texture, New Rectangle(202 + OwnX, 474, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & P.Level & vbNewLine & vbNewLine &
"Gender: " & P.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & P.CatchTrainerName & "/" & P.OT & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & P.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & P.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & P.CatchTrainerName & "/" & P.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString, New Vector2(150 + OwnX, 360), Color.Black)
DrawButton(New Vector2(180, 520), "Clear", 5)
@ -154,7 +154,7 @@
GenderString = D.RequestGender
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request Level: " & D.RequestLevel & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Request Level: " & D.RequestLevel & Environment.NewLine & Environment.NewLine &
"Request Gender: " & GenderString, New Vector2(150 + OwnX, 360), Color.Black)
End If
@ -198,9 +198,9 @@
Core.SpriteBatch.Draw(D.Pokemon.Item.Texture, New Rectangle(202 + OppX, 474, 24, 24), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & vbNewLine & vbNewLine &
"Gender: " & D.Pokemon.Gender.ToString() & vbNewLine & vbNewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & vbNewLine & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Level: " & D.Pokemon.Level & Environment.NewLine & Environment.NewLine &
"Gender: " & D.Pokemon.Gender.ToString() & Environment.NewLine & Environment.NewLine &
"OT: " & D.Pokemon.CatchTrainerName & "/" & D.Pokemon.OT & Environment.NewLine & Environment.NewLine &
"Item: " & ItemString, New Vector2(150 + OppX, 360), Color.Black)
@ -222,15 +222,15 @@
If v > 0 Then
Canvas.DrawRectangle(New Rectangle(540, 430, 120, 120), New Color(255, 255, 255, 150))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You get" & vbNewLine & "stars:", New Vector2(560, 435), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You get" & Environment.NewLine & "stars:", New Vector2(560, 435), Color.Black)
GTSMainScreen.DrawStars(v, New Vector2(560, 480))
End If
Else
If PokeIndex > -1 Then
Dim t As String = "Your chosen Pokémon does not match the" & vbNewLine & "conditions given by your trade partner."
Dim t As String = "Your chosen Pokémon does not match the" & Environment.NewLine & "conditions given by your trade partner."
If Core.Player.Pokemons(PokeIndex).HasHMMove() = True Then
t = "This Pokémon knows an HM move." & vbNewLine & "You can't trade this Pokémon."
t = "This Pokémon knows an HM move." & Environment.NewLine & "You can't trade this Pokémon."
End If
If Core.Player.Pokemons(PokeIndex).IsEgg() = True Then
t = "You can't trade an egg."

View File

@ -74,7 +74,7 @@
Private Sub GotTradeID(ByVal result As String)
Dim list As List(Of API.JoltValue) = API.HandleData(result)
If IsNumeric(list(1).Value) = True Then
If StringHelper.IsNumeric(list(1).Value) = True Then
Me.WonderTradeID = CInt(list(1).Value)
Me.PartnerEmblem = New Emblem(GameJoltID, 0)
Else
@ -88,9 +88,9 @@
Select Case Me.ScreenState
Case ScreenStates.Choose
Dim t As String = "With Wonder Trade, you trade your" & vbNewLine &
"Pokémon instantly with a random one" & vbNewLine &
"from anyone anywhere in the world!" & vbNewLine & vbNewLine &
Dim t As String = "With Wonder Trade, you trade your" & Environment.NewLine &
"Pokémon instantly with a random one" & Environment.NewLine &
"from anyone anywhere in the world!" & Environment.NewLine & Environment.NewLine &
"Do you want to do a Wonder Trade?"
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - 300), 150, 600, 200), New Color(135, 168, 20, 100))
@ -338,7 +338,7 @@
Case 1
Core.SpriteBatch.Draw(Me.SelectedPokemon.GetTexture(False), New Rectangle(CInt(Core.windowSize.Width / 2 - 128), CInt(Core.windowSize.Height / 2 - 128), 256, 256), Color.White)
Dim t As String = "Sending " & Me.SelectedPokemon.GetDisplayName() & " to Wondertrade." & vbNewLine & "Good-bye, " & Me.SelectedPokemon.GetDisplayName() & "!"
Dim t As String = "Sending " & Me.SelectedPokemon.GetDisplayName() & " to Wondertrade." & Environment.NewLine & "Good-bye, " & Me.SelectedPokemon.GetDisplayName() & "!"
Core.SpriteBatch.DrawString(FontManager.MainFont, t, New Vector2(CInt(Core.windowSize.Width / 2 - FontManager.MainFont.MeasureString(t).X / 2), CInt(Core.windowSize.Height / 2 + 130)), Color.White)
Case 2

View File

@ -32,7 +32,7 @@
If IndicedStats.Contains(statName.ToLower()) = False Then
If statName.ToLower() = "steps taken" Then
TempSteps += 1
If DateDiff(DateInterval.Second, lastStepTime, Date.Now) >= 20 Then
If (Date.Now - lastStepTime).Seconds >= 20 Then
lastStepTime = Date.Now
Return True
End If

View File

@ -86,7 +86,7 @@ Namespace GameJolt
Dim cUsername As String = Encryption.EncryptString(UserName.Text, "") 'CLASSIFIED
Dim cToken As String = Encryption.EncryptString(Token.Text, "") 'CLASSIFIED
System.IO.File.WriteAllText(GameController.GamePath & "\Save\gamejoltAcc.dat", cUsername & vbNewLine & cToken)
System.IO.File.WriteAllText(GameController.GamePath & "\Save\gamejoltAcc.dat", cUsername & Environment.NewLine & cToken)
End If
End Sub
@ -337,7 +337,7 @@ Namespace GameJolt
WaitingForResponse = True
GameJolt.API.LoggedIn = False
WaitingMessage = "The version of your game does not match with" & vbNewLine & "the version required to play online. If you have" & vbNewLine & "the lastest version of the game, the game is" & vbNewLine & "getting updated right now." & vbNewLine & vbNewLine & vbNewLine & "Your version: " & GameController.GAMEVERSION & vbNewLine & "Required version: " & list(1).Value
WaitingMessage = "The version of your game does not match with" & Environment.NewLine & "the version required to play online. If you have" & Environment.NewLine & "the lastest version of the game, the game is" & Environment.NewLine & "getting updated right now." & Environment.NewLine & Environment.NewLine & Environment.NewLine & "Your version: " & GameController.GAMEVERSION & Environment.NewLine & "Required version: " & list(1).Value
ShowokButton = True
LogInButton.Text = "Log in"
@ -356,7 +356,7 @@ Namespace GameJolt
WaitingForResponse = True
GameJolt.API.LoggedIn = False
WaitingMessage = "Cannot connect to account!" & vbNewLine & "You have to use your Token," & vbNewLine & "not your Password."
WaitingMessage = "Cannot connect to account!" & Environment.NewLine & "You have to use your Token," & Environment.NewLine & "not your Password."
ShowokButton = True
LogInButton.Text = "Log in"

View File

@ -131,14 +131,14 @@
Private Sub DrawMainMenu()
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - 400), 100, 800, 240), New Color(177, 228, 247, 200))
Dim t As String = "Battle Spot allows you to battle against the registered teams of" & vbNewLine & "other players. These battles will be held against the computer."
Dim t As String = "Battle Spot allows you to battle against the registered teams of" & Environment.NewLine & "other players. These battles will be held against the computer."
Select Case Me.MainCursor
Case 0
t &= vbNewLine & vbNewLine & "The Team Management gives you the option to set up your own" & vbNewLine & "team others can battle against."
t &= Environment.NewLine & Environment.NewLine & "The Team Management gives you the option to set up your own" & Environment.NewLine & "team others can battle against."
Case 1
t &= vbNewLine & vbNewLine & "Start a battle against a random team registered by another player." & vbNewLine & "You have to register your own team first."
t &= Environment.NewLine & Environment.NewLine & "Start a battle against a random team registered by another player." & Environment.NewLine & "You have to register your own team first."
Case 2
t &= vbNewLine & vbNewLine & "Quit the Battle Spot."
t &= Environment.NewLine & Environment.NewLine & "Quit the Battle Spot."
End Select
Core.SpriteBatch.DrawString(FontManager.MainFont, t, New Vector2(CSng(Core.windowSize.Width / 2 - FontManager.MainFont.MeasureString(t).X / 2), 220 - FontManager.MainFont.MeasureString(t).Y / 2), Color.Black)
@ -218,7 +218,7 @@
Private Sub DrawTeamRegistration()
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - 400), 100, 800, 240), New Color(177, 228, 247, 200))
Dim t As String = "When you register your team, the game will store a copy of your" & vbNewLine & "Pokémon online so that other players can download that team and" & vbNewLine & "battle against it." & vbNewLine & vbNewLine & "If you register a new team, the old one will be overwritten with" & vbNewLine & "the new one."
Dim t As String = "When you register your team, the game will store a copy of your" & Environment.NewLine & "Pokémon online so that other players can download that team and" & Environment.NewLine & "battle against it." & Environment.NewLine & Environment.NewLine & "If you register a new team, the old one will be overwritten with" & Environment.NewLine & "the new one."
Core.SpriteBatch.DrawString(FontManager.MainFont, t, New Vector2(CSng(Core.windowSize.Width / 2 - FontManager.MainFont.MeasureString(t).X / 2), 180 - FontManager.MainFont.MeasureString(t).Y / 2), Color.Black)
@ -316,7 +316,7 @@
For Each p As Pokemon In Core.Player.Pokemons
If p.IsEgg() = False Then
If storageData <> "" Then
storageData &= vbNewLine
storageData &= Environment.NewLine
End If
storageData &= p.GetSaveData()
End If

View File

@ -28,7 +28,7 @@
End Sub
Shared Sub Ping()
Dim diff As Integer = CInt(DateDiff(DateInterval.Second, LastPing, Date.Now))
Dim diff As Integer = (Date.Now - LastPing).Seconds
If diff >= 30 Then
Logger.Debug("Ping session...")
@ -101,7 +101,7 @@
API.LoggedIn = False
SessionStarted = False
Status = "Idle"
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
ConnectScreen.Setup(New ConnectScreen(ConnectScreen.Modes.Disconnect, "Disconnected", "The GameJolt server doesn't respond.", Core.CurrentScreen))
End If
End If

View File

@ -112,18 +112,18 @@
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(50, 150), Color.White)
Else
If Me.failedDownload = True Then
Dim t As String = "Failed to download Mystery Event data." & vbNewLine & "Please check your internet connection and try again."
Dim t As String = "Failed to download Mystery Event data." & Environment.NewLine & "Please check your internet connection and try again."
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(52, 152), Color.Black)
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(50, 150), Color.White)
Else
If EventData.Count = 0 Then
Dim t As String = "There are no Mystery Events available" & vbNewLine & "at the moment. Please try again later."
Dim t As String = "There are no Mystery Events available" & Environment.NewLine & "at the moment. Please try again later."
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(52, 152), Color.Black)
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(50, 150), Color.White)
Else
Dim t As String = "Please select the Mystery Events that" & vbNewLine & "you want to activate for your gameplay session:"
Dim t As String = "Please select the Mystery Events that" & Environment.NewLine & "you want to activate for your gameplay session:"
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(52, 152), Color.Black)
Core.SpriteBatch.DrawString(FontManager.InGameFont, t, New Vector2(50, 150), Color.White)
@ -153,16 +153,16 @@
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\GTS"), New Rectangle(58, startY + i * 100 + 13, 32, 32), New Rectangle(384, 96, 16, 16), Color.White)
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, cEvent.EventType.ToString() & ": " & cEvent.Name & vbNewLine & activated, New Vector2(100, startY + i * 100 + 8), textColor)
Core.SpriteBatch.DrawString(FontManager.MiniFont, cEvent.EventType.ToString() & ": " & cEvent.Name & Environment.NewLine & activated, New Vector2(100, startY + i * 100 + 8), textColor)
Next
Canvas.DrawGradient(New Rectangle(500, startY, 400, 300), Color.White, Color.Gray, False, -1)
Dim sEvent As MysteryEvent = EventData(cursor)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Name: " & sEvent.Name & vbNewLine & vbNewLine &
"Type: " & sEvent.EventType.ToString() & vbNewLine & vbNewLine &
"Multiplicator: " & sEvent.Value & "x" & vbNewLine & vbNewLine &
"Description:" & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Name: " & sEvent.Name & Environment.NewLine & Environment.NewLine &
"Type: " & sEvent.EventType.ToString() & Environment.NewLine & Environment.NewLine &
"Multiplicator: " & sEvent.Value & "x" & Environment.NewLine & Environment.NewLine &
"Description:" & Environment.NewLine &
sEvent.Description.CropStringToWidth(FontManager.MiniFont, 300), New Vector2(512, startY + 12), Color.Black)
End If
End If

View File

@ -181,9 +181,9 @@
Core.SpriteBatch.Draw(PlayerTexture, New Rectangle(CInt(Position.X), CInt(Position.Y), CInt(32 * Scale), CInt(32 * Scale)), New Rectangle(0, frameSize.Height * 2, frameSize.Width, frameSize.Height), Color.White)
If PokemonList Is Nothing OrElse PokemonList.Count = 0 Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, PlayerName & vbNewLine & PlayerTitle & vbNewLine & vbNewLine & "Level: " & PlayerLevel & vbNewLine & "(Points: " & PlayerPoints & ")", New Vector2(32 * Scale + 10 + Position.X, 10 + Position.Y), EmblemFontColor, 0.0F, Vector2.Zero, CSng(Scale / 4), SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MiniFont, PlayerName & Environment.NewLine & PlayerTitle & Environment.NewLine & Environment.NewLine & "Level: " & PlayerLevel & Environment.NewLine & "(Points: " & PlayerPoints & ")", New Vector2(32 * Scale + 10 + Position.X, 10 + Position.Y), EmblemFontColor, 0.0F, Vector2.Zero, CSng(Scale / 4), SpriteEffects.None, 0.0F)
Else
Core.SpriteBatch.DrawString(FontManager.MiniFont, PlayerName & vbNewLine & PlayerTitle & vbNewLine & "Level: " & PlayerLevel & vbNewLine & "(Points: " & PlayerPoints & ")", New Vector2(32 * Scale + 10 + Position.X, 6 + Position.Y), EmblemFontColor, 0.0F, Vector2.Zero, CSng(Scale / 4), SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MiniFont, PlayerName & Environment.NewLine & PlayerTitle & Environment.NewLine & "Level: " & PlayerLevel & Environment.NewLine & "(Points: " & PlayerPoints & ")", New Vector2(32 * Scale + 10 + Position.X, 6 + Position.Y), EmblemFontColor, 0.0F, Vector2.Zero, CSng(Scale / 4), SpriteEffects.None, 0.0F)
For i = 0 To 5
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(192, 0, 32, 32), ""), New Rectangle(CInt(32 * Scale + (10 / 4) * Scale + Position.X + i * (10 * Scale)), CInt(Position.Y + 22.5F * Scale), CInt(Scale * 8), CInt(Scale * 8)), Color.White)
@ -410,7 +410,7 @@
Public Sub StartLoading(ByVal userName As String)
Dim APICall As New APICall(AddressOf GotGameJoltID)
APICall.FetchUserdata(Username)
APICall.FetchUserdata(userName)
Me.Username = userName
Me.startedLoading = True
@ -452,7 +452,7 @@
GotPublicKeys(PublicKeys)
Else
Dim APICall As New APICall(AddressOf GotPublicKeys)
APICall.GetKeys(False, "saveStorageV" & GameJolt.GamejoltSave.Version & "|" & GameJoltID & "|*")
APICall.GetKeys(False, "saveStorageV" & GameJolt.GamejoltSave.VERSION & "|" & GameJoltID & "|*")
End If
Dim APICall1 As New APICall(AddressOf GotOnlineTeamKey)
@ -477,21 +477,21 @@
Dim exists(3) As Boolean
For Each Item As API.JoltValue In list
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.Version & "|" & GameJoltID & "|points" Then
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.VERSION & "|" & GameJoltID & "|points" Then
If exists(0) = False Then
Dim APICall As New APICall(AddressOf GetPlayerPoints)
APICall.GetStorageData(Item.Value, False)
exists(0) = True
End If
End If
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.Version & "|" & GameJoltID & "|emblem" Then
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.VERSION & "|" & GameJoltID & "|emblem" Then
If exists(1) = False Then
Dim APICall As New APICall(AddressOf GetPlayerEmblem)
APICall.GetStorageData(Item.Value, False)
exists(1) = True
End If
End If
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.Version & "|" & GameJoltID & "|gender" Then
If Item.Value = "saveStorageV" & GameJolt.GamejoltSave.VERSION & "|" & GameJoltID & "|gender" Then
If exists(2) = False Then
Dim APICall As New APICall(AddressOf GetPlayerGender)
APICall.GetStorageData(Item.Value, False)
@ -873,7 +873,7 @@
End Sub
Public Shared Sub AchieveEmblem(ByVal emblem As String)
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
If Core.GameJoltSave.AchievedEmblems.Contains(emblem.ToLower()) = False Then
Dim trophy_id As Integer = EmblemToTrophyID(emblem)

View File

@ -912,44 +912,44 @@ Namespace GameJolt
ot = "0" & ot
End While
Dim s As String = "Name|" & GameJolt.API.username & vbNewLine &
"Position|1,0.1,3" & vbNewLine &
"MapFile|yourroom.dat" & vbNewLine &
"Rotation|1.570796" & vbNewLine &
"RivalName|???" & vbNewLine &
"Money|3000" & vbNewLine &
"Badges|0" & vbNewLine &
"Gender|Male" & vbNewLine &
"PlayTime|0,0,0,0" & vbNewLine &
"OT|" & ot & vbNewLine &
"Points|0" & vbNewLine &
"hasPokedex|0" & vbNewLine &
"hasPokegear|0" & vbNewLine &
"freeCamera|1" & vbNewLine &
"thirdPerson|0" & vbNewLine &
"skin|" & GameJolt.Emblem.GetPlayerSpriteFile(1, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Gender) & vbNewLine &
"location|Your Room" & vbNewLine &
"battleAnimations|2" & vbNewLine &
"BoxAmount|5" & vbNewLine &
"LastRestPlace|yourroom.dat" & vbNewLine &
"LastRestPlacePosition|1,0.1,3" & vbNewLine &
"DiagonalMovement|0" & vbNewLine &
"RepelSteps|0" & vbNewLine &
"LastSavePlace|yourroom.dat" & vbNewLine &
"LastSavePlacePosition|1,0.1,3" & vbNewLine &
"Difficulty|" & GameModeManager.GetGameRuleValue("Difficulty", "0") & vbNewLine &
"BattleStyle|0" & vbNewLine &
"saveCreated|" & GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION & vbNewLine &
"LastPokemonPosition|999,999,999" & vbNewLine &
"DaycareSteps|0" & vbNewLine &
"GameMode|Kolben" & vbNewLine &
"PokeFiles|" & vbNewLine &
"VisitedMaps|yourroom.dat" & vbNewLine &
"TempSurfSkin|Hilbert" & vbNewLine &
"Surfing|0" & vbNewLine &
"ShowModels|1" & vbNewLine &
"GTSStars|4" & vbNewLine &
"SandBoxMode|0" & vbNewLine &
Dim s As String = "Name|" & GameJolt.API.username & Environment.NewLine &
"Position|1,0.1,3" & Environment.NewLine &
"MapFile|yourroom.dat" & Environment.NewLine &
"Rotation|1.570796" & Environment.NewLine &
"RivalName|???" & Environment.NewLine &
"Money|3000" & Environment.NewLine &
"Badges|0" & Environment.NewLine &
"Gender|Male" & Environment.NewLine &
"PlayTime|0,0,0,0" & Environment.NewLine &
"OT|" & ot & Environment.NewLine &
"Points|0" & Environment.NewLine &
"hasPokedex|0" & Environment.NewLine &
"hasPokegear|0" & Environment.NewLine &
"freeCamera|1" & Environment.NewLine &
"thirdPerson|0" & Environment.NewLine &
"skin|" & GameJolt.Emblem.GetPlayerSpriteFile(1, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Gender) & Environment.NewLine &
"location|Your Room" & Environment.NewLine &
"battleAnimations|2" & Environment.NewLine &
"BoxAmount|5" & Environment.NewLine &
"LastRestPlace|yourroom.dat" & Environment.NewLine &
"LastRestPlacePosition|1,0.1,3" & Environment.NewLine &
"DiagonalMovement|0" & Environment.NewLine &
"RepelSteps|0" & Environment.NewLine &
"LastSavePlace|yourroom.dat" & Environment.NewLine &
"LastSavePlacePosition|1,0.1,3" & Environment.NewLine &
"Difficulty|" & GameModeManager.GetGameRuleValue("Difficulty", "0") & Environment.NewLine &
"BattleStyle|0" & Environment.NewLine &
"saveCreated|" & GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION & Environment.NewLine &
"LastPokemonPosition|999,999,999" & Environment.NewLine &
"DaycareSteps|0" & Environment.NewLine &
"GameMode|Kolben" & Environment.NewLine &
"PokeFiles|" & Environment.NewLine &
"VisitedMaps|yourroom.dat" & Environment.NewLine &
"TempSurfSkin|Hilbert" & Environment.NewLine &
"Surfing|0" & Environment.NewLine &
"ShowModels|1" & Environment.NewLine &
"GTSStars|4" & Environment.NewLine &
"SandBoxMode|0" & Environment.NewLine &
"EarnedAchievements|"
Return s
@ -981,39 +981,39 @@ Namespace GameJolt
End Sub
Public Shared Function GetOptionsData() As String
Dim s As String = "FOV|50" & vbNewLine &
"TextSpeed|2" & vbNewLine &
Dim s As String = "FOV|50" & Environment.NewLine &
"TextSpeed|2" & Environment.NewLine &
"MouseSpeed|12"
Return s
End Function
Public Shared Function GetBerryData() As String
Dim s As String = "{route29.dat|13,0,5|6|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route29.dat|14,0,5|6|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route29.dat|15,0,5|6|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{azalea.dat|9,0,3|0|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{azalea.dat|9,0,4|1|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{azalea.dat|9,0,5|0|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route30.dat|7,0,41|10|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route30.dat|14,0,5|2|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route30.dat|15,0,5|6|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route30.dat|16,0,5|2|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{routes\route35.dat|0,0,4|7|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{routes\route35.dat|1,0,4|8|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route36.dat|37,0,7|0|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route36.dat|38,0,7|4|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route36.dat|39,0,7|3|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route39.dat|8,0,2|9|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route39.dat|8,0,3|6|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route38.dat|13,0,12|16|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route38.dat|14,0,12|23|1|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{route38.dat|15,0,12|16|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{routes\route43.dat|13,0,45|23|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{routes\route43.dat|13,0,46|24|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{routes\route43.dat|13,0,47|25|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{safarizone\main.dat|3,0,11|5|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
"{safarizone\main.dat|4,0,11|0|2|0|2012,9,21,4,0,0|1}" & vbNewLine &
Dim s As String = "{route29.dat|13,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route29.dat|14,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route29.dat|15,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{azalea.dat|9,0,3|0|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{azalea.dat|9,0,4|1|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{azalea.dat|9,0,5|0|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route30.dat|7,0,41|10|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route30.dat|14,0,5|2|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route30.dat|15,0,5|6|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route30.dat|16,0,5|2|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{routes\route35.dat|0,0,4|7|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{routes\route35.dat|1,0,4|8|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route36.dat|37,0,7|0|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route36.dat|38,0,7|4|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route36.dat|39,0,7|3|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route39.dat|8,0,2|9|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route39.dat|8,0,3|6|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route38.dat|13,0,12|16|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route38.dat|14,0,12|23|1|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{route38.dat|15,0,12|16|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{routes\route43.dat|13,0,45|23|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{routes\route43.dat|13,0,46|24|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{routes\route43.dat|13,0,47|25|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{safarizone\main.dat|3,0,11|5|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{safarizone\main.dat|4,0,11|0|2|0|2012,9,21,4,0,0|1}" & Environment.NewLine &
"{safarizone\main.dat|5,0,11|6|3|0|2012,9,21,4,0,0|1}"
Return s

View File

@ -60,8 +60,8 @@
Private Sub DownloadOnlineSprite()
Dim p As Servers.Player = Core.ServersManager.PlayerCollection.GetPlayer(PartnerNetworkID)
If Not p Is Nothing Then
If p.GamejoltID <> "" Then
GameJolt.Emblem.GetOnlineSprite(p.GamejoltID)
If p.GameJoltId <> "" Then
GameJolt.Emblem.GetOnlineSprite(p.GameJoltId)
End If
End If
End Sub
@ -104,17 +104,17 @@
itemString = OfferPokemon.Item.Name
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, OfferPokemon.GetDisplayName() & vbNewLine & "Level: " & OfferPokemon.Level & vbNewLine & "OT: " & OfferPokemon.OT & " / " & OfferPokemon.CatchTrainerName & vbNewLine & "Item: " & itemString, New Vector2(114, 414), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, OfferPokemon.GetDisplayName() & Environment.NewLine & "Level: " & OfferPokemon.Level & Environment.NewLine & "OT: " & OfferPokemon.OT & " / " & OfferPokemon.CatchTrainerName & Environment.NewLine & "Item: " & itemString, New Vector2(114, 414), Color.Black)
End If
'Menu:
If ReceivedTradeOffer = True Then
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2), 100, 64 * 4, 64), New Color(255, 255, 255, 150))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Your trade partner" & vbNewLine & "accepts this trade.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Your trade partner" & Environment.NewLine & "accepts this trade.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Else
If SentTradeOffer = True Then
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2), 100, 64 * 4, 64), New Color(255, 255, 255, 150))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You accepted" & vbNewLine & "this trade.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You accepted" & Environment.NewLine & "this trade.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
End If
End If
@ -173,7 +173,7 @@
itemString = TradePokemon.Item.Name
End If
Core.SpriteBatch.DrawString(FontManager.MiniFont, TradePokemon.GetDisplayName() & vbNewLine & "Level: " & TradePokemon.Level & vbNewLine & "OT: " & TradePokemon.OT & " / " & TradePokemon.CatchTrainerName & vbNewLine & "Item: " & itemString, New Vector2(CInt(Core.windowSize.Width - 356) + 14, 414), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, TradePokemon.GetDisplayName() & Environment.NewLine & "Level: " & TradePokemon.Level & Environment.NewLine & "OT: " & TradePokemon.OT & " / " & TradePokemon.CatchTrainerName & Environment.NewLine & "Item: " & itemString, New Vector2(CInt(Core.windowSize.Width - 356) + 14, 414), Color.Black)
End If
End Sub
@ -216,11 +216,11 @@
End If
Next
If partnerOnServer = False Then
DisconnectMessage = "The other player disconnected." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "The other player disconnected." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
ScreenState = ScreenStates.Stopped
End If
Else
DisconnectMessage = "You got disconnected from the server." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "You got disconnected from the server." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
ScreenState = ScreenStates.Stopped
End If
End If
@ -346,7 +346,7 @@
Public Shared Sub OtherPlayerQuits()
If IsTradeScreen() = True Then
ScreenState = ScreenStates.Stopped
DisconnectMessage = "The other player quit the trade." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "The other player quit the trade." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
End If
End Sub
@ -431,7 +431,7 @@
End If
Next
Dim t As String = "Sending " & OfferPokemon.GetDisplayName() & " to " & p.Name & "." & vbNewLine & "Good-bye, " & OfferPokemon.GetDisplayName() & "!"
Dim t As String = "Sending " & OfferPokemon.GetDisplayName() & " to " & p.Name & "." & Environment.NewLine & "Good-bye, " & OfferPokemon.GetDisplayName() & "!"
Core.SpriteBatch.DrawString(FontManager.MainFont, t, New Vector2(CInt(Core.windowSize.Width / 2 - FontManager.MainFont.MeasureString(t).X / 2), CInt(Core.windowSize.Height / 2 + 130)), Color.White)
Case 2

View File

@ -73,8 +73,8 @@
Private Sub DownloadOnlineSprite()
Dim p As Servers.Player = Core.ServersManager.PlayerCollection.GetPlayer(PartnerNetworkID)
If Not p Is Nothing Then
If p.GamejoltID <> "" Then
GameJolt.Emblem.GetOnlineSprite(p.GamejoltID)
If p.GameJoltId <> "" Then
GameJolt.Emblem.GetOnlineSprite(p.GameJoltId)
End If
End If
End Sub
@ -120,11 +120,11 @@
End If
Next
If partnerOnServer = False Then
DisconnectMessage = "The other player disconnected." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "The other player disconnected." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
ScreenState = ScreenStates.Stopped
End If
Else
DisconnectMessage = "You got disconnected from the server." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "You got disconnected from the server." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
ScreenState = ScreenStates.Stopped
End If
End If
@ -167,11 +167,11 @@
'Menu:
If ReceivedBattleOffer = True Then
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2), 100, 64 * 4, 64), New Color(255, 255, 255, 150))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Your opponent wants to" & vbNewLine & "battle with this setup.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Your opponent wants to" & Environment.NewLine & "battle with this setup.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Else
If SentBattleOffer = True Then
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2), 100, 64 * 4, 64), New Color(255, 255, 255, 150))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You want to battle" & vbNewLine & "with this setup.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You want to battle" & Environment.NewLine & "with this setup.", New Vector2(CInt(Core.windowSize.Width / 2 - (64 * 4) / 2) + 4, 104), Color.Black)
End If
End If
@ -487,7 +487,7 @@
Public Shared Sub OtherPlayerQuits()
If IsLobbyScreen() = True Then
ScreenState = ScreenStates.Stopped
DisconnectMessage = "The other player quit the battle." & vbNewLine & vbNewLine & "Press any key to exit."
DisconnectMessage = "The other player quit the battle." & Environment.NewLine & Environment.NewLine & "Press any key to exit."
End If
End Sub
@ -580,7 +580,7 @@
t.Gender = 0
t.IntroType = 11
t.OutroMessage = ". . ."
t.GameJoltID = tempPlayer.GamejoltID
t.GameJoltID = tempPlayer.GameJoltId
For Each p As Pokemon In t.Pokemons
p.Level = 50
@ -610,8 +610,8 @@
b.IsRemoteBattle = True
b.PartnerNetworkID = PartnerNetworkID
If tempPlayer.GamejoltID <> "" Then
b.PVPGameJoltID = tempPlayer.GamejoltID
If tempPlayer.GameJoltId <> "" Then
b.PVPGameJoltID = tempPlayer.GameJoltId
End If
Core.SetScreen(New BattleIntroScreen(Core.CurrentScreen, b, t, t.GetIniMusicName(), t.IntroType))
@ -718,19 +718,19 @@
'Draw Own Statistics:
With BattleResults.OwnStatistics
Dim s1 As String = "Turns:" & vbNewLine &
" Moves:" & vbNewLine &
" Switches:" & vbNewLine & vbNewLine &
"Super Effective:" & vbNewLine &
"Not very Effective:" & vbNewLine &
"No Effect:" & vbNewLine & vbNewLine &
Dim s1 As String = "Turns:" & Environment.NewLine &
" Moves:" & Environment.NewLine &
" Switches:" & Environment.NewLine & Environment.NewLine &
"Super Effective:" & Environment.NewLine &
"Not very Effective:" & Environment.NewLine &
"No Effect:" & Environment.NewLine & Environment.NewLine &
"Critical Hits:"
Dim s2 As String = .Turns & vbNewLine &
.Moves & vbNewLine &
.Switches & vbNewLine & vbNewLine &
.SuperEffective & vbNewLine &
.NotVeryEffective & vbNewLine &
.NoEffect & vbNewLine & vbNewLine &
Dim s2 As String = .Turns & Environment.NewLine &
.Moves & Environment.NewLine &
.Switches & Environment.NewLine & Environment.NewLine &
.SuperEffective & Environment.NewLine &
.NotVeryEffective & Environment.NewLine &
.NoEffect & Environment.NewLine & Environment.NewLine &
.Critical
Core.SpriteBatch.DrawString(FontManager.MiniFont, s1, New Vector2(40, 340), Color.White, 0.0F, Vector2.Zero, 1.1F, SpriteEffects.None, 0.0F)
@ -793,19 +793,19 @@
'Draw Opp Statistics:
With BattleResults.OppStatistics
Dim s1 As String = "Turns:" & vbNewLine &
" Moves:" & vbNewLine &
" Switches:" & vbNewLine & vbNewLine &
"Super Effective:" & vbNewLine &
"Not very Effective:" & vbNewLine &
"No Effect:" & vbNewLine & vbNewLine &
Dim s1 As String = "Turns:" & Environment.NewLine &
" Moves:" & Environment.NewLine &
" Switches:" & Environment.NewLine & Environment.NewLine &
"Super Effective:" & Environment.NewLine &
"Not very Effective:" & Environment.NewLine &
"No Effect:" & Environment.NewLine & Environment.NewLine &
"Critical Hits:"
Dim s2 As String = .Turns & vbNewLine &
.Moves & vbNewLine &
.Switches & vbNewLine & vbNewLine &
.SuperEffective & vbNewLine &
.NotVeryEffective & vbNewLine &
.NoEffect & vbNewLine & vbNewLine &
Dim s2 As String = .Turns & Environment.NewLine &
.Moves & Environment.NewLine &
.Switches & Environment.NewLine & Environment.NewLine &
.SuperEffective & Environment.NewLine &
.NotVeryEffective & Environment.NewLine &
.NoEffect & Environment.NewLine & Environment.NewLine &
.Critical
Core.SpriteBatch.DrawString(FontManager.MiniFont, s1, New Vector2(Core.windowSize.Width - 360, 340), Color.White, 0.0F, Vector2.Zero, 1.1F, SpriteEffects.None, 0.0F)

View File

@ -163,7 +163,7 @@
Me._protocolVersion = bits(0)
'Get second part, set PackageType:
If IsNumeric(bits(1)) = True Then
If StringHelper.IsNumeric(bits(1)) Then
Me._packageType = CType(CInt(bits(1)), PackageTypes)
Else
Me._isValid = False
@ -171,7 +171,7 @@
End If
'Get third part, set Origin:
If IsNumeric(bits(2)) = True Then
If StringHelper.IsNumeric(bits(2)) Then
Me._origin = CInt(bits(2))
Else
Me._isValid = False
@ -180,7 +180,7 @@
'Get data items count:
Dim dataItemsCount As Integer = 0
If IsNumeric(bits(3)) = True Then
If StringHelper.IsNumeric(bits(3)) Then
dataItemsCount = CInt(bits(3))
Else
Me._isValid = False
@ -191,7 +191,7 @@
'Count from 4th item to second last item. Those are the offsets.
For i = 4 To dataItemsCount - 1 + 4
If IsNumeric(bits(i)) = True Then
If StringHelper.IsNumeric(bits(i)) Then
OffsetList.Add(CInt(bits(i)))
Else
Me._isValid = False

View File

@ -70,7 +70,7 @@
Dim Player As Player = Core.ServersManager.PlayerCollection.GetPlayer(p.Origin)
If Not Player Is Nothing Then
GameJoltID = Player.GameJoltID
GameJoltID = Player.GameJoltId
End If
Chat.AddLine(New Chat.ChatMessage(Core.ServersManager.PlayerCollection.GetPlayerName(p.Origin), p.DataItems(0), GameJoltID, Chat.ChatMessage.MessageTypes.GlobalMessage))
@ -108,7 +108,7 @@
End Sub
Private Shared Sub HandleKicked(ByVal p As Package)
Core.ServersManager.ServerConnection.Disconnect("You got kicked!", "Reason: " & vbNewLine & p.DataItems(0))
Core.ServersManager.ServerConnection.Disconnect("You got kicked!", "Reason: " & Environment.NewLine & p.DataItems(0))
End Sub
Private Shared Sub HandleCreatePlayer(ByVal p As Package)

View File

@ -182,7 +182,7 @@ Namespace Servers
''' </summary>
Private Sub InternalPing()
Try
If DateDiff(DateInterval.Second, Me.LastPingTime, Date.Now) >= 10 Then
If (Date.Now - Me.LastPingTime).Seconds >= 10 Then
Me.SendPackage(New Package(Package.PackageTypes.Ping, Core.ServersManager.ID, Package.ProtocolTypes.UDP))
Me.LastPingTime = Date.Now
End If
@ -206,10 +206,10 @@ Namespace Servers
Public Sub SendChatMessage(ByVal message As String)
If message.ToLower().StartsWith("/login ") = True Then
Dim password As String = message.Remove(0, 7)
Dim hashedPassword As String = BitConverter.ToString(new SHA512Managed().ComputeHash(Encoding.UTF8.GetBytes(password))).Replace("-", "").ToLower()
Dim hashedPassword As String = BitConverter.ToString(New SHA512Managed().ComputeHash(Encoding.UTF8.GetBytes(password))).Replace("-", "").ToLower()
message = "/login " + hashedPassword
SendPackage(New Package(Package.PackageTypes.ChatMessage, Core.ServersManager.ID, Package.ProtocolTypes.TCP, message))
Else If message.ToLower().StartsWith("/pm ") = True Then
ElseIf message.ToLower().StartsWith("/pm ") = True Then
message = message.Remove(0, 4)
Dim playerName As String = message
While Core.ServersManager.PlayerCollection.HasPlayer(playerName) = False And playerName.Contains(" ") = True
@ -250,7 +250,7 @@ Namespace Servers
Me._streamWriter.Flush()
Catch ex As Exception
Logger.Log(Logger.LogTypes.Warning, "ServerConnection.vb: Error while sending data to server (TCP): " & ex.Message)
Me.Disconnect("Disconnected from Server", "Error trying to send data to the server (TCP)." & vbNewLine & ex.Message)
Me.Disconnect("Disconnected from Server", "Error trying to send data to the server (TCP)." & Environment.NewLine & ex.Message)
End Try
Me.LastPingTime = Date.Now
@ -294,7 +294,7 @@ Namespace Servers
Logger.Debug("Received invalid server package.")
End If
Catch ex As Exception
Logger.Log(Logger.LogTypes.Warning, "ServerConnection.vb: Error while receiving server data (TCP): " & vbNewLine & ex.Message)
Logger.Log(Logger.LogTypes.Warning, "ServerConnection.vb: Error while receiving server data (TCP): " & Environment.NewLine & ex.Message)
Me.Disconnect("Disconnected from Server", "Error while receiving server data (TCP).")
End Try
End While

View File

@ -89,10 +89,10 @@ Public Class OverworldScreen
''' </summary>
''' <remarks>Implements the GetScreenStatus method.</remarks>
Public Overrides Function GetScreenStatus() As String
Dim s As String = "IsSurfing=" & Level.Surfing.ToString() & vbNewLine &
"IsRiding=" & Level.Riding.ToString() & vbNewLine &
"LevelFile=" & Level.LevelFile & vbNewLine &
"UsedStrength=" & Level.UsedStrength.ToString() & vbNewLine &
Dim s As String = "IsSurfing=" & Level.Surfing.ToString() & Environment.NewLine &
"IsRiding=" & Level.Riding.ToString() & Environment.NewLine &
"LevelFile=" & Level.LevelFile & Environment.NewLine &
"UsedStrength=" & Level.UsedStrength.ToString() & Environment.NewLine &
"EntityCount=" & Level.Entities.Count
Return s

View File

@ -603,7 +603,7 @@
End If
Next
BoxData = String.Join(vbNewLine, TempBoxData)
BoxData = String.Join(Environment.NewLine, TempBoxData)
End If
' Check Day Care.
@ -624,7 +624,7 @@
End If
Next
DaycareData = String.Join(vbNewLine, TempDaycareData)
DaycareData = String.Join(Environment.NewLine, TempDaycareData)
End If
ActionScript.RegisterID("PokemonIndev054Update")
@ -657,7 +657,7 @@
End If
Next
BoxData = String.Join(vbNewLine, TempBoxData)
BoxData = String.Join(Environment.NewLine, TempBoxData)
End If
' Check Day Care.
@ -678,7 +678,7 @@
End If
Next
DaycareData = String.Join(vbNewLine, TempDaycareData)
DaycareData = String.Join(Environment.NewLine, TempDaycareData)
End If
' Remove Duplicate data.
@ -1046,7 +1046,7 @@
If IO.File.Exists(GameController.GamePath & "\Save\" & filePrefix & "\RoamingPokemon.dat") = True Then
For Each line As String In IO.File.ReadAllLines(GameController.GamePath & "\Save\" & filePrefix & "\RoamingPokemon.dat")
If RoamingPokemonData <> "" Then
RoamingPokemonData &= vbNewLine
RoamingPokemonData &= Environment.NewLine
End If
If line.CountSeperators("|") < 5 Then
'Convert potential old data:
@ -1176,7 +1176,7 @@
Dim APICallSave As New GameJolt.APICall(AddressOf SaveGameHelpers.CompleteGameJoltSave)
AddHandler APICallSave.CallFails, Sub(ByVal ex As Exception)
SaveGameHelpers.CompleteGameJoltSave("false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false" & vbNewLine & "false")
SaveGameHelpers.CompleteGameJoltSave("false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false" & Environment.NewLine & "false")
End Sub
Dim keys As New List(Of String)
@ -1213,7 +1213,7 @@
Dim Data As String = ""
For i = 0 To Pokemons.Count - 1
If Data <> "" Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Data &= Pokemons(i).GetSaveData()
Next
@ -1245,7 +1245,7 @@
Dim c As OverworldCamera = GetOverworldCamera()
Dim freeCameraString As String = c.FreeCameraMode.ToNumberString()
Dim diff As Integer = CInt(DateDiff(DateInterval.Second, GameStart, Date.Now))
Dim diff As Integer = (Date.Now - GameStart).Seconds
Dim p As TimeSpan = PlayTime + TimeHelpers.ConvertSecondToTime(diff)
Dim PlayTimeString As String = p.Hours & "," & p.Minutes & "," & p.Seconds & "," & p.Days
@ -1281,49 +1281,49 @@
skin = TempRideSkin
End If
Dim Data As String = "Name|" & Name & vbNewLine &
"Position|" & c.Position.X.ToString().Replace(GameController.DecSeparator, ".") & "," & c.Position.Y.ToString.Replace(GameController.DecSeparator, ".") & "," & c.Position.Z.ToString().Replace(GameController.DecSeparator, ".") & vbNewLine &
"MapFile|" & Screen.Level.LevelFile & vbNewLine &
"Rotation|" & c.Yaw.ToString.Replace(GameController.DecSeparator, ".") & vbNewLine &
"RivalName|" & RivalName & vbNewLine &
"Money|" & Money & vbNewLine &
"Badges|" & badgeString & vbNewLine &
"Gender|" & GenderString & vbNewLine &
"PlayTime|" & PlayTimeString & vbNewLine &
"OT|" & OT & vbNewLine &
"Points|" & Points.ToString() & vbNewLine &
"hasPokedex|" & hasPokedexString & vbNewLine &
"hasPokegear|" & HasPokegear.ToNumberString() & vbNewLine &
"freeCamera|" & freeCameraString & vbNewLine &
"thirdPerson|" & c.ThirdPerson.ToNumberString() & vbNewLine &
"skin|" & skin & vbNewLine &
"location|" & Screen.Level.MapName & vbNewLine &
"battleAnimations|" & ShowBattleAnimations.ToString() & vbNewLine &
"BoxAmount|" & BoxAmount.ToString() & vbNewLine &
"LastRestPlace|" & LastRestPlace & vbNewLine &
"LastRestPlacePosition|" & LastRestPlacePosition & vbNewLine &
"DiagonalMovement|" & DiagonalMovement.ToNumberString() & vbNewLine &
"RepelSteps|" & RepelSteps.ToString() & vbNewLine &
"LastSavePlace|" & LastSavePlace & vbNewLine &
"LastSavePlacePosition|" & LastSavePlacePosition & vbNewLine &
"Difficulty|" & DifficultyMode.ToString() & vbNewLine &
"BattleStyle|" & BattleStyle.ToString() & vbNewLine &
"saveCreated|" & SaveCreated & vbNewLine &
"LastPokemonPosition|" & lastPokemonPosition & vbNewLine &
"DaycareSteps|" & DaycareSteps.ToString() & vbNewLine &
"GameMode|" & GameMode & vbNewLine &
"PokeFiles|" & PokeFilesString & vbNewLine &
"VisitedMaps|" & VisitedMaps & vbNewLine &
"TempSurfSkin|" & TempSurfSkin & vbNewLine &
"Surfing|" & Screen.Level.Surfing.ToNumberString() & vbNewLine &
"BP|" & BP & vbNewLine &
"ShowModels|" & ShowModelsInBattle.ToNumberString() & vbNewLine &
"GTSStars|" & GTSStars & vbNewLine &
"SandBoxMode|" & SandBoxMode.ToNumberString() & vbNewLine &
Dim Data As String = "Name|" & Name & Environment.NewLine &
"Position|" & c.Position.X.ToString().Replace(GameController.DecSeparator, ".") & "," & c.Position.Y.ToString.Replace(GameController.DecSeparator, ".") & "," & c.Position.Z.ToString().Replace(GameController.DecSeparator, ".") & Environment.NewLine &
"MapFile|" & Screen.Level.LevelFile & Environment.NewLine &
"Rotation|" & c.Yaw.ToString.Replace(GameController.DecSeparator, ".") & Environment.NewLine &
"RivalName|" & RivalName & Environment.NewLine &
"Money|" & Money & Environment.NewLine &
"Badges|" & badgeString & Environment.NewLine &
"Gender|" & GenderString & Environment.NewLine &
"PlayTime|" & PlayTimeString & Environment.NewLine &
"OT|" & OT & Environment.NewLine &
"Points|" & Points.ToString() & Environment.NewLine &
"hasPokedex|" & hasPokedexString & Environment.NewLine &
"hasPokegear|" & HasPokegear.ToNumberString() & Environment.NewLine &
"freeCamera|" & freeCameraString & Environment.NewLine &
"thirdPerson|" & c.ThirdPerson.ToNumberString() & Environment.NewLine &
"skin|" & skin & Environment.NewLine &
"location|" & Screen.Level.MapName & Environment.NewLine &
"battleAnimations|" & ShowBattleAnimations.ToString() & Environment.NewLine &
"BoxAmount|" & BoxAmount.ToString() & Environment.NewLine &
"LastRestPlace|" & LastRestPlace & Environment.NewLine &
"LastRestPlacePosition|" & LastRestPlacePosition & Environment.NewLine &
"DiagonalMovement|" & DiagonalMovement.ToNumberString() & Environment.NewLine &
"RepelSteps|" & RepelSteps.ToString() & Environment.NewLine &
"LastSavePlace|" & LastSavePlace & Environment.NewLine &
"LastSavePlacePosition|" & LastSavePlacePosition & Environment.NewLine &
"Difficulty|" & DifficultyMode.ToString() & Environment.NewLine &
"BattleStyle|" & BattleStyle.ToString() & Environment.NewLine &
"saveCreated|" & SaveCreated & Environment.NewLine &
"LastPokemonPosition|" & lastPokemonPosition & Environment.NewLine &
"DaycareSteps|" & DaycareSteps.ToString() & Environment.NewLine &
"GameMode|" & GameMode & Environment.NewLine &
"PokeFiles|" & PokeFilesString & Environment.NewLine &
"VisitedMaps|" & VisitedMaps & Environment.NewLine &
"TempSurfSkin|" & TempSurfSkin & Environment.NewLine &
"Surfing|" & Screen.Level.Surfing.ToNumberString() & Environment.NewLine &
"BP|" & BP & Environment.NewLine &
"ShowModels|" & ShowModelsInBattle.ToNumberString() & Environment.NewLine &
"GTSStars|" & GTSStars & Environment.NewLine &
"SandBoxMode|" & SandBoxMode.ToNumberString() & Environment.NewLine &
"EarnedAchievements|" & EarnedAchievementsString
If IsAutosave = True Then
Data &= vbNewLine & "AutoSave|" & newFilePrefix
Data &= Environment.NewLine & "AutoSave|" & newFilePrefix
End If
Return Data
@ -1336,8 +1336,8 @@
Dim MouseSpeedString As String = CStr(c.RotationSpeed * 10000)
Dim TextSpeedString As String = CStr(TextBox.TextSpeed)
Dim Data As String = "FOV|" & FOVstring & vbNewLine &
"TextSpeed|" & TextSpeedString & vbNewLine &
Dim Data As String = "FOV|" & FOVstring & Environment.NewLine &
"TextSpeed|" & TextSpeedString & Environment.NewLine &
"MouseSpeed|" & MouseSpeedString
Return Data
@ -1348,7 +1348,7 @@
For Each c In Inventory
If Data <> "" Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Data &= "{" & c.ItemID & "|" & c.Amount & "}"
@ -1356,7 +1356,7 @@
For Each mail As Items.MailItem.MailData In Mails
If Data <> "" Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Data &= "Mail|" & Items.MailItem.GetStringFromMail(mail)
Next
@ -1792,23 +1792,23 @@
If CanFireStepEvent() = True Then
Screen.Level.WalkedSteps = 0
Dim s As String = "version=2" & vbNewLine &
"@Text.Show(Your repel effect wore off.)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@Text.Show(Your repel effect wore off.)" & Environment.NewLine &
":end"
If Temp.LastUsedRepel > -1 Then
Dim haveItemLeft As Boolean = Inventory.GetItemAmount(Temp.LastUsedRepel) > 0
If haveItemLeft = True Then
s = "version=2" & vbNewLine &
"@Text.Show(Your repel effect wore off.*Do you want to use~another <inventory.name(" & Temp.LastUsedRepel & ")>?)" & vbNewLine &
"@Options.Show(Yes,No)" & vbNewLine &
":when:Yes" & vbNewLine &
"@sound.play(repel_use)" & vbNewLine &
"@Text.Show(<player.name> used~a <inventory.name(" & Temp.LastUsedRepel & ")>.)" & vbNewLine &
"@item.repel(" & Temp.LastUsedRepel & ")" & vbNewLine &
"@item.remove(" & Temp.LastUsedRepel & ",1,0)" & vbNewLine &
":endwhen" & vbNewLine &
s = "version=2" & Environment.NewLine &
"@Text.Show(Your repel effect wore off.*Do you want to use~another <inventory.name(" & Temp.LastUsedRepel & ")>?)" & Environment.NewLine &
"@Options.Show(Yes,No)" & Environment.NewLine &
":when:Yes" & Environment.NewLine &
"@sound.play(repel_use)" & Environment.NewLine &
"@Text.Show(<player.name> used~a <inventory.name(" & Temp.LastUsedRepel & ")>.)" & Environment.NewLine &
"@item.repel(" & Temp.LastUsedRepel & ")" & Environment.NewLine &
"@item.remove(" & Temp.LastUsedRepel & ",1,0)" & Environment.NewLine &
":endwhen" & Environment.NewLine &
":end"
End If
End If

View File

@ -44,21 +44,21 @@ Public Class PlayerInventory
Public Function GetItemPocketChar(ByVal Item As Item) As String
Select Case Item.ItemType
Case Items.ItemTypes.Standard
Return ChrW(128)
Return StringHelper.GetChar(128)
Case Items.ItemTypes.BattleItems
Return ChrW(135)
Return StringHelper.GetChar(135)
Case Items.ItemTypes.KeyItems
Return ChrW(129)
Return StringHelper.GetChar(129)
Case Items.ItemTypes.Machines
Return ChrW(130)
Return StringHelper.GetChar(130)
Case Items.ItemTypes.Mail
Return ChrW(131)
Return StringHelper.GetChar(131)
Case Items.ItemTypes.Medicine
Return ChrW(132)
Return StringHelper.GetChar(132)
Case Items.ItemTypes.Plants
Return ChrW(133)
Return StringHelper.GetChar(133)
Case Items.ItemTypes.Pokéballs
Return ChrW(134)
Return StringHelper.GetChar(134)
End Select
Return ""

View File

@ -13,7 +13,7 @@
Public Shared Function CountEntries(ByVal Data As String, ByVal Type() As Integer) As Integer
Dim counts As Integer = 0
Dim pData() As String = Data.Split(CChar(vbNewLine))
Dim pData() As String = Data.Split(CChar(Environment.NewLine))
For Each Entry As String In pData
Entry = Entry.Remove(0, Entry.IndexOf("{") + 1)
Entry = Entry.Remove(Entry.Length - 1, 1)
@ -33,7 +33,7 @@
Dim IDs As New List(Of Integer)
For Each r As String In Range
If IsNumeric(r) = True Then
If StringHelper.IsNumeric(r) = True Then
If IDs.Contains(CInt(r)) = False Then
IDs.Add(CInt(r))
End If
@ -53,7 +53,7 @@
Dim counts As Integer = 0
Dim pData() As String = Data.Split(CChar(vbNewLine))
Dim pData() As String = Data.Split(CChar(Environment.NewLine))
For Each Entry As String In pData
Entry = Entry.Remove(0, Entry.IndexOf("{") + 1)
Entry = Entry.Remove(Entry.Length - 1, 1)
@ -72,7 +72,7 @@
End Function
Public Shared Function GetEntryType(ByVal Data As String, ByVal ID As Integer) As Integer
Dim pData() As String = Data.Split(CChar(vbNewLine))
Dim pData() As String = Data.Split(CChar(Environment.NewLine))
If pData.Count >= ID Then
If pData(ID - 1).Contains(ID.ToString() & "|") = True Then
@ -101,7 +101,7 @@
End If
Else
If Data <> "" Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Data &= "{" & ID & "|" & Type & "}"
Return Data
@ -116,7 +116,7 @@
For i = 1 To POKEMONCOUNT
Data &= "{" & i & "|0}"
If i <> POKEMONCOUNT Then
Data &= vbNewLine
Data &= Environment.NewLine
End If
Next
@ -124,7 +124,7 @@
End Function
Public Shared Function GetLastSeen(ByVal Data As String) As Integer
Dim pData() As String = Data.Split(CChar(vbNewLine))
Dim pData() As String = Data.Split(CChar(Environment.NewLine))
Dim lastSeen As Integer = 1
For Each Entry As String In pData

View File

@ -143,7 +143,7 @@ Public Class SaveGameHelpers
''' </summary>
''' <param name="input">The player data.</param>
Private Shared Function GetTimeFixedPlayerData(ByVal input As String) As String
Dim inputArr As String() = input.Split({vbNewLine}, StringSplitOptions.None)
Dim inputArr As String() = input.Split({Environment.NewLine}, StringSplitOptions.None)
Dim output As String = ""
For Each l As String In inputArr
@ -152,7 +152,7 @@ Public Class SaveGameHelpers
inputLine = "PlayTime|xxxxxxxxxx"
End If
If output <> "" Then
output &= vbNewLine
output &= Environment.NewLine
End If
output &= inputLine
Next

View File

@ -6,7 +6,7 @@ Namespace Items.Berries
Inherits Berry
Public Sub New()
MyBase.New(64800, "Pokéblock ingredient." & vbNewLine & "Plant in loamy soil to grow Spelon.", "13.2cm", "Soft", 1, 2)
MyBase.New(64800, "Pokéblock ingredient." & Environment.NewLine & "Plant in loamy soil to grow Spelon.", "13.2cm", "Soft", 1, 2)
Me.Spicy = 30
Me.Dry = 10

View File

@ -59,24 +59,24 @@ Namespace Items.KeyItems
endRotation = endRotation - 4
End If
s &= vbNewLine & "@player.showrod(1)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(Oh!~A bite!)" & vbNewLine &
"@player.hiderod" & vbNewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & vbNewLine &
"@Level.Update" & vbNewLine &
"@pokemon.cry(" & PokemonID & ")" & vbNewLine &
"@level.wait(50)" & vbNewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & vbNewLine &
"@npc.remove(1337)" & vbNewLine &
"@battle.setvar(divebattle,true)" & vbNewLine &
"@battle.wild(" & p.GetSaveData() & ")" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(1)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(Oh!~A bite!)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & Environment.NewLine &
"@Level.Update" & Environment.NewLine &
"@pokemon.cry(" & PokemonID & ")" & Environment.NewLine &
"@level.wait(50)" & Environment.NewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine &
"@npc.remove(1337)" & Environment.NewLine &
"@battle.setvar(divebattle,true)" & Environment.NewLine &
"@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine &
":end"
Else
s &= vbNewLine & "@player.showrod(1)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(No, there's nothing here...)" & vbNewLine &
"@player.hiderod" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(1)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(No, there's nothing here...)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
":end"
End If

View File

@ -59,24 +59,24 @@ Namespace Items.KeyItems
endRotation = endRotation - 4
End If
s &= vbNewLine & "@player.showrod(0)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(Oh!~A bite!)" & vbNewLine &
"@player.hiderod" & vbNewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & vbNewLine &
"@Level.Update" & vbNewLine &
"@pokemon.cry(" & PokemonID & ")" & vbNewLine &
"@level.wait(50)" & vbNewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & vbNewLine &
"@npc.remove(1337)" & vbNewLine &
"@battle.setvar(divebattle,true)" & vbNewLine &
"@battle.wild(" & p.GetSaveData() & ")" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(0)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(Oh!~A bite!)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & Environment.NewLine &
"@Level.Update" & Environment.NewLine &
"@pokemon.cry(" & PokemonID & ")" & Environment.NewLine &
"@level.wait(50)" & Environment.NewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine &
"@npc.remove(1337)" & Environment.NewLine &
"@battle.setvar(divebattle,true)" & Environment.NewLine &
"@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine &
":end"
Else
s &= vbNewLine & "@player.showrod(0)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(No, there's nothing here...)" & vbNewLine &
"@player.hiderod" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(0)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(No, there's nothing here...)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
":end"
End If

View File

@ -59,24 +59,24 @@ Namespace Items.KeyItems
endRotation = endRotation - 4
End If
s &= vbNewLine & "@player.showrod(2)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(Oh!~A bite!)" & vbNewLine &
"@player.hiderod" & vbNewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & vbNewLine &
"@Level.Update" & vbNewLine &
"@pokemon.cry(" & PokemonID & ")" & vbNewLine &
"@level.wait(50)" & vbNewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & vbNewLine &
"@npc.remove(1337)" & vbNewLine &
"@battle.setvar(divebattle,true)" & vbNewLine &
"@battle.wild(" & p.GetSaveData() & ")" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(2)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(Oh!~A bite!)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
"@npc.spawn(" & spawnPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & spawnPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & ",0,...,[POKEMON|" & PokemonShiny & "]" & PokemonID & PokemonForms.GetOverworldAddition(p) & ",0," & endRotation & ",POKEMON,1337,Still)" & Environment.NewLine &
"@Level.Update" & Environment.NewLine &
"@pokemon.cry(" & PokemonID & ")" & Environment.NewLine &
"@level.wait(50)" & Environment.NewLine &
"@text.show(The wild " & p.OriginalName & "~attacked!)" & Environment.NewLine &
"@npc.remove(1337)" & Environment.NewLine &
"@battle.setvar(divebattle,true)" & Environment.NewLine &
"@battle.wild(" & p.GetSaveData() & ")" & Environment.NewLine &
":end"
Else
s &= vbNewLine & "@player.showrod(2)" & vbNewLine &
"@text.show(. . . . . . . . . .)" & vbNewLine &
"@text.show(No, there's nothing here...)" & vbNewLine &
"@player.hiderod" & vbNewLine &
s &= Environment.NewLine & "@player.showrod(2)" & Environment.NewLine &
"@text.show(. . . . . . . . . .)" & Environment.NewLine &
"@text.show(No, there's nothing here...)" & Environment.NewLine &
"@player.hiderod" & Environment.NewLine &
":end"
End If

View File

@ -33,27 +33,27 @@ Namespace Items.Medicine
End If
Dim s As String =
"version=2" & vbNewLine &
"@sound.play(success_small)" & vbNewLine &
"@text.show(" & Pokemon.GetDisplayName() & " reached~level " & Pokemon.Level & "!)" & vbNewLine
"version=2" & Environment.NewLine &
"@sound.play(success_small)" & Environment.NewLine &
"@text.show(" & Pokemon.GetDisplayName() & " reached~level " & Pokemon.Level & "!)" & Environment.NewLine
Dim removedItem As Boolean = False
If Pokemon.AttackLearns.ContainsKey(Pokemon.Level) = True Then
If Pokemon.KnowsMove(Pokemon.AttackLearns(Pokemon.Level)) = False Then
If Pokemon.Attacks.Count = 4 Then
s &= "@pokemon.learnattack(" & PokeIndex & "," & Pokemon.AttackLearns(Pokemon.Level).ID & ")" & vbNewLine
s &= "@pokemon.learnattack(" & PokeIndex & "," & Pokemon.AttackLearns(Pokemon.Level).ID & ")" & Environment.NewLine
Dim t As String = Me.RemoveItem()
If t <> "" Then
s &= "@text.show(" & t & ")" & vbNewLine
s &= "@text.show(" & t & ")" & Environment.NewLine
End If
removedItem = True
Else
Pokemon.Attacks.Add(Pokemon.AttackLearns(Pokemon.Level))
s &= "@sound.play(success_small)" & vbNewLine &
"@text.show(" & Pokemon.GetDisplayName() & " learned~" & Pokemon.AttackLearns(Pokemon.Level).Name & "!*" & Me.RemoveItem() & ")" & vbNewLine
s &= "@sound.play(success_small)" & Environment.NewLine &
"@text.show(" & Pokemon.GetDisplayName() & " learned~" & Pokemon.AttackLearns(Pokemon.Level).Name & "!*" & Me.RemoveItem() & ")" & Environment.NewLine
removedItem = True
PlayerStatistics.Track("Moves learned", 1)
End If
@ -61,13 +61,13 @@ Namespace Items.Medicine
End If
If Pokemon.CanEvolve(EvolutionCondition.EvolutionTrigger.LevelUp, "") = True Then
s &= "@pokemon.evolve(" & PokeIndex & ")" & vbNewLine
s &= "@pokemon.evolve(" & PokeIndex & ")" & Environment.NewLine
End If
If removedItem = False Then
Dim t As String = Me.RemoveItem()
If t <> "" Then
s &= "@text.show(" & t & ")" & vbNewLine
s &= "@text.show(" & t & ")" & Environment.NewLine
End If
End If

View File

@ -26,7 +26,7 @@ Namespace Items.Standard
Dim yFinish As String = (Screen.Camera.Position.Y + 2.9F).ToString().ReplaceDecSeparator()
Dim s As String = "version=2" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & t & ")
@level.wait(20)
@camera.activatethirdperson
@ -45,9 +45,9 @@ Namespace Items.Standard
@player.turnto(2)"
If setToFirstPerson = True Then
s &= vbNewLine & "@camera.deactivatethirdperson"
s &= Environment.NewLine & "@camera.deactivatethirdperson"
End If
s &= vbNewLine &
s &= Environment.NewLine &
"@level.update
@screen.fadein
:end"

View File

@ -214,7 +214,7 @@ Public Class EvolutionCondition
canEvolve = False
End If
Case ConditionTypes.Trade
If IsNumeric(c.Argument) = True Then
If StringHelper.IsNumeric(c.Argument) Then
If CInt(c.Argument) > 0 Then
If CInt(c.Argument) <> CInt(arg) Then
canEvolve = False

View File

@ -1354,12 +1354,12 @@ Public Class Pokemon
If Value.Contains(",") = True Then
Dim MachinesValue() As String = Value.Split(CChar(","))
For i = 0 To MachinesValue.Length - 1
If IsNumeric(MachinesValue(i)) = True Then
If StringHelper.IsNumeric(MachinesValue(i)) Then
Me.Machines.Add(CInt(MachinesValue(i)))
End If
Next
Else
If IsNumeric(Value) = True Then
If StringHelper.IsNumeric(Value) Then
If CInt(Value) = -1 Then
Me.Machines.Clear()
Me.CanLearnAllMachines = True
@ -1564,7 +1564,7 @@ Public Class Pokemon
Case "eggsteps"
Me.EggSteps = CInt(tagValue)
Case "item"
If IsNumeric(tagValue) = True Then
If StringHelper.IsNumeric(tagValue) Then
Me.Item = Item.GetItemByID(CInt(tagValue))
End If
Case "itemdata"

View File

@ -48,31 +48,31 @@
Dim newPosition As New Vector2(0, 1)
Dim s As String = "version=2" & vbNewLine &
"@pokemon.cry(" & p.Number & ")" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@pokemon.cry(" & p.Number & ")" & Environment.NewLine
If CType(Screen.Camera, OverworldCamera).ThirdPerson = False Then
If reaction.HasNotification = True Then
s &= "@camera.activatethirdperson" & vbNewLine &
"@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & vbNewLine
s &= "@camera.activatethirdperson" & Environment.NewLine &
"@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & Environment.NewLine
s &= "@entity.showmessagebulb(" & CInt(reaction.Notification).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & vbNewLine
s &= "@entity.showmessagebulb(" & CInt(reaction.Notification).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & Environment.NewLine
s &= "@camera.deactivatethirdperson" & vbNewLine
s &= "@camera.deactivatethirdperson" & Environment.NewLine
End If
s &= "@text.show(" & reaction.GetMessage(p) & ")" & vbNewLine
s &= "@text.show(" & reaction.GetMessage(p) & ")" & Environment.NewLine
Else
Dim preYaw As Single = Screen.Camera.Yaw
If reaction.HasNotification = True Then
s &= "@camera.setyaw(" & CType(Screen.Camera, OverworldCamera).GetAimYawFromDirection(Screen.Camera.GetPlayerFacingDirection()) & ")" & vbNewLine
s &= "@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & vbNewLine
s &= "@entity.showmessagebulb(" & CInt(reaction.Notification).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & vbNewLine
s &= "@camera.setyaw(" & CType(Screen.Camera, OverworldCamera).GetAimYawFromDirection(Screen.Camera.GetPlayerFacingDirection()) & ")" & Environment.NewLine
s &= "@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & Environment.NewLine
s &= "@entity.showmessagebulb(" & CInt(reaction.Notification).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & Environment.NewLine
s &= "@camera.deactivatethirdperson" & vbNewLine
s &= "@camera.deactivatethirdperson" & Environment.NewLine
End If
s &= "@text.show(" & reaction.GetMessage(p) & ")" & vbNewLine
s &= "@camera.activatethirdperson" & vbNewLine
s &= "@camera.setyaw(" & preYaw & ")" & vbNewLine
s &= "@text.show(" & reaction.GetMessage(p) & ")" & Environment.NewLine
s &= "@camera.activatethirdperson" & Environment.NewLine
s &= "@camera.setyaw(" & preYaw & ")" & Environment.NewLine
End If
s &= ":end"
@ -98,43 +98,43 @@
Dim item As Item = Item.GetItemByID(PickupItemID)
Dim s As String = "version=2" & vbNewLine &
"@pokemon.cry(" & p.Number & ")" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@pokemon.cry(" & p.Number & ")" & Environment.NewLine
If CType(Screen.Camera, OverworldCamera).ThirdPerson = False Then
s &= "@camera.activatethirdperson" & vbNewLine &
"@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & vbNewLine
s &= "@camera.activatethirdperson" & Environment.NewLine &
"@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & Environment.NewLine
s &= "@entity.showmessagebulb(" & CInt(MessageBulb.NotifcationTypes.Question).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & vbNewLine
s &= "@entity.showmessagebulb(" & CInt(MessageBulb.NotifcationTypes.Question).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & Environment.NewLine
s &= "@camera.deactivatethirdperson" & vbNewLine
s &= "@text.show(" & message & ")" & vbNewLine &
"@options.show(Yes,No)" & vbNewLine &
":when:Yes" & vbNewLine &
"@text.show(Your Pokémon handed over~the " & item.Name & "!)" & vbNewLine &
"@item.give(" & PickupItemID & ",1)" & vbNewLine &
"@item.messagegive(" & PickupItemID & ",1)" & vbNewLine &
":when:No" & vbNewLine &
"@text.show(Your Pokémon kept~the item happily.)" & vbNewLine &
"@pokemon.addfriendship(0,10)" & vbNewLine &
":endwhen" & vbNewLine
s &= "@camera.deactivatethirdperson" & Environment.NewLine
s &= "@text.show(" & message & ")" & Environment.NewLine &
"@options.show(Yes,No)" & Environment.NewLine &
":when:Yes" & Environment.NewLine &
"@text.show(Your Pokémon handed over~the " & item.Name & "!)" & Environment.NewLine &
"@item.give(" & PickupItemID & ",1)" & Environment.NewLine &
"@item.messagegive(" & PickupItemID & ",1)" & Environment.NewLine &
":when:No" & Environment.NewLine &
"@text.show(Your Pokémon kept~the item happily.)" & Environment.NewLine &
"@pokemon.addfriendship(0,10)" & Environment.NewLine &
":endwhen" & Environment.NewLine
Else
s &= "@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & vbNewLine
s &= "@entity.showmessagebulb(" & CInt(MessageBulb.NotifcationTypes.Question).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & vbNewLine
s &= "@camera.setposition(" & newPosition.X & ",1," & newPosition.Y & ")" & Environment.NewLine
s &= "@entity.showmessagebulb(" & CInt(MessageBulb.NotifcationTypes.Question).ToString() & "|" & cPosition.X + offset.X & "|" & cPosition.Y + 0.7F & "|" & cPosition.Z + offset.Y & ")" & Environment.NewLine
s &= "@camera.deactivatethirdperson" & vbNewLine
s &= "@camera.deactivatethirdperson" & Environment.NewLine
s &= "@text.show(" & message & ")" & vbNewLine &
"@options.show(Yes,No)" & vbNewLine &
":when:Yes" & vbNewLine &
"@text.show(Your Pokémon handed over~the " & item.Name & "!)" & vbNewLine &
"@item.give(" & PickupItemID & ",1)" & vbNewLine &
"@item.messagegive(" & PickupItemID & ",1)" & vbNewLine &
":when:No" & vbNewLine &
"@text.show(Your Pokémon kept~the item happily.)" & vbNewLine &
"@pokemon.addfriendship(0,10)" & vbNewLine &
":endwhen" & vbNewLine
s &= "@camera.activatethirdperson" & vbNewLine
s &= "@text.show(" & message & ")" & Environment.NewLine &
"@options.show(Yes,No)" & Environment.NewLine &
":when:Yes" & Environment.NewLine &
"@text.show(Your Pokémon handed over~the " & item.Name & "!)" & Environment.NewLine &
"@item.give(" & PickupItemID & ",1)" & Environment.NewLine &
"@item.messagegive(" & PickupItemID & ",1)" & Environment.NewLine &
":when:No" & Environment.NewLine &
"@text.show(Your Pokémon kept~the item happily.)" & Environment.NewLine &
"@pokemon.addfriendship(0,10)" & Environment.NewLine &
":endwhen" & Environment.NewLine
s &= "@camera.activatethirdperson" & Environment.NewLine
End If
s &= ":end"
@ -737,7 +737,7 @@
pokePart = pokePart.Remove(0, 1)
lReference = ExcludeIDs
End If
If IsNumeric(pokePart) = True Then
If StringHelper.IsNumeric(pokePart) = True Then
If lReference.Contains(CInt(pokePart)) = False Then
lReference.Add(CInt(pokePart))
End If

View File

@ -32,7 +32,7 @@ Public Class RoamingPokemon
Dim data() As String = line.Split(CChar("|"))
If newData <> "" Then
newData &= vbNewLine
newData &= Environment.NewLine
End If
If CInt(data(2)) = worldID Or worldID = -1 Then
@ -77,7 +77,7 @@ Public Class RoamingPokemon
For Each line As String In Core.Player.RoamingPokemonData.SplitAtNewline()
If line.StartsWith(compareData) = False Then
If newData <> "" Then
newData &= vbNewLine
newData &= Environment.NewLine
End If
newData &= line
End If
@ -93,7 +93,7 @@ Public Class RoamingPokemon
For Each line As String In Core.Player.RoamingPokemonData.SplitAtNewline()
If newData <> "" Then
newData &= vbNewLine
newData &= Environment.NewLine
End If
If line.StartsWith(compareData) = False Then
newData &= line

View File

@ -5,7 +5,7 @@
Dim files() As String = System.IO.Directory.GetFiles(GameController.GamePath & "\Content\Pokemon\Data", "*.dat", IO.SearchOption.TopDirectoryOnly)
For Each f As String In files
If IsNumeric(System.IO.Path.GetFileNameWithoutExtension(f)) = True Then
If StringHelper.IsNumeric(System.IO.Path.GetFileNameWithoutExtension(f)) Then
Dim newID As Integer = CInt(System.IO.Path.GetFileNameWithoutExtension(f))
If IDPreset Is Nothing OrElse IDPreset.Contains(newID) = True Then
validIDs.Add(newID)
@ -39,7 +39,7 @@
Dim OutputID As Integer = CInt(lData(1))
Dim Moveset As New List(Of Integer)
For Each move As String In lData(2).Split(CChar(","))
If move <> "" And IsNumeric(move) = True Then
If move <> "" And StringHelper.IsNumeric(move) Then
Moveset.Add(CInt(move))
End If
Next

View File

@ -94,7 +94,7 @@
Public Shared Function GetContentPackInfo(ByVal ContentPackName As String) As String()
If System.IO.File.Exists(GameController.GamePath & "\ContentPacks\" & ContentPackName & "\info.dat") = False Then
Dim s As String = "1.00" & vbNewLine & "Pokémon3D" & vbNewLine & "[Add information here!]"
Dim s As String = "1.00" & Environment.NewLine & "Pokémon3D" & Environment.NewLine & "[Add information here!]"
System.IO.File.WriteAllText(GameController.GamePath & "\ContentPacks\" & ContentPackName & "\info.dat", s)
End If
Return System.IO.File.ReadAllLines(GameController.GamePath & "\ContentPacks\" & ContentPackName & "\info.dat")

View File

@ -568,9 +568,9 @@ Public Class GameMode
gameRules.Add(New GameRule("CanGetAchievements", "1"))
gameRules.Add(New GameRule("ShowFollowPokemon", "1"))
GameMode.GameRules = gameRules
gameMode.GameRules = gameRules
Return GameMode
Return gameMode
End Function
''' <summary>
@ -578,32 +578,32 @@ Public Class GameMode
''' </summary>
''' <param name="File">The file this GameMode should get exported to.</param>
Public Sub SaveToFile(ByVal File As String)
Dim s As String = "Name|" & Me._name & vbNewLine &
"Description|" & Me._description & vbNewLine &
"Version|" & Me._version & vbNewLine &
"Author|" & Me._author & vbNewLine &
"MapPath|" & Me._mapPath & vbNewLine &
"ScriptPath|" & Me._scriptPath & vbNewLine &
"PokeFilePath|" & Me._pokeFilePath & vbNewLine &
"PokemonDataPath|" & Me._pokemonDataPath & vbNewLine &
"ContentPath|" & Me._contentPath & vbNewLine &
"LocalizationsPath|" & Me._localizationsPath & vbNewLine
Dim s As String = "Name|" & Me._name & Environment.NewLine &
"Description|" & Me._description & Environment.NewLine &
"Version|" & Me._version & Environment.NewLine &
"Author|" & Me._author & Environment.NewLine &
"MapPath|" & Me._mapPath & Environment.NewLine &
"ScriptPath|" & Me._scriptPath & Environment.NewLine &
"PokeFilePath|" & Me._pokeFilePath & Environment.NewLine &
"PokemonDataPath|" & Me._pokemonDataPath & Environment.NewLine &
"ContentPath|" & Me._contentPath & Environment.NewLine &
"LocalizationsPath|" & Me._localizationsPath & Environment.NewLine
Dim GameRuleString As String = "Gamerules|"
For Each rule As GameRule In Me._gameRules
GameRuleString &= "(" & rule.RuleName & "|" & rule.RuleValue & ")"
Next
s &= GameRuleString & vbNewLine &
"StartMap|" & Me._startMap & vbNewLine &
"StartPosition|" & Me._startPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & Me._startPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & Me._startPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & vbNewLine &
"StartRotation|" & Me._startRotation.ToString().Replace(GameController.DecSeparator, ".") & vbNewLine &
"StartScript|" & StartScript & vbNewLine &
"StartLocationName|" & Me._startLocationName & vbNewLine &
"StartDialogue|" & Me._startDialogue & vbNewLine &
"StartColor|" & Me._startColor.R & "," & Me._startColor.G & "," & Me._startColor.B & vbNewLine &
"PokemonAppear|" & Me._pokemonAppear & vbNewLine &
"IntroMusic|" & Me._introMusic & vbNewLine
s &= GameRuleString & Environment.NewLine &
"StartMap|" & Me._startMap & Environment.NewLine &
"StartPosition|" & Me._startPosition.X.ToString().Replace(GameController.DecSeparator, ".") & "," & Me._startPosition.Y.ToString().Replace(GameController.DecSeparator, ".") & "," & Me._startPosition.Z.ToString().Replace(GameController.DecSeparator, ".") & Environment.NewLine &
"StartRotation|" & Me._startRotation.ToString().Replace(GameController.DecSeparator, ".") & Environment.NewLine &
"StartScript|" & StartScript & Environment.NewLine &
"StartLocationName|" & Me._startLocationName & Environment.NewLine &
"StartDialogue|" & Me._startDialogue & Environment.NewLine &
"StartColor|" & Me._startColor.R & "," & Me._startColor.G & "," & Me._startColor.B & Environment.NewLine &
"PokemonAppear|" & Me._pokemonAppear & Environment.NewLine &
"IntroMusic|" & Me._introMusic & Environment.NewLine
Dim SkinColorsString As String = "SkinColors|"
Dim iSC As Integer = 0
@ -617,7 +617,7 @@ Public Class GameMode
iSC += 1
Next
s &= SkinColorsString & vbNewLine
s &= SkinColorsString & Environment.NewLine
Dim SkinFilesString As String = "SkinFiles|"
Dim iSF As Integer = 0
@ -631,7 +631,7 @@ Public Class GameMode
iSF += 1
Next
s &= SkinFilesString & vbNewLine
s &= SkinFilesString & Environment.NewLine
Dim SkinNamesString As String = "SkinNames|"
Dim iSN As Integer = 0

View File

@ -225,7 +225,7 @@
If SearchForIntro = True And lastSong.ToLower() <> Song.ToLower() Then
If SongFiles.Keys.Contains("intro\" & Song.ToLower()) = True Then
If SongFiles("intro\" & Song.ToLower()).Origin = SongFiles(Song.ToLower()).Origin Then
IntroEndTime = DateAdd(DateInterval.Second, -1, Date.Now) + SongFiles("intro\" & Song.ToLower()).Song.Duration
IntroEndTime = Date.Now.AddSeconds(-1) + SongFiles("intro\" & Song.ToLower()).Song.Duration
PlayMusic("intro\" & Song.ToLower(), NewFadeInSpeed, NewFadeOutSpeed)
MediaPlayer.IsRepeating = False
@ -390,7 +390,7 @@
If FadeIntoIntro = True Then
IntroStarted = True
IntroEndTime = DateAdd(DateInterval.Second, -1, Date.Now) + SongFiles(NextSong).Song.Duration
IntroEndTime = Date.Now.AddSeconds(-1) + SongFiles(NextSong).Song.Duration
FadeIntoIntro = False
End If
@ -432,7 +432,7 @@
Public Shared Function SongExists(ByVal songName As String) As Boolean
Dim s As CSong = GetSong(songName, False)
Return Not IsNothing(s)
Return s IsNot Nothing
End Function
Public Shared Sub ForceVolumeUpdate()

View File

@ -132,7 +132,7 @@ Public Class TextureManager
Public Shared Function GetTexture(ByVal Texture As Texture2D, ByVal Rectangle As Rectangle, Optional ByVal Factor As Integer = 1) As Texture2D
Dim tex As Texture2D = Nothing
If TextureRectList.TryGetValue(New KeyValuePair(Of Int32, Rectangle)(Texture.GetHashCode(), Rectangle), tex) then
If TextureRectList.TryGetValue(New KeyValuePair(Of Int32, Rectangle)(Texture.GetHashCode(), Rectangle), tex) Then
Return tex
End If
@ -143,7 +143,7 @@ Public Class TextureManager
End Function
Private Shared Function TextureRectangle(ByVal Texture As Texture2D, ByVal Rectangle As Rectangle, Optional ByVal Factor As Integer = 1) As Texture2D
If IsNothing(Rectangle) Then
If Rectangle = Rectangle.Empty Then
Return Texture
Else
Rectangle = New Rectangle(Rectangle.X * Factor, Rectangle.Y * Factor, Rectangle.Width * Factor, Rectangle.Height * Factor)

View File

@ -5,7 +5,7 @@
Dim BattleScreen As BattleSystem.BattleScreen
Dim index As Integer = 0
Dim textIndex As Integer = 0
Dim Text() As String = {Localization.GetString("black_out_screen_line1"), vbNewLine, " ", Localization.GetString("black_out_screen_line2"), Localization.GetString("black_out_screen_line3"), Localization.GetString("black_out_screen_line4"), Localization.GetString("black_out_screen_line5")}
Dim Text() As String = {Localization.GetString("black_out_screen_line1"), Environment.NewLine, " ", Localization.GetString("black_out_screen_line2"), Localization.GetString("black_out_screen_line3"), Localization.GetString("black_out_screen_line4"), Localization.GetString("black_out_screen_line5")}
Dim ready As Boolean = False
Dim delay As Single = 0.2F
@ -100,7 +100,7 @@
Dim aText As String = ""
For i = 0 To textIndex
If i <> textIndex Then
aText &= Text(i) & vbNewLine
aText &= Text(i) & Environment.NewLine
Else
If textIndex < Text.Count() Then
aText &= Text(i).Remove(index)

View File

@ -519,7 +519,7 @@
End Sub
Private Function SongOver() As Boolean
Return startTime + duration < DateAdd(DateInterval.Second, +1, Date.Now)
Return startTime + duration < Date.Now.AddSeconds(1)
End Function
'Protected Overrides Sub Finalize()

View File

@ -52,7 +52,7 @@
Dim t As String = ""
For i = OffsetY To 11 + OffsetY
If i <> OffsetY Then
t &= vbNewLine & vbNewLine
t &= Environment.NewLine & Environment.NewLine
End If
If DonatorList.Count - 1 >= i Then
t &= DonatorList(i)

View File

@ -4,7 +4,7 @@
Public Shared Sub AddHistoryItem(ByVal Name As String, ByVal Data As String, ByVal IsScriptOrigin As Boolean, ByVal ShowOnTimeline As Boolean)
If Core.Player.HistoryData <> "" Then
Core.Player.HistoryData &= vbNewLine
Core.Player.HistoryData &= Environment.NewLine
End If
Dim dateString As String = ""

View File

@ -56,7 +56,7 @@
Select Case Me.State
Case States.Wait
Me.Labels.Add(New Label(Localization.GetString("apricorn_screen_producing").Replace("~", vbNewLine), New Vector2(100, 200), FontManager.MainFont))
Me.Labels.Add(New Label(Localization.GetString("apricorn_screen_producing").Replace("~", Environment.NewLine), New Vector2(100, 200), FontManager.MainFont))
Me.Labels.Add(New Label(Localization.GetString("apricorn_screen_backadvice"), New Vector2(100, 260), Color.DarkGray, FontManager.MainFont))
Case States.CanGive
Dim T As Texture2D = TextureManager.GetTexture("Items\ItemSheet")
@ -252,7 +252,7 @@
Private Sub AdjustButtonTexts()
For Each b As ButtonIcon In Buttons
If IsNumeric(b.AdditionalValue) = True Then
If StringHelper.IsNumeric(b.AdditionalValue) Then
Dim apricornID As Integer = 0
Select Case CInt(b.AdditionalValue)
@ -307,7 +307,7 @@
d.Year & "," & d.Month & "," & d.Day & "," & d.Hour & "," & d.Minute & "," & d.Second & "}"
If Core.Player.ApricornData <> "" Then
Core.Player.ApricornData &= vbNewLine
Core.Player.ApricornData &= Environment.NewLine
End If
Core.Player.ApricornData &= s
@ -356,7 +356,7 @@
For i = 0 To Data.Count() - 1
If Data(i).StartsWith("{" & Me.owner & "|") = False Then
If s <> "" Then
s &= vbNewLine
s &= Environment.NewLine
End If
s &= Data(i)
End If
@ -418,9 +418,8 @@
If ApricornData(0) = Me.owner Then
Dim d() As String = ApricornData(2).Split(CChar(","))
Dim gaveDate As Date = New Date(CInt(d(0)), CInt(d(1)), CInt(d(2)), CInt(d(3)), CInt(d(4)), CInt(d(5)))
Dim currentDate As Date = Date.Now
diff = CInt(DateDiff(DateInterval.Minute, gaveDate, currentDate))
diff = (Date.Now - gaveDate).Minutes
End If
End If
Next

View File

@ -478,7 +478,7 @@ Public Class NewInventoryScreen
itemSubTitle = "Hidden Machine"
End If
itemDescription &= vbNewLine & techMachine.Attack.Description
itemDescription &= Environment.NewLine & techMachine.Attack.Description
Case Items.ItemTypes.Standard
'JSON stuff
'itemSubTitle = _translation.STANDARD_ITEM_TITLE(cItem.ItemType.ToString())
@ -532,8 +532,8 @@ Public Class NewInventoryScreen
Dim offsetX As Integer = 100
Dim offsetY As Integer = Core.windowSize.Height - 390
Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.windowSize.Width / 2) + 180 + offSetX, 240 + offSetY, 128, 64))
Core.SpriteBatch.DrawString(FontManager.InGameFont, trashText, New Vector2(CInt(Core.windowSize.Width / 2) - (FontManager.InGameFont.MeasureString(trashText).X / 2) + 256 + offSetX, 276 + offSetY), Color.Black)
Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.windowSize.Width / 2) + 180 + offsetX, 240 + offsetY, 128, 64))
Core.SpriteBatch.DrawString(FontManager.InGameFont, trashText, New Vector2(CInt(Core.windowSize.Width / 2) - (FontManager.InGameFont.MeasureString(trashText).X / 2) + 256 + offsetX, 276 + offsetY), Color.Black)
End If
End Sub

View File

@ -42,21 +42,21 @@
Me.MouseVisible = True
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
Me.UserBanned = LogInScreen.UserBanned(Core.GameJoltSave.GameJoltID)
Dim APICall As New APICall(AddressOf GotPublicKeys)
APICall.GetKeys(False, "saveStorageV" & GameJolt.GamejoltSave.Version & "|*|*")
APICall.GetKeys(False, "saveStorageV" & GameJolt.GamejoltSave.VERSION & "|*|*")
End If
If Me.UserBanned = False Then
FunctionList.Add("PSS")
If API.LoggedIn = True And Core.Player.IsGamejoltSave = True And Core.Player.Pokemons.Count > 0 Then
If API.LoggedIn = True And Core.Player.IsGameJoltSave = True And Core.Player.Pokemons.Count > 0 Then
FunctionList.Add("Battle Spot")
End If
If (ActionScript.IsRegistered("pokegear_card_GTS") = True Or GameController.IS_DEBUG_ACTIVE = True) = True And API.LoggedIn = True And Core.Player.IsGamejoltSave = True Then
If (ActionScript.IsRegistered("pokegear_card_GTS") = True Or GameController.IS_DEBUG_ACTIVE = True) = True And API.LoggedIn = True And Core.Player.IsGameJoltSave = True Then
FunctionList.Add("GTS")
End If
If API.LoggedIn = True And Core.Player.IsGamejoltSave = True And Core.Player.Pokemons.Count > 0 Then
If API.LoggedIn = True And Core.Player.IsGameJoltSave = True And Core.Player.Pokemons.Count > 0 Then
FunctionList.Add("Wondertrade")
End If
End If
@ -427,7 +427,7 @@
Core.SpriteBatch.DrawString(FontManager.MiniFont, "PSS Ranklist", New Vector2(CInt(startPos.X + 50), CInt(startPos.Y + 45)), Color.Black)
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
' Draw own information:
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + 220), CInt(startPos.Y + 40), 16, 32), New Rectangle(96, 112, 8, 16), Color.White)
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + 220 + 16), CInt(startPos.Y + 40), 304, 32), New Rectangle(102, 112, 4, 16), Color.White)
@ -555,7 +555,7 @@
Me.RankingList.Clear()
InitializedRanklist = True
If Core.Player.IsGamejoltSave = True And UserBanned = False Then
If Core.Player.IsGameJoltSave = True And UserBanned = False Then
Dim APICall As New APICall(AddressOf GotDataRanklist)
APICall.FetchTable(100, "14908")
@ -621,7 +621,7 @@
Core.SpriteBatch.DrawString(FontManager.MiniFont, "PSS Friendlist", New Vector2(CInt(startPos.X + 50), CInt(startPos.Y + 45)), Color.Black)
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
' Draw own information:
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + 220), CInt(startPos.Y + 40), 16, 32), New Rectangle(96, 112, 8, 16), Color.White)
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + 220 + 16), CInt(startPos.Y + 40), 304, 32), New Rectangle(102, 112, 4, 16), Color.White)
@ -886,7 +886,7 @@
Canvas.DrawScrollBar(New Vector2(startPos.X + 570, startPos.Y + 85), LocalList.Count, 9, LocalScroll, New Size(4, 300), False, New Color(252, 196, 68), New Color(217, 120, 18))
Else
If ConnectScreen.Connected = True Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, "No other players connected to server" & vbNewLine & """" & JoinServerScreen.SelectedServer.GetName() & """.", New Vector2(CInt(startPos.X + 50), CInt(startPos.Y + 85)), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "No other players connected to server" & Environment.NewLine & """" & JoinServerScreen.SelectedServer.GetName() & """.", New Vector2(CInt(startPos.X + 50), CInt(startPos.Y + 85)), Color.Black)
Else
Core.SpriteBatch.DrawString(FontManager.MiniFont, "You are playing locally.", New Vector2(CInt(startPos.X + 50), CInt(startPos.Y + 85)), Color.Black)
End If
@ -1009,7 +1009,7 @@
Dim sameServer As Boolean = False
Dim sameConnection As Boolean = False
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
If Not UserEmblem Is Nothing Then
sameConnection = True
End If
@ -1030,7 +1030,7 @@
For x = 0 To 4
Dim c As Color = Color.White
Dim t As String = ""
Dim texV As Vector2 = Nothing
Dim texV As Vector2 = New Vector2
Select Case x
Case 0
t = "Battle"
@ -1061,7 +1061,7 @@
End If
End Select
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + (x * 96) + 76), CInt(startPos.Y + 100), 64, 64), New Rectangle(0, 0, 32, 32), c)
If IsNothing(texV) = False Then
If texV <> Vector2.Zero Then
Core.SpriteBatch.Draw(TextureManager.GetTexture("GUI\Menus\pokegear"), New Rectangle(CInt(startPos.X + (x * 96) + 76), CInt(startPos.Y + 100), 64, 64), New Rectangle(CInt(texV.X), CInt(texV.Y), 32, 32), c)
End If
If Cursors(1) = x Then
@ -1089,7 +1089,7 @@
Dim sameServer As Boolean = False
Dim sameConnection As Boolean = False
If Core.Player.IsGamejoltSave = True Then
If Core.Player.IsGameJoltSave = True Then
If Not UserEmblem Is Nothing Then
sameConnection = True
End If
@ -1461,17 +1461,17 @@
Me.InitializedFrontier = True
If ActionScript.IsRegistered("gold ability") = True Then
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Gold Ability", .Description = "You defeated the Frontier Brain of" & vbNewLine & "Battle Tower a second time and you've" & vbNewLine & "your real strength when it comes to battles.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(50, 200, 50, 50), "")})
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Gold Ability", .Description = "You defeated the Frontier Brain of" & Environment.NewLine & "Battle Tower a second time and you've" & Environment.NewLine & "your real strength when it comes to battles.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(50, 200, 50, 50), "")})
Else
If ActionScript.IsRegistered("silver ability") = True Then
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Silver Ability", .Description = "You defeated the Frontier Brain of" & vbNewLine & "Battle Tower and showed him how" & vbNewLine & "you and your Pokémon really are.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(0, 200, 50, 50), "")})
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Silver Ability", .Description = "You defeated the Frontier Brain of" & Environment.NewLine & "Battle Tower and showed him how" & Environment.NewLine & "you and your Pokémon really are.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(0, 200, 50, 50), "")})
End If
End If
If ActionScript.IsRegistered("gold knowledge") = True Then
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Gold Knowledge", .Description = "This Emblem displays how great you can" & vbNewLine & "interact with Pokémon and how well" & vbNewLine & "you can adapt your strategy to a new situation.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(150, 200, 50, 50), "")})
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Gold Knowledge", .Description = "This Emblem displays how great you can" & Environment.NewLine & "interact with Pokémon and how well" & Environment.NewLine & "you can adapt your strategy to a new situation.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(150, 200, 50, 50), "")})
Else
If ActionScript.IsRegistered("silver knowledge") = True Then
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Silver Knowledge", .Description = "Only few trainers achieved this emblem" & vbNewLine & "which shows what strength lies" & vbNewLine & "inside them.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(100, 200, 50, 50), "")})
Me.FrontierList.Add(New FrontierSymbol() With {.Name = "Silver Knowledge", .Description = "Only few trainers achieved this emblem" & Environment.NewLine & "which shows what strength lies" & Environment.NewLine & "inside them.", .Texture = TextureManager.GetTexture("GUI\Badges", New Rectangle(100, 200, 50, 50), "")})
End If
End If
End Sub
@ -1561,7 +1561,7 @@
Dim lDayTimes() As String = data(4).Split(CChar(","))
For Each daytime As String In lDayTimes
If IsNumeric(daytime) = True Then
If StringHelper.IsNumeric(daytime) = True Then
DayTimes.Add(CType(CInt(daytime), World.DayTime))
End If
Next
@ -1758,16 +1758,16 @@
Dim text1 As String = "...No channels found..."
If Not CurrentStation Is Nothing Then
text1 = "You are listening to:" & vbNewLine & CurrentStation.Name
text1 = "You are listening to:" & Environment.NewLine & CurrentStation.Name
End If
Core.SpriteBatch.DrawString(FontManager.MainFont, text1, New Vector2(startPos.X + 150 - CInt(FontManager.MainFont.MeasureString(text1).X / 2), startPos.Y + 160), Color.Black)
Dim text2 As String = ""
If Screen.Level.IsRadioOn = True Then
text2 = "Background station:" & vbNewLine & Screen.Level.SelectedRadioStation.Name & "." & vbNewLine & "Press Accept to remove."
text2 = "Background station:" & Environment.NewLine & Screen.Level.SelectedRadioStation.Name & "." & Environment.NewLine & "Press Accept to remove."
Else
If Not CurrentStation Is Nothing Then
text2 = "Press Accept to listen" & vbNewLine & "to this station in" & vbNewLine & "the background."
text2 = "Press Accept to listen" & Environment.NewLine & "to this station in" & Environment.NewLine & "the background."
End If
End If
If text2 <> "" Then

View File

@ -602,7 +602,7 @@ Public Class JoinServerScreen
tooltipText = PlayerList.ToArray().ArrayToString(True)
End If
Dim v = FontManager.MiniFont.MeasureString("Player list:" & vbNewLine & tooltipText)
Dim v = FontManager.MiniFont.MeasureString("Player list:" & Environment.NewLine & tooltipText)
Dim drawY As Integer = MouseHandler.MousePosition.Y + 10
If drawY + v.Y + 12 > Core.windowSize.Height Then
@ -659,7 +659,7 @@ Public Class JoinServerScreen
Dim data() As String = System.IO.File.ReadAllLines(GameController.GamePath & "\Save\server_list.dat")
For Each line As String In data
If newData <> "" Then
newData &= vbNewLine
newData &= Environment.NewLine
End If
If line.StartsWith(server_name & ",") = True Then
Dim lineData() As String = line.Split(CChar(","))
@ -688,7 +688,7 @@ Public Class JoinServerScreen
For Each s As Server In Me.ServerList
If s.IsLocal = False Then
If data <> "" Then
data &= vbNewLine
data &= Environment.NewLine
End If
data &= s.ToString()
End If

View File

@ -333,7 +333,7 @@ Public Class NewMainMenuScreen
Private Sub ClickedProfile()
If _selectedProfile = 0 And Security.FileValidation.IsValid(False) = False Then
_messageBox.Show("File validation failed!" & vbNewLine & "Redownload the game's files to solve this problem.")
_messageBox.Show("File validation failed!" & Environment.NewLine & "Redownload the game's files to solve this problem.")
Else
_profiles(_selectedProfile).SelectProfile()
End If
@ -437,22 +437,22 @@ Public Class NewMainMenuScreen
For i = 0 To tmpProfile.PokemonTextures.Count - 1
SpriteBatch.Draw(tmpProfile.PokemonTextures(i), New Rectangle(displayRect.X + 30 + i * 70, displayRect.Y + 70, 64, 64), Color.White)
Next
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Name: " & tmpProfile.Name & vbNewLine &
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Name: " & tmpProfile.Name & Environment.NewLine &
"GameMode: " & tmpProfile.GameMode, New Vector2(displayRect.X + 30, displayRect.Y + 20), Color.White, 0F, Vector2.Zero, 0.5F, SpriteEffects.None, 0F)
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Badges: " & tmpProfile.Badges.ToString() & vbNewLine &
"Time played: " & tmpProfile.TimePlayed & vbNewLine &
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Badges: " & tmpProfile.Badges.ToString() & Environment.NewLine &
"Time played: " & tmpProfile.TimePlayed & Environment.NewLine &
"Location: " & tmpProfile.Location, New Vector2(displayRect.X + 30, displayRect.Y + 150), Color.White, 0F, Vector2.Zero, 0.5F, SpriteEffects.None, 0F)
Else
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Name: " & tmpProfile.Name & vbNewLine &
GetFontRenderer().DrawString(FontManager.GameJoltFont, "Name: " & tmpProfile.Name & Environment.NewLine &
"GameMode: " & tmpProfile.GameMode, New Vector2(displayRect.X + 30, displayRect.Y + 20), Color.White, 0F, Vector2.Zero, 0.5F, SpriteEffects.None, 0F)
SpriteBatch.Draw(_menuTexture, New Rectangle(displayRect.X + 30, displayRect.Y + 70, 32, 32), New Rectangle(0, 32, 32, 32), Color.White)
Dim errorText As String = ""
If tmpProfile.IsGameJolt() Then
errorText = "Download failed. Press Accept to try again." & vbNewLine & vbNewLine &
"If the problem persists, please try again later" & vbNewLine &
"or contact us in our Discord server:" & vbNewLine & vbNewLine &
errorText = "Download failed. Press Accept to try again." & Environment.NewLine & Environment.NewLine &
"If the problem persists, please try again later" & Environment.NewLine &
"or contact us in our Discord server:" & Environment.NewLine & Environment.NewLine &
"http://www.discord.me/p3d"
Else
errorText = "The required GameMode does not exist!"
@ -717,7 +717,7 @@ Public Class NewMainMenuScreen
End If
If _isNewGameButton Then
Dim text As String = "NEW" & vbNewLine & "GAME"
Dim text As String = "NEW" & Environment.NewLine & "GAME"
If alpha >= 250 And CurrentScreen.Identification = Identifications.MainMenuScreen Then
FontRenderer.DrawString(FontManager.GameJoltFont, text, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(text).X) / 2,
@ -847,7 +847,7 @@ Public Class NewMainMenuScreen
LoadGameJolt()
Else
Dim messageBox As New UI.MessageBox(CurrentScreen)
messageBox.Show("The required GameMode does not exist." & vbNewLine & "Reaquire the GameMode to play on this profile.")
messageBox.Show("The required GameMode does not exist." & Environment.NewLine & "Reaquire the GameMode to play on this profile.")
End If
End If
@ -888,7 +888,7 @@ Public Class GameModeSelectionScreen
Public Overrides Sub Draw()
PreScreen.Draw()
Dim text = "Select a GameMode" + vbNewLine + "to start the new game with"
Dim text = "Select a GameMode" + Environment.NewLine + "to start the new game with"
GetFontRenderer().DrawString(FontManager.GameJoltFont, text, New Vector2(30, 30), Color.White)

View File

@ -4,7 +4,7 @@ Friend Class SplashScreen
Inherits Screen
Private Const LICENSE_TEXT As String = """MonoGame"", the MonoGame Logo and source code are copyrights of MonoGame Team (monogame.net)." + vbNewLine +
Private Const LICENSE_TEXT As String = """MonoGame"", the MonoGame Logo and source code are copyrights of MonoGame Team (monogame.net).\n" +
"Pokémon 3D is not affiliated with Nintendo, Creatures Inc. or GAME FREAK Inc."
Private ReadOnly _monoGameLogo As Texture2D

View File

@ -220,20 +220,20 @@
offsetString = "ON (QUALITY: " & (100 - Core.GameOptions.LoadOffsetMaps).ToString() & ")"
End If
Dim t As String = "MAP: " & Level.LevelFile & vbNewLine &
"LEVEL: " & Level.MapName & vbNewLine &
"RENDERDISTANCE: " & Core.GameOptions.RenderDistance.ToString() & vbNewLine &
Dim t As String = "MAP: " & Level.LevelFile & Environment.NewLine &
"LEVEL: " & Level.MapName & Environment.NewLine &
"RENDERDISTANCE: " & Core.GameOptions.RenderDistance.ToString() & Environment.NewLine &
"OFFSETMAPS: " & offsetString
Core.SpriteBatch.DrawString(FontManager.MiniFont, t, New Vector2(2, Core.windowSize.Height - FontManager.MiniFont.MeasureString(t).Y - 2), Color.White)
Dim t2 As String = "WASD: Move around" & vbNewLine &
"MOUSE SCROLL: Change camera speed" & vbNewLine &
"LEFT MOUSE CLICK: Interact" & vbNewLine &
"ARROW KEYS UP/DOWN: Change RenderDistance" & vbNewLine &
"ARROW KEYS LEFT/RIGHT: Change Offset Map Quality" & vbNewLine &
"R: Reload map" & vbNewLine &
"Q: Replace player" & vbNewLine &
Dim t2 As String = "WASD: Move around" & Environment.NewLine &
"MOUSE SCROLL: Change camera speed" & Environment.NewLine &
"LEFT MOUSE CLICK: Interact" & Environment.NewLine &
"ARROW KEYS UP/DOWN: Change RenderDistance" & Environment.NewLine &
"ARROW KEYS LEFT/RIGHT: Change Offset Map Quality" & Environment.NewLine &
"R: Reload map" & Environment.NewLine &
"Q: Replace player" & Environment.NewLine &
"ESC: Close Map Preview"
Core.SpriteBatch.DrawString(FontManager.MiniFont, t2, New Vector2(Core.windowSize.Width - FontManager.MiniFont.MeasureString(t2).X - 2, Core.windowSize.Height - FontManager.MiniFont.MeasureString(t2).Y - 2), Color.White)

View File

@ -553,41 +553,41 @@
End If
End If
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & p.GetDisplayName() & " used~Fly.)" & vbNewLine
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & p.GetDisplayName() & " used~Fly.)" & Environment.NewLine
If CType(Screen.Camera, OverworldCamera).ThirdPerson = False Then
s &= "@camera.activateThirdPerson" & vbNewLine
s &= "@camera.activateThirdPerson" & Environment.NewLine
End If
s &= "@camera.setposition(0,0.9,3)" & vbNewLine &
"@level.wait(30)" & vbNewLine &
"@pokemon.cry(" & p.Number & ")" & vbNewLine &
"@player.wearskin([POKEMON|" & isShiny & "]" & p.Number & PokemonForms.GetOverworldAddition(p) & ")" & vbNewLine &
"@player.turnto(2)" & vbNewLine &
"@player.move(2)" & vbNewLine &
"@camera.fix" & vbNewLine &
"@player.setmovement(0,2,3)" & vbNewLine &
"@player.move(3)" & vbNewLine &
"@screen.fadeout(10)" & vbNewLine &
"@camera.defix" & vbNewLine &
"@camera.reset" & vbNewLine &
"@player.turnto(0)" & vbNewLine &
"@player.warp(" & FlyToFile & "," & FlyToPosition.X.ToString().ReplaceDecSeparator() & "," & (FlyToPosition.Y - 4 + 0.1F).ToString().ReplaceDecSeparator() & "," & (FlyToPosition.Z + 6).ToString().ReplaceDecSeparator() & ",0)" & vbNewLine &
"@camera.setyaw(0)" & vbNewLine &
"@camera.setposition(0,-3.7,-4.5)" & vbNewLine &
"@sound.play(Battle\Effects\effect_fly)" & vbNewLine &
"@level.update" & vbNewLine &
"@player.setmovement(0,-2,-3)" & vbNewLine &
"@screen.fadein(10)" & vbNewLine &
"@camera.fix" & vbNewLine &
"@player.move(2)" & vbNewLine &
"@camera.reset" & vbNewLine &
"@camera.defix(1)" & vbNewLine &
"@player.setmovement(0,-2,0)" & vbNewLine &
"@player.move(2)" & vbNewLine &
"@player.turnto(2)" & vbNewLine &
"@player.wearskin(" & skinName & ")" & vbNewLine
s &= "@camera.setposition(0,0.9,3)" & Environment.NewLine &
"@level.wait(30)" & Environment.NewLine &
"@pokemon.cry(" & p.Number & ")" & Environment.NewLine &
"@player.wearskin([POKEMON|" & isShiny & "]" & p.Number & PokemonForms.GetOverworldAddition(p) & ")" & Environment.NewLine &
"@player.turnto(2)" & Environment.NewLine &
"@player.move(2)" & Environment.NewLine &
"@camera.fix" & Environment.NewLine &
"@player.setmovement(0,2,3)" & Environment.NewLine &
"@player.move(3)" & Environment.NewLine &
"@screen.fadeout(10)" & Environment.NewLine &
"@camera.defix" & Environment.NewLine &
"@camera.reset" & Environment.NewLine &
"@player.turnto(0)" & Environment.NewLine &
"@player.warp(" & FlyToFile & "," & FlyToPosition.X.ToString().ReplaceDecSeparator() & "," & (FlyToPosition.Y - 4 + 0.1F).ToString().ReplaceDecSeparator() & "," & (FlyToPosition.Z + 6).ToString().ReplaceDecSeparator() & ",0)" & Environment.NewLine &
"@camera.setyaw(0)" & Environment.NewLine &
"@camera.setposition(0,-3.7,-4.5)" & Environment.NewLine &
"@sound.play(Battle\Effects\effect_fly)" & Environment.NewLine &
"@level.update" & Environment.NewLine &
"@player.setmovement(0,-2,-3)" & Environment.NewLine &
"@screen.fadein(10)" & Environment.NewLine &
"@camera.fix" & Environment.NewLine &
"@player.move(2)" & Environment.NewLine &
"@camera.reset" & Environment.NewLine &
"@camera.defix(1)" & Environment.NewLine &
"@player.setmovement(0,-2,0)" & Environment.NewLine &
"@player.move(2)" & Environment.NewLine &
"@player.turnto(2)" & Environment.NewLine &
"@player.wearskin(" & skinName & ")" & Environment.NewLine
While Core.CurrentScreen.Identification <> Identifications.OverworldScreen
If Core.CurrentScreen.PreScreen.Identification = Identifications.OverworldScreen Then
@ -599,10 +599,10 @@
End While
If CType(Screen.Camera, OverworldCamera).ThirdPerson = False Then
s &= "@camera.deactivatethirdperson" & vbNewLine
s &= "@camera.deactivatethirdperson" & Environment.NewLine
End If
s &= "@level.wait(1)" & vbNewLine &
s &= "@level.wait(1)" & Environment.NewLine &
":end"
PlayerStatistics.Track("Fly used", 1)
Core.Player.IsFlying = True

View File

@ -116,7 +116,7 @@
For Each line As String In Core.Player.HallOfFameData.SplitAtNewline()
If line.Contains(",") = True Then
Dim s As String = line.Remove(line.IndexOf(","))
If IsNumeric(s) = True Then
If StringHelper.IsNumeric(s) = True Then
If IDs.Contains(CInt(s)) = False Then
IDs.Add(CInt(s))
AmountOfEntries = CInt(s) + 1
@ -242,19 +242,19 @@
If id = -1 Then
Core.SpriteBatch.DrawString(FontManager.MainFont, "Player " & SelectedEntry.Name, New Vector2(pos.X + 4, pos.Y + 4), Color.White, 0.0F, Vector2.Zero, 1.5F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Playtime" & vbNewLine & vbNewLine & "OT" & vbNewLine & vbNewLine & "Points", New Vector2(pos.X + 10, pos.Y + 54), Color.White, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, SelectedEntry.PlayTime & vbNewLine & vbNewLine & SelectedEntry.OT & vbNewLine & vbNewLine & SelectedEntry.Points, New Vector2(pos.X + 116, pos.Y + 55), New Color(173, 216, 230), 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Playtime" & Environment.NewLine & Environment.NewLine & "OT" & Environment.NewLine & Environment.NewLine & "Points", New Vector2(pos.X + 10, pos.Y + 54), Color.White, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, SelectedEntry.PlayTime & Environment.NewLine & Environment.NewLine & SelectedEntry.OT & Environment.NewLine & Environment.NewLine & SelectedEntry.Points, New Vector2(pos.X + 116, pos.Y + 55), New Color(173, 216, 230), 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Else
Dim p As Pokemon = SelectedEntry.PokemonList(id).GetPokemon()
Core.SpriteBatch.Draw(p.GetMenuTexture(), New Rectangle(CInt(pos.X + 4), CInt(pos.Y + 6), 32, 32), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetDisplayName(), New Vector2(pos.X + 40, pos.Y + 4), Color.White, 0.0F, Vector2.Zero, 1.5F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Level" & vbNewLine & vbNewLine & "OT" & vbNewLine & vbNewLine & "Type 1" & vbNewLine & vbNewLine & "Type 2", New Vector2(pos.X + 10, pos.Y + 43), Color.White, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Level" & Environment.NewLine & Environment.NewLine & "OT" & Environment.NewLine & Environment.NewLine & "Type 1" & Environment.NewLine & Environment.NewLine & "Type 2", New Vector2(pos.X + 10, pos.Y + 43), Color.White, 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)
Dim s As String = p.Level & vbNewLine & vbNewLine & p.OT & " / " & p.CatchTrainerName & vbNewLine & vbNewLine & p.Type1.Type.ToString()
Dim s As String = p.Level & Environment.NewLine & Environment.NewLine & p.OT & " / " & p.CatchTrainerName & Environment.NewLine & Environment.NewLine & p.Type1.Type.ToString()
If p.Type2.Type <> Element.Types.Blank Then
s &= vbNewLine & vbNewLine & p.Type2.Type.ToString()
s &= Environment.NewLine & Environment.NewLine & p.Type2.Type.ToString()
Else
s &= vbNewLine & vbNewLine & "none"
s &= Environment.NewLine & Environment.NewLine & "none"
End If
Core.SpriteBatch.DrawString(FontManager.MainFont, s, New Vector2(pos.X + 116, pos.Y + 44), New Color(173, 216, 230), 0.0F, Vector2.Zero, 1.0F, SpriteEffects.None, 0.0F)

View File

@ -66,7 +66,7 @@
Canvas.DrawImageBorder(TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(x, y, 48, 48), ""), 1, New Rectangle(CInt(P.X), CInt(P.Y), 288, 32))
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Write new mail.", New Vector2(CInt(P.X) + 13, CInt(P.Y) + 14), Color.Black)
Else
Dim item As Item = item.GetItemByID(mail.MailID)
Dim item As Item = Item.GetItemByID(mail.MailID)
Dim x As Integer = 0
Dim y As Integer = 0
@ -101,7 +101,7 @@
Private Sub DrawCurrentMail()
If index = 0 Then
Dim mail As Items.MailItem.MailData = TempNewMail
Dim item As Item = item.GetItemByID(mail.MailID)
Dim item As Item = Item.GetItemByID(mail.MailID)
Core.SpriteBatch.Draw(item.Texture, New Rectangle(420, 84, 48, 48), Color.White)
@ -117,7 +117,7 @@
Canvas.DrawRectangle(New Rectangle(420, 140, 660, 2), Color.DarkGray)
Dim text As String = ("Text: (" & mail.MailText.Length & "/" & 200 & ")" & vbNewLine & vbNewLine & mail.MailText.Replace("<br>", vbNewLine)).CropStringToWidth(FontManager.MiniFont, 600)
Dim text As String = ("Text: (" & mail.MailText.Length & "/" & 200 & ")" & Environment.NewLine & Environment.NewLine & mail.MailText.Replace("<br>", Environment.NewLine)).CropStringToWidth(FontManager.MiniFont, 600)
If EditMailIndex = 1 Then
c = Color.Blue
text &= "_"
@ -154,7 +154,7 @@
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Cancel", New Vector2(696, yPlus + 334), Color.Black)
Else
Dim mail As Items.MailItem.MailData = Core.Player.Mails(index - 1)
Dim item As Item = item.GetItemByID(mail.MailID)
Dim item As Item = Item.GetItemByID(mail.MailID)
Core.SpriteBatch.Draw(item.Texture, New Rectangle(420, 84, 48, 48), Color.White)
@ -162,7 +162,7 @@
Canvas.DrawRectangle(New Rectangle(420, 140, 660, 2), Color.DarkGray)
Dim text As String = ("Text: " & vbNewLine & vbNewLine & mail.MailText).CropStringToWidth(FontManager.MiniFont, 600)
Dim text As String = ("Text: " & Environment.NewLine & Environment.NewLine & mail.MailText).CropStringToWidth(FontManager.MiniFont, 600)
Core.SpriteBatch.DrawString(FontManager.MiniFont, text, New Vector2(430, 160), Color.Black)
Dim yPlus As Integer = CInt(FontManager.MiniFont.MeasureString(text).Y)
@ -179,7 +179,7 @@
Dim t As TrophyInformation = GetTrophyInformation(mail.MailAttachment)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Trophy:", New Vector2(430, yPlus + 320), Color.Black)
Core.SpriteBatch.Draw(t.Texture, New Rectangle(430, yPlus + 340, 64, 64), Color.White)
Core.SpriteBatch.DrawString(FontManager.MiniFont, (t.Name & vbNewLine & vbNewLine & t.Description).CropStringToWidth(FontManager.MiniFont, 500), New Vector2(510, yPlus + 340), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, (t.Name & Environment.NewLine & Environment.NewLine & t.Description).CropStringToWidth(FontManager.MiniFont, 500), New Vector2(510, yPlus + 340), Color.Black)
End If
End If
End Sub
@ -264,13 +264,13 @@
Select Case EditMailIndex
Case 0
KeyBindings.GetInput(TempNewMail.MailHeader, 25, True, True)
TempNewMail.MailHeader = TempNewMail.MailHeader.Replace("\,", ",").Replace(vbNewLine, "").Replace("|", "/")
TempNewMail.MailHeader = TempNewMail.MailHeader.Replace("\,", ",").Replace(Environment.NewLine, "").Replace("|", "/")
Case 1
KeyBindings.GetInput(TempNewMail.MailText, 200, True, True)
TempNewMail.MailText = TempNewMail.MailText.Replace("\,", ",").Replace(vbNewLine, "<br>").Replace("|", "/")
TempNewMail.MailText = TempNewMail.MailText.Replace("\,", ",").Replace(Environment.NewLine, "<br>").Replace("|", "/")
Case 2
KeyBindings.GetInput(TempNewMail.MailSignature, 25, True, True)
TempNewMail.MailSignature = TempNewMail.MailSignature.Replace("\,", ",").Replace(vbNewLine, "").Replace("|", "/")
TempNewMail.MailSignature = TempNewMail.MailSignature.Replace("\,", ",").Replace(Environment.NewLine, "").Replace("|", "/")
End Select
End If

View File

@ -729,7 +729,7 @@ Public Class StorageSystemScreen
Dim returnData As String = ""
For Each l As String In newData
If returnData <> "" Then
returnData &= vbNewLine
returnData &= Environment.NewLine
End If
returnData &= l
Next
@ -1273,7 +1273,7 @@ Public Class StorageSystemScreen
maxPokemon = 6
End If
Dim t As String = "Box: " & box.Name & vbNewLine & "Pokémon: " & box.Pokemon.Count & " / " & maxPokemon & vbNewLine & "Level: " & levelString
Dim t As String = "Box: " & box.Name & Environment.NewLine & "Pokémon: " & box.Pokemon.Count & " / " & maxPokemon & Environment.NewLine & "Level: " & levelString
Core.SpriteBatch.DrawString(FontManager.MiniFont, t, New Vector2(667, 417), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, t, New Vector2(665, 415), Color.White)
@ -1345,15 +1345,15 @@ Public Class StorageSystemScreen
nameString = p.GetDisplayName()
End If
Dim t As String = nameString & vbNewLine &
"DEX NO. " & p.Number & vbNewLine &
"LEVEL " & p.Level & vbNewLine &
"HP " & p.HP & " / " & p.MaxHP & vbNewLine &
"ATTACK " & p.Attack & vbNewLine &
"DEFENSE " & p.Defense & vbNewLine &
"SP. ATK " & p.SpAttack & vbNewLine &
"SP. DEF " & p.SpDefense & vbNewLine &
"SPEED " & p.Speed & vbNewLine &
Dim t As String = nameString & Environment.NewLine &
"DEX NO. " & p.Number & Environment.NewLine &
"LEVEL " & p.Level & Environment.NewLine &
"HP " & p.HP & " / " & p.MaxHP & Environment.NewLine &
"ATTACK " & p.Attack & Environment.NewLine &
"DEFENSE " & p.Defense & Environment.NewLine &
"SP. ATK " & p.SpAttack & Environment.NewLine &
"SP. DEF " & p.SpDefense & Environment.NewLine &
"SPEED " & p.Speed & Environment.NewLine &
"ITEM " & itemString
Core.SpriteBatch.DrawString(FontManager.MiniFont, t, New Vector2(667, 417), Color.Black)
@ -1982,8 +1982,8 @@ Public Class StorageSystemFilterScreen
Next
If Filters.Count > 0 Then
Core.SpriteBatch.DrawString(FontManager.MainFont, "Results: " & vbNewLine & vbNewLine & "Filters: ", New Vector2(90 + 64 * 11, 119), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MainFont, Me.Results & vbNewLine & vbNewLine & Me.Filters.Count, New Vector2(190 + 64 * 11, 119), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Results: " & Environment.NewLine & Environment.NewLine & "Filters: ", New Vector2(90 + 64 * 11, 119), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MainFont, Me.Results & Environment.NewLine & Environment.NewLine & Me.Filters.Count, New Vector2(190 + 64 * 11, 119), Color.White)
End If
If Menu.Visible = True Then

View File

@ -498,13 +498,13 @@ Public Class PokedexScreen
If CHabitat Is Nothing Then
Core.SpriteBatch.DrawString(FontManager.MainFont, Profile.Pokedex.Name, New Vector2(60, 55), Color.White, 0.0F, Vector2.Zero, 1.5F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Seen: " & vbNewLine & vbNewLine & "Obtained: ", New Vector2(420, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, Profile.Seen + Profile.Obtained & vbNewLine & vbNewLine & Profile.Obtained, New Vector2(540, 45), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Seen: " & Environment.NewLine & Environment.NewLine & "Obtained: ", New Vector2(420, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, Profile.Seen + Profile.Obtained & Environment.NewLine & Environment.NewLine & Profile.Obtained, New Vector2(540, 45), Color.Black)
Else
Core.SpriteBatch.DrawString(FontManager.MainFont, CHabitat.Name, New Vector2(60, 80), Color.White, 0.0F, Vector2.Zero, 1.5F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.Draw(CHabitat.Texture, New Rectangle(60, 32, 64, 48), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Available: " & vbNewLine & vbNewLine & "Obtained: ", New Vector2(420, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, CHabitat.PokemonList.Count & vbNewLine & vbNewLine & CHabitat.PokemonCaught, New Vector2(540, 45), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Available: " & Environment.NewLine & Environment.NewLine & "Obtained: ", New Vector2(420, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, CHabitat.PokemonList.Count & Environment.NewLine & Environment.NewLine & CHabitat.PokemonCaught, New Vector2(540, 45), Color.Black)
Dim progressTexture As Texture2D = Me.CHabitat.ProgressTexture
If Not progressTexture Is Nothing Then
@ -594,8 +594,8 @@ Public Class PokedexScreen
End Select
Next
End If
Core.SpriteBatch.DrawString(FontManager.MainFont, "Order:" & vbNewLine & "Filter:" & vbNewLine & "Press Q on the keyboard to search.", New Vector2(685, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, orderText & vbNewLine & filterText, New Vector2(790, 45), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Order:" & Environment.NewLine & "Filter:" & Environment.NewLine & "Press Q on the keyboard to search.", New Vector2(685, 45), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, orderText & Environment.NewLine & filterText, New Vector2(790, 45), Color.Black)
If menu.Visible = True Then
menu.Draw()
@ -636,9 +636,9 @@ Public Class PokedexScreen
End While
If entryType = 0 Then
Core.SpriteBatch.DrawString(FontManager.MainFont, "???" & vbNewLine & vbNewLine & "No. " & no, New Vector2(830, 200), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "???" & Environment.NewLine & Environment.NewLine & "No. " & no, New Vector2(830, 200), Color.White)
Else
Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetName() & vbNewLine & vbNewLine & "No. " & no, New Vector2(830, 200), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, p.GetName() & Environment.NewLine & Environment.NewLine & "No. " & no, New Vector2(830, 200), Color.White)
Core.SpriteBatch.Draw(p.GetTexture(True), New Rectangle(670, 140, 128, 128), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "SPECIES", New Vector2(680, 310), Color.Black)
@ -1110,7 +1110,7 @@ Public Class PokedexScreen
Dim dayTimes As New List(Of Integer)
For Each s As String In daytimesData
If IsNumeric(s) = True Then
If StringHelper.IsNumeric(s) = True Then
Dim i As Integer = CInt(s)
If i > 0 Then
dayTimes.Add(i)

View File

@ -86,7 +86,7 @@
If c = CChar(" ") Then
If FontManager.MiniFont.MeasureString(n & c).X > 170 Then
t &= vbNewLine
t &= Environment.NewLine
n = ""
Else
t &= " "
@ -108,7 +108,7 @@
acc = "-"
End If
.DrawString(FontManager.MiniFont, "Power: " & power & vbNewLine & "Accuracy: " & acc & vbNewLine & vbNewLine & t, New Vector2(CInt(p.X + 432 - 300 + AttackPos), p.Y + 38), Color.Black)
.DrawString(FontManager.MiniFont, "Power: " & power & Environment.NewLine & "Accuracy: " & acc & Environment.NewLine & Environment.NewLine & t, New Vector2(CInt(p.X + 432 - 300 + AttackPos), p.Y + 38), Color.Black)
.Draw(A.GetDamageCategoryImage(), New Rectangle(CInt(p.X + 432 - 150 + AttackPos), CInt(p.Y + 42), 56, 28), Color.White)
End With

View File

@ -361,7 +361,7 @@
End If
End If
If p1.IsGenderLess = True Then
If p1.IsGenderless = True Then
If p2.EggGroup1 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Or p2.EggGroup2 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Then
chance = -1
Else
@ -369,7 +369,7 @@
chance = -1
End If
End If
ElseIf p2.IsGenderLess = True Then
ElseIf p2.IsGenderless = True Then
If p1.EggGroup1 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Or p1.EggGroup2 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Then
chance = -1
Else
@ -377,7 +377,7 @@
chance = -1
End If
End If
ElseIf p1.IsGenderLess = False And p2.IsGenderLess = False Then
ElseIf p1.IsGenderless = False And p2.IsGenderless = False Then
If p1.Gender <> p2.Gender Then
If p1.EggGroup1 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Or p2.EggGroup1 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Or p1.EggGroup2 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Or p2.EggGroup2 = net.Pokemon3D.Game.Pokemon.EggGroups.Ditto Then
chance = -1
@ -562,12 +562,12 @@
Dim newEggID As Integer = net.Pokemon3D.Game.Pokemon.GetPokemonByID(parentID).EggPokemon
Dim s As String = DaycareID.ToString() & "|Egg|" & newEggID.ToString()
Logger.Debug("Egg created!" & vbNewLine & "EggID: " & newEggID)
Logger.Debug("Egg created!" & Environment.NewLine & "EggID: " & newEggID)
TriggerCall(DaycareID)
Dim oldData As String = Core.Player.DaycareData
If oldData <> "" Then
oldData &= vbNewLine
oldData &= Environment.NewLine
End If
oldData &= s
Core.Player.DaycareData = oldData

View File

@ -129,7 +129,7 @@
If c = CChar(" ") Then
If FontManager.MiniFont.MeasureString(n & c).X > 170 Then
t &= vbNewLine
t &= Environment.NewLine
n = ""
Else
t &= " "
@ -151,7 +151,7 @@
acc = "-"
End If
.DrawString(FontManager.MiniFont, "Power: " & power & vbNewLine & "Accuracy: " & acc & vbNewLine & vbNewLine & t, New Vector2(CInt(p.X + 432 - 300 + AttackPos), p.Y + 38), Color.Black)
.DrawString(FontManager.MiniFont, "Power: " & power & Environment.NewLine & "Accuracy: " & acc & Environment.NewLine & Environment.NewLine & t, New Vector2(CInt(p.X + 432 - 300 + AttackPos), p.Y + 38), Color.Black)
.Draw(A.GetDamageCategoryImage(), New Rectangle(CInt(p.X + 432 - 150 + AttackPos), CInt(p.Y + 42), 56, 28), Color.White)
End With
@ -175,7 +175,7 @@
Else
drawText = "Forget """ & Pokemon.Attacks(AttackIndex).Name & """ to learn """ & newAttack.Name & """?"
If canForget = False Then
drawText = "Cannot forget the move " & Pokemon.Attacks(AttackIndex).Name & " because" & vbNewLine & "it's a Hidden Machine move."
drawText = "Cannot forget the move " & Pokemon.Attacks(AttackIndex).Name & " because" & Environment.NewLine & "it's a Hidden Machine move."
End If
End If
@ -221,15 +221,15 @@
End If
If currentCharIndex > (Pokemon.GetDisplayName() & " ").Length + 1 Then
If currentCharIndex < GetText().Length Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, ("wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & vbNewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?").Remove(currentCharIndex - (Pokemon.GetDisplayName() & " ").Length), New Vector2(FontManager.MiniFont.MeasureString(Pokemon.GetDisplayName()).X + 152, 20), Color.White)
Core.SpriteBatch.DrawString(FontManager.MiniFont, ("wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & Environment.NewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?").Remove(currentCharIndex - (Pokemon.GetDisplayName() & " ").Length), New Vector2(FontManager.MiniFont.MeasureString(Pokemon.GetDisplayName()).X + 152, 20), Color.White)
Else
Core.SpriteBatch.DrawString(FontManager.MiniFont, "wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & vbNewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?", New Vector2(FontManager.MiniFont.MeasureString(Pokemon.GetDisplayName()).X + 152, 20), Color.White)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & Environment.NewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?", New Vector2(FontManager.MiniFont.MeasureString(Pokemon.GetDisplayName()).X + 152, 20), Color.White)
End If
End If
End Sub
Private Function GetText() As String
Return Pokemon.GetDisplayName() & " wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & vbNewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?"
Return Pokemon.GetDisplayName() & " wants to learn """ & newAttack.Name & """. But " & Pokemon.GetDisplayName() & " can only learn 4 attacks." & Environment.NewLine & "Do you want " & Pokemon.GetDisplayName() & " to forget an attack to learn """ & newAttack.Name & """?"
End Function
Private Sub DrawAttack(ByVal i As Integer, ByVal A As BattleSystem.Attack)

View File

@ -119,8 +119,8 @@ Public Class NameObjectScreen
Core.SpriteBatch.DrawString(FontManager.InGameFont, "Rename " & Me._defaultName & genderString & "?", New Vector2(CInt(Core.windowSize.Width / 2) - 182 + 22, 90), Color.White)
If genderUnicode <> 0 Then
Core.SpriteBatch.DrawString(FontManager.TextFont, ChrW(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Rename " & Me._defaultName).X - 147, 93), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, ChrW(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Rename " & Me._defaultName).X - 150, 90), Color.White, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, StringHelper.GetChar(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Rename " & Me._defaultName).X - 147, 93), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, StringHelper.GetChar(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Rename " & Me._defaultName).X - 150, 90), Color.White, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
End If
ChooseBox.Showing = False
@ -142,8 +142,8 @@ Public Class NameObjectScreen
Core.SpriteBatch.DrawString(FontManager.InGameFont, "Enter name for " & Me._defaultName & genderString & ":", New Vector2(CInt(Core.windowSize.Width / 2) - 182 + 22, 90), Color.White)
If genderUnicode <> 0 Then
Core.SpriteBatch.DrawString(FontManager.TextFont, ChrW(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Enter name for " & Me._defaultName).X - 150, 93), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, ChrW(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Enter name for " & Me._defaultName).X - 153, 90), Color.White, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, StringHelper.GetChar(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Enter name for " & Me._defaultName).X - 150, 93), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.TextFont, StringHelper.GetChar(genderUnicode), New Vector2(CInt(Core.windowSize.Width / 2) + FontManager.InGameFont.MeasureString("Enter name for " & Me._defaultName).X - 153, 90), Color.White, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
End If
Canvas.DrawRectangle(New Rectangle(CInt(Core.windowSize.Width / 2) - 89, 136, 208, 32), New Color(101, 142, 255))

View File

@ -852,19 +852,19 @@ Public Class PartyScreen
Core.SetScreen(Core.CurrentScreen.PreScreen)
End If
If Screen.Level.IsDark = True Then
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & PokemonList(_index).GetDisplayName() & " used~Flash!)" & vbNewLine &
"@environment.toggledarkness" & vbNewLine &
"@sound.play(Battle\Effects\effect_thunderbolt)" & vbNewLine &
"@text.show(The area got lit up!)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & PokemonList(_index).GetDisplayName() & " used~Flash!)" & Environment.NewLine &
"@environment.toggledarkness" & Environment.NewLine &
"@sound.play(Battle\Effects\effect_thunderbolt)" & Environment.NewLine &
"@text.show(The area got lit up!)" & Environment.NewLine &
":end"
PlayerStatistics.Track("Flash used", 1)
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
Else
Dim s As String = "version=2" & vbNewLine &
"@text.show(" & PokemonList(_index).GetDisplayName() & " used~Flash!)" & vbNewLine &
"@sound.play(Battle\Effects\effect_thunderbolt)" & vbNewLine &
"@text.show(The area is already~lit up!)" & vbNewLine &
Dim s As String = "version=2" & Environment.NewLine &
"@text.show(" & PokemonList(_index).GetDisplayName() & " used~Flash!)" & Environment.NewLine &
"@sound.play(Battle\Effects\effect_thunderbolt)" & Environment.NewLine &
"@text.show(The area is already~lit up!)" & Environment.NewLine &
":end"
CType(Core.CurrentScreen, OverworldScreen).ActionScript.StartScript(s, 2)
End If
@ -985,13 +985,13 @@ Public Class PartyScreen
:endwhile
@screen.fadeout
@camera.defix
@player.warp(" & Core.Player.LastRestPlace & "," & Core.Player.LastRestPlacePosition & ",0)" & vbNewLine &
@player.warp(" & Core.Player.LastRestPlace & "," & Core.Player.LastRestPlacePosition & ",0)" & Environment.NewLine &
"@player.turnto(2)"
If setToFirstPerson = True Then
s &= vbNewLine & "@camera.deactivatethirdperson"
s &= Environment.NewLine & "@camera.deactivatethirdperson"
End If
s &= vbNewLine &
s &= Environment.NewLine &
"@level.update
@screen.fadein
:end"
@ -1034,9 +1034,9 @@ Public Class PartyScreen
@player.turnto(2)"
If setToFirstPerson = True Then
s &= vbNewLine & "@camera.deactivatethirdperson"
s &= Environment.NewLine & "@camera.deactivatethirdperson"
End If
s &= vbNewLine &
s &= Environment.NewLine &
"@level.update
@screen.fadein
:end"

View File

@ -517,11 +517,11 @@
Dim s As String = ""
Dim percent As Integer = CInt((GetPokemon().EggSteps / GetPokemon().BaseEggSteps) * 100)
If percent <= 33 Then
s = "It looks like this Egg will" & vbNewLine & "take a long time to hatch."
s = "It looks like this Egg will" & Environment.NewLine & "take a long time to hatch."
ElseIf percent > 33 And percent <= 66 Then
s = "It's getting warmer and moves" & vbNewLine & "a little. It will hatch soon."
s = "It's getting warmer and moves" & Environment.NewLine & "a little. It will hatch soon."
Else
s = "There is strong movement" & vbNewLine & "noticeable. It will hatch soon!"
s = "There is strong movement" & Environment.NewLine & "noticeable. It will hatch soon!"
End If
Canvas.DrawRectangle(New Rectangle(450, 172, 350, 32), New Color(0, 0, 0, CInt(100 * _fadeIn)))

View File

@ -112,7 +112,7 @@
Core.SpriteBatch.Draw(Pokemon.GetTexture(True), New Rectangle(80, 100, 128, 128), Color.White)
Core.SpriteBatch.DrawString(FontManager.MiniFont, Pokemon.GetDisplayName() & vbNewLine & "Level: " & Pokemon.Level, New Vector2(80, 260), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, Pokemon.GetDisplayName() & Environment.NewLine & "Level: " & Pokemon.Level, New Vector2(80, 260), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Pokémon's moves:", New Vector2(245, 140), Color.Black)
For i = 0 To Pokemon.Attacks.Count - 1
@ -122,7 +122,7 @@
Next
If Me.MovesList.Count = 0 Then
Core.SpriteBatch.DrawString(FontManager.MiniFont, "The Pokémon cannot learn" & vbNewLine & "a new move here.", New Vector2(580, 140), Color.Black)
Core.SpriteBatch.DrawString(FontManager.MiniFont, "The Pokémon cannot learn" & Environment.NewLine & "a new move here.", New Vector2(580, 140), Color.Black)
Else
Core.SpriteBatch.DrawString(FontManager.MiniFont, "Tutor moves (" & MovesList.Count & "):", New Vector2(580, 140), Color.Black)

View File

@ -50,35 +50,35 @@
If Core.GameOptions.Extras.Contains("Backup Save Feature") Then
.DrawString(FontManager.MiniFont,
"Press Dismiss to close this" & vbNewLine &
"screen and try to save again" & vbNewLine &
"in order to prevent data" & vbNewLine &
"corruption." & vbNewLine & vbNewLine & vbNewLine &
"Your save has been backed" & vbNewLine &
"up in the event of the" & vbNewLine &
"Press Dismiss to close this" & Environment.NewLine &
"screen and try to save again" & Environment.NewLine &
"in order to prevent data" & Environment.NewLine &
"corruption." & Environment.NewLine & Environment.NewLine & Environment.NewLine &
"Your save has been backed" & Environment.NewLine &
"up in the event of the" & Environment.NewLine &
"Gamejolt API being down.", New Vector2(Delta_X + 90, Delta_Y + 100), Color.Black)
.DrawString(FontManager.MiniFont,
"You may safely quit the" & vbNewLine &
"game now or try to save" & vbNewLine &
"again later." & vbNewLine & vbNewLine & vbNewLine &
"The backup save can be" & vbNewLine &
"found in the Backup Save" & vbNewLine &
"You may safely quit the" & Environment.NewLine &
"game now or try to save" & Environment.NewLine &
"again later." & Environment.NewLine & Environment.NewLine & Environment.NewLine &
"The backup save can be" & Environment.NewLine &
"found in the Backup Save" & Environment.NewLine &
"folder", New Vector2(Delta_X + 390, Delta_Y + 100), Color.Black)
Else
.DrawString(FontManager.MiniFont,
"Press Dismiss to close this" & vbNewLine &
"screen and try to save again" & vbNewLine &
"in order to prevent data" & vbNewLine &
"corruption." & vbNewLine & vbNewLine & vbNewLine &
"If the problem persists, the" & vbNewLine &
"GameJolt servers could be" & vbNewLine &
"down for maintenance right" & vbNewLine &
"Press Dismiss to close this" & Environment.NewLine &
"screen and try to save again" & Environment.NewLine &
"in order to prevent data" & Environment.NewLine &
"corruption." & Environment.NewLine & Environment.NewLine & Environment.NewLine &
"If the problem persists, the" & Environment.NewLine &
"GameJolt servers could be" & Environment.NewLine &
"down for maintenance right" & Environment.NewLine &
"now.", New Vector2(Delta_X + 90, Delta_Y + 100), Color.Black)
.DrawString(FontManager.MiniFont, "Please try again later," & vbNewLine &
"or contact us here:" & vbNewLine & vbNewLine &
"Discord server" & vbNewLine &
"www.discord.me/p3d" & vbNewLine & vbNewLine &
"Official Forum" & vbNewLine &
.DrawString(FontManager.MiniFont, "Please try again later," & Environment.NewLine &
"or contact us here:" & Environment.NewLine & Environment.NewLine &
"Discord server" & Environment.NewLine &
"www.discord.me/p3d" & Environment.NewLine & Environment.NewLine &
"Official Forum" & Environment.NewLine &
"pokemon3d.net/forum/news", New Vector2(Delta_X + 390, Delta_Y + 100), Color.Black)
End If
@ -124,7 +124,7 @@
End If
Next
.DrawString(FontManager.MiniFont, Localization.GetString("save_screen_name") & ": " & Core.Player.Name & vbNewLine & vbNewLine & Localization.GetString("save_screen_badges") & ": " & Core.Player.Badges.Count.ToString() & vbNewLine & vbNewLine & Localization.GetString("save_screen_money") & ": " & Core.Player.Money & vbNewLine & vbNewLine & Localization.GetString("save_screen_time") & ": " & TimeHelpers.GetDisplayTime(TimeHelpers.GetCurrentPlayTime(), True), New Vector2(Delta_X + 400, Delta_Y + 215), Color.DarkBlue)
.DrawString(FontManager.MiniFont, Localization.GetString("save_screen_name") & ": " & Core.Player.Name & Environment.NewLine & Environment.NewLine & Localization.GetString("save_screen_badges") & ": " & Core.Player.Badges.Count.ToString() & Environment.NewLine & Environment.NewLine & Localization.GetString("save_screen_money") & ": " & Core.Player.Money & Environment.NewLine & Environment.NewLine & Localization.GetString("save_screen_time") & ": " & TimeHelpers.GetDisplayTime(TimeHelpers.GetCurrentPlayTime(), True), New Vector2(Delta_X + 400, Delta_Y + 215), Color.DarkBlue)
End If
End With
Screen.ChooseBox.Draw(New Vector2(Delta_X + 115, Delta_Y + 155), False, 1.5F)

View File

@ -736,7 +736,7 @@ Public Class TradeScreen
Core.SpriteBatch.Draw(texture, New Rectangle(856, 484, 64, 64), New Rectangle(16, 32, 16, 16), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "+", New Vector2(856 + 19, 484 + 6), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Per Item: " & selectedItem.Price.ToString() & GetCurrencyShort() & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MainFont, "Per Item: " & selectedItem.Price.ToString() & GetCurrencyShort() & Environment.NewLine &
"Total: " & (BuyItemsAmount * selectedItem.Price).ToString() & GetCurrencyShort(), New Vector2(930, 490), Color.White)
' Buy button:
@ -1073,7 +1073,7 @@ Public Class TradeScreen
Core.SpriteBatch.Draw(texture, New Rectangle(856, 484, 64, 64), New Rectangle(16, 32, 16, 16), Color.White)
Core.SpriteBatch.DrawString(FontManager.MainFont, "+", New Vector2(856 + 19, 484 + 6), Color.Black, 0.0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0.0F)
Core.SpriteBatch.DrawString(FontManager.MainFont, "Per Item: " & selectedItem.SellPrice().ToString() & GetCurrencyShort() & vbNewLine &
Core.SpriteBatch.DrawString(FontManager.MainFont, "Per Item: " & selectedItem.SellPrice().ToString() & GetCurrencyShort() & Environment.NewLine &
"Total: " & (SellItemsAmount * selectedItem.SellPrice()).ToString() & GetCurrencyShort(), New Vector2(930, 490), Color.White)
' Sell button:
@ -1143,7 +1143,7 @@ Public Class TradeScreen
Dim tradeItem As TradeItem = Me.SellItemsList(Me.Scroll + Me.Cursor)
Dim text As String = "Do you want to sell" & vbNewLine & Me.SellItemsAmount & " " & tradeItem.GetItem().Name & "?"
Dim text As String = "Do you want to sell" & Environment.NewLine & Me.SellItemsAmount & " " & tradeItem.GetItem().Name & "?"
Core.SpriteBatch.DrawString(FontManager.MiniFont,
text,

View File

@ -1,4 +1,6 @@
Namespace Security
Imports System.Windows.Forms
Namespace Security
Public Class HackerAlerts
@ -23,7 +25,7 @@ http://pokemon3d.net/forum/faq/44/
Thank you for your cooperation."
MsgBox(text, MsgBoxStyle.OkOnly, "Pokémon 3D Injection Shield")
MessageBox.Show(text, "Pokémon 3D Injection Shield", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
t.Start()
End Sub

View File

@ -123,7 +123,7 @@ nextScript:
If System.IO.File.Exists(path) = True Then
Dim Data As String = System.IO.File.ReadAllText(path)
Data = Data.Replace(vbNewLine, "^")
Data = Data.Replace(Environment.NewLine, "^")
Dim ScriptData() As String = Data.Split(CChar("^"))
AddScriptLines(ScriptData)
@ -140,13 +140,13 @@ nextScript:
AddScriptLines(ScriptData)
Case 2 ' Start a script from direct input.
Dim activator As String = Environment.StackTrace.Split(vbNewLine)(3)
Dim activator As String = Environment.StackTrace.Split(Environment.NewLine)(3)
activator = activator.Remove(activator.IndexOf("("))
Logger.Debug("Start Script (DirectInput; " & activator & ")")
l.ScriptName = "Type: Direct; Input: " & Input
Dim Data As String = Input.Replace(vbNewLine, "^")
Dim Data As String = Input.Replace(Environment.NewLine, "^")
Dim ScriptData() As String = Data.Split(CChar("^"))
@ -163,10 +163,10 @@ nextScript:
l.ScriptVersion = CInt(newScript.Remove(0, ("version=").Length))
l.CurrentLine += 1
Else
While newScript.StartsWith(" ") = True Or newScript.StartsWith(vbTab) = True
While newScript.StartsWith(" ") = True Or newScript.StartsWith(StringHelper.Tab) = True
newScript = newScript.Remove(0, 1)
End While
While newScript.EndsWith(" ") = True Or newScript.EndsWith(vbTab) = True
While newScript.EndsWith(" ") = True Or newScript.EndsWith(StringHelper.Tab) = True
newScript = newScript.Remove(newScript.Length - 1, 1)
End While
If newScript <> "" Then
@ -369,37 +369,40 @@ nextScript:
Dim remove As Boolean = False
Dim date1 = Date.Now
Dim date2 = regDate
Dim diff = date1 - date2
Select Case format
Case "days", "day"
If DateDiff(DateInterval.Day, regDate, Date.Now) >= value Then
If diff.Days >= value Then
remove = True
End If
Case "minutes", "minute"
If DateDiff(DateInterval.Minute, regDate, Date.Now) >= value Then
If diff.Minutes >= value Then
remove = True
End If
Case "seconds", "second"
If DateDiff(DateInterval.Second, regDate, Date.Now) >= value Then
If diff.Seconds >= value Then
remove = True
End If
Case "years", "year"
If CInt(Math.Floor(DateDiff(DateInterval.Day, regDate, Date.Now) / 365)) >= value Then
If CInt(Math.Floor(diff.TotalDays / 365)) >= value Then
remove = True
End If
Case "weeks", "week"
If CInt(Math.Floor(DateDiff(DateInterval.Day, regDate, Date.Now) / 7)) >= value Then
If CInt(Math.Floor(diff.TotalDays / 7)) >= value Then
remove = True
End If
Case "months", "month"
If DateDiff(DateInterval.Month, regDate, Date.Now) >= value Then
If ((date1.Year - date2.Year) * 12) + date1.Month - date2.Month >= value Then
remove = True
End If
Case "hours", "hour"
If DateDiff(DateInterval.Hour, regDate, Date.Now) >= value Then
If diff.Hours >= value Then
remove = True
End If
Case "dayofweek"
If DateDiff(DateInterval.Weekday, regDate, Date.Now) >= value Then
If CInt(Math.Floor(diff.TotalDays / 7)) >= value Then
remove = True
End If
End Select
@ -431,17 +434,13 @@ nextScript:
End Sub
Public Shared Function UnixToTime(ByVal strUnixTime As String) As Date
UnixToTime = DateAdd(DateInterval.Second, Val(strUnixTime), #1/1/1970#)
If UnixToTime.IsDaylightSavingTime = True Then
UnixToTime = DateAdd(DateInterval.Hour, 1, UnixToTime)
End If
Dim unixDate = New Date(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc)
unixDate.AddSeconds(Convert.ToInt64(strUnixTime)).ToLocalTime()
Return unixDate
End Function
Public Shared Function TimeToUnix(ByVal dteDate As Date) As String
If dteDate.IsDaylightSavingTime = True Then
dteDate = DateAdd(DateInterval.Hour, -1, dteDate)
End If
TimeToUnix = DateDiff(DateInterval.Second, #1/1/1970#, dteDate).ToString()
Return (dteDate.ToUniversalTime() - New Date(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc)).TotalSeconds.ToString()
End Function
Public Shared Sub RegisterID(ByVal i As String)

Some files were not shown because too many files have changed in this diff Show More