diff --git a/2.5DHero/2.5DHero/2.5DHero.vbproj b/2.5DHero/2.5DHero/2.5DHero.vbproj index 61536e744..58154a5d4 100644 --- a/2.5DHero/2.5DHero/2.5DHero.vbproj +++ b/2.5DHero/2.5DHero/2.5DHero.vbproj @@ -61,6 +61,9 @@ + + + $(MonoGameInstallDirectory)\MonoGame\v3.0\Assemblies\DesktopGL\MonoGame.Framework.dll @@ -1679,9 +1682,11 @@ - + + + @@ -1729,6 +1734,7 @@ + @@ -1746,6 +1752,7 @@ + @@ -1780,6 +1787,7 @@ + \ No newline at end of file diff --git a/2.5DHero/2.5DHero/Core/Core.vb b/2.5DHero/2.5DHero/Core/Core.vb index 28ffcdef0..e83191cd0 100644 --- a/2.5DHero/2.5DHero/Core/Core.vb +++ b/2.5DHero/2.5DHero/Core/Core.vb @@ -78,7 +78,7 @@ If CommandLineArgHandler.NoSplash = True Then Core.LoadContent() - SetScreen(New MainMenuScreen()) + SetScreen(New PressStartScreen()) Else SetScreen(New SplashScreen(GameInstance)) End If diff --git a/2.5DHero/2.5DHero/Network/GameJolt/API.vb b/2.5DHero/2.5DHero/Network/GameJolt/API.vb index 74795eeee..7a35a8f3e 100644 --- a/2.5DHero/2.5DHero/Network/GameJolt/API.vb +++ b/2.5DHero/2.5DHero/Network/GameJolt/API.vb @@ -6,6 +6,7 @@ Public Shared username As String = "" Public Shared token As String = "" + Public Shared gameJoltId As String = "" Public Shared LoggedIn As Boolean = False diff --git a/2.5DHero/2.5DHero/Resources/FontManager.vb b/2.5DHero/2.5DHero/Resources/FontManager.vb index 645a69e31..d0ee6605c 100644 --- a/2.5DHero/2.5DHero/Resources/FontManager.vb +++ b/2.5DHero/2.5DHero/Resources/FontManager.vb @@ -128,7 +128,7 @@ Public Class FontManager Return loadedGameJoltFont Else hasLoadedGameJoltFont = True - loadedGameJoltFont = Content.Load(Of SpriteFont)("SharedResources\Fonts\GameJolt") + loadedGameJoltFont = Content.Load(Of SpriteFont)("Fonts\BMP\GameJolt") loadedGameJoltFont.DefaultCharacter = " "c Return loadedGameJoltFont End If diff --git a/2.5DHero/2.5DHero/Resources/GameModeManager.vb b/2.5DHero/2.5DHero/Resources/GameModeManager.vb index ba4895665..972822ba3 100644 --- a/2.5DHero/2.5DHero/Resources/GameModeManager.vb +++ b/2.5DHero/2.5DHero/Resources/GameModeManager.vb @@ -67,6 +67,12 @@ Public Class GameModeManager End Get End Property + Public Shared ReadOnly Property GetAllGameModes() As GameMode() + Get + Return GameModeList.ToArray() + End Get + End Property + ''' ''' Checks if a GameMode exists. ''' @@ -548,7 +554,7 @@ Public Class GameMode Dim SkinNames As List(Of String) = {"Ethan", "Lyra", "Nate", "Rosa", "Hilbert", "Hilda"}.ToList() Dim gameMode As New GameMode("Pokemon 3D", "The normal game mode.", GameController.GAMEVERSION, "Kolben Games", "\maps\", "\Scripts\", "\maps\poke\", "\Content\Pokemon\Data\", "\Content\", "\Content\Localization\", New List(Of GameRule), - "yourroom.dat", New Vector3(1.0F, 0.1F, 3.0F), MathHelper.PiOver2, "Your Room", "", New Color(59, 123, 165), "0", "welcome", SkinColors, SkinFiles, SkinNames) + "newgame\intro0.dat", New Vector3(1.0F, 0.1F, 3.0F), MathHelper.PiOver2, "Your Room", "", New Color(59, 123, 165), "0", "welcome", SkinColors, SkinFiles, SkinNames) Dim gameRules As New List(Of GameRule) gameRules.Add(New GameRule("MaxLevel", "100")) diff --git a/2.5DHero/2.5DHero/Screens/Battle/BlackOutScreen.vb b/2.5DHero/2.5DHero/Screens/Battle/BlackOutScreen.vb index 99f8e6b6c..b8ab0ed0e 100644 --- a/2.5DHero/2.5DHero/Screens/Battle/BlackOutScreen.vb +++ b/2.5DHero/2.5DHero/Screens/Battle/BlackOutScreen.vb @@ -34,7 +34,7 @@ Public Overrides Sub Update() If Me.IsGameOver = True Then If Controls.Accept(True, False) = True Then - Core.SetScreen(New MainMenuScreen()) + Core.SetScreen(New PressStartScreen()) Core.Player.loadedSave = False End If Else diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/ConnectScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/ConnectScreen.vb index 535672366..2d58d485d 100644 --- a/2.5DHero/2.5DHero/Screens/MainMenu/ConnectScreen.vb +++ b/2.5DHero/2.5DHero/Screens/MainMenu/ConnectScreen.vb @@ -73,7 +73,7 @@ If Me.MyMode = Modes.Disconnect Then If Controls.Accept(True, True, True) = True Or Controls.Dismiss(True, True, True) = True Then If quitToMenu = True Then - Core.SetScreen(New MainMenuScreen()) + Core.SetScreen(New PressStartScreen()) Else Core.SetScreen(Me.PreScreen) End If @@ -86,7 +86,7 @@ If Controls.Dismiss() = True Then Connected = False Core.ServersManager.ServerConnection.Disconnect() - Core.SetScreen(New MainMenuScreen()) + Core.SetScreen(New PressStartScreen()) End If End If End Sub diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/JoinServerScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/JoinServerScreen.vb index 5a5690b16..b517aef3b 100644 --- a/2.5DHero/2.5DHero/Screens/MainMenu/JoinServerScreen.vb +++ b/2.5DHero/2.5DHero/Screens/MainMenu/JoinServerScreen.vb @@ -244,7 +244,8 @@ Public Class JoinServerScreen End If If Controls.Dismiss() = True Then - CType(Me.PreScreen, MainMenuScreen).menuIndex = 0 + ''CType(Me.PreScreen, NewMainMenuScreen)._menuIndex = 0 + Core.Player.Unload() Core.SetScreen(Me.PreScreen) End If diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/MainMenuScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/MainMenuScreen.vb index a8e7ddaad..d4bdeba22 100644 --- a/2.5DHero/2.5DHero/Screens/MainMenu/MainMenuScreen.vb +++ b/2.5DHero/2.5DHero/Screens/MainMenu/MainMenuScreen.vb @@ -1,8 +1,4 @@ -Imports System.Net -Imports System.Net.Cache -Imports System.Threading.Tasks - -Public Class MainMenuScreen +Public Class MainMenuScreen Inherits Screen @@ -18,6 +14,7 @@ Public Class MainMenuScreen Dim currentLevel As Integer = -1 Dim levelChangeDelay As Integer = 0 + 'Dim mainMenuMaps As DataModel.Json.Game.MainMenuMapModel() Dim mainTexture As Texture2D @@ -36,9 +33,9 @@ Public Class MainMenuScreen Dim tempLoadDisplay As String = "" Public Overrides Function GetScreenStatus() As String - Dim s As String = "MenuIndex=" & Me.menuIndex & vbNewLine & - "CurrentLevel=" & Me.currentLevel & vbNewLine & - "LevelChangeDelay=" & Me.levelChangeDelay.ToString() + Dim s As String = "MenuIndex=" & menuIndex & vbNewLine & + "CurrentLevel=" & currentLevel & vbNewLine & + "LevelChangeDelay=" & levelChangeDelay.ToString() Return s End Function @@ -46,23 +43,23 @@ Public Class MainMenuScreen Public Sub New() GameModeManager.SetGameModePointer("Kolben") - Me.Identification = Identifications.MainMenuScreen - Me.CanBePaused = False - Me.MouseVisible = True - Me.CanChat = False - Me.currentLanguage = Localization.LanguageSuffix + Identification = Identifications.MainMenuScreen + CanBePaused = False + MouseVisible = True + CanChat = False + currentLanguage = Localization.LanguageSuffix - Screen.TextBox.Showing = False - Screen.PokemonImageView.Showing = False - Screen.ChooseBox.Showing = False + TextBox.Showing = False + PokemonImageView.Showing = False + ChooseBox.Showing = False - Effect = New BasicEffect(Core.GraphicsDevice) + Effect = New BasicEffect(GraphicsDevice) Effect.FogEnabled = True SkyDome = New SkyDome() Camera = New MainMenuCamera() - ' renderTarget = New RenderTarget2D(Core.GraphicsDevice, Core.windowSize.Width, Core.windowSize.Height, False, Core.GraphicsDevice.PresentationParameters.BackBufferFormat, DepthFormat.Depth24) - ' blurEffect = Core.Content.Load(Of Effect)("Effects\BlurEffect") + renderTarget = New RenderTarget2D(Core.GraphicsDevice, Core.windowSize.Width, Core.windowSize.Height, False, Core.GraphicsDevice.PresentationParameters.BackBufferFormat, DepthFormat.Depth24) + blurEffect = Core.Content.Load(Of Effect)("Effects\BlurEffect") Core.Player.Skin = "Hilbert" Level = New Level() @@ -70,10 +67,10 @@ Public Class MainMenuScreen mainTexture = TextureManager.GetTexture("GUI\Menus\Menu") - Screen.Level.World.Initialize(Screen.Level.EnvironmentType, Screen.Level.WeatherType) + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) - If System.IO.Directory.Exists(GameController.GamePath & "\Save\") = False Then - System.IO.Directory.CreateDirectory(GameController.GamePath & "\Save\") + If IO.Directory.Exists(GameController.GamePath & "\Save\") = False Then + IO.Directory.CreateDirectory(GameController.GamePath & "\Save\") End If GetSaves() @@ -81,54 +78,8 @@ Public Class MainMenuScreen GetPacks() GameJolt.Emblem.ClearOnlineSpriteCache() - Screen.Level.World.Initialize(Screen.Level.EnvironmentType, Screen.Level.WeatherType) - - UpdateCheck() End Sub - Private Sub UpdateCheck() - Try - If Not GameController.UpdateChecked Then - Logger.Debug("---Check Version---") - - If Not Core.GameOptions.UpdateDisabled AndAlso My.Computer.Network.IsAvailable Then - WaitForUpdaterAsync() - End If - End If - Catch ex As Exception - End Try - End Sub - - Private Async Function WaitForUpdaterAsync() As Task - Dim Updater As New Process - Updater.EnableRaisingEvents = True - Updater.StartInfo = New ProcessStartInfo("Updater.exe") - Updater.Start() - - AddHandler Updater.Exited, Sub() - Select Case Updater.ExitCode - Case 0 - GameController.UpdateChecked = True - Case 1 - Core.GameInstance.Exit() - Case 2 - Core.GameOptions.UpdateDisabled = True - Core.GameOptions.SaveOptions() - GameController.UpdateChecked = True - Case 3 - Core.GameOptions.UpdateDisabled = True - Core.GameOptions.SaveOptions() - Core.GameInstance.Exit() - End Select - End Sub - - Await Task.Delay(20000) - If Not Updater.HasExited Then - Updater.Kill() - GameController.UpdateChecked = True - End If - End Function - Private Sub GetPacks(Optional ByVal reload As Boolean = False) PackNames.Clear() @@ -139,8 +90,8 @@ Public Class MainMenuScreen PackNames.AddRange(EnabledPackNames) - If System.IO.Directory.Exists(GameController.GamePath & "\ContentPacks\") = True Then - For Each ContentPackFolder As String In System.IO.Directory.GetDirectories(GameController.GamePath & "\ContentPacks\") + If IO.Directory.Exists(GameController.GamePath & "\ContentPacks\") = True Then + For Each ContentPackFolder As String In IO.Directory.GetDirectories(GameController.GamePath & "\ContentPacks\") Dim newContentPack As String = ContentPackFolder.Remove(0, (GameController.GamePath & "\ContentPacks\").Length) If PackNames.Contains(newContentPack) = False Then PackNames.Add(newContentPack) @@ -153,10 +104,10 @@ Public Class MainMenuScreen Languages.Clear() LanguageNames.Clear() - For Each file As String In System.IO.Directory.GetFiles(GameController.GamePath & "\Content\Localization\") + For Each file As String In IO.Directory.GetFiles(GameController.GamePath & "\Content\Localization\") If file.EndsWith(".dat") = True Then - Dim content() As String = System.IO.File.ReadAllLines(file) - file = System.IO.Path.GetFileNameWithoutExtension(file) + Dim content() As String = IO.File.ReadAllLines(file) + file = IO.Path.GetFileNameWithoutExtension(file) If file.StartsWith("Tokens_") = True Then Dim TokenName As String = file.Remove(0, 7) @@ -177,17 +128,17 @@ Public Class MainMenuScreen End Sub Private Sub GetSaves() - If System.IO.File.Exists(GameController.GamePath & "\Save\lastSession.id") = True Then - Dim idData As String = System.IO.File.ReadAllText(GameController.GamePath & "\Save\lastSession.id") - If System.IO.Directory.Exists(GameController.GamePath & "\Save\" & idData) = False Then - System.IO.File.Delete(GameController.GamePath & "\Save\lastSession.id") + If IO.File.Exists(GameController.GamePath & "\Save\lastSession.id") = True Then + Dim idData As String = IO.File.ReadAllText(GameController.GamePath & "\Save\lastSession.id") + If IO.Directory.Exists(GameController.GamePath & "\Save\" & idData) = False Then + IO.File.Delete(GameController.GamePath & "\Save\lastSession.id") End If End If Saves.Clear() SaveNames.Clear() - For Each Folder As String In System.IO.Directory.GetDirectories(GameController.GamePath & "\Save") + For Each Folder As String In IO.Directory.GetDirectories(GameController.GamePath & "\Save") If Player.IsSaveGameFolder(Folder) = True Then Saves.Add(Folder) End If @@ -197,7 +148,7 @@ Public Class MainMenuScreen If i <= Saves.Count - 1 Then Dim entry As String = Saves(i) - Dim Data() As String = System.IO.File.ReadAllText(entry & "\Player.dat").SplitAtNewline() + Dim Data() As String = IO.File.ReadAllText(entry & "\Player.dat").SplitAtNewline() Dim Name As String = "Missingno." Dim Autosave As Boolean = False @@ -223,8 +174,8 @@ Public Class MainMenuScreen Private Sub GetGameModes() ModeNames.Clear() - For Each folder As String In System.IO.Directory.GetDirectories(GameController.GamePath & "\GameModes\") - If System.IO.File.Exists(folder & "\GameMode.dat") = True Then + For Each folder As String In IO.Directory.GetDirectories(GameController.GamePath & "\GameModes\") + If IO.File.Exists(folder & "\GameMode.dat") = True Then Dim directory As String = folder If directory.EndsWith("\") = True Then directory = directory.Remove(directory.Length - 1, 1) @@ -273,14 +224,15 @@ Public Class MainMenuScreen End Sub Public Overrides Sub Update() - Lighting.UpdateLighting(Screen.Effect) + Lighting.UpdateLighting(Effect) Camera.Update() Level.Update() SkyDome.Update() + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) - If Core.GameInstance.IsActive = True Then - Select Case Me.menuIndex + If GameInstance.IsActive = True Then + Select Case menuIndex Case 0 UpdateMainMenu() Case 1 @@ -300,12 +252,12 @@ Public Class MainMenuScreen End Select End If - If Me.levelChangeDelay <= 0 Then - If Core.Random.Next(0, 1000) = 0 Then + If levelChangeDelay <= 0 Then + If Random.Next(0, 1000) = 0 Then ChangeLevel() End If Else - Me.levelChangeDelay -= 1 + levelChangeDelay -= 1 End If End Sub @@ -321,7 +273,7 @@ Public Class MainMenuScreen SkyDome.Draw(45.0F) Level.Draw() - World.DrawWeather(Screen.Level.World.CurrentMapWeather) + World.DrawWeather(Level.World.CurrentMapWeather) 'Core.GraphicsDevice.SetRenderTarget(Nothing) @@ -337,7 +289,7 @@ Public Class MainMenuScreen 'Core.SpriteBatch.End() 'Core.SpriteBatch.BeginBatch() - Select Case Me.menuIndex + Select Case menuIndex Case 0 DrawMainMenu() Case 1 @@ -355,14 +307,14 @@ Public Class MainMenuScreen Case 7 DrawLoadGameJoltSaveMenu() End Select - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, GameController.DEVELOPER_NAME, New Vector2(7, Core.ScreenSize.Height - FontManager.InGameFont.MeasureString(GameController.DEVELOPER_NAME).Y - 1), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, GameController.DEVELOPER_NAME, New Vector2(4, Core.ScreenSize.Height - FontManager.InGameFont.MeasureString(GameController.DEVELOPER_NAME).Y - 4), Color.White) - Core.SpriteBatch.DrawInterface(TextureManager.GetTexture("GUI\Logos\P3D"), New Rectangle(CInt(Core.ScreenSize.Width / 2) - 260, 40, 500, 110), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, GameController.DEVELOPER_NAME, New Vector2(7, ScreenSize.Height - FontManager.InGameFont.MeasureString(GameController.DEVELOPER_NAME).Y - 1), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, GameController.DEVELOPER_NAME, New Vector2(4, ScreenSize.Height - FontManager.InGameFont.MeasureString(GameController.DEVELOPER_NAME).Y - 4), Color.White) + SpriteBatch.DrawInterface(TextureManager.GetTexture("GUI\Logos\P3D"), New Rectangle(CInt(ScreenSize.Width / 2) - 260, 40, 500, 110), Color.White) If Core.GameOptions.ShowDebug = 0 Then Dim s As String = GameController.GAMENAME & " " & GameController.GAMEDEVELOPMENTSTAGE & " " & GameController.GAMEVERSION - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, s, New Vector2(7, 7), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, s, New Vector2(5, 5), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, s, New Vector2(7, 7), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, s, New Vector2(5, 5), Color.White) End If End Sub @@ -387,7 +339,7 @@ Public Class MainMenuScreen If i = mainmenuIndex Then CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 48, 48, 48), "") Else - If i < 2 And Saves.Count = 0 Or i = 0 And System.IO.Directory.Exists(GameController.GamePath & "\Save\autosave") = False Then + If i < 2 And Saves.Count = 0 Or i = 0 And IO.Directory.Exists(GameController.GamePath & "\Save\autosave") = False Then CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(48, 0, 48, 48), "") Else CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") @@ -396,118 +348,118 @@ Public Class MainMenuScreen If i = 4 Then If i = mainmenuIndex Then - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 64, 0, 64, 64), New Rectangle(96, 80, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 64, 0, 64, 64), New Rectangle(96, 80, 16, 16), Color.White) Else - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 64, 0, 64, 64), New Rectangle(96, 64, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 64, 0, 64, 64), New Rectangle(96, 64, 16, 16), Color.White) End If ElseIf i = 5 Then If i = mainmenuIndex Then - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 64, 64, 64, 64), New Rectangle(112, 80, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 64, 64, 64, 64), New Rectangle(112, 80, 16, 16), Color.White) Else - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 64, 64, 64, 64), New Rectangle(112, 64, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 64, 64, 64, 64), New Rectangle(112, 64, 16, 16), Color.White) End If ElseIf i = 6 Then - If Security.FileValidation.IsValid(False) = True And GameController.Hacker = False Then + If Security.FileValidation.IsValid(False) = True Then If GameJolt.API.LoggedIn = True Then If i = mainmenuIndex Then - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 196, Core.ScreenSize.Height - 60, 192, 56), New Rectangle(160, 96, 96, 28), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 196, ScreenSize.Height - 60, 192, 56), New Rectangle(160, 96, 96, 28), Color.White) Else - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 196, Core.ScreenSize.Height - 60, 192, 56), New Rectangle(160, 65, 96, 28), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 196, ScreenSize.Height - 60, 192, 56), New Rectangle(160, 65, 96, 28), Color.White) End If - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Logged in as", New Vector2(Core.ScreenSize.Width - 148, Core.ScreenSize.Height - 54), Color.White) - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, GameJolt.API.username, New Vector2(Core.ScreenSize.Width - 148, Core.ScreenSize.Height - 34), New Color(204, 255, 0)) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Logged in as", New Vector2(ScreenSize.Width - 148, ScreenSize.Height - 54), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, GameJolt.API.username, New Vector2(ScreenSize.Width - 148, ScreenSize.Height - 34), New Color(204, 255, 0)) Else If i = mainmenuIndex Then - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 60, Core.ScreenSize.Height - 60, 56, 56), New Rectangle(129, 96, 28, 28), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 60, ScreenSize.Height - 60, 56, 56), New Rectangle(129, 96, 28, 28), Color.White) Else - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(Core.ScreenSize.Width - 60, Core.ScreenSize.Height - 60, 56, 56), New Rectangle(129, 65, 28, 28), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(ScreenSize.Width - 60, ScreenSize.Height - 60, 56, 56), New Rectangle(129, 65, 28, 28), Color.White) End If End If Else - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "File Validation failed. Download a new copy of the game to fix this.", New Vector2(220, Core.ScreenSize.Height - 30), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "File Validation failed. Download a new copy of the game to fix this.", New Vector2(220, ScreenSize.Height - 30), Color.White) End If ElseIf i = 7 Then - If GameJolt.API.LoggedIn = True And Security.FileValidation.IsValid(False) = True And GameController.Hacker = False Then - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2), 160 + 128, 320, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) + 160 + 20, 196 + 128), Color.Black) + If GameJolt.API.LoggedIn = True And Security.FileValidation.IsValid(False) = True Then + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2), 160 + 128, 320, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) + 160 + 20, 196 + 128), Color.Black) End If ElseIf i = 1 And GameJolt.API.LoggedIn = True Then - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 - 160 - 20, 160 + i * 128, 320, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) - 10 - 160 - 20, 196 + i * 128), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 180 - 160 - 20, 160 + i * 128, 320, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) - 10 - 160 - 20, 196 + i * 128), Color.Black) Else - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180, 160 + i * 128, 320, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) - 10, 196 + i * 128), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 180, 160 + i * 128, 320, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - (FontManager.InGameFont.MeasureString(Text).X / 2) - 10, 196 + i * 128), Color.Black) End If Next Dim d As New Dictionary(Of Buttons, String) d.Add(Buttons.A, "Accept") If GameJolt.API.LoggedIn = True Then - DrawGamePadControls(d, New Vector2(Core.ScreenSize.Width - 170, Core.ScreenSize.Height - 100)) + DrawGamePadControls(d, New Vector2(ScreenSize.Width - 170, ScreenSize.Height - 100)) Else - DrawGamePadControls(d, New Vector2(Core.ScreenSize.Width - 234, Core.ScreenSize.Height - 40)) + DrawGamePadControls(d, New Vector2(ScreenSize.Width - 234, ScreenSize.Height - 40)) End If End Sub Private Sub UpdateMainMenu() If Controls.Up(True, True) = True Then - Me.mainmenuIndex -= 1 + mainmenuIndex -= 1 End If If Controls.Down(True, True) = True Then - Me.mainmenuIndex += 1 + mainmenuIndex += 1 End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 7 If i = 4 Then - If Core.ScaleScreenRec(New Rectangle(Core.ScreenSize.Width - 64, 0, 64, 64)).Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = 4 + If ScaleScreenRec(New Rectangle(ScreenSize.Width - 64, 0, 64, 64)).Contains(MouseHandler.MousePosition) = True Then + mainmenuIndex = 4 If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then LanguageButton() End If End If ElseIf i = 5 Then - If Core.ScaleScreenRec(New Rectangle(Core.ScreenSize.Width - 64, 64, 64, 64)).Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = 5 + If ScaleScreenRec(New Rectangle(ScreenSize.Width - 64, 64, 64, 64)).Contains(MouseHandler.MousePosition) = True Then + mainmenuIndex = 5 If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then PacksButton() End If End If ElseIf i = 6 Then - Dim r As Rectangle = Core.ScaleScreenRec(New Rectangle(Core.ScreenSize.Width - 196, Core.ScreenSize.Height - 60, 192, 56)) + Dim r As Rectangle = ScaleScreenRec(New Rectangle(ScreenSize.Width - 196, ScreenSize.Height - 60, 192, 56)) If GameJolt.API.LoggedIn = False Then - r = Core.ScaleScreenRec(New Rectangle(Core.ScreenSize.Width - 64, Core.ScreenSize.Height - 64, 64, 64)) + r = ScaleScreenRec(New Rectangle(ScreenSize.Width - 64, ScreenSize.Height - 64, 64, 64)) End If If r.Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = 6 + mainmenuIndex = 6 If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then GameJoltButton() End If End If ElseIf i = 1 And GameJolt.API.LoggedIn = True Then - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 - 160 - 20, 160 + i * 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 180 - 160 - 20, 160 + i * 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + mainmenuIndex = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then LoadGameButton() End If End If ElseIf i = 7 And GameJolt.API.LoggedIn = True Then - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2), 160 + 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2), 160 + 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + mainmenuIndex = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then LoadGameJoltButton() End If End If Else - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180, 160 + i * 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.mainmenuIndex = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 180, 160 + i * 128, 320 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + mainmenuIndex = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then - Select Case Me.mainmenuIndex + Select Case mainmenuIndex Case 0 ContinueButton() Case 1 @@ -523,7 +475,7 @@ Public Class MainMenuScreen Next End If - If Security.FileValidation.IsValid(False) = True And GameController.Hacker = False Then + If Security.FileValidation.IsValid(False) = True Then If GameJolt.API.LoggedIn = True Then mainmenuIndex = CInt(MathHelper.Clamp(mainmenuIndex, 0, 7)) Else @@ -534,7 +486,7 @@ Public Class MainMenuScreen End If If Controls.Accept(False, True) = True Then - Select Case Me.mainmenuIndex + Select Case mainmenuIndex Case 0 ContinueButton() Case 1 @@ -560,7 +512,7 @@ Public Class MainMenuScreen packsMenuIndex(0) = 0 packsMenuIndex(2) = 0 - Me.menuIndex = 4 + menuIndex = 4 End Sub Private Sub LanguageButton() @@ -569,7 +521,7 @@ Public Class MainMenuScreen languageMenuIndex(0) = Languages.IndexOf(currentLanguage) End If - Me.menuIndex = 3 + menuIndex = 3 End Sub Private Sub ContinueButton() @@ -577,7 +529,7 @@ Public Class MainMenuScreen Core.Player.IsGameJoltSave = False Core.Player.LoadGame("autosave") - Core.SetScreen(New JoinServerScreen(Me)) + SetScreen(New JoinServerScreen(Me)) End If End Sub @@ -585,28 +537,28 @@ Public Class MainMenuScreen GetSaves() If Saves.Count > 0 Then - Me.menuIndex = 1 + menuIndex = 1 End If End Sub Private Sub LoadGameJoltButton() - If Security.FileValidation.IsValid(False) = True And GameController.Hacker = False Then + If Security.FileValidation.IsValid(False) = True Then If GameJolt.API.LoggedIn = True Then - Core.GameJoltSave.DownloadSave(GameJolt.LogInScreen.LoadedGameJoltID, True) + GameJoltSave.DownloadSave(GameJolt.LogInScreen.LoadedGameJoltID, True) End If - Me.menuIndex = 7 + menuIndex = 7 End If End Sub Private Sub CloseGameButton() Core.GameOptions.SaveOptions() - Core.GameInstance.Exit() + GameInstance.Exit() End Sub Private Sub GameJoltButton() - If Security.FileValidation.IsValid(False) = True And GameController.Hacker = False Then - Core.SetScreen(New GameJolt.LogInScreen(Me)) + If Security.FileValidation.IsValid(False) = True Then + SetScreen(New GameJolt.LogInScreen(Me)) End If End Sub @@ -624,10 +576,10 @@ Public Class MainMenuScreen c = New Color(101, 142, 255) End If - Canvas.DrawRectangle(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) + Canvas.DrawRectangle(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) Next - Canvas.DrawScrollBar(New Vector2(CInt(Core.ScreenSize.Width / 2) + 250, 180), Saves.Count, 4, loadMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) + Canvas.DrawScrollBar(New Vector2(CInt(ScreenSize.Width / 2) + 250, 180), Saves.Count, 4, loadMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) Dim x As Integer = Saves.Count - 1 x = CInt(MathHelper.Clamp(x, 0, 3)) @@ -636,14 +588,14 @@ Public Class MainMenuScreen Dim Name As String = SaveNames(i + loadMenuIndex(2)) If i + loadMenuIndex(2) = loadMenuIndex(0) Then - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) Else - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) End If Next - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 272, 388, 512, 128), True) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 272, 388, 512, 128), True) If tempLoadDisplay = "" Then Dim dispName As String = "(Unknown)" @@ -652,7 +604,7 @@ Public Class MainMenuScreen Dim dispLocation As String = "(Unknown)" Dim dispGameMode As String = "Kolben" - Dim Data() As String = System.IO.File.ReadAllText(Saves(loadMenuIndex(0)) & "\Player.dat").SplitAtNewline() + Dim Data() As String = IO.File.ReadAllText(Saves(loadMenuIndex(0)) & "\Player.dat").SplitAtNewline() For Each Line As String In Data If Line.Contains("|") = True Then Dim ID As String = Line.Remove(Line.IndexOf("|")) @@ -692,14 +644,14 @@ Public Class MainMenuScreen End If Next - Me.tempLoadDisplay = Localization.GetString("load_menu_name") & ": " & dispName & vbNewLine & + tempLoadDisplay = Localization.GetString("load_menu_name") & ": " & dispName & vbNewLine & Localization.GetString("load_menu_gamemode") & ": " & dispGameMode & vbNewLine & Localization.GetString("load_menu_badges") & ": " & dispBadges & vbNewLine & Localization.GetString("load_menu_location") & ": " & Localization.GetString("Places_" & dispLocation) & vbNewLine & Localization.GetString("load_menu_time") & ": " & dispPlayTime End If - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, tempLoadDisplay, New Vector2(CInt(Core.ScreenSize.Width / 2) - 252, 416), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, tempLoadDisplay, New Vector2(CInt(ScreenSize.Width / 2) - 252, 416), Color.Black) For i = 0 To 2 Dim Text As String = "" @@ -718,8 +670,8 @@ Public Class MainMenuScreen CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") End If - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 272 + i * 192, 550, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 254 + i * 192, 582), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 272 + i * 192, 550, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 254 + i * 192, 582), Color.Black) Next Dim d As New Dictionary(Of Buttons, String) @@ -744,22 +696,22 @@ Public Class MainMenuScreen tempLoadDisplay = "" End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 2 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 272 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.loadMenuIndex(1) = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 272 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + loadMenuIndex(1) = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then Select Case loadMenuIndex(1) Case 0 Core.Player.IsGameJoltSave = False - Core.Player.LoadGame(System.IO.Path.GetFileName(Saves(loadMenuIndex(0)))) + Core.Player.LoadGame(IO.Path.GetFileName(Saves(loadMenuIndex(0)))) - Core.SetScreen(New JoinServerScreen(Me)) + SetScreen(New JoinServerScreen(Me)) Case 1 - Me.menuIndex = 2 + menuIndex = 2 Case 2 - Me.menuIndex = 0 + menuIndex = 0 tempLoadDisplay = "" End Select @@ -769,9 +721,9 @@ Public Class MainMenuScreen End If For i = 0 To 3 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then - Me.loadMenuIndex(0) = i + loadMenuIndex(2) + loadMenuIndex(0) = i + loadMenuIndex(2) tempLoadDisplay = "" End If End If @@ -793,20 +745,20 @@ Public Class MainMenuScreen Select Case loadMenuIndex(1) Case 0 Core.Player.IsGameJoltSave = False - Core.Player.LoadGame(System.IO.Path.GetFileName(Saves(loadMenuIndex(0)))) + Core.Player.LoadGame(IO.Path.GetFileName(Saves(loadMenuIndex(0)))) - Core.SetScreen(New JoinServerScreen(Me)) + SetScreen(New JoinServerScreen(Me)) Case 1 - Me.menuIndex = 2 + menuIndex = 2 Case 2 - Me.menuIndex = 0 + menuIndex = 0 tempLoadDisplay = "" End Select End If If Controls.Dismiss() = True Then - Me.menuIndex = 0 + menuIndex = 0 End If End Sub @@ -815,77 +767,77 @@ Public Class MainMenuScreen #Region "LoadGameJoltSaveMenu" Private Sub DrawLoadGameJoltSaveMenu() - If Core.GameJoltSave.DownloadFailed = False Then - Dim downloaded As Boolean = Core.GameJoltSave.DownloadFinished + If GameJoltSave.DownloadFailed = False Then + Dim downloaded As Boolean = GameJoltSave.DownloadFinished If downloaded = True Then - Dim r As New Rectangle(CInt(Core.ScreenSize.Width / 2) - 256, 300, 512, 128) - If Core.ScaleScreenRec(r).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Or Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 0 Then - Canvas.DrawRectangle(Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 264, 292, 528, 144)), New Color(255, 255, 255, 150)) + Dim r As New Rectangle(CInt(ScreenSize.Width / 2) - 256, 300, 512, 128) + If ScaleScreenRec(r).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Or GameInstance.IsMouseVisible = False And loadGameJoltIndex = 0 Then + Canvas.DrawRectangle(ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 264, 292, 528, 144)), New Color(255, 255, 255, 150)) End If - If GameJolt.LogInScreen.UserBanned(Core.GameJoltSave.GameJoltID) = True Then - Dim reason As String = GameJolt.LogInScreen.GetBanReasonByID(GameJolt.LogInScreen.BanReasonIDForUser(Core.GameJoltSave.GameJoltID)) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, reason, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(reason).X / 2) + 2, 260 + 2), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, reason, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(reason).X / 2), 260), Color.Red) + If GameJolt.LogInScreen.UserBanned(GameJoltSave.GameJoltID) = True Then + Dim reason As String = GameJolt.LogInScreen.GetBanReasonByID(GameJolt.LogInScreen.BanReasonIDForUser(GameJoltSave.GameJoltID)) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, reason, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(reason).X / 2) + 2, 260 + 2), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, reason, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(reason).X / 2), 260), Color.Red) End If - GameJolt.Emblem.Draw(GameJolt.API.username, Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Points, Core.GameJoltSave.Gender, Core.GameJoltSave.Emblem, Core.ScaleScreenVec(New Vector2(CSng(Core.ScreenSize.Width / 2) - 256, 300)), CSng(4 * Core.SpriteBatch.InterfaceScale), Core.GameJoltSave.DownloadedSprite) + GameJolt.Emblem.Draw(GameJolt.API.username, GameJoltSave.GameJoltID, GameJoltSave.Points, GameJoltSave.Gender, GameJoltSave.Emblem, ScaleScreenVec(New Vector2(CSng(ScreenSize.Width / 2) - 256, 300)), CSng(4 * SpriteBatch.InterfaceScale), GameJoltSave.DownloadedSprite) Dim y As Integer = 0 - If Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Or Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 1 Then + If ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Or GameInstance.IsMouseVisible = False And loadGameJoltIndex = 1 Then y = 16 - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Change to male.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Change to male.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4), Color.White) End If - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32), New Rectangle(144, 32 + y, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32), New Rectangle(144, 32 + y, 16, 16), Color.White) y = 0 - If Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Or Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 2 Then + If ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Or GameInstance.IsMouseVisible = False And loadGameJoltIndex = 2 Then y = 16 - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Change to female.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4 + 48), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Change to female.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4 + 48), Color.White) End If - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32), New Rectangle(160, 32 + y, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32), New Rectangle(160, 32 + y, 16, 16), Color.White) y = 0 - If Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Or Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 3 Then + If ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Or GameInstance.IsMouseVisible = False And loadGameJoltIndex = 3 Then y = 16 - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Reset save.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4 + 48 + 48), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, "Reset save.", New Vector2(r.X + 64 + 4 + r.Width, r.Y + 4 + 48 + 48), Color.White) End If - Core.SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32), New Rectangle(176, 32 + y, 16, 16), Color.White) + SpriteBatch.DrawInterface(mainTexture, New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32), New Rectangle(176, 32 + y, 16, 16), Color.White) Else - Dim downloadProgress As Integer = Core.GameJoltSave.DownloadProgress - Dim total As Integer = Core.GameJoltSave.TotalDownloadItems + Dim downloadProgress As Integer = GameJoltSave.DownloadProgress + Dim total As Integer = GameJoltSave.TotalDownloadItems - Dim downloadtext As String = "Downloading profile..." - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, downloadtext & LoadingDots.Dots, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(downloadtext).X / 2) + 2, 322), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, downloadtext & LoadingDots.Dots, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(downloadtext).X / 2), 320), Color.White) + Dim downloadtext As String = "Downloading profile" + SpriteBatch.DrawInterfaceString(FontManager.MainFont, downloadtext & LoadingDots.Dots, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(downloadtext).X / 2) + 2, 322), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, downloadtext & LoadingDots.Dots, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(downloadtext).X / 2), 320), Color.White) - Canvas.DrawScrollBar(New Vector2(CInt(Core.ScreenSize.Width / 2) - 256, 400), total, downloadProgress, 0, New Size(512, 8), True, Color.Black, Color.White, True) + Canvas.DrawScrollBar(New Vector2(CInt(ScreenSize.Width / 2) - 256, 400), total, downloadProgress, 0, New Size(512, 8), True, Color.Black, Color.White, True) End If Else Dim failText As String = "The download failed! Please try again." - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, failText, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(failText).X / 2) + 2, 322), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, failText, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(failText).X / 2), 320), Color.DarkRed) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, failText, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(failText).X / 2) + 2, 322), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, failText, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(failText).X / 2), 320), Color.DarkRed) End If If ControllerHandler.IsConnected() = False Then - Dim text As String = "Right-Click to quit to the main menu." - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, text, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(text).X / 2) + 2, 502), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.MainFont, text, New Vector2(CSng(Core.ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(text).X / 2), 500), Color.White) + Dim text As String = "Right-Click to quit to the main menu" + SpriteBatch.DrawInterfaceString(FontManager.MainFont, text, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(text).X / 2) + 2, 502), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MainFont, text, New Vector2(CSng(ScreenSize.Width / 2 - FontManager.MainFont.MeasureString(text).X / 2), 500), Color.White) End If Dim d As New Dictionary(Of Buttons, String) d.Add(Buttons.A, "Select") d.Add(Buttons.B, "Back") - Me.DrawGamePadControls(d) + DrawGamePadControls(d) End Sub Private Sub UpdateLoadGameJoltSaveMenu() - Dim downloaded As Boolean = Core.GameJoltSave.DownloadFinished + Dim downloaded As Boolean = GameJoltSave.DownloadFinished If downloaded = True Then If Controls.Down(True, True, False, True, True) = True Or Controls.Right(True, True, False, True, True) = True Then @@ -898,244 +850,36 @@ Public Class MainMenuScreen loadGameJoltIndex = loadGameJoltIndex.Clamp(0, 3) If Controls.Accept(True, True) = True Then - If Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 0 Or Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 256, 300, 512, 128)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = False And loadGameJoltIndex = 0 Or ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 256, 300, 512, 128)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Then Core.Player.IsGameJoltSave = True - - ' Backup Save module - ' 1. Load Encrypted.dat file. - ' 2. Load OverWrite folder - ' 3. Apply Extra Fixes. - - ' Enable Backup Save functionality. - If (Core.GameOptions.Extras.Contains("Backup Save Feature")) Then - ' Make a copy of last known good gamejolt save! - Dim timestamp As String = Date.Now.ToString("yyyy-MM-dd_HH.mm.ss") - - If Not Directory.Exists(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp) Then - Directory.CreateDirectory(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp) - End If - - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Apricorns.dat", Core.GameJoltSave.Apricorns) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Berries.dat", Core.GameJoltSave.Berries) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Box.dat", Core.GameJoltSave.Box) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Daycare.dat", Core.GameJoltSave.Daycare) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/HallOfFame.dat", Core.GameJoltSave.HallOfFame) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/ItemData.dat", Core.GameJoltSave.ItemData) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Items.dat", Core.GameJoltSave.Items) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/NPC.dat", Core.GameJoltSave.NPC) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Options.dat", Core.GameJoltSave.Options) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Party.dat", Core.GameJoltSave.Party) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Player.dat", Core.GameJoltSave.Player) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Pokedex.dat", Core.GameJoltSave.Pokedex) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Register.dat", Core.GameJoltSave.Register) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/RoamingPokemon.dat", Core.GameJoltSave.RoamingPokemon) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/SecretBase.dat", Core.GameJoltSave.SecretBase) - File.WriteAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID & "/" & timestamp & "/Statistics.dat", Core.GameJoltSave.Statistics) - - If Directory.Exists(GameController.GamePath & "/Backup Save/" & Core.GameJoltSave.GameJoltID.ToString() & "/Encrypted/") Then - If File.Exists(GameController.GamePath & "/Backup Save/" & Core.GameJoltSave.GameJoltID.ToString() & "/Encrypted/Encrypted.dat") Then - Dim Items() As String = File.ReadAllText(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID.ToString() & "/Encrypted/Encrypted.dat").Split(CChar("|")) - Dim Hash As String = String.Join("|", Items.Take(16)) - - ' Ensure that the items count is 17. Last index is for validation purpose. - If Items.Count() = 17 Then - ' Try using the new algorithm. - Try - If String.Equals(Hash, Encryption.DecryptString(Items.Last(), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID))) Then - Core.GameJoltSave._apricorns = Encryption.DecryptString(Items(0), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._berries = Encryption.DecryptString(Items(1), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._box = Encryption.DecryptString(Items(2), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._daycare = Encryption.DecryptString(Items(3), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._hallOfFame = Encryption.DecryptString(Items(4), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._itemData = Encryption.DecryptString(Items(5), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._items = Encryption.DecryptString(Items(6), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._NPC = Encryption.DecryptString(Items(7), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._options = Encryption.DecryptString(Items(8), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._party = Encryption.DecryptString(Items(9), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._player = Encryption.DecryptString(Items(10), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._pokedex = Encryption.DecryptString(Items(11), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._register = Encryption.DecryptString(Items(12), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._roamingPokemon = Encryption.DecryptString(Items(13), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._secretBase = Encryption.DecryptString(Items(14), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - Core.GameJoltSave._statistics = Encryption.DecryptString(Items(15), StringObfuscation.Obfuscate(GameJoltSave.GameJoltID)) - End If - Catch ex As Exception - - End Try - - ' Try again using the old algorithm. - Try - If String.Equals(Hash, Encryption.DecryptString(Items.Last(), StringObfuscation.Obfuscate("TheDialgaTeam"))) Then - ' Ensure that you are not cheating. - Dim PlayerData() As String = Items(10).SplitAtNewline() - If (PlayerData.Any(Function(a) String.Equals(a, "OT|" & GameJoltSave.GameJoltID))) Then - Core.GameJoltSave._apricorns = Encryption.DecryptString(Items(0), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._berries = Encryption.DecryptString(Items(1), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._box = Encryption.DecryptString(Items(2), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._daycare = Encryption.DecryptString(Items(3), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._hallOfFame = Encryption.DecryptString(Items(4), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._itemData = Encryption.DecryptString(Items(5), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._items = Encryption.DecryptString(Items(6), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._NPC = Encryption.DecryptString(Items(7), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._options = Encryption.DecryptString(Items(8), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._party = Encryption.DecryptString(Items(9), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._player = Encryption.DecryptString(Items(10), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._pokedex = Encryption.DecryptString(Items(11), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._register = Encryption.DecryptString(Items(12), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._roamingPokemon = Encryption.DecryptString(Items(13), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._secretBase = Encryption.DecryptString(Items(14), StringObfuscation.Obfuscate("TheDialgaTeam")) - Core.GameJoltSave._statistics = Encryption.DecryptString(Items(15), StringObfuscation.Obfuscate("TheDialgaTeam")) - Else - MsgBox("The game detected that you are trying to load the legacy Backup Save from Indev 0.53.3 Patch Update 6/7. Due to the nature of cloning account via Backup Save, we are unable to load this save." & vbNewLine & vbNewLine & "Please contact jianmingyong at http://pokemon3d.net/forum/ for more detail.", MsgBoxStyle.OkOnly, "Error") - End If - End If - Catch ex As Exception - - End Try - End If - Else - ' Disable the older support for security reason. - Try - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Apricorns.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Berries.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Box.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Daycare.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/HallOfFame.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/ItemData.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Items.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/NPC.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Options.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Party.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Player.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Pokedex.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Register.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/RoamingPokemon.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/SecretBase.dat") AndAlso - File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Encrypted/Statistics.dat") Then - MsgBox("The game detected that you are trying to load the legacy Backup Save from Indev 0.53.3 Patch Update 5 and below. Due to the nature of cloning account via Backup Save, we are unable to load this save." & vbNewLine & vbNewLine & "Please contact jianmingyong at http://pokemon3d.net/forum/ for more detail.", MsgBoxStyle.OkOnly, "Error") - End If - Catch ex As Exception - - End Try - End If - End If -#If DEBUG Then - If Not Directory.Exists(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID.ToString() & "/Overwrite") Then - Directory.CreateDirectory(GameController.GamePath & "/Backup Save/" & GameJoltSave.GameJoltID.ToString() & "/Overwrite") - End If - - If Directory.Exists(GameController.GamePath & "/Backup Save/" & Core.GameJoltSave.GameJoltID.ToString() & "/Overwrite/") Then - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Apricorns.dat") Then - Core.GameJoltSave._apricorns = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Apricorns.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Apricorns.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Berries.dat") Then - Core.GameJoltSave._berries = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Berries.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Berries.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Box.dat") Then - Core.GameJoltSave._box = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Box.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Box.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Daycare.dat") Then - Core.GameJoltSave._daycare = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Daycare.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Daycare.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/HallOfFame.dat") Then - Core.GameJoltSave._hallOfFame = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/HallOfFame.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/HallOfFame.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/ItemData.dat") Then - Core.GameJoltSave._itemData = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/ItemData.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/ItemData.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Items.dat") Then - Core.GameJoltSave._items = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Items.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Items.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/NPC.dat") Then - Core.GameJoltSave._NPC = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/NPC.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/NPC.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Options.dat") Then - Core.GameJoltSave._options = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Options.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Options.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Party.dat") Then - Core.GameJoltSave._party = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Party.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Party.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Player.dat") Then - Core.GameJoltSave._player = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Player.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Player.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Pokedex.dat") Then - Core.GameJoltSave._pokedex = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Pokedex.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Pokedex.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Register.dat") Then - Core.GameJoltSave._register = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Register.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Register.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/RoamingPokemon.dat") Then - Core.GameJoltSave._roamingPokemon = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/RoamingPokemon.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/RoamingPokemon.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/SecretBase.dat") Then - Core.GameJoltSave._secretBase = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/SecretBase.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/SecretBase.dat") - End If - - If File.Exists(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Statistics.dat") Then - Core.GameJoltSave._statistics = File.ReadAllText(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Statistics.dat") - File.Delete(GameController.GamePath + "/Backup Save/" + Core.GameJoltSave.GameJoltID.ToString() + "/Overwrite/Statistics.dat") - End If - End If -#End If - End If - Core.Player.LoadGame("GAMEJOLTSAVE") - Core.SetScreen(New JoinServerScreen(Me)) + SetScreen(New JoinServerScreen(Me)) End If - Dim r As Rectangle = Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 256, 300, 512, 128)) - If Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 1 Or Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Then + Dim r As Rectangle = ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 256, 300, 512, 128)) + If GameInstance.IsMouseVisible = False And loadGameJoltIndex = 1 Or ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Then ButtonChangeMale() End If - If Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 2 Or Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = False And loadGameJoltIndex = 2 Or ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Then ButtonChangeFemale() End If - If Core.GameInstance.IsMouseVisible = False And loadGameJoltIndex = 3 Or Core.ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = False And loadGameJoltIndex = 3 Or ScaleScreenRec(New Rectangle(r.X + 32 + r.Width, r.Y + 48 + 48, 32, 32)).Contains(MouseHandler.MousePosition) = True And GameInstance.IsMouseVisible = True Then ButtonResetSave() End If End If End If If Controls.Dismiss(True, True) = True Then - Me.menuIndex = 0 + menuIndex = 0 End If End Sub Private Sub ButtonChangeMale() - Core.GameJoltSave.Gender = "0" + GameJoltSave.Gender = "0" - Core.Player.Skin = GameJolt.Emblem.GetPlayerSpriteFile(GameJolt.Emblem.GetPlayerLevel(Core.GameJoltSave.Points), Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Gender) - Select Case Core.GameJoltSave.Gender + Core.Player.Skin = GameJolt.Emblem.GetPlayerSpriteFile(GameJolt.Emblem.GetPlayerLevel(GameJoltSave.Points), GameJoltSave.GameJoltID, GameJoltSave.Gender) + Select Case GameJoltSave.Gender Case "0" Core.Player.Male = True Case "1" @@ -1146,10 +890,10 @@ Public Class MainMenuScreen End Sub Private Sub ButtonChangeFemale() - Core.GameJoltSave.Gender = "1" + GameJoltSave.Gender = "1" - Core.Player.Skin = GameJolt.Emblem.GetPlayerSpriteFile(GameJolt.Emblem.GetPlayerLevel(Core.GameJoltSave.Points), Core.GameJoltSave.GameJoltID, Core.GameJoltSave.Gender) - Select Case Core.GameJoltSave.Gender + Core.Player.Skin = GameJolt.Emblem.GetPlayerSpriteFile(GameJolt.Emblem.GetPlayerLevel(GameJoltSave.Points), GameJoltSave.GameJoltID, GameJoltSave.Gender) + Select Case GameJoltSave.Gender Case "0" Core.Player.Male = True Case "1" @@ -1160,7 +904,7 @@ Public Class MainMenuScreen End Sub Private Sub ButtonResetSave() - Core.GameJoltSave.ResetSave() + GameJoltSave.ResetSave() End Sub #End Region @@ -1176,10 +920,10 @@ Public Class MainMenuScreen c = New Color(101, 142, 255) End If - Canvas.DrawRectangle(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) + Canvas.DrawRectangle(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) Next - Canvas.DrawScrollBar(New Vector2(CInt(Core.ScreenSize.Width / 2) + 250, 180), Languages.Count, 4, languageMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) + Canvas.DrawScrollBar(New Vector2(CInt(ScreenSize.Width / 2) + 250, 180), Languages.Count, 4, languageMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) Dim x As Integer = Languages.Count - 1 x = CInt(MathHelper.Clamp(x, 0, 3)) @@ -1188,10 +932,10 @@ Public Class MainMenuScreen Dim Name As String = LanguageNames(i + languageMenuIndex(2)) If i + languageMenuIndex(2) = languageMenuIndex(0) Then - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) Else - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) End If Next @@ -1212,8 +956,8 @@ Public Class MainMenuScreen CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") End If - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 208 + i * 192, 550, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 190 + i * 192, 582), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 208 + i * 192, 550, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 190 + i * 192, 582), Color.Black) Next End Sub @@ -1233,29 +977,29 @@ Public Class MainMenuScreen End If End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 1 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 208 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.languageMenuIndex(1) = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 208 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + languageMenuIndex(1) = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then Select Case languageMenuIndex(1) Case 0 currentLanguage = Languages(languageMenuIndex(0)) Core.GameOptions.SaveOptions() - Me.menuIndex = 0 + menuIndex = 0 Case 1 Localization.Load(currentLanguage) - Me.menuIndex = 0 + menuIndex = 0 End Select End If End If Next For i = 0 To 3 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then - Me.languageMenuIndex(0) = i + languageMenuIndex(2) + languageMenuIndex(0) = i + languageMenuIndex(2) End If End If Next @@ -1282,15 +1026,15 @@ Public Class MainMenuScreen Case 0 currentLanguage = Languages(languageMenuIndex(0)) Core.GameOptions.SaveOptions() - Me.menuIndex = 0 + menuIndex = 0 Case 1 Localization.Load(currentLanguage) - Me.menuIndex = 0 + menuIndex = 0 End Select End If If Controls.Dismiss() = True Then - Me.menuIndex = 0 + menuIndex = 0 End If End Sub @@ -1314,10 +1058,10 @@ Public Class MainMenuScreen End If End If - Canvas.DrawRectangle(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) + Canvas.DrawRectangle(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) Next - Canvas.DrawScrollBar(New Vector2(CInt(Core.ScreenSize.Width / 2) + 250, 180), PackNames.Count, 4, packsMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) + Canvas.DrawScrollBar(New Vector2(CInt(ScreenSize.Width / 2) + 250, 180), PackNames.Count, 4, packsMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) Dim x As Integer = PackNames.Count - 1 x = CInt(MathHelper.Clamp(x, 0, 3)) @@ -1333,10 +1077,10 @@ Public Class MainMenuScreen End If If i + packsMenuIndex(2) = packsMenuIndex(0) Then - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 245, 191 + i * 50), textColor) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 245, 191 + i * 50), textColor) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) Else - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), textColor) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), textColor) End If Next End If @@ -1358,8 +1102,8 @@ Public Class MainMenuScreen CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") End If - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 208 + i * 192, 550, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 190 + i * 192, 582), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 208 + i * 192, 550, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 190 + i * 192, 582), Color.Black) Next For i = 2 To 5 Dim Text As String = "" @@ -1392,8 +1136,8 @@ Public Class MainMenuScreen CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") End If - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt((Core.ScreenSize.Width / 2) + 280), ((i - 2) * 64) + 180, 160, 32), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt((Core.ScreenSize.Width / 2) + 280) + 15, ((i - 2) * 64) + 16 + 180), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt((ScreenSize.Width / 2) + 280), ((i - 2) * 64) + 180, 160, 32), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt((ScreenSize.Width / 2) + 280) + 15, ((i - 2) * 64) + 16 + 180), Color.Black) Next End Sub @@ -1413,38 +1157,38 @@ Public Class MainMenuScreen End If End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 1 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 208 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.packsMenuIndex(1) = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 208 + i * 192, 550, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + packsMenuIndex(1) = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then Select Case packsMenuIndex(1) Case 0 ButtonApplyPacks() Case 1 - Me.menuIndex = 0 + menuIndex = 0 End Select End If End If Next For i = 2 To 5 - If Core.ScaleScreenRec(New Rectangle(CInt((Core.ScreenSize.Width / 2) + 280), ((i - 2) * 64) + 180, 160 + 32, 32 + 32)).Contains(MouseHandler.MousePosition) = True Then - Me.packsMenuIndex(1) = i + If ScaleScreenRec(New Rectangle(CInt((ScreenSize.Width / 2) + 280), ((i - 2) * 64) + 180, 160 + 32, 32 + 32)).Contains(MouseHandler.MousePosition) = True Then + packsMenuIndex(1) = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then Select Case packsMenuIndex(1) - Case 2 ' Up - Me.ButtonUp() - Case 3 ' Down - Me.ButtonDown() - Case 4 ' Toggle + Case 2 'up + ButtonUp() + Case 3 'down + ButtonDown() + Case 4 'toggle If PackNames.Count > 0 Then - Me.ButtonToggle(PackNames(packsMenuIndex(0))) + ButtonToggle(PackNames(packsMenuIndex(0))) End If - Case 5 ' ContentPack information - Me.ButtonPackInformation() + Case 5 'packinformation + ButtonPackInformation() End Select End If End If @@ -1452,9 +1196,9 @@ Public Class MainMenuScreen End If For i = 0 To 3 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then - Me.packsMenuIndex(0) = i + packsMenuIndex(2) + packsMenuIndex(0) = i + packsMenuIndex(2) End If End If Next @@ -1476,22 +1220,22 @@ Public Class MainMenuScreen Case 0 ButtonApplyPacks() Case 1 - Me.menuIndex = 0 + menuIndex = 0 Case 2 - Me.ButtonUp() + ButtonUp() Case 3 - Me.ButtonDown() + ButtonDown() Case 4 If PackNames.Count > 0 Then - Me.ButtonToggle(PackNames(packsMenuIndex(0))) + ButtonToggle(PackNames(packsMenuIndex(0))) End If Case 5 - Me.ButtonPackInformation() + ButtonPackInformation() End Select End If If Controls.Dismiss() = True Then - Me.menuIndex = 0 + menuIndex = 0 End If End Sub @@ -1500,16 +1244,16 @@ Public Class MainMenuScreen Exit Sub End If - Me.menuIndex = 5 + menuIndex = 5 Dim packName As String = PackNames(packsMenuIndex(0)) PInfoSlpash = Nothing PInfoContent = "" Try - If System.IO.File.Exists(GameController.GamePath & "\ContentPacks\" & packName & "\splash.png") = True Then - Using stream As System.IO.Stream = System.IO.File.Open(GameController.GamePath & "\ContentPacks\" & packName & "\splash.png", IO.FileMode.OpenOrCreate) - PInfoSlpash = Texture2D.FromStream(Core.GraphicsDevice, stream) + If IO.File.Exists(GameController.GamePath & "\ContentPacks\" & packName & "\splash.png") = True Then + Using stream As IO.Stream = IO.File.Open(GameController.GamePath & "\ContentPacks\" & packName & "\splash.png", IO.FileMode.OpenOrCreate) + PInfoSlpash = Texture2D.FromStream(GraphicsDevice, stream) End Using End If Catch ex As Exception @@ -1517,18 +1261,18 @@ Public Class MainMenuScreen End Try Dim contentPackPath As String = GameController.GamePath & "\ContentPacks\" & packName & "\" - If System.IO.Directory.Exists(contentPackPath & "Songs") = True Then + If IO.Directory.Exists(contentPackPath & "Songs") = True Then Dim hasWMA As Boolean = False Dim hasXNB As Boolean = False Dim hasMP3 As Boolean = False - For Each file As String In System.IO.Directory.GetFiles(contentPackPath & "Songs") - If System.IO.Path.GetExtension(file).ToLower() = ".xnb" Then + For Each file As String In IO.Directory.GetFiles(contentPackPath & "Songs") + If IO.Path.GetExtension(file).ToLower() = ".xnb" Then hasXNB = True End If - If System.IO.Path.GetExtension(file).ToLower() = ".wma" Then + If IO.Path.GetExtension(file).ToLower() = ".wma" Then hasWMA = True End If - If System.IO.Path.GetExtension(file).ToLower() = ".mp3" Then + If IO.Path.GetExtension(file).ToLower() = ".mp3" Then hasMP3 = True End If Next @@ -1537,18 +1281,18 @@ Public Class MainMenuScreen PInfoContent = Localization.GetString("pack_menu_songs") End If End If - If System.IO.Directory.Exists(contentPackPath & "Sounds") = True Then + If IO.Directory.Exists(contentPackPath & "Sounds") = True Then Dim hasWMA As Boolean = False Dim hasXNB As Boolean = False Dim hasWAV As Boolean = False - For Each file As String In System.IO.Directory.GetFiles(contentPackPath & "Sounds") - If System.IO.Path.GetExtension(file).ToLower() = ".xnb" Then + For Each file As String In IO.Directory.GetFiles(contentPackPath & "Sounds") + If IO.Path.GetExtension(file).ToLower() = ".xnb" Then hasXNB = True End If - If System.IO.Path.GetExtension(file).ToLower() = ".wma" Then + If IO.Path.GetExtension(file).ToLower() = ".wma" Then hasWMA = True End If - If System.IO.Path.GetExtension(file).ToLower() = ".wav" Then + If IO.Path.GetExtension(file).ToLower() = ".wav" Then hasWAV = True End If Next @@ -1564,14 +1308,14 @@ Public Class MainMenuScreen Dim textureDirectories() As String = {"Textures", "GUI", "Items", "Pokemon", "SkyDomeResource"} For Each folder As String In textureDirectories - If System.IO.Directory.Exists(contentPackPath & folder) = True Then + If IO.Directory.Exists(contentPackPath & folder) = True Then Dim hasXNB As Boolean = False Dim hasPNG As Boolean = False - For Each file As String In System.IO.Directory.GetFiles(contentPackPath & folder, "*.*", IO.SearchOption.AllDirectories) - If System.IO.Path.GetExtension(file).ToLower() = ".xnb" Then + For Each file As String In IO.Directory.GetFiles(contentPackPath & folder, "*.*", IO.SearchOption.AllDirectories) + If IO.Path.GetExtension(file).ToLower() = ".xnb" Then hasXNB = True End If - If System.IO.Path.GetExtension(file).ToLower() = ".png" Then + If IO.Path.GetExtension(file).ToLower() = ".png" Then hasPNG = True End If Next @@ -1616,16 +1360,16 @@ Public Class MainMenuScreen End If If Not PInfoSlpash Is Nothing Then - Core.SpriteBatch.DrawInterface(PInfoSlpash, Core.ScreenSize, Color.White) + SpriteBatch.DrawInterface(PInfoSlpash, ScreenSize, Color.White) End If Dim CanvasTexture As Texture2D = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 256, 160, 480, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Localization.GetString("pack_menu_name") & ": " & PInfoName, New Vector2(CInt(Core.ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString(Localization.GetString("pack_menu_name") & ": " & PInfoName).X / 2), 195), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 256, 160, 480, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Localization.GetString("pack_menu_name") & ": " & PInfoName, New Vector2(CInt(ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString(Localization.GetString("pack_menu_name") & ": " & PInfoName).X / 2), 195), Color.Black) - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 256, 288, 480, 224), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, Localization.GetString("pack_menu_version") & ": " & PInfoVersion & vbNewLine & Localization.GetString("pack_menu_by") & ": " & PInfoAuthor & vbNewLine & Localization.GetString("pack_menu_content") & ": " & PInfoContent & vbNewLine & Localization.GetString("pack_menu_description") & ": " & PInfoDescription.Replace("
", vbNewLine), New Vector2(CInt(Core.ScreenSize.Width / 2) - 220, 323), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 256, 288, 480, 224), True) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, Localization.GetString("pack_menu_version") & ": " & PInfoVersion & vbNewLine & Localization.GetString("pack_menu_by") & ": " & PInfoAuthor & vbNewLine & Localization.GetString("pack_menu_content") & ": " & PInfoContent & vbNewLine & Localization.GetString("pack_menu_description") & ": " & PInfoDescription.Replace("
", vbNewLine), New Vector2(CInt(ScreenSize.Width / 2) - 220, 323), Color.Black) For i = 0 To 1 If i = packInfoIndex Then @@ -1647,17 +1391,17 @@ Public Class MainMenuScreen Text = Localization.GetString("pack_menu_back") End Select - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 + (200 * i), 550, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 160 + (200 * i), 582), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 180 + (200 * i), 550, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 160 + (200 * i), 582), Color.Black) Next End Sub Private Sub UpdatePackInformationMenu() Dim packName As String = PInfoName - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 1 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 + (200 * i), 550, 160, 96)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 180 + (200 * i), 550, 160, 96)).Contains(MouseHandler.MousePosition) = True Then packInfoIndex = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then @@ -1679,7 +1423,7 @@ Public Class MainMenuScreen packInfoIndex -= 1 End If - Me.packInfoIndex = CInt(MathHelper.Clamp(Me.packInfoIndex, 0, 1)) + packInfoIndex = CInt(MathHelper.Clamp(packInfoIndex, 0, 1)) If Controls.Accept(False) = True Then Select Case packInfoIndex @@ -1760,11 +1504,11 @@ Public Class MainMenuScreen Private Sub DrawDeleteMenu() Dim CanvasTexture As Texture2D = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2 - 352), 172, 704, 96), Color.White, True) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2 - 352), 172, 704, 96), Color.White, True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Localization.GetString("delete_menu_delete_confirm"), New Vector2(CInt(Core.ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString(Localization.GetString("delete_menu_delete_confirm")).X / 2), 200), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Localization.GetString("delete_menu_delete_confirm"), New Vector2(CInt(ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString(Localization.GetString("delete_menu_delete_confirm")).X / 2), 200), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, """" & SaveNames(loadMenuIndex(0)) & """ ?", New Vector2(CInt(Core.ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString("""" & SaveNames(loadMenuIndex(0)) & """ ?").X / 2), 240), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, """" & SaveNames(loadMenuIndex(0)) & """ ?", New Vector2(CInt(ScreenSize.Width / 2) - CInt(FontManager.InGameFont.MeasureString("""" & SaveNames(loadMenuIndex(0)) & """ ?").X / 2), 240), Color.Black) For i = 0 To 1 Dim Text As String = Localization.GetString("delete_menu_delete") @@ -1779,8 +1523,8 @@ Public Class MainMenuScreen CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") End If - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 182 + i * 192, 370, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 164 + i * 192, 402), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 182 + i * 192, 370, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 164 + i * 192, 402), Color.Black) Next End Sub @@ -1792,9 +1536,9 @@ Public Class MainMenuScreen deleteIndex = 0 End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 1 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 182 + i * 192, 370, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 182 + i * 192, 370, 128 + 32, 64 + 32)).Contains(MouseHandler.MousePosition) = True Then deleteIndex = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then @@ -1820,12 +1564,12 @@ Public Class MainMenuScreen End Sub Private Sub Delete() - System.IO.Directory.Delete(Saves(loadMenuIndex(0)), True) + IO.Directory.Delete(Saves(loadMenuIndex(0)), True) Dim deleteAutosave As Boolean = False - For Each f As String In System.IO.Directory.GetDirectories(GameController.GamePath & "\Save\") - If System.IO.File.Exists(f & "\Player.dat") = True Then - Dim Data() As String = System.IO.File.ReadAllText(f & "\Player.dat").SplitAtNewline() + For Each f As String In IO.Directory.GetDirectories(GameController.GamePath & "\Save\") + If IO.File.Exists(f & "\Player.dat") = True Then + Dim Data() As String = IO.File.ReadAllText(f & "\Player.dat").SplitAtNewline() Dim Autosave As Boolean = False For Each Line As String In Data @@ -1839,7 +1583,7 @@ Public Class MainMenuScreen End If Next If deleteAutosave = True Then - System.IO.Directory.Delete(GameController.GamePath & "\Save\autosave", True) + IO.Directory.Delete(GameController.GamePath & "\Save\autosave", True) End If tempLoadDisplay = "" @@ -1862,16 +1606,16 @@ Public Class MainMenuScreen If Core.GameOptions.StartedOfflineGame = True Then If GameModeManager.GameModeCount < 2 Then GameModeManager.SetGameModePointer("Kolben") - Core.SetScreen(New TransitionScreen(Me, New NewGameScreen(), Color.Black, False)) + 'SetScreen(New TransitionScreen(Me, New NewGameScreen(), Color.Black, False)) Else GetGameModes() GameModeSplash = Nothing - Me.menuIndex = 6 + menuIndex = 6 End If Else Core.GameOptions.StartedOfflineGame = True Core.GameOptions.SaveOptions() - Core.SetScreen(New OfflineGameWarningScreen(Me)) + SetScreen(New OfflineGameWarningScreen(Me)) End If End Sub @@ -1880,7 +1624,7 @@ Public Class MainMenuScreen Private Sub DrawNewGameMenu() If Not GameModeSplash Is Nothing Then - Core.SpriteBatch.DrawInterface(GameModeSplash, Core.ScreenSize, Color.White) + SpriteBatch.DrawInterface(GameModeSplash, ScreenSize, Color.White) End If Dim CanvasTexture As Texture2D @@ -1891,10 +1635,10 @@ Public Class MainMenuScreen c = New Color(101, 142, 255) End If - Canvas.DrawRectangle(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) + Canvas.DrawRectangle(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48), c, True) Next - Canvas.DrawScrollBar(New Vector2(CInt(Core.ScreenSize.Width / 2) + 250, 180), ModeNames.Count, 4, gameModeMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) + Canvas.DrawScrollBar(New Vector2(CInt(ScreenSize.Width / 2) + 250, 180), ModeNames.Count, 4, gameModeMenuIndex(2), New Size(4, 200), False, New Color(190, 190, 190), New Color(63, 63, 63), True) Dim x As Integer = ModeNames.Count - 1 x = CInt(MathHelper.Clamp(x, 0, 3)) @@ -1903,15 +1647,15 @@ Public Class MainMenuScreen Dim Name As String = ModeNames(i + gameModeMenuIndex(2)) If i + gameModeMenuIndex(2) = gameModeMenuIndex(0) Then - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 245, 191 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.White) Else - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(Core.ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Name, New Vector2(CInt(ScreenSize.Width / 2) - 248, 188 + i * 50), Color.Black) End If Next CanvasTexture = TextureManager.GetTexture("GUI\Menus\Menu", New Rectangle(0, 0, 48, 48), "") - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 272, 388, 512, 128), True) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 272, 388, 512, 128), True) If tempGameModesDisplay = "" Then Dim GameMode As GameMode = GameModeManager.GetGameMode(ModeNames(gameModeMenuIndex(0))) @@ -1922,14 +1666,14 @@ Public Class MainMenuScreen Dim dispAuthor As String = GameMode.Author Dim dispContentPath As String = GameMode.ContentPath - Me.tempGameModesDisplay = Localization.GetString("gamemode_menu_name") & ": " & dispName & vbNewLine & + tempGameModesDisplay = Localization.GetString("gamemode_menu_name") & ": " & dispName & vbNewLine & Localization.GetString("gamemode_menu_version") & ": " & dispVersion & vbNewLine & Localization.GetString("gamemode_menu_author") & ": " & dispAuthor & vbNewLine & Localization.GetString("gamemode_menu_contentpath") & ": " & dispContentPath & vbNewLine & Localization.GetString("gamemode_menu_description") & ": " & dispDescription End If - Core.SpriteBatch.DrawInterfaceString(FontManager.MiniFont, tempGameModesDisplay, New Vector2(CInt(Core.ScreenSize.Width / 2) - 252, 416), Color.Black) + SpriteBatch.DrawInterfaceString(FontManager.MiniFont, tempGameModesDisplay, New Vector2(CInt(ScreenSize.Width / 2) - 252, 416), Color.Black) For i = 0 To 1 If i = gameModeMenuIndex(1) Then @@ -1947,8 +1691,8 @@ Public Class MainMenuScreen Text = Localization.GetString("gamemode_menu_back") End Select - Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 + (200 * i), 550, 128, 64), True) - Core.SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(Core.ScreenSize.Width / 2) - 160 + (200 * i), 582), Color.Black) + Canvas.DrawImageBorder(CanvasTexture, 2, New Rectangle(CInt(ScreenSize.Width / 2) - 180 + (200 * i), 550, 128, 64), True) + SpriteBatch.DrawInterfaceString(FontManager.InGameFont, Text, New Vector2(CInt(ScreenSize.Width / 2) - 160 + (200 * i), 582), Color.Black) Next End Sub @@ -1970,17 +1714,17 @@ Public Class MainMenuScreen GameModeSplash = Nothing End If - If Core.GameInstance.IsMouseVisible = True Then + If GameInstance.IsMouseVisible = True Then For i = 0 To 1 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 180 + (200 * i), 550, 160, 96)).Contains(MouseHandler.MousePosition) = True Then - Me.gameModeMenuIndex(1) = i + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 180 + (200 * i), 550, 160, 96)).Contains(MouseHandler.MousePosition) = True Then + gameModeMenuIndex(1) = i If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then Select Case gameModeMenuIndex(1) Case 0 AcceptGameMode() Case 1 - Me.menuIndex = 0 + menuIndex = 0 tempGameModesDisplay = "" End Select @@ -1990,9 +1734,9 @@ Public Class MainMenuScreen End If For i = 0 To 3 - If Core.ScaleScreenRec(New Rectangle(CInt(Core.ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then + If ScaleScreenRec(New Rectangle(CInt(ScreenSize.Width / 2) - 258, 180 + i * 50, 480, 48)).Contains(MouseHandler.MousePosition) = True Then If MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) = True Then - Me.gameModeMenuIndex(0) = i + gameModeMenuIndex(2) + gameModeMenuIndex(0) = i + gameModeMenuIndex(2) tempGameModesDisplay = "" GameModeSplash = Nothing End If @@ -2016,7 +1760,7 @@ Public Class MainMenuScreen Case 0 AcceptGameMode() Case 1 - Me.menuIndex = 0 + menuIndex = 0 tempGameModesDisplay = "" End Select @@ -2025,9 +1769,9 @@ Public Class MainMenuScreen If GameModeSplash Is Nothing Then Try Dim fileName As String = GameController.GamePath & "\GameModes\" & ModeNames(gameModeMenuIndex(0)) & "\GameMode.png" - If System.IO.File.Exists(fileName) = True Then - Using stream As System.IO.Stream = System.IO.File.Open(fileName, IO.FileMode.OpenOrCreate) - GameModeSplash = Texture2D.FromStream(Core.GraphicsDevice, stream) + If IO.File.Exists(fileName) = True Then + Using stream As IO.Stream = IO.File.Open(fileName, IO.FileMode.OpenOrCreate) + GameModeSplash = Texture2D.FromStream(GraphicsDevice, stream) End Using End If Catch ex As Exception @@ -2036,13 +1780,13 @@ Public Class MainMenuScreen End If If Controls.Dismiss() = True Then - Me.menuIndex = 0 + menuIndex = 0 End If End Sub Private Sub AcceptGameMode() GameModeManager.SetGameModePointer(ModeNames(gameModeMenuIndex(0))) - Core.SetScreen(New TransitionScreen(Me, New NewGameScreen(), Color.Black, False)) + 'SetScreen(New TransitionScreen(Me, New NewGameScreen(), Color.Black, False)) End Sub #End Region diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/NewGameCamera.vb b/2.5DHero/2.5DHero/Screens/MainMenu/NewGameCamera.vb new file mode 100644 index 000000000..1607ef00a --- /dev/null +++ b/2.5DHero/2.5DHero/Screens/MainMenu/NewGameCamera.vb @@ -0,0 +1,63 @@ +Public Class NewGameCamera + + Inherits OverworldCamera + + Public Sub New() + Me.Name = "New Game" + Core.Player.startThirdPerson = False + Me.Position = New Vector3(13, 2, 14) + Me.Speed = 0.0008F + + Yaw = CSng(Core.Random.NextDouble() * MathHelper.TwoPi) + Pitch = -0.2F + + View = Matrix.CreateLookAt(Position, Vector3.Zero, Vector3.Up) + Projection = Matrix.CreatePerspectiveFieldOfView(MathHelper.ToRadians(45.0), Core.GraphicsDevice.Viewport.AspectRatio, 0.01, 16) + + Update() + End Sub + + Public Overrides Sub Update() + Ray = createRay() + + UpdateMatrices() + UpdateFrustrum() + End Sub + + Public Function createRay() As Ray + Dim centerX As Integer = CInt(Core.windowSize.Width / 2) + Dim centerY As Integer = CInt(Core.windowSize.Height / 2) + + Dim nearSource As Vector3 = New Vector3(centerX, centerY, 0) + Dim farSource As Vector3 = New Vector3(centerX, centerY, 1) + + Dim nearPoint As Vector3 = Core.GraphicsDevice.Viewport.Unproject(nearSource, Projection, View, Matrix.Identity) + Dim farPoint As Vector3 = Core.GraphicsDevice.Viewport.Unproject(farSource, Projection, View, Matrix.Identity) + + Dim direction As Vector3 = farPoint - nearPoint + direction.Normalize() + + Return New Ray(nearPoint, direction) + End Function + + Private Sub UpdateFrustrum() + Dim rotation As Matrix = Matrix.CreateRotationX(Pitch) * Matrix.CreateRotationY(Yaw) + + Dim fPosition As New Vector3(Me.Position.X, Me.Position.Y, Me.Position.Z) + + Dim transformed As Vector3 = Vector3.Transform(New Vector3(0, 0, -1), rotation) + Dim lookAt As Vector3 = fPosition + transformed + + Me.BoundingFrustum = New BoundingFrustum(Matrix.CreateLookAt(fPosition, lookAt, Vector3.Up) * Projection) + End Sub + + Public Sub UpdateMatrices() + Dim rotation As Matrix = Matrix.CreateRotationX(Pitch) * Matrix.CreateRotationY(Yaw) + + Dim transformed As Vector3 = Vector3.Transform(New Vector3(0, 0, -1), rotation) + Dim lookAt As Vector3 = Position + transformed + + View = Matrix.CreateLookAt(Position, lookAt, Vector3.Up) + End Sub + +End Class \ No newline at end of file diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/NewNewGameScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/NewNewGameScreen.vb new file mode 100644 index 000000000..05fb8c154 --- /dev/null +++ b/2.5DHero/2.5DHero/Screens/MainMenu/NewNewGameScreen.vb @@ -0,0 +1,285 @@ +Namespace Screens.MainMenu + + ''' + ''' The screen that is used to act out a New Game sequence. + ''' + Public Class NewNewGameScreen + + Inherits OverworldScreen + + Private Shared _fadeValue As Integer = 255 'Fade progress value for the black screen fade. + + 'Public Shared Property FadeValue() As Integer + ' Get + ' Return _fadeValue + ' End Get + ' Set(value As Integer) + ' _fadeValue = value + ' End Set + 'End Property + + Public Sub New(ByVal currentScreen As Screen) + Identification = Identifications.NewGameScreen + CanChat = False + MouseVisible = False + IsOverlay = True + PreScreen = currentScreen + CanBePaused = False + UpdateFadeOut = True + + + 'Set up 3D environment variables (Effect, Camera, SkyDome and Level): + Effect = New BasicEffect(GraphicsDevice) + Effect.FogEnabled = True + + 'Reset Construct: + ScriptStorage.Clear() + Me.ActionScript.Scripts.Clear() + + + Camera = New NewGameCamera() + + SkyDome = New SkyDome() + Level = New Level() + Level.Load(GameModeManager.ActiveGameMode.StartMap) + + Core.Player.Unload() + + MusicManager.StopMusic() + + 'Initialize the World information with the loaded level. + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) + + Me.ActionScript.StartScript("newgame\intro", 0) + End Sub + + Public Overrides Sub Update() + Lighting.UpdateLighting(Effect) 'Update the lighting on the basic effect. + + 'Update the Dialogues: + ChooseBox.Update() + If ChooseBox.Showing = False Then + TextBox.Update() + End If + If PokemonImageView.Showing = True Then + PokemonImageView.Update() + End If + + 'If no dialogue is showing, do level update tasks: + If TextBox.Showing = False And ChooseBox.Showing = False And PokemonImageView.Showing = False Then + If Me.ActionScript.IsReady Then + Camera.Update() + Level.Update() + End If + If ActionScript.Scripts.Count = 0 Then + If CurrentScreen.Identification = Screen.Identifications.NewGameScreen Then + Core.SetScreen(New TransitionScreen(CurrentScreen, New OverworldScreen(), Color.Black, False)) + Else + Dim fadeSpeed As Integer = 12 + If OverworldScreen.FadeValue > 0 Then + OverworldScreen.FadeValue -= fadeSpeed + If OverworldScreen.FadeValue <= 0 Then + OverworldScreen.FadeValue = 0 + End If + End If + End If + Else + Me.ActionScript.Update() 'Update construct scripts. + End If + Else + Camera.Update() + Level.Update() + End If + + SkyDome.Update() + + 'Update the World with new environment variables. + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) + + End Sub + + Public Overrides Sub Draw() + SkyDome.Draw(Camera.FOV) + + Level.Draw() + + PokemonImageView.Draw() + TextBox.Draw() + + 'Only draw the ChooseBox when it's the current screen, cause the same ChooseBox might get used on other screens. + If IsCurrentScreen() = True Then + ChooseBox.Draw() + End If + + If FadeValue > 0 Then + Canvas.DrawRectangle(windowSize, New Color(0, 0, 0, FadeValue)) + End If + End Sub + + Public Shared Sub EndNewGame(ByVal map As String, ByVal x As Single, ByVal y As Single, ByVal z As Single, ByVal rot As Integer) + Dim folderPath As String = Core.Player.Name + Dim folderPrefix As Integer = 0 + + If folderPath.ToLower() = "autosave" Then + folderPath = "autosave0" + End If + + Dim savePath As String = GameController.GamePath & "\Save\" + + While IO.Directory.Exists(savePath & folderPath) = True + If folderPath <> Core.Player.Name Then + folderPath = folderPath.Remove(folderPath.Length - folderPrefix.ToString().Length, folderPrefix.ToString().Length) + End If + + folderPath &= folderPrefix + + folderPrefix += 1 + End While + + If IO.Directory.Exists(GameController.GamePath & "\Save") = False Then + IO.Directory.CreateDirectory(GameController.GamePath & "\Save") + End If + + IO.Directory.CreateDirectory(savePath & folderPath) + + Core.Player.filePrefix = folderPath + Core.Player.GameStart = Date.Now + + Core.Player.SaveGame(False) + Core.Player.LoadGame(folderPath) + + Core.Player.startFOV = 60 + Core.Player.startFreeCameraMode = True + Core.Player.startPosition = New Vector3(x, y, z) + Core.Player.startMap = map + Core.Player.startRotationSpeed = 12 + Core.Player.startSurfing = False + Core.Player.startThirdPerson = False + Core.Player.startRiding = False + Core.Player.startRotation = CSng(MathHelper.Pi * (rot / 2)) + + 'Construct.Controller.GetInstance().Context = Construct.ScriptContext.Overworld + + ''SetScreen(New TransitionScreen(CurrentScreen, New OverworldScreen(), Color.Black, False)) + ''SetScreen(New OverworldScreen()) + Core.Player.SaveGame(False) + End Sub + + ''' + ''' A screen used to select from a range of skins. + ''' + Public Class CharacterSelectionScreen + + Inherits Screen + + Private _skins As String() + Private _sprites As New List(Of Texture2D) + + Private _offset As Single = 0F + Private _index As Integer = 0 + + Private _fadeIn As Single = 0F + + Private Shared _selectedSkin As String = "" + + Public Shared Property SelectedSkin() As String + Get + Return _selectedSkin + End Get + Set(value As String) + _selectedSkin = value + End Set + End Property + + Public Sub New(ByVal currentScreen As Screen, ByVal skins As String()) + Identification = Identifications.CharacterSelectionScreen + PreScreen = currentScreen + CanBePaused = True + CanChat = False + CanDrawDebug = True + CanGoFullscreen = True + CanTakeScreenshot = True + MouseVisible = True + + For Each skin As String In skins + _sprites.Add(TextureManager.GetTexture("Textures\NPC\" & skin)) + Next + + _skins = skins + End Sub + + Public Overrides Sub Update() + If _fadeIn < 1.0F Then + _fadeIn = MathHelper.Lerp(1.0F, _fadeIn, 0.95F) + If _fadeIn + 0.01F >= 1.0F Then + _fadeIn = 1.0F + End If + Else + If Controls.Left(True) And _index > 0 Then + _index -= 1 + _offset -= 280 + End If + If Controls.Right(True) And _index < _skins.Count - 1 Then + _index += 1 + _offset += 280 + End If + + If _offset > 0F Then + _offset = MathHelper.Lerp(0F, _offset, 0.9F) + If _offset - 0.01F <= 0F Then + _offset = 0F + End If + ElseIf _offset < 0F Then + _offset = MathHelper.Lerp(0F, _offset, 0.9F) + If _offset + 0.01F >= 0F Then + _offset = 0F + End If + End If + + If Controls.Accept(False, True, True) Then + _selectedSkin = _skins(_index) + SetScreen(PreScreen) + End If + If Controls.Accept(True, False, False) Then + For i = 0 To _skins.Count - 1 + If New Rectangle(CInt(windowSize.Width / 2 - 128 + i * 280 - _index * 280 + _offset), CInt(windowSize.Height / 2 - 128), 256, 256).Contains(MouseHandler.MousePosition) Then + If i = _index Then + _selectedSkin = _skins(_index) + SetScreen(PreScreen) + Else + _offset += (i - _index) * 280 + _index = i + End If + Exit For + End If + Next + End If + End If + End Sub + + Public Overrides Sub Draw() + PreScreen.Draw() + + Canvas.DrawRectangle(windowSize, Screens.UI.ColorProvider.MainColor(False, CInt(100 * _fadeIn))) + + DrawGradients(255) + + SpriteBatch.DrawString(FontManager.MainFont, "Select your appearance", New Vector2(windowSize.Width / 2.0F - FontManager.MainFont.MeasureString("Select your appearance").X, 100), New Color(255, 255, 255, CInt(255 * _fadeIn)), 0F, Vector2.Zero, 2.0F, SpriteEffects.None, 0F) + + For i = 0 To _sprites.Count - 1 + Dim sprite As Texture2D = _sprites(i) + Dim frameSize As New Size(CInt(sprite.Width / 3), CInt(sprite.Height / 4)) + + Dim outSize As Integer = 256 - Math.Abs(_index - i) * 30 + + SpriteBatch.Draw(sprite, New Rectangle(CInt(windowSize.Width / 2 - CInt(outSize / 2) + i * 280 - _index * 280 + _offset), CInt(windowSize.Height / 2 - 128), outSize, outSize), New Rectangle(0, frameSize.Height * 2, frameSize.Width, frameSize.Height), New Color(255, 255, 255, CInt(255 * _fadeIn))) + Next + + SpriteBatch.DrawString(FontManager.MainFont, _skins(_index), New Vector2(windowSize.Width / 2.0F - FontManager.MainFont.MeasureString(_skins(_index)).X / 2.0F, windowSize.Height / 2.0F + 200), New Color(255, 255, 255, CInt(255 * _fadeIn))) + End Sub + + End Class + + End Class + +End Namespace \ No newline at end of file diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/PauseScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/PauseScreen.vb index 262987c3d..39fe607cf 100644 --- a/2.5DHero/2.5DHero/Screens/MainMenu/PauseScreen.vb +++ b/2.5DHero/2.5DHero/Screens/MainMenu/PauseScreen.vb @@ -258,10 +258,11 @@ End If Chat.ClearChat() If Core.Player.loadedSave = True And Me.canCreateAutosave = True Then - Core.Player.SaveGame(True) + 'Core.Player.SaveGame(True) + Core.Player.SaveGame(False) End If ScriptStorage.Clear() - Core.SetScreen(New MainMenuScreen()) + Core.SetScreen(New PressStartScreen()) Core.Player.loadedSave = False End Sub diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/PressStartScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/PressStartScreen.vb new file mode 100644 index 000000000..49518bbf7 --- /dev/null +++ b/2.5DHero/2.5DHero/Screens/MainMenu/PressStartScreen.vb @@ -0,0 +1,900 @@ +''' +''' The "Press {BUTTON} to start" screen. +''' +Public Class PressStartScreen + + Inherits Screen + + Private _fadeIn As Single = 1.0F + Private _introDelay As Single = 4.0F + Private _logoFade As Single = 1.0F + + 'Private _mainMenuMaps As DataModel.Json.Game.MainMenuMapModel() + + Private _logoTexture As Texture2D = Nothing + Private _shineTexture As Texture2D = Nothing + + Private _logoRenderer As SpriteBatch + Private _shineRenderer As SpriteBatch + Private _backgroundRenderer As SpriteBatch + + Private target As RenderTarget2D + + Dim tempF As Single = 0F + Dim tempG As Single = 0F + + Public Sub New() + Identification = Identifications.PressStartScreen + CanBePaused = False + MouseVisible = True + CanChat = False + + TextBox.Showing = False + PokemonImageView.Showing = False + ChooseBox.Showing = False + + GameModeManager.SetGameModePointer("Kolben") + + Effect = New BasicEffect(GraphicsDevice) + Effect.FogEnabled = True + + SkyDome = New SkyDome() + Camera = New MainMenuCamera() + + Core.Player.Skin = "Hilbert" + Level = New Level() + ChangeLevel() + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) + + If IO.Directory.Exists(GameController.GamePath & "\Save\") = False Then + IO.Directory.CreateDirectory(GameController.GamePath & "\Save\") + End If + + GameJolt.Emblem.ClearOnlineSpriteCache() + + _logoTexture = TextureManager.GetTexture("GUI\Logos\Pokemon_Small") + _shineTexture = TextureManager.GetTexture("GUI\Logos\logo_shine") + + _logoRenderer = New SpriteBatch(GraphicsDevice) + _shineRenderer = New SpriteBatch(GraphicsDevice) + _backgroundRenderer = New SpriteBatch(GraphicsDevice) + + target = New RenderTarget2D(GraphicsDevice, windowSize.Width, windowSize.Height) + + 'crappy fix + Screens.MainMenu.NewNewGameScreen.CharacterSelectionScreen.SelectedSkin = "" + Core.Player.Unload() + End Sub + + Public Overrides Sub Update() + Lighting.UpdateLighting(Effect) + + Camera.Update() + Level.Update() + SkyDome.Update() + Level.World.Initialize(Level.EnvironmentType, Level.WeatherType) + + If _introDelay > 0F Then + _introDelay -= 0.1F + If _introDelay <= 0F Then + _introDelay = 0F + End If + Else + If IsCurrentScreen() Then + If _fadeIn > 0.0F Then + _fadeIn = MathHelper.Lerp(0.0F, _fadeIn, 0.93F) + If _fadeIn - 0.01F <= 0.0F Then + _fadeIn = 0.0F + End If + End If + Else + If _logoFade > 0.0F Then + _logoFade = MathHelper.Lerp(0.0F, _logoFade, 0.2F) + If _logoFade - 0.01F <= 0.0F Then + _logoFade = 0.0F + End If + End If + End If + + tempF += 0.01F + tempG += 0.04F + + If IsCurrentScreen() Then + If KeyBoardHandler.KeyPressed(KeyBindings.EnterKey1) Or ControllerHandler.ButtonPressed(Buttons.A) Or MouseHandler.ButtonPressed(MouseHandler.MouseButtons.LeftButton) Then + SetScreen(New NewMainMenuScreen(Me)) + End If + End If + End If + End Sub + + Private _blurHandler As Resources.GaussianEffect + + Public Overrides Sub Draw() + If _blurHandler Is Nothing Then + _blurHandler = New Resources.GaussianEffect(windowSize.Width, windowSize.Height) + End If + + GraphicsDevice.SetRenderTarget(target) + GraphicsDevice.Clear(BackgroundColor) + + SkyDome.Draw(45.0F) + Level.Draw() + + GraphicsDevice.SetRenderTarget(Nothing) + + _backgroundRenderer.Begin() + _backgroundRenderer.Draw(_blurHandler.Perform(target), New Rectangle(0, 0, windowSize.Width, windowSize.Height), Color.White) + _backgroundRenderer.End() + + If IsCurrentScreen() Then + _logoRenderer.Begin(SpriteSortMode.Texture, BlendState.AlphaBlend, SamplerState.AnisotropicClamp, DepthStencilState.Default, RasterizerState.CullNone) + Else + _logoRenderer.Begin(SpriteSortMode.Texture, BlendState.NonPremultiplied, SamplerState.AnisotropicClamp, DepthStencilState.Default, RasterizerState.CullNone) + End If + _shineRenderer.Begin(SpriteSortMode.Texture, BlendState.Additive) + + _logoRenderer.Draw(_logoTexture, New Rectangle(CInt(ScreenSize.Width / 2) - 400, CInt(160 * _fadeIn), 768, 282), New Color(255, 255, 255, CInt(255 * _logoFade))) + _shineRenderer.Draw(_shineTexture, New Rectangle(CInt(ScreenSize.Width / 2 - 250 + Math.Sin(tempF) * 240.0F), CInt(-100 + Math.Sin(tempG) * 10.0F + CInt(160 * _fadeIn)), 512, 512), New Color(255, 255, 255, CInt(255 * _logoFade))) + + If _fadeIn = 0F Then + If IsCurrentScreen() And CInt(Date.Now.Millisecond / 500) = 1 Then + Dim text As String = String.Empty + If ControllerHandler.IsConnected() Then + text = "Press to start" + Else + text = "Press " & KeyBindings.EnterKey1.ToString() & " or click to start" + End If + + Dim textSize As Vector2 = FontManager.GameJoltFont.MeasureString(text) + + GetFontRenderer().DrawString(FontManager.GameJoltFont, text, New Vector2(windowSize.Width / 2.0F - textSize.X / 2.0F, + windowSize.Height / 2.0F - textSize.Y / 2.0F + 100), Color.White) + + If ControllerHandler.IsConnected() Then + SpriteBatch.Draw(TextureManager.GetTexture("GUI\GamePad\xboxControllerButtonA"), New Rectangle(CInt(windowSize.Width / 2 - textSize.X / 2 + FontManager.GameJoltFont.MeasureString("Press ").X), + CInt(windowSize.Height / 2 - textSize.Y / 2 + 98), 40, 40), Color.White) + End If + End If + End If + + _logoRenderer.End() + _shineRenderer.End() + + Canvas.DrawRectangle(windowSize, New Color(0, 0, 0, CInt(255 * _fadeIn))) + End Sub + + Private Sub ChangeLevel() + Dim levelCount As Integer = 0 + For Each levelPath As String In System.IO.Directory.GetFiles(GameController.GamePath & "\maps\mainmenu\") + Dim levelFile As String = System.IO.Path.GetFileName(levelPath) + If levelFile.StartsWith("mainmenu") = True And levelFile.EndsWith(".dat") = True Then + levelCount += 1 + End If + Next + + Dim levelID As Integer = Core.Random.Next(0, levelCount) + + Level.Load("mainmenu\mainmenu" & levelID & ".dat") + End Sub + + Public Overrides Sub ChangeTo() + Core.Player.Unload() + Core.Player.Skin = "Hilbert" + TextBox.Hide() + TextBox.CanProceed = True + OverworldScreen.FadeValue = 0 + + MusicManager.PlayMusic("title", True, 0.0F, 0.0F) + End Sub + +End Class + +Public Class NewMainMenuScreen + + 'TODO: Replace old MainMenuScreen. + + Inherits Screen + + Private _screenOffset As Vector2 = New Vector2(20, 180) + Private _screenOffsetTarget As Vector2 = New Vector2(20, 180) + + Private _loading As Boolean = True + Private _fadeIn As Single = 0F + Private _expandDisplay As Single = 0F + Private _closingDisplay As Boolean = False + Private _displayTextFade As Single = 0F + + Private _sliderPosition As Single = 0F + Private _sliderTarget As Integer = 0 + + Private _menuTexture As Texture2D = Nothing + + Private _profiles As New List(Of GameProfile) + Private _selectedProfile As Integer = 0 + Private _menuIndex As Integer = 1 '0 = New Game, 1 = Profiles + + Private _messageBox As UI.MessageBox + + Public Sub New(ByVal currentScreen As Screen) + Identification = Identifications.MainMenuScreen + PreScreen = currentScreen + + CanBePaused = False + MouseVisible = True + CanChat = False + + _menuTexture = TextureManager.GetTexture("GUI\Menus\MainMenu") + + _screenOffset.X = CSng(windowSize.Width / 2 - 80) + _screenOffsetTarget.X = _screenOffset.X + _sliderTarget = GetSliderTarget(_selectedProfile) + _sliderPosition = _sliderTarget + + _messageBox = New UI.MessageBox(Me) + End Sub + + Public Overrides Sub Update() + PreScreen.Update() + If _loading = False Then + If _fadeIn < 1.0F Then + _fadeIn = MathHelper.Lerp(1.0F, _fadeIn, 0.93F) + If _fadeIn + 0.01F >= 1.0F Then + _fadeIn = 1.0F + _sliderPosition = _sliderTarget + End If + Else + If Controls.Accept(True, False, False) Then + 'Click on profiles: + For x = 0 To _profiles.Count - 1 + Dim xOffset As Single = _screenOffset.X + x * 180 + ((x + 1) * 100 * (1 - _fadeIn)) + + If New Rectangle(CInt(xOffset), CInt(_screenOffset.Y), 160, 160).Contains(MouseHandler.MousePosition) Then + If _selectedProfile = x Then + ClickedProfile() + Else + Dim diff As Integer = x - _selectedProfile + _screenOffsetTarget.X -= diff * 180 + + _selectedProfile = x + End If + Exit For + End If + Next + End If + + If Controls.Right(True) And _selectedProfile < _profiles.Count - 1 Then + _selectedProfile += 1 + _screenOffsetTarget.X -= 180 + End If + If Controls.Left(True) And _selectedProfile > 0 Then + _selectedProfile -= 1 + _screenOffsetTarget.X += 180 + End If + _selectedProfile = _selectedProfile.Clamp(0, _profiles.Count - 1) + + If _fadeIn = 1.0F Then + If Controls.Accept(False, True, True) Then + ClickedProfile() + End If + + 'Try to load the GameJolt profile once the player has logged in. + _profiles(0).LoadGameJolt() + End If + + If _profiles(_selectedProfile).Loaded = False Then + _closingDisplay = True + Else + _closingDisplay = False + End If + + _sliderTarget = GetSliderTarget(_selectedProfile) + If _sliderPosition < _sliderTarget Then + _sliderPosition = MathHelper.Lerp(_sliderTarget, _sliderPosition, 0.8F) + ElseIf _sliderPosition > _sliderTarget Then + _sliderPosition = MathHelper.Lerp(_sliderTarget, _sliderPosition, 0.8F) + End If + + If _fadeIn = 1.0F Then + If _closingDisplay Then + If _expandDisplay > 0.0F Then + _expandDisplay = MathHelper.Lerp(0.0F, _expandDisplay, 0.9F) + If _expandDisplay - 0.01F <= 0.0F Then + _expandDisplay = 0.0F + End If + End If + Else + If _expandDisplay < 1.0F Then + _expandDisplay = MathHelper.Lerp(1.0F, _expandDisplay, 0.9F) + If _expandDisplay + 0.01F >= 1.0F Then + _expandDisplay = 1.0F + End If + End If + End If + End If + End If + UpdateScreenOffset() + End If + End Sub + + 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.") + Else + _profiles(_selectedProfile).SelectProfile() + End If + End Sub + + Private Sub UpdateScreenOffset() + If _screenOffset.X > _screenOffsetTarget.X Then + _screenOffset.X = MathHelper.Lerp(_screenOffsetTarget.X, _screenOffset.X, 0.93F) + If _screenOffset.X - 0.01F <= _screenOffsetTarget.X Then + _screenOffset.X = _screenOffsetTarget.X + End If + End If + If _screenOffset.X < _screenOffsetTarget.X Then + _screenOffset.X = MathHelper.Lerp(_screenOffsetTarget.X, _screenOffset.X, 0.93F) + If _screenOffset.X + 0.01F >= _screenOffsetTarget.X Then + _screenOffset.X = _screenOffsetTarget.X + End If + End If + If _screenOffset.Y > _screenOffsetTarget.Y Then + _screenOffset.Y = MathHelper.Lerp(_screenOffsetTarget.Y, _screenOffset.Y, 0.93F) + If _screenOffset.Y - 0.01F <= _screenOffsetTarget.Y Then + _screenOffset.Y = _screenOffsetTarget.Y + End If + End If + If _screenOffset.Y < _screenOffsetTarget.Y Then + _screenOffset.Y = MathHelper.Lerp(_screenOffsetTarget.Y, _screenOffset.Y, 0.93F) + If _screenOffset.Y + 0.01F >= _screenOffsetTarget.Y Then + _screenOffset.Y = _screenOffsetTarget.Y + End If + End If + End Sub + + Public Overrides Sub Draw() + PreScreen.Draw() + + If _loading = False Then + If _selectedProfile = 0 Then + DrawGradients(CInt(255 * _fadeIn), True) + Else + DrawGradients(CInt(255 * _fadeIn), False) + End If + End If + + If IsCurrentScreen() Then + If _loading Then + Dim textSize As Vector2 = FontManager.GameJoltFont.MeasureString("Please wait..") + GetFontRenderer().DrawString(FontManager.GameJoltFont, "Please wait" & LoadingDots.Dots, New Vector2(windowSize.Width / 2.0F - textSize.X / 2.0F, + windowSize.Height / 2.0F - textSize.Y / 2.0F + 100), Color.White) + Else + DrawProfiles() + End If + End If + End Sub + + Private Sub DrawProfiles() + 'Draw profiles: + For x = 0 To _profiles.Count - 1 + Dim xOffset As Single = _screenOffset.X + x * 180 + ((x + 1) * 100 * (1 - _fadeIn)) + + _profiles(x).Draw(New Vector2(xOffset, _screenOffset.Y), CInt(_fadeIn * 255), (x = _selectedProfile), _menuTexture) + Next + + If _fadeIn = 1.0F Then + 'Draw arrow: + SpriteBatch.Draw(_menuTexture, New Rectangle(CInt(_sliderPosition - 16), CInt(_screenOffset.Y + 170), 32, 16), New Rectangle(0, 16, 32, 16), Color.White) + + Dim displayRect = New Rectangle(CInt((_sliderPosition - 300).Clamp(20, windowSize.Width - 620)), CInt(_screenOffset.Y + 170 + 16), 600, CInt(240 * _expandDisplay)) + + 'Draw display: + If _expandDisplay > 0F Then + Canvas.DrawRectangle(displayRect, Screens.UI.ColorProvider.MainColor(False)) + Canvas.DrawRectangle(New Rectangle(displayRect.X, displayRect.Y + displayRect.Height - 3, displayRect.Width, 3), Screens.UI.ColorProvider.AccentColor(False, CInt(255 * _expandDisplay))) + End If + + 'Dark theme: + If (_selectedProfile = 0 Or _selectedProfile = 1) And _sliderPosition <= GetSliderTarget(1) Then + Dim maxDistance As Integer = 180 + Dim distance As Integer = CInt(Math.Abs(_sliderTarget - _sliderPosition)) + Dim dist As Double = distance / maxDistance + + If _selectedProfile = 0 Then + dist = 1 - dist + End If + + SpriteBatch.Draw(_menuTexture, New Rectangle(CInt(_sliderPosition - 16), CInt(_screenOffset.Y + 170), 32, 16), New Rectangle(32, 16, 32, 16), New Color(255, 255, 255, CInt(255 * dist))) + If _expandDisplay > 0F Then + Canvas.DrawRectangle(displayRect, Screens.UI.ColorProvider.MainColor(True, CInt(255 * dist))) + Canvas.DrawRectangle(New Rectangle(displayRect.X, displayRect.Y + displayRect.Height - 3, displayRect.Width, 3), Screens.UI.ColorProvider.AccentColor(True, CInt(255 * dist * _expandDisplay))) + End If + End If + + 'Draw profile info: + Dim tmpProfile = _profiles(_selectedProfile) + + If _expandDisplay = 1.0F Then + If tmpProfile.GameModeExists Then + 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 & + "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 & + "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 & + "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) + GetFontRenderer().DrawString(FontManager.GameJoltFont, "The required GameMode does not exist!", New Vector2(displayRect.X + 70, displayRect.Y + 78), Color.White, 0F, Vector2.Zero, 0.5F, SpriteEffects.None, 0F) + + End If + End If + End If + End Sub + + Private Function GetSliderTarget(ByVal index As Integer) As Integer + Return CInt(_screenOffset.X + index * 180 + 80) + End Function + + Public Overrides Sub ChangeTo() + If _profiles.Count = 0 Then + 'Dim t As New Threading.Thread(AddressOf LoadProfiles) + 't.IsBackground = True + 't.Start() + LoadProfiles() + End If + End Sub + + Private Sub LoadProfiles() + _profiles.Add(New GameProfile("", False)) + + Dim files As String() = {"Apricorns.dat", "Berries.dat", "Box.dat", "Daycare.dat", "HallOfFame.dat", "ItemData.dat", "Items.dat", "NPC.dat", "Options.dat", "Party.dat", "Player.dat", "Pokedex.dat", "Register.dat", "RoamingPokemon.dat", "SecretBase.dat", "Statistics.dat"} + For Each path As String In IO.Directory.GetDirectories(GameController.GamePath & "\Save\") + + Dim exists As Boolean = True + For Each file As String In files + If IO.File.Exists(path & "\" & file) = False Then + exists = False + Exit For + End If + Next + + If exists = True Then + _profiles.Add(New GameProfile(path, False)) + End If + Next + + GameModeManager.SetGameModePointer("Kolben") + + _profiles.Add(New GameProfile("", True)) + + _loading = False + End Sub + + Private Class GameProfile + + Private _isGameJolt As Boolean = False + Private _loaded As Boolean = False + Private _isLoading As Boolean = False + Private _failedGameJoltLoading As Boolean = False + + Private _path As String = "" + Private _isNewGameButton As Boolean = False + + Private _name As String + Private _gameMode As String + Private _pokedexSeen As Integer + Private _pokedexCaught As Integer + Private _badges As Integer + Private _timePlayed As String + Private _location As String + Private _pokemonTextures As New List(Of Texture2D) + Private _sprite As Texture2D + Private _gameModeExists As Boolean + Private _skin As String = "" + + Private _fontSize As Single = 0.75F + Private _spriteIndex As Integer = 0 + Private _spriteDelay As Single = 1.5F + Private _logoBounce As Single = 0F + Private ReadOnly _spriteOrder As Integer() = {0, 1, 0, 2} + + Public ReadOnly Property IsGameJolt As Boolean + Get + Return _isGameJolt + End Get + End Property + + Public ReadOnly Property Path() As String + Get + Return _path + End Get + End Property + + Public ReadOnly Property Name() As String + Get + Return _name + End Get + End Property + + Public ReadOnly Property GameMode() As String + Get + Return _gameMode + End Get + End Property + + Public ReadOnly Property PokedexSeen() As Integer + Get + Return _pokedexSeen + End Get + End Property + + Public ReadOnly Property PokedexCaught() As Integer + Get + Return _pokedexCaught + End Get + End Property + + Public ReadOnly Property Badges() As Integer + Get + Return _badges + End Get + End Property + + Public ReadOnly Property TimePlayed() As String + Get + Return _timePlayed + End Get + End Property + + Public ReadOnly Property Location() As String + Get + Return _location + End Get + End Property + + Public ReadOnly Property PokemonTextures() As List(Of Texture2D) + Get + Return _pokemonTextures + End Get + End Property + + Public ReadOnly Property Loaded() As Boolean + Get + Return _loaded + End Get + End Property + + Public ReadOnly Property IsLoading() As Boolean + Get + Return _isLoading + End Get + End Property + + Public ReadOnly Property GameModeExists() As Boolean + Get + Return _gameModeExists + End Get + End Property + + Public Sub New(ByVal path As String, ByVal isNewGameButton As Boolean) + If isNewGameButton Then + _isNewGameButton = True + _fontSize = 1.0F + Else + If path = "" Then + _isGameJolt = True + _loaded = False + + + _sprite = Content.Load(Of Texture2D)("Textures\UI\GameJolt\gameJoltIcon") + + LoadGameJolt() + Else + _path = path + + LoadFromPlayerData(IO.File.ReadAllText(path & "\Player.dat")) + LoadContent(IO.File.ReadAllText(path & "\Party.dat")) + + _loaded = True + End If + End If + End Sub + + Private Sub LoadContent(ByVal data As String) + If GameModeManager.GameModeExists(_gameMode) Then + _gameModeExists = True + + GameModeManager.SetGameModePointer(_gameMode) + + Dim pokemonData As String() = data.SplitAtNewline() + For Each line As String In pokemonData + If line.StartsWith("{") Then + _pokemonTextures.Add(Pokemon.GetPokemonByData(line).GetMenuTexture(True)) + End If + Next + + If _isGameJolt = False Then + _sprite = TextureManager.GetTexture("Textures\NPC\" & _skin) + End If + Else + _gameModeExists = False + _sprite = Content.Load(Of Texture2D)("SharedResources\Textures\unknownSprite") + End If + End Sub + + Private Sub LoadFromPlayerData(ByVal data As String) + Dim playerData As String() = data.SplitAtNewline() + For Each line As String In playerData + If line.Contains("|") Then + Dim id As String = line.Split("|"c)(0) + Dim content As String = line.Split("|"c)(1) + + Select Case id.ToLower() + Case "name" + _name = content + + While FontManager.GameJoltFont.MeasureString(_name).X * _fontSize > 140 + _fontSize -= 0.01F + End While + Case "badges" + If content.Length > 0 Then + _badges = content.Split(","c).Length + Else + _badges = 0 + End If + Case "playtime" + Dim timedata As String() = content.Split(","c) + + Dim hours As Integer = CInt(timedata(0)) + CInt(timedata(3)) * 24 + Dim minutes As Integer = CInt(timedata(1)) + Dim seconds As Integer = CInt(timedata(2)) + + _timePlayed = hours.ToString("D2") & ":" & minutes.ToString("D2") & ":" & seconds.ToString("D2") + Case "location" + _location = content + Case "gamemode" + _gameMode = content + Case "skin" + _skin = content + End Select + End If + Next + End Sub + + Public Sub Draw(ByVal offset As Vector2, ByVal alpha As Integer, ByVal isSelected As Boolean, ByVal t As Texture2D) + If _isGameJolt Then + For x = 0 To 9 + For y = 0 To 9 + SpriteBatch.Draw(t, New Rectangle(CInt(x * 16 + offset.X), CInt(y * 16 + offset.Y), 16, 16), New Rectangle(32, 0, 16, 16), New Color(255, 255, 255, alpha)) + Next + Next + Canvas.DrawRectangle(New Rectangle(CInt(offset.X), CInt(offset.Y), 160, 3), Screens.UI.ColorProvider.AccentColor(True, alpha)) + + If _isLoading And GameJoltSave.DownloadProgress > 0 Then + Dim width As Integer = CInt((GameJoltSave.DownloadProgress / (GameJolt.GamejoltSave.SAVEFILECOUNT + GameJolt.GamejoltSave.EXTRADATADOWNLOADCOUNT)) * 160) + Canvas.DrawRectangle(New Rectangle(CInt(offset.X), CInt(offset.Y + 3), width, 157), New Color(100, 100, 100, 128)) + End If + Else + For x = 0 To 9 + For y = 0 To 9 + SpriteBatch.Draw(t, New Rectangle(CInt(x * 16 + offset.X), CInt(y * 16 + offset.Y), 16, 16), New Rectangle(0, 0, 16, 16), New Color(255, 255, 255, alpha)) + Next + Next + Canvas.DrawRectangle(New Rectangle(CInt(offset.X), CInt(offset.Y), 160, 3), Screens.UI.ColorProvider.AccentColor(False, alpha)) + End If + + If _isNewGameButton Then + Dim text As String = "NEW" & vbNewLine & "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, + offset.Y + 80 - (FontManager.GameJoltFont.MeasureString(text).Y) / 2), New Color(255, 255, 255, alpha)) + Else + SpriteBatch.DrawString(FontManager.GameJoltFont, text, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(text).X) / 2, + offset.Y + 80 - (FontManager.GameJoltFont.MeasureString(text).Y) / 2), New Color(255, 255, 255, alpha)) + End If + Else + If _loaded Then + Dim frameSize As Size = New Size(CInt(_sprite.Width / 3), CInt(_sprite.Height / 4)) + If isSelected Then + _spriteDelay -= 0.1F + If _spriteDelay <= 0F Then + _spriteDelay = 1.5F + _spriteIndex += 1 + If _spriteIndex = _spriteOrder.Length Then + _spriteIndex = 0 + End If + End If + Else + _spriteIndex = 0 + End If + + SpriteBatch.Draw(_sprite, New Rectangle(CInt(offset.X + 17), CInt(offset.Y - 10), 128, 128), New Rectangle(frameSize.Width * _spriteOrder(_spriteIndex), frameSize.Height * 2, frameSize.Width, frameSize.Height), New Color(255, 255, 255, alpha)) + + If alpha >= 250 And CurrentScreen.Identification = Identifications.MainMenuScreen Then + FontRenderer.DrawString(FontManager.GameJoltFont, _name, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(_name).X * _fontSize) / 2, offset.Y + 120), New Color(255, 255, 255, alpha), 0F, Vector2.Zero, New Vector2(_fontSize), SpriteEffects.None, 0F) + Else + SpriteBatch.DrawString(FontManager.GameJoltFont, _name, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(_name).X * _fontSize) / 2, offset.Y + 120), New Color(255, 255, 255, alpha), 0F, Vector2.Zero, New Vector2(_fontSize), SpriteEffects.None, 0F) + End If + Else + If isSelected Then + _logoBounce += 0.2F + Else + _logoBounce = 0F + End If + + Dim text As String = "Log in" + If _isLoading Then + text = "Loading..." + End If + + SpriteBatch.Draw(_sprite, New Rectangle(CInt(offset.X + 46), CInt(offset.Y + 36 + Math.Sin(_logoBounce) * 8.0F), 68, 72), New Color(255, 255, 255, alpha)) + + If alpha >= 250 And CurrentScreen.Identification = Identifications.MainMenuScreen Then + FontRenderer.DrawString(FontManager.GameJoltFont, text, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(text).X * _fontSize) / 2, offset.Y + 120), New Color(255, 255, 255, alpha), 0F, Vector2.Zero, New Vector2(_fontSize), SpriteEffects.None, 0F) + Else + SpriteBatch.DrawString(FontManager.GameJoltFont, text, New Vector2(offset.X + 80 - (FontManager.GameJoltFont.MeasureString(text).X * _fontSize) / 2, offset.Y + 120), New Color(255, 255, 255, alpha), 0F, Vector2.Zero, New Vector2(_fontSize), SpriteEffects.None, 0F) + End If + End If + End If + End Sub + + Public Sub LoadGameJolt() + If GameJolt.API.LoggedIn Then + If _isGameJolt And _loaded = False And _isLoading = False Then + _isLoading = True + + GameJoltSave.DownloadSave(GameJolt.API.gameJoltId, True) + ElseIf _isGameJolt And _loaded = False And _isLoading Then + If GameJoltSave.DownloadFinished Then + _loaded = True + _isLoading = False + + _sprite = GameJoltSave.DownloadedSprite + If _sprite Is Nothing Then + _sprite = GameJolt.Emblem.GetPlayerSprite(GameJolt.Emblem.GetPlayerLevel(GameJoltSave.Points), GameJoltSave.GameJoltID, GameJoltSave.Gender) + End If + + LoadFromPlayerData(GameJoltSave.Player) + LoadContent(GameJoltSave.Party) + Else + If GameJoltSave.DownloadFailed Then + _loaded = True + _isLoading = False + _failedGameJoltLoading = True + + _sprite = Content.Load(Of Texture2D)("SharedResources\Textures\unknownSprite") + End If + End If + End If + End If + End Sub + + Public Sub SelectProfile() + If _isNewGameButton Then + If GameModeManager.GameModeCount = 1 Then + 'There's only the default GameMode available, so just load that one: + GameModeManager.SetGameModePointer("Kolben") + SetScreen(New Screens.MainMenu.NewNewGameScreen(CurrentScreen)) + Else + 'There is more than one GameMode, prompt a selection screen: + SetScreen(New GameModeSelectionScreen(CurrentScreen)) + End If + Else + If _isGameJolt And _loaded = False And GameJolt.API.LoggedIn = False Then + SetScreen(New GameJolt.LogInScreen(CurrentScreen)) + Else + If _gameModeExists Then + GameModeManager.SetGameModePointer(_gameMode) + + If _isGameJolt Then + Core.Player.IsGameJoltSave = True + Core.Player.LoadGame("GAMEJOLTSAVE") + + SetScreen(New JoinServerScreen(CurrentScreen)) + Else + Core.Player.IsGameJoltSave = False + Core.Player.LoadGame(IO.Path.GetFileName(_path)) + + SetScreen(New JoinServerScreen(CurrentScreen)) + End If + 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.") + End If + End If + End If + End Sub + + End Class + +End Class + +Public Class GameModeSelectionScreen + + Inherits Screen + + Private _gameModes As GameMode() + Private _index As Integer = 0 + Private _offset As Single = 0F + + Private Const WIDTH = 400 + Private Const HEIGHT = 64 + Private Const GAP = 32 + + Public Sub New(ByVal currentScreen As Screen) + Me.Identification = Identifications.GameModeSelectionScreen + CanBePaused = True + CanChat = False + CanDrawDebug = True + CanGoFullscreen = True + CanMuteMusic = True + CanTakeScreenshot = True + + PreScreen = currentScreen + + _gameModes = GameModeManager.GetAllGameModes + End Sub + + Public Overrides Sub Draw() + PreScreen.Draw() + + Dim text = "Select a GameMode" + vbNewLine + "to start the new game with" + + GetFontRenderer().DrawString(FontManager.GameJoltFont, text, New Vector2(30, 30), Color.White) + + Dim center = windowSize.Width - 250 + For i = 0 To _gameModes.Length - 1 + Dim y = CType(i * (HEIGHT + GAP) + _offset + windowSize.Height / 2 - HEIGHT / 2, Integer) + Dim color = Screens.UI.ColorProvider.LightColor + Dim alphaColor = New Color(color.R, color.G, color.B, 0) + Dim halfWidth = CType(WIDTH / 2, Integer) + + Canvas.DrawGradient(New Rectangle(center - halfWidth, y, 50, HEIGHT), alphaColor, color, True, -1) + Canvas.DrawGradient(New Rectangle(center + halfWidth - 50, y, 50, HEIGHT), color, alphaColor, True, -1) + Canvas.DrawRectangle(New Rectangle(center - halfWidth + 50, y, WIDTH - 100, HEIGHT), color) + + Dim displayText = _gameModes(i).Name + Dim textSize = FontManager.GameJoltFont.MeasureString(displayText) + + GetFontRenderer().DrawString(FontManager.GameJoltFont, displayText, New Vector2(center - halfWidth + 50, CType(y + HEIGHT / 2 - ((textSize.Y * 0.75F) / 2), Integer)), Color.White, 0F, Vector2.Zero, 0.75F, SpriteEffects.None, 0F) + Next + End Sub + + Public Overrides Sub Update() + ' PreScreen is the MainMenuScreen, so update the pre screen of that to achieve the background world: + PreScreen.PreScreen.Update() + + If _index > 0 AndAlso Controls.Up(True, True, True, True, True, True) Then + _index -= 1 + End If + If _index < _gameModes.Length - 1 AndAlso Controls.Down(True, True, True, True, True, True) Then + _index += 1 + End If + If Controls.Dismiss(True, True, True) Then + SetScreen(PreScreen) + End If + If Controls.Accept(True, True, True) Then + GameModeManager.SetGameModePointer(_gameModes(_index).DirectoryName) + SetScreen(New Screens.MainMenu.NewNewGameScreen(PreScreen)) + End If + + Dim targetOffset = GetTargetOffset() + + If _offset <> targetOffset Then + _offset = MathHelper.Lerp(_offset, targetOffset, 0.25F) + If Math.Abs(_offset - targetOffset) <= 0.01F Then + _offset = targetOffset + End If + End If + End Sub + + Private Function GetTargetOffset() As Integer + Return -_index * (HEIGHT + GAP) + End Function + +End Class \ No newline at end of file diff --git a/2.5DHero/2.5DHero/Screens/MainMenu/SplashScreen.vb b/2.5DHero/2.5DHero/Screens/MainMenu/SplashScreen.vb index d46d88f83..8b92b5e4f 100644 --- a/2.5DHero/2.5DHero/Screens/MainMenu/SplashScreen.vb +++ b/2.5DHero/2.5DHero/Screens/MainMenu/SplashScreen.vb @@ -61,7 +61,7 @@ Friend Class SplashScreen If MapPreviewScreen.MapViewMode = True Then Core.SetScreen(New MapPreviewScreen()) Else - Core.SetScreen(New MainMenuScreen()) + Core.SetScreen(New PressStartScreen()) End If ' Core.SetScreen(New TransitionScreen(Me, New IntroScreen(), Color.Black, False)) End If diff --git a/2.5DHero/2.5DHero/Scripts/newgame/intro.dat b/2.5DHero/2.5DHero/Scripts/newgame/intro.dat new file mode 100644 index 000000000..840b823bc --- /dev/null +++ b/2.5DHero/2.5DHero/Scripts/newgame/intro.dat @@ -0,0 +1,191 @@ +Version=2 + +@camera.set(6,3,7,0,0-0.3) +@camera.update +@level.update + +@music.play(system\gameintro) +@screen.fadein + +=0 +:when:<100 + @level.wait(1) + @camera.update + +=1 +:endwhen + +:when:<9 + @npc.warp(1,~+0.03,~,~) + @npc.warp(5,~+0.03,~,~) + @npc.warp(6,~+0.03,~,~) + @camera.sety(~+0.02) + @camera.update +:endwhen +:when:<15 + @npc.warp(1,~+0.03,~,~) + @npc.warp(5,~+0.03,~,~) + @npc.warp(6,~+0.03,~,~) + @camera.sety(~+0.02) + @camera.setpitch(~-0.0011) + @camera.update +:endwhen + +@npc.setspeed(2,0.7) +@npc.move(2,12) + +=0 +:when:<255 + @camera.setx(~-0.01) + @camera.setz(~-0.01) + @camera.sety(~-0.004) + @camera.setpitch(~-0.0012) + @camera.update + +=1 + @screen.setfade() +:endwhen + +@camera.set(40,1.1,11,0,0) +@camera.update +@level.update + +@screen.fadein(15) + +@npc.turn(3,1) +@camera.update +@level.wait(5) + +@npc.turn(3,2) +@camera.update +@level.wait(5) + +@npc.turn(3,3) +@camera.update +@level.wait(5) + +@npc.turn(3,0) +@camera.update +@level.wait(5) + +@npc.turn(3,2) +@camera.update +@level.wait(5) + +@npc.move(4,3) + +=0 +:when:<50 + @level.wait(1) + @camera.update + +=1 +:endwhen + +@npc.setspeed(4,2) +@npc.move(4,1) + +@sound.play(destroy) + +:when:>35 + @npc.warp(3,~-0.05,~,~) + @camera.update +:endwhen + +@screen.fadeout(2) +@music.stop + +@level.load(newgame\intro.dat) + +@camera.set(9,0.5,9,0,0-0.1) +@camera.update + +@screen.fadein + +@music.play(route\1) +@npc.move(0,4) +@npc.turn(0,2) + +@text.show(Hello, sorry to~keep you waiting!*Welcome to the~world of Pokémon!*My name is Oak.~People call me~Pokémon Professor.*This world is inhabited~by creatures that~we call...) +@screen.fadeout(20) +@camera.set(20,3,4,3.36,-0.59) +@camera.update +@level.update +@screen.fadein(20) +@text.show(...Pokémon.*People and Pokémon~live together by supporting~each other.) + +@screen.fadeout(20) +@camera.set(35,1,14,6.16,0-0.187) +@camera.update +@level.update +@screen.fadein(20) + +@text.show(Some people play~with Pokémon, some battle~with them.*But we don't know~everything about~Pokémon yet.) + +@screen.fadeout(20) +@camera.set(9,0.5,9,0,0-0.1) +@camera.update +@level.update +@screen.fadein(20) +@text.show(There are still~many mysteries to solve.*That's why I study~Pokémon every day.) +@text.show(But let's get~back to you.) + +@screen.skinselection(Ethan,Lyra,Hilbert,Hilda,Nate,Rosa,Leaf) + +@player.wearskin() +@npc.wearskin(1,) + +:when:<11.5 + @camera.setz(~+0.05) + @camera.sety(~+0.02) + @camera.setpitch(~-0.006) + @camera.update +:endwhen + +@text.show(Now, what did you say~your name was?) +@screen.input(,name,,14) +@player.setname() + +@text.show(Alright, nice to meet you,~!) + +@screen.fadeout(20) +@camera.set(26,1.1,36,5.93,0-0.276) +@camera.update +@level.update +@screen.fadein(20) + +@npc.move(4,3) +@level.wait(50) +@npc.turn(4,1) +@npc.move(4,4) +@npc.turn(3,3) +@npc.move(3,2) +@npc.turn(3,0) +@npc.move(3,2) +@sound.play(enter) + +@text.show(This is your home~in New Bark Town,~you live there~with your mother~right next to Professor Elm.) + +@screen.fadeout(20) +@camera.set(9,1.5,11.5,0,0-0.4) +@camera.update +@level.update +@screen.fadein(20) + +@text.show(,~are you ready?*Your very own Pokémon~story is about to unfold.*You'll face fun times~and tough challenges.*A world of dreams and~adventures with Pokémon~awaits!*Let's go!~I'll be seeing you later!) + +=0 + +:when:<255 + @camera.setz(~+0.01) + @camera.sety(~+0.004) + @camera.setpitch(~-0.0012) + @camera.update + +=1 + @screen.setfade() +:endwhen + +@player.setot() +@player.addmoney(3000) +@rival.setname(???) + +@system.endnewgame(johto\newbark\yourroom.dat,1,0.1,3,1) + +:end \ No newline at end of file diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommander.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommander.vb index fd3e1ef96..725883ff9 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommander.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommander.vb @@ -135,6 +135,8 @@ Namespace ScriptVersion2 DoRadio(subClass) Case "help" DoHelp(subClass) + Case "system" + DoSystem(subClass) Case "title" DoTitle(subClass) Case Else diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoCamera.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoCamera.vb index 24f787c6c..0aaa35ef4 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoCamera.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoCamera.vb @@ -13,19 +13,26 @@ Dim c As OverworldCamera = CType(Screen.Camera, OverworldCamera) Dim doCameraUpdate As Boolean = True + Dim position As Vector3 + If Core.CurrentScreen.Identification = Screen.Identifications.NewGameScreen Then + position = c.Position + Else + position = c.ThirdPersonOffset + End If + Select Case command.ToLower() Case "set" - Dim x As Single = sng(argument.GetSplit(0).Replace("~", CStr(c.ThirdPersonOffset.X)).Replace(".", GameController.DecSeparator)) - Dim y As Single = sng(argument.GetSplit(1).Replace("~", CStr(c.ThirdPersonOffset.Y)).Replace(".", GameController.DecSeparator)) - Dim z As Single = sng(argument.GetSplit(2).Replace("~", CStr(c.ThirdPersonOffset.Z)).Replace(".", GameController.DecSeparator)) + Dim x As Single = sng(argument.GetSplit(0).Replace("~", CStr(position.X)).Replace(".", GameController.DecSeparator)) + Dim y As Single = sng(argument.GetSplit(1).Replace("~", CStr(position.Y)).Replace(".", GameController.DecSeparator)) + Dim z As Single = sng(argument.GetSplit(2).Replace("~", CStr(position.Z)).Replace(".", GameController.DecSeparator)) Dim yaw As Single = sng(argument.GetSplit(3).Replace(".", GameController.DecSeparator)) Dim pitch As Single = sng(argument.GetSplit(4).Replace(".", GameController.DecSeparator)) - c.ThirdPersonOffset = New Vector3(x, y, z) + position = New Vector3(x, y, z) c.Yaw = yaw c.Pitch = pitch Case "reset" - c.ThirdPersonOffset = New Vector3(0.0F, 0.3F, 1.5F) + position = New Vector3(0.0F, 0.3F, 1.5F) If argument <> "" Then doCameraUpdate = CBool(argument) End If @@ -34,27 +41,27 @@ c.Yaw = yaw Case "setpitch" - Dim pitch As Single = sng(argument.Replace(",", ".").Replace(".", GameController.DecSeparator)) + Dim pitch As Single = sng(argument.Replace("~", CStr(c.Pitch)).Replace(",", ".").Replace(".", GameController.DecSeparator)) c.Pitch = pitch Case "setposition" - Dim x As Single = sng(argument.GetSplit(0).Replace("~", CStr(c.ThirdPersonOffset.X)).Replace(".", GameController.DecSeparator)) - Dim y As Single = sng(argument.GetSplit(1).Replace("~", CStr(c.ThirdPersonOffset.Y)).Replace(".", GameController.DecSeparator)) - Dim z As Single = sng(argument.GetSplit(2).Replace("~", CStr(c.ThirdPersonOffset.Z)).Replace(".", GameController.DecSeparator)) + Dim x As Single = sng(argument.GetSplit(0).Replace("~", CStr(position.X)).Replace(".", GameController.DecSeparator)) + Dim y As Single = sng(argument.GetSplit(1).Replace("~", CStr(position.Y)).Replace(".", GameController.DecSeparator)) + Dim z As Single = sng(argument.GetSplit(2).Replace("~", CStr(position.Z)).Replace(".", GameController.DecSeparator)) - c.ThirdPersonOffset = New Vector3(x, y, z) + position = New Vector3(x, y, z) Case "setx" - Dim x As Single = sng(argument.Replace("~", CStr(c.ThirdPersonOffset.X)).Replace(".", GameController.DecSeparator)) + Dim x As Single = sng(argument.Replace("~", CStr(position.X)).Replace(".", GameController.DecSeparator)) - c.ThirdPersonOffset.X = x + position.X = x Case "sety" - Dim y As Single = sng(argument.Replace("~", CStr(c.ThirdPersonOffset.Y)).Replace(".", GameController.DecSeparator)) + Dim y As Single = sng(argument.Replace("~", CStr(position.Y)).Replace(".", GameController.DecSeparator)) - c.ThirdPersonOffset.Y = y + position.Y = y Case "setz" - Dim z As Single = sng(argument.Replace("~", CStr(c.ThirdPersonOffset.Z)).Replace(".", GameController.DecSeparator)) + Dim z As Single = sng(argument.Replace("~", CStr(position.Z)).Replace(".", GameController.DecSeparator)) - c.ThirdPersonOffset.Z = z + position.Z = z Case "togglethirdperson" If Core.CurrentScreen.Identification = Screen.Identifications.OverworldScreen Then c.SetThirdPerson(Not c.ThirdPerson, False) @@ -132,6 +139,13 @@ c.Yaw = facing * MathHelper.PiOver2 End Select + + If Core.CurrentScreen.Identification = Screen.Identifications.NewGameScreen Then + c.Position = position + Else + c.ThirdPersonOffset = position + End If + c.UpdateThirdPersonCamera() If doCameraUpdate = True Then c.UpdateFrustum() diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoLevel.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoLevel.vb index 0f7b6b94e..f13920105 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoLevel.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoLevel.vb @@ -55,6 +55,10 @@ If doWait = False Then IsReady = True End If + Case "load" + Screen.Level = New Level() + Screen.Level.Load(argument) + IsReady = True Case "reload" Screen.Level.WarpData.WarpDestination = Screen.Level.LevelFile Screen.Level.WarpData.WarpPosition = Screen.Camera.Position diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoPlayer.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoPlayer.vb index 4e8d3ca24..0355c5012 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoPlayer.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoPlayer.vb @@ -237,6 +237,9 @@ Case "save" Core.Player.SaveGame(False) + IsReady = True + Case "setname" + Core.Player.Name = argument IsReady = True Case "setrivalname" Core.Player.RivalName = argument diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoScreen.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoScreen.vb index 1118d6342..ed59b9ac0 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoScreen.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoScreen.vb @@ -222,6 +222,13 @@ IsReady = True CanContinue = False + Case "skinselection" + Dim skins = argument.Split(","c) + If Screens.MainMenu.NewNewGameScreen.CharacterSelectionScreen.SelectedSkin <> "" Then + IsReady = True + Else + SetScreen(New Screens.MainMenu.NewNewGameScreen.CharacterSelectionScreen(CurrentScreen, skins)) + End If Case Else IsReady = True End Select diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoSystem.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoSystem.vb new file mode 100644 index 000000000..cbc77f254 --- /dev/null +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptCommands/DoSystem.vb @@ -0,0 +1,25 @@ +Namespace ScriptVersion2 + + Partial Class ScriptCommander + + ' -------------------------------------------------------------------------------------------------------------------------- + ' Contains the @system commands. + ' -------------------------------------------------------------------------------------------------------------------------- + + Private Shared Sub DoSystem(ByVal subClass As String) + Dim command As String = ScriptComparer.GetSubClassArgumentPair(subClass).Command + Dim argument As String = ScriptComparer.GetSubClassArgumentPair(subClass).Argument + + Select Case command.ToLower() + Case "endnewgame" + Dim args As String() = argument.Split(","c) + Screens.MainMenu.NewNewGameScreen.EndNewGame(args(0), sng(args(1)), sng(args(2)), sng(args(3)), int(args(4))) + IsReady = True + Case Else + IsReady = True + End Select + End Sub + + End Class + +End Namespace \ No newline at end of file diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptComparer.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptComparer.vb index 2493293c4..860dacc06 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptComparer.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptComparer.vb @@ -304,6 +304,8 @@ Namespace ScriptVersion2 Return DoCamera(subClass) Case "filesystem" Return DoFileSystem(subClass) + Case "screen" + Return DoScreen(subClass) End Select Return DefaultNull End Function diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoCamera.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoCamera.vb index 88a1e14ef..cf1d82649 100644 --- a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoCamera.vb +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoCamera.vb @@ -12,15 +12,21 @@ Dim c As OverworldCamera = CType(Screen.Camera, OverworldCamera) + Dim position As Vector3 + If Core.CurrentScreen.Identification = Screen.Identifications.NewGameScreen Then + position = c.Position + Else + position = c.ThirdPersonOffset + End If Select Case command.ToLower() Case "isfixed" Return ReturnBoolean(c.Fixed) Case "x" - Return c.ThirdPersonOffset.X.ToString().ReplaceDecSeparator() + Return position.X.ToString().ReplaceDecSeparator() Case "y" - Return c.ThirdPersonOffset.Y.ToString().ReplaceDecSeparator() + Return position.Y.ToString().ReplaceDecSeparator() Case "z" - Return c.ThirdPersonOffset.Z.ToString().ReplaceDecSeparator() + Return position.Z.ToString().ReplaceDecSeparator() Case "yaw" Return c.Yaw.ToString().ReplaceDecSeparator() Case "pitch" diff --git a/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoScreen.vb b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoScreen.vb new file mode 100644 index 000000000..449b13645 --- /dev/null +++ b/2.5DHero/2.5DHero/World/ActionScript/V2/ScriptConstructs/DoScreen.vb @@ -0,0 +1,23 @@ +Namespace ScriptVersion2 + + Partial Class ScriptComparer + + ' -------------------------------------------------------------------------------------------------------------------------- + ' Contains the constructs. + ' -------------------------------------------------------------------------------------------------------------------------- + + Private Shared Function DoScreen(ByVal subClass As String) As Object + Dim command As String = GetSubClassArgumentPair(subClass).Command + Dim argument As String = GetSubClassArgumentPair(subClass).Argument + + Select Case command.ToLower() + Case "selectedskin" + Return Screens.MainMenu.NewNewGameScreen.CharacterSelectionScreen.SelectedSkin + End Select + + Return DefaultNull + End Function + + End Class + +End Namespace \ No newline at end of file diff --git a/2.5DHero/2.5DHero/maps/newgame/intro.dat b/2.5DHero/2.5DHero/maps/newgame/intro.dat new file mode 100644 index 000000000..a7ebf0ebd --- /dev/null +++ b/2.5DHero/2.5DHero/maps/newgame/intro.dat @@ -0,0 +1,94 @@ +{"Level"{LEV[{"Name"{str[Intro Map]}}{"MusicLoop"{str[RouteMusic1]}}]}} +{"Actions"{LEV[{"CanTeleport"{bool[1]}}{"CanDig"{bool[1]}}{"CanFly"{bool[1]}}{"EnviromentType"{int[1]}}{"Weather"{int[1]}}{"Lightning"{int[1]}}]}} + +{"Floor"{ENT[{"Size"{intArr[50,40]}}{"Position"{intArr[0,0,0]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,0,16,16]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[50,10,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[0,0,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +9,9=starting position + +Oak: +{"NPC"{NPC[{"Position"{sngArr[13,0,5]}}{"TextureID"{str[oak]}}{"ID"{int[0]}}{"Name"{str[Oak]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Player: +{"NPC"{NPC[{"Position"{sngArr[9,0,9]}}{"TextureID"{str[0]}}{"ID"{int[1]}}{"Name"{str[PLAYER]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +First route scene: +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[6,6]}}{"Position"{intArr[20,0,6]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[2,1]}}{"Position"{intArr[26,0,8]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,1]}}{"Position"{intArr[26,0,9]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,2]}}{"Position"{intArr[19,0,10]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,1]}}{"Position"{intArr[23,0,12]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[2,2]}}{"Position"{intArr[22,0,8]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[112,16,16,16]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[1,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[22,0.3,12]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[24,0.3,7]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[25,0.3,11]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,2]}}{"EntityID"{str[HeadbuttTree]}}{"Position"{sngArr[19,-0.2,11]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[16,32,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,3]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[21,0,5]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[80,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[21,0,10]}}{"TextureID"{str[[POKEMON|N]44]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[1]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} +{"NPC"{NPC[{"Position"{sngArr[22,0,8]}}{"TextureID"{str[[POKEMON|N]13]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[2]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} +{"NPC"{NPC[{"Position"{sngArr[23,0,9]}}{"TextureID"{str[[POKEMON|N]25]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[0]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} + +Second scene: +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[14,8]}}{"Position"{intArr[30,0,4]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[10,2]}}{"Position"{intArr[32,0,8]}}{"TexturePath"{str[Park]}}{"Texture"{rec[0,0,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[2,3]}}{"Position"{intArr[32,0,5]}}{"TexturePath"{str[Park]}}{"Texture"{rec[0,0,16,16]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[3,3]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1.1,1.1,1.1]}}{"Position"{sngArr[37,-0.1,4]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[32,0,32,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,6]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1.1,1.1,1.1]}}{"Position"{sngArr[30,-0.1,4]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[32,0,32,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[4,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[40,0,5]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[3,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[41,0,6]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[2,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[42,0,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[10,1]}}{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.5,1]}}{"Position"{sngArr[31,-0.25,10.7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,16,16,8]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[10,1]}}{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.2]}}{"Position"{sngArr[31,-0.4,11]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[0,24,16,6]]}}{"TextureIndex"{intArr[0,0,0,0,0,0,0,0,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[2,0.4,1]}}{"Position"{sngArr[35.5,-0.1,6.725]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,32,32,8]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.55]}}{"Position"{sngArr[35,-0.4,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[48,49,9,3][16,49,16,3][32,49,16,3][16,40,16,9][57,49,1,1]]}}{"TextureIndex"{intArr[1,1,4,4,0,0,2,2,3,3]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.55]}}{"Position"{sngArr[36,-0.4,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[48,49,9,3][16,49,16,3][32,49,16,3][32,40,16,9][57,49,1,1]]}}{"TextureIndex"{intArr[1,1,4,4,0,0,2,2,3,3]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"Entity"{ENT[{"Scale"{sngArr[0.3,0.4,0.3]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[34,-0.3,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,69,8,11][16,61,8,8]]}}{"TextureIndex"{intArr[0,0,0,0,0,0,0,0,1,1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[39,0,9]}}{"TextureID"{str[1]}}{"ID"{int[2]}}{"Name"{str[Lady2]}}{"Action"{int[0]}}{"AdditionalValue"{str[This is Mail I got~from my daughter.~It cheers me up.]}}{"Rotation"{int[3]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[35,0,8]}}{"TextureID"{str[[POKEMON|N]53]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[2]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[36,0,8]}}{"TextureID"{str[15]}}{"ID"{int[2]}}{"Name"{str[Lady1]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\quick_claw]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[33,0,5]}}{"TextureID"{str[18]}}{"ID"{int[2]}}{"Name"{str[Guy2]}}{"Action"{int[0]}}{"AdditionalValue"{str[I'm printing out~my Pokédex.*You can also print~out stuff like*Mail and your PC~Boxes.]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[34,0,5]}}{"TextureID"{str[[POKEMON|N]137]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[40,0,6]}}{"TextureID"{str[[POKEMON|N]167]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[2]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} + + + +{"EntityField"{ENT[{"Size"{intArr[50,10,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[0,0,24]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Floor"{ENT[{"Size"{intArr[6,2]}}{"Position"{intArr[25,0,32]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[112,16,16,16]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[4,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[24,0.3,28]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Your House: +{"EntityField"{ENT[{"Size"{intArr[4,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} +{"EntityField"{ENT[{"Size"{intArr[2,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[4,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} +{"EntityField"{ENT[{"Size"{intArr[2,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"Entity"{ENT[{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[48,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[32,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Entity"{ENT[{"EntityID"{str[WarpBlock]}}{"Position"{sngArr[29,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[johto\newbark\yourhouse.dat,7,0.1,7,0]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[4,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[80,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,-1,-1,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[27,0,33]}}{"TextureID"{str[3]}}{"ID"{int[3]}}{"Name"{str[Mom]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\newbark\mom]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[23,0,33]}}{"TextureID"{str[63]}}{"ID"{int[4]}}{"Name"{str[GateKeeper2]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} diff --git a/2.5DHero/2.5DHero/maps/newgame/intro0.dat b/2.5DHero/2.5DHero/maps/newgame/intro0.dat new file mode 100644 index 000000000..926994e09 --- /dev/null +++ b/2.5DHero/2.5DHero/maps/newgame/intro0.dat @@ -0,0 +1,51 @@ +{"Level"{LEV[{"Name"{str[Intro Map]}}{"MusicLoop"{str[RouteMusic1]}}]}} +{"Actions"{LEV[{"CanTeleport"{bool[1]}}{"CanDig"{bool[1]}}{"CanFly"{bool[1]}}{"EnviromentType"{int[1]}}{"Weather"{int[1]}}{"Lightning"{int[1]}}]}} + +Underwater: +{"Floor"{ENT[{"Size"{intArr[20,6]}}{"Position"{intArr[-2,0,0]}}{"TexturePath"{str[intro]}}{"Texture"{rec[16,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[2,0,1]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[4,0,2]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[7,0,1]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[11,0,2]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,0,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,64,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,1,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,48,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,2,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,32,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,3,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,16,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,4,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[3,3]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[9,0.3,1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[16,0,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[3,0.3,2]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[16,0,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Position"{sngArr[5,0,1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Position"{sngArr[2,0,3]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Shellder: +{"NPC"{NPC[{"Position"{sngArr[8,0,2]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[5,2,1]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[4,1,3]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Magikarp: +{"NPC"{NPC[{"Position"{sngArr[0,7,2]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[1]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[-3,8,1]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[5]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[-4,8,3]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[6]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[26,17]}}{"EntityID"{str[Water]}}{"Position"{sngArr[-6,12,-9]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[0,16,16,16][144,16,16,16]]}}{"TextureIndex"{intArr[0,0,1,1]}}{"Collision"{bool[0]}}{"ModelID"{int[0]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} + +Lapras: +{"NPC"{NPC[{"Position"{sngArr[12,12.2,2]}}{"TextureID"{str[[POKEMON|N]131]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Overworld: +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[35.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[39.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[43.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[47.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[20,8]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,0,0]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,112,16,16][48,96,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,1,1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Jigglypuff: +{"NPC"{NPC[{"Position"{sngArr[40,1,7]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]39]}}{"ID"{int[3]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Pikachu: +{"NPC"{NPC[{"Position"{sngArr[45,1,7]}}{"TextureID"{str[[POKEMON|N]25]}}{"ID"{int[4]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} diff --git a/2.5DHero/2.5DHeroContent/Content/Content.mgcb b/2.5DHero/2.5DHeroContent/Content/Content.mgcb index 47a3e69e8..f07bc501a 100644 --- a/2.5DHero/2.5DHeroContent/Content/Content.mgcb +++ b/2.5DHero/2.5DHeroContent/Content/Content.mgcb @@ -46282,3 +46282,156 @@ /processorParam:TextureFormat=Color /build:Textures/UI/TrainerCard/Papers.png +#begin Fonts/BMP/GameJolt.xnb +/copy:Fonts/BMP/GameJolt.xnb + +#begin GUI/Logos/logo_shine.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:GUI/Logos/logo_shine.png + +#begin Textures/UI/GameJolt/Loading/0.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/Loading/0.png + +#begin Textures/UI/GameJolt/Loading/1.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/Loading/1.png + +#begin Textures/UI/GameJolt/Loading/2.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/Loading/2.png + +#begin Textures/UI/GameJolt/Loading/3.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/Loading/3.png + +#begin Textures/UI/GameJolt/gameJoltIcon.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/gameJoltIcon.png + +#begin Textures/UI/GameJolt/login.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/login.png + +#begin Textures/UI/GameJolt/logo.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/logo.png + +#begin Textures/UI/GameJolt/question.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/question.png + +#begin Textures/UI/GameJolt/x.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/UI/GameJolt/x.png + +#begin GUI/Menus/MainMenu.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:GUI/Menus/MainMenu.png + +#begin Textures/intro.png +/importer:TextureImporter +/processor:TextureProcessor +/processorParam:ColorKeyColor=255,0,255,255 +/processorParam:ColorKeyEnabled=True +/processorParam:GenerateMipmaps=False +/processorParam:PremultiplyAlpha=True +/processorParam:ResizeToPowerOfTwo=False +/processorParam:MakeSquare=False +/processorParam:TextureFormat=Color +/build:Textures/intro.png + +#begin Songs/gameintro.ogg +/importer:OggImporter +/processor:SongProcessor +/processorParam:Quality=Best +/build:Songs/gameintro.ogg + diff --git a/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.png b/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.png new file mode 100644 index 000000000..e4f7e8c88 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.xnb b/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.xnb new file mode 100644 index 000000000..ac4f0f6e0 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Fonts/BMP/GameJolt.xnb differ diff --git a/2.5DHero/2.5DHeroContent/Content/GUI/Logos/Pokemon_Small.png b/2.5DHero/2.5DHeroContent/Content/GUI/Logos/Pokemon_Small.png index 41a7a83d7..1cc09c7c2 100644 Binary files a/2.5DHero/2.5DHeroContent/Content/GUI/Logos/Pokemon_Small.png and b/2.5DHero/2.5DHeroContent/Content/GUI/Logos/Pokemon_Small.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/GUI/Logos/logo_shine.png b/2.5DHero/2.5DHeroContent/Content/GUI/Logos/logo_shine.png new file mode 100644 index 000000000..bd564f7ae Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/GUI/Logos/logo_shine.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/GUI/Menus/MainMenu.png b/2.5DHero/2.5DHeroContent/Content/GUI/Menus/MainMenu.png new file mode 100644 index 000000000..a51ece621 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/GUI/Menus/MainMenu.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Songs/gameintro.ogg b/2.5DHero/2.5DHeroContent/Content/Songs/gameintro.ogg new file mode 100644 index 000000000..6943a6606 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Songs/gameintro.ogg differ diff --git a/2.5DHero/2.5DHeroContent/Content/Songs/violet.ogg b/2.5DHero/2.5DHeroContent/Content/Songs/violet.ogg index 703d09e29..d4677b42a 100644 Binary files a/2.5DHero/2.5DHeroContent/Content/Songs/violet.ogg and b/2.5DHero/2.5DHeroContent/Content/Songs/violet.ogg differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/0.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/0.png new file mode 100644 index 000000000..2a27c75c4 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/0.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/1.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/1.png new file mode 100644 index 000000000..14adabfcb Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/1.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/2.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/2.png new file mode 100644 index 000000000..824cfeb1b Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/2.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/3.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/3.png new file mode 100644 index 000000000..7f18f3b90 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/Loading/3.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/gameJoltIcon.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/gameJoltIcon.png new file mode 100644 index 000000000..a5b799fc0 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/gameJoltIcon.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/login.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/login.png new file mode 100644 index 000000000..c1adc40c4 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/login.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/logo.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/logo.png new file mode 100644 index 000000000..244a1e58d Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/logo.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/question.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/question.png new file mode 100644 index 000000000..4cfd56a31 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/question.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/x.png b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/x.png new file mode 100644 index 000000000..dfc561d15 Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/UI/GameJolt/x.png differ diff --git a/2.5DHero/2.5DHeroContent/Content/Textures/intro.png b/2.5DHero/2.5DHeroContent/Content/Textures/intro.png new file mode 100644 index 000000000..f2254d90f Binary files /dev/null and b/2.5DHero/2.5DHeroContent/Content/Textures/intro.png differ diff --git a/2.5DHero/2.5DHeroContent/Scripts/newgame/intro.dat b/2.5DHero/2.5DHeroContent/Scripts/newgame/intro.dat new file mode 100644 index 000000000..997bad2bb --- /dev/null +++ b/2.5DHero/2.5DHeroContent/Scripts/newgame/intro.dat @@ -0,0 +1,191 @@ +Version=2 + +@camera.set(6,3,7,0,0-0.3) +@camera.update +@level.update + +@music.play(gameintro) +@screen.fadein + +@storage.set(integer,levelWait,0) +:while:<100 + @level.wait(1) + @camera.update + @storage.set(integer,levelWait,+1) +:endwhile + +:while:<9 + @npc.warp(1,~+0.03,~,~) + @npc.warp(5,~+0.03,~,~) + @npc.warp(6,~+0.03,~,~) + @camera.sety(~+0.02) + @camera.update +:endwhile +:while:<15 + @npc.warp(1,~+0.03,~,~) + @npc.warp(5,~+0.03,~,~) + @npc.warp(6,~+0.03,~,~) + @camera.sety(~+0.02) + @camera.setpitch(~-0.0011) + @camera.update +:endwhile + +@npc.setspeed(2,0.7) +@npc.move(2,12) + +@storage.set(integer,screenFade,0) +:while:<255 + @camera.setx(~-0.01) + @camera.setz(~-0.01) + @camera.sety(~-0.004) + @camera.setpitch(~-0.0012) + @camera.update + @storage.set(integer,screenFade,+1) + @screen.setfade() +:endwhile + +@camera.set(40,1.1,11,0,0) +@camera.update +@level.update + +@screen.fadein(15) + +@npc.turn(3,1) +@camera.update +@level.wait(5) + +@npc.turn(3,2) +@camera.update +@level.wait(5) + +@npc.turn(3,3) +@camera.update +@level.wait(5) + +@npc.turn(3,0) +@camera.update +@level.wait(5) + +@npc.turn(3,2) +@camera.update +@level.wait(5) + +@npc.move(4,3) + +@storage.set(integer,levelWait,0) +:while:<50 + @level.wait(1) + @camera.update + @storage.set(integer,levelWait,+1) +:endwhile + +@npc.setspeed(4,2) +@npc.move(4,1) + +@sound.play(destroy) + +:while:>35 + @npc.warp(3,~-0.05,~,~) + @camera.update +:endwhile + +@screen.fadeout(2) +@music.stop + +@level.load(newgame\intro.dat) + +@camera.set(9,0.5,9,0,0-0.1) +@camera.update + +@screen.fadein + +@music.play(RouteMusic1) +@npc.move(0,4) +@npc.turn(0,2) + +@text.show(Hello, sorry to~keep you waiting!*Welcome to the~world of Pokémon!*My name is Oak.~People call me~Pokémon Professor.*This world is inhabited~by creatures that~we call...) +@screen.fadeout(20) +@camera.set(20,3,4,3.36,-0.59) +@camera.update +@level.update +@screen.fadein(20) +@text.show(...Pokémon.*People and Pokémon~live together by supporting~each other.) + +@screen.fadeout(20) +@camera.set(35,1,14,6.16,0-0.187) +@camera.update +@level.update +@screen.fadein(20) + +@text.show(Some people play~with Pokémon, some battle~with them.*But we don't know~everything about~Pokémon yet.) + +@screen.fadeout(20) +@camera.set(9,0.5,9,0,0-0.1) +@camera.update +@level.update +@screen.fadein(20) +@text.show(There are still~many mysteries to solve.*That's why I study~Pokémon every day.) +@text.show(But let's get~back to you.) + +@screen.skinselection(Ethan,Lyra,Hilbert,Hilda,Nate,Rosa,Leaf) + +@player.wearskin() +@npc.wearskin(1,) + +:while:<11.5 + @camera.setz(~+0.05) + @camera.sety(~+0.02) + @camera.setpitch(~-0.006) + @camera.update +:endwhile + +@text.show(Now, what did you say~your name was?) +@screen.input(,name,,14) +@player.setname() + +@text.show(Alright, nice to meet you,~!) + +@screen.fadeout(20) +@camera.set(26,1.1,36,5.93,0-0.276) +@camera.update +@level.update +@screen.fadein(20) + +@npc.move(4,3) +@level.wait(50) +@npc.turn(4,1) +@npc.move(4,4) +@npc.turn(3,3) +@npc.move(3,2) +@npc.turn(3,0) +@npc.move(3,2) +@sound.play(enter) + +@text.show(This is your home~in New Bark Town,~you live there~with your mother~right next to Professor Elm.) + +@screen.fadeout(20) +@camera.set(9,1.5,11.5,0,0-0.4) +@camera.update +@level.update +@screen.fadein(20) + +@text.show(,~are you ready?*Your very own Pokémon~story is about to unfold.*You'll face fun times~and tough challenges.*A world of dreams and~adventures with Pokémon~awaits!*Let's go!~I'll be seeing you later!) + +@storage.set(integer,screenFade,0) + +:while:<255 + @camera.setz(~+0.01) + @camera.sety(~+0.004) + @camera.setpitch(~-0.0012) + @camera.update + @storage.set(integer,screenFade,+1) + @screen.setfade() +:endwhile + +@player.setot() +@player.addmoney(3000) + + +@system.endnewgame(yourroom.dat,1,0.1,3,1) + +:end \ No newline at end of file diff --git a/2.5DHero/2.5DHeroContent/maps/newgame/intro.dat b/2.5DHero/2.5DHeroContent/maps/newgame/intro.dat new file mode 100644 index 000000000..a7ebf0ebd --- /dev/null +++ b/2.5DHero/2.5DHeroContent/maps/newgame/intro.dat @@ -0,0 +1,94 @@ +{"Level"{LEV[{"Name"{str[Intro Map]}}{"MusicLoop"{str[RouteMusic1]}}]}} +{"Actions"{LEV[{"CanTeleport"{bool[1]}}{"CanDig"{bool[1]}}{"CanFly"{bool[1]}}{"EnviromentType"{int[1]}}{"Weather"{int[1]}}{"Lightning"{int[1]}}]}} + +{"Floor"{ENT[{"Size"{intArr[50,40]}}{"Position"{intArr[0,0,0]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,0,16,16]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[50,10,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[0,0,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +9,9=starting position + +Oak: +{"NPC"{NPC[{"Position"{sngArr[13,0,5]}}{"TextureID"{str[oak]}}{"ID"{int[0]}}{"Name"{str[Oak]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Player: +{"NPC"{NPC[{"Position"{sngArr[9,0,9]}}{"TextureID"{str[0]}}{"ID"{int[1]}}{"Name"{str[PLAYER]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +First route scene: +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[6,6]}}{"Position"{intArr[20,0,6]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[2,1]}}{"Position"{intArr[26,0,8]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,1]}}{"Position"{intArr[26,0,9]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,2]}}{"Position"{intArr[19,0,10]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,1]}}{"Position"{intArr[23,0,12]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[2,2]}}{"Position"{intArr[22,0,8]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[112,16,16,16]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[1,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[22,0.3,12]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[24,0.3,7]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[25,0.3,11]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,2]}}{"EntityID"{str[HeadbuttTree]}}{"Position"{sngArr[19,-0.2,11]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[16,32,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[1,3]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[21,0,5]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[80,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[21,0,10]}}{"TextureID"{str[[POKEMON|N]44]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[1]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} +{"NPC"{NPC[{"Position"{sngArr[22,0,8]}}{"TextureID"{str[[POKEMON|N]13]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[2]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} +{"NPC"{NPC[{"Position"{sngArr[23,0,9]}}{"TextureID"{str[[POKEMON|N]25]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\ilex\farfetchd]}}{"Rotation"{int[0]}}{"Movement"{str[Walk]}}{"MoveRectangles"{recArr[[20,8,4,3]]}}]}} + +Second scene: +{"Floor"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[14,8]}}{"Position"{intArr[30,0,4]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[96,16,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[10,2]}}{"Position"{intArr[32,0,8]}}{"TexturePath"{str[Park]}}{"Texture"{rec[0,0,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[2,3]}}{"Position"{intArr[32,0,5]}}{"TexturePath"{str[Park]}}{"Texture"{rec[0,0,16,16]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[3,3]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1.1,1.1,1.1]}}{"Position"{sngArr[37,-0.1,4]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[32,0,32,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[2,6]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1.1,1.1,1.1]}}{"Position"{sngArr[30,-0.1,4]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[32,0,32,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[4,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[40,0,5]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[3,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[41,0,6]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[Grass]}}{"Size"{intArr[2,1]}}{"EntityID"{str[Grass]}}{"Position"{sngArr[42,0,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[10,1]}}{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.5,1]}}{"Position"{sngArr[31,-0.25,10.7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,16,16,8]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[10,1]}}{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.2]}}{"Position"{sngArr[31,-0.4,11]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[0,24,16,6]]}}{"TextureIndex"{intArr[0,0,0,0,0,0,0,0,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[2,0.4,1]}}{"Position"{sngArr[35.5,-0.1,6.725]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,32,32,8]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[0]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.55]}}{"Position"{sngArr[35,-0.4,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[48,49,9,3][16,49,16,3][32,49,16,3][16,40,16,9][57,49,1,1]]}}{"TextureIndex"{intArr[1,1,4,4,0,0,2,2,3,3]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"EntityID"{str[Cube]}}{"Scale"{sngArr[1,0.2,0.55]}}{"Position"{sngArr[36,-0.4,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[48,49,9,3][16,49,16,3][32,49,16,3][32,40,16,9][57,49,1,1]]}}{"TextureIndex"{intArr[1,1,4,4,0,0,2,2,3,3]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"Entity"{ENT[{"Scale"{sngArr[0.3,0.4,0.3]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[34,-0.3,7]}}{"TexturePath"{str[Park]}}{"Textures"{recArr[[16,69,8,11][16,61,8,8]]}}{"TextureIndex"{intArr[0,0,0,0,0,0,0,0,1,1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[39,0,9]}}{"TextureID"{str[1]}}{"ID"{int[2]}}{"Name"{str[Lady2]}}{"Action"{int[0]}}{"AdditionalValue"{str[This is Mail I got~from my daughter.~It cheers me up.]}}{"Rotation"{int[3]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[35,0,8]}}{"TextureID"{str[[POKEMON|N]53]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[2]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[36,0,8]}}{"TextureID"{str[15]}}{"ID"{int[2]}}{"Name"{str[Lady1]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\quick_claw]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[33,0,5]}}{"TextureID"{str[18]}}{"ID"{int[2]}}{"Name"{str[Guy2]}}{"Action"{int[0]}}{"AdditionalValue"{str[I'm printing out~my Pokédex.*You can also print~out stuff like*Mail and your PC~Boxes.]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[34,0,5]}}{"TextureID"{str[[POKEMON|N]137]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[40,0,6]}}{"TextureID"{str[[POKEMON|N]167]}}{"ID"{int[2]}}{"Name"{str[Persian]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\nationalpark\persian]}}{"Rotation"{int[2]}}{"Movement"{str[Looking]}}{"MoveRectangles"{recArr[]}}]}} + + + +{"EntityField"{ENT[{"Size"{intArr[50,10,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[0,0,24]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Floor"{ENT[{"Size"{intArr[6,2]}}{"Position"{intArr[25,0,32]}}{"TexturePath"{str[Routes]}}{"Texture"{rec[112,16,16,16]}}]}} +{"EntityField"{ENT[{"SeasonTexture"{str[PlantColoring]}}{"Size"{intArr[4,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[24,0.3,28]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,64,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Your House: +{"EntityField"{ENT[{"Size"{intArr[4,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,0,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} +{"EntityField"{ENT[{"Size"{intArr[2,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[0,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[4,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} +{"EntityField"{ENT[{"Size"{intArr[2,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[64,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,0,0,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}} + +{"Entity"{ENT[{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[48,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31,1,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[32,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"Entity"{ENT[{"EntityID"{str[WarpBlock]}}{"Position"{sngArr[29,0,31]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[16,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[johto\newbark\yourhouse.dat,7,0.1,7,0]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[4,4]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[28,1,28]}}{"TexturePath"{str[BarkTown]}}{"Textures"{recArr[[80,0,16,16]]}}{"TextureIndex"{intArr[-1,-1,-1,-1,-1,-1,-1,-1,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"NPC"{NPC[{"Position"{sngArr[27,0,33]}}{"TextureID"{str[3]}}{"ID"{int[3]}}{"Name"{str[Mom]}}{"Action"{int[1]}}{"AdditionalValue"{str[johto\newbark\mom]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[23,0,33]}}{"TextureID"{str[63]}}{"ID"{int[4]}}{"Name"{str[GateKeeper2]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} diff --git a/2.5DHero/2.5DHeroContent/maps/newgame/intro0.dat b/2.5DHero/2.5DHeroContent/maps/newgame/intro0.dat new file mode 100644 index 000000000..926994e09 --- /dev/null +++ b/2.5DHero/2.5DHeroContent/maps/newgame/intro0.dat @@ -0,0 +1,51 @@ +{"Level"{LEV[{"Name"{str[Intro Map]}}{"MusicLoop"{str[RouteMusic1]}}]}} +{"Actions"{LEV[{"CanTeleport"{bool[1]}}{"CanDig"{bool[1]}}{"CanFly"{bool[1]}}{"EnviromentType"{int[1]}}{"Weather"{int[1]}}{"Lightning"{int[1]}}]}} + +Underwater: +{"Floor"{ENT[{"Size"{intArr[20,6]}}{"Position"{intArr[-2,0,0]}}{"TexturePath"{str[intro]}}{"Texture"{rec[16,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[2,0,1]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[4,0,2]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[7,0,1]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} +{"Floor"{ENT[{"Size"{intArr[1,1]}}{"Position"{intArr[11,0,2]}}{"TexturePath"{str[intro]}}{"Texture"{rec[0,32,16,16]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,0,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,64,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,1,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,48,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,2,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,32,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,1,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,3,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,16,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[20,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[-2,4,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[48,0,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[3,3]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[9,0.3,1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[16,0,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,2]}}{"EntityID"{str[WallBill]}}{"Scale"{sngArr[1,2,1]}}{"Position"{sngArr[3,0.3,2]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[16,0,16,32]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Position"{sngArr[5,0,1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"EntityField"{ENT[{"Size"{intArr[1,1]}}{"EntityID"{str[WallBill]}}{"Position"{sngArr[2,0,3]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[0,16,16,16]]}}{"TextureIndex"{intArr[0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[3]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Shellder: +{"NPC"{NPC[{"Position"{sngArr[8,0,2]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[5,2,1]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[4,1,3]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]90]}}{"ID"{int[0]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Magikarp: +{"NPC"{NPC[{"Position"{sngArr[0,7,2]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[1]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[-3,8,1]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[5]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} +{"NPC"{NPC[{"Position"{sngArr[-4,8,3]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]129]}}{"ID"{int[6]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[26,17]}}{"EntityID"{str[Water]}}{"Position"{sngArr[-6,12,-9]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[0,16,16,16][144,16,16,16]]}}{"TextureIndex"{intArr[0,0,1,1]}}{"Collision"{bool[0]}}{"ModelID"{int[0]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[3]}}]}} + +Lapras: +{"NPC"{NPC[{"Position"{sngArr[12,12.2,2]}}{"TextureID"{str[[POKEMON|N]131]}}{"ID"{int[2]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Overworld: +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[31.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[35.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[39.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[43.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} +{"Entity"{ENT[{"Scale"{sngArr[4,8,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[47.5,3.5,-1]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,0,64,128]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,-1,-1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +{"EntityField"{ENT[{"Size"{intArr[20,8]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[30,0,0]}}{"TexturePath"{str[intro]}}{"Textures"{recArr[[64,112,16,16][48,96,16,16]]}}{"TextureIndex"{intArr[0,0,-1,-1,-1,-1,-1,-1,1,1]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}} + +Jigglypuff: +{"NPC"{NPC[{"Position"{sngArr[40,1,7]}}{"AnimateIdle"{bool[true]}}{"TextureID"{str[[POKEMON|N]39]}}{"ID"{int[3]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}} + +Pikachu: +{"NPC"{NPC[{"Position"{sngArr[45,1,7]}}{"TextureID"{str[[POKEMON|N]25]}}{"ID"{int[4]}}{"Name"{str[Pokemon]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[1]}}{"Movement"{str[Still]}}{"MoveRectangles"{recArr[]}}]}}