Jelajahi Sumber

SpritFont - Refactor to build on iOS.

Dominique Louis 1 bulan lalu
induk
melakukan
8c10312e56

+ 2 - 2
SpriteFont/.vscode/launch.json

@@ -17,7 +17,7 @@
             "type": "coreclr",
             "request": "launch",
             "preLaunchTask": "build-desktopgl",
-            "program": "${workspaceFolder}/Platforms/DesktopGL/bin/Debug/net8.0/SpriteFont.DesktopGL.exe",
+            "program": "${workspaceFolder}/Platforms/DesktopGL/bin/Debug/net8.0/SpriteFont.DesktopGL",
             "args": [],
             "cwd": "${workspaceFolder}/Platforms/DesktopGL",
             "stopAtEntry": false,
@@ -39,7 +39,7 @@
             "type": "coreclr",
             "request": "launch",
             "preLaunchTask": "build-ios",
-            "program": "${workspaceFolder}/Platforms/iOS/bin/Debug/net8.0-ios/SpriteFont.iOS.dll",
+            "program": "${workspaceFolder}/Platforms/iOS/bin/Debug/net8.0-ios/iossimulator-arm64/SpriteFont.iOS.dll",
             "args": [],
             "cwd": "${workspaceFolder}/Platforms/iOS",
             "stopAtEntry": false,

+ 1 - 1
SpriteFont/Core/SpriteFontGame.cs

@@ -1,7 +1,7 @@
 using Microsoft.Xna.Framework;
 using Microsoft.Xna.Framework.Graphics;
 
-namespace SpriteFontSample.Core
+namespace SpriteFontSample
 {
     /// <summary>
     /// This is the main type for your game

+ 0 - 1
SpriteFont/Platforms/Android/MainActivity.cs

@@ -1,7 +1,6 @@
 using Android.App;
 using Android.Content.PM;
 using Android.OS;
-using SpriteFontSample.Core;
 
 namespace SpriteFontSample.Android
 {

+ 0 - 1
SpriteFont/Platforms/DesktopGL/Program.cs

@@ -1,5 +1,4 @@
 using System;
-using SpriteFontSample.Core;
 
 namespace SpriteFontSample.DesktopGL
 {

+ 0 - 1
SpriteFont/Platforms/Windows/Program.cs

@@ -1,5 +1,4 @@
 using System;
-using SpriteFontSample.Core;
 
 namespace SpriteFontSample.Windows
 {

+ 2 - 3
SpriteFont/Platforms/iOS/Program.cs

@@ -1,11 +1,10 @@
 using Foundation;
 using UIKit;
-using SpriteFontSample.Core;
 
 namespace SpriteFontSample.iOS
 {
     [Register("AppDelegate")]
-    class Program : UIApplicationDelegate
+    class AppDelegate : UIApplicationDelegate
     {
         private SpriteFontGame game;
 
@@ -17,7 +16,7 @@ namespace SpriteFontSample.iOS
 
         static void Main(string[] args)
         {
-            UIApplication.Main(args, null, "AppDelegate");
+            UIApplication.Main(args, null, typeof(AppDelegate));
         }
     }
 }

+ 34 - 34
SpriteFont/SpriteFont.sln

@@ -2,8 +2,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00
 # Visual Studio Version 17
 VisualStudioVersion = 17.5.2.0
 MinimumVisualStudioVersion = 10.0.40219.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.Core", "Core\Core.csproj", "{A1A1A1A1-0000-0000-0000-000000000001}"
-EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.Windows", "Platforms\Windows\SpriteFont.Windows.csproj", "{A1A1A1A1-0000-0000-0000-000000000002}"
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.DesktopGL", "Platforms\DesktopGL\SpriteFont.DesktopGL.csproj", "{A1A1A1A1-0000-0000-0000-000000000003}"
@@ -12,37 +10,39 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.Android", "Platf
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.iOS", "Platforms\iOS\SpriteFont.iOS.csproj", "{A1A1A1A1-0000-0000-0000-000000000005}"
 EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFont.Core", "Core\SpriteFont.Core.csproj", "{64F21030-855D-48C8-825F-3A1016781319}"
+EndProject
 Global
-	   GlobalSection(SolutionConfigurationPlatforms) = preSolution
-			   Debug|Any CPU = Debug|Any CPU
-			   Release|Any CPU = Release|Any CPU
-	   EndGlobalSection
-	   GlobalSection(ProjectConfigurationPlatforms) = postSolution
-			   {A1A1A1A1-0000-0000-0000-000000000001}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000001}.Debug|Any CPU.Build.0 = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000001}.Release|Any CPU.ActiveCfg = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000001}.Release|Any CPU.Build.0 = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000002}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000002}.Debug|Any CPU.Build.0 = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000002}.Release|Any CPU.ActiveCfg = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000002}.Release|Any CPU.Build.0 = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000003}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000003}.Debug|Any CPU.Build.0 = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000003}.Release|Any CPU.ActiveCfg = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000003}.Release|Any CPU.Build.0 = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000004}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000004}.Debug|Any CPU.Build.0 = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000004}.Release|Any CPU.ActiveCfg = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000004}.Release|Any CPU.Build.0 = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000005}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000005}.Debug|Any CPU.Build.0 = Debug|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000005}.Release|Any CPU.ActiveCfg = Release|Any CPU
-			   {A1A1A1A1-0000-0000-0000-000000000005}.Release|Any CPU.Build.0 = Release|Any CPU
-	   EndGlobalSection
-	   GlobalSection(SolutionProperties) = preSolution
-			   HideSolutionNode = FALSE
-	   EndGlobalSection
-	   GlobalSection(ExtensibilityGlobals) = postSolution
-			   SolutionGuid = {CA94EE0E-1A07-40F5-9141-FABFB7481655}
-	   EndGlobalSection
+				GlobalSection(SolutionConfigurationPlatforms) = preSolution
+						Debug|Any CPU = Debug|Any CPU
+						Release|Any CPU = Release|Any CPU
+				EndGlobalSection
+				GlobalSection(ProjectConfigurationPlatforms) = postSolution
+						{A1A1A1A1-0000-0000-0000-000000000002}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000002}.Debug|Any CPU.Build.0 = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000002}.Release|Any CPU.ActiveCfg = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000002}.Release|Any CPU.Build.0 = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000003}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000003}.Debug|Any CPU.Build.0 = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000003}.Release|Any CPU.ActiveCfg = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000003}.Release|Any CPU.Build.0 = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000004}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000004}.Debug|Any CPU.Build.0 = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000004}.Release|Any CPU.ActiveCfg = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000004}.Release|Any CPU.Build.0 = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000005}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000005}.Debug|Any CPU.Build.0 = Debug|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000005}.Release|Any CPU.ActiveCfg = Release|Any CPU
+						{A1A1A1A1-0000-0000-0000-000000000005}.Release|Any CPU.Build.0 = Release|Any CPU
+					{64F21030-855D-48C8-825F-3A1016781319}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+					{64F21030-855D-48C8-825F-3A1016781319}.Debug|Any CPU.Build.0 = Debug|Any CPU
+					{64F21030-855D-48C8-825F-3A1016781319}.Release|Any CPU.ActiveCfg = Release|Any CPU
+					{64F21030-855D-48C8-825F-3A1016781319}.Release|Any CPU.Build.0 = Release|Any CPU
+				EndGlobalSection
+				GlobalSection(SolutionProperties) = preSolution
+						HideSolutionNode = FALSE
+				EndGlobalSection
+				GlobalSection(ExtensibilityGlobals) = postSolution
+						SolutionGuid = {CA94EE0E-1A07-40F5-9141-FABFB7481655}
+				EndGlobalSection
 EndGlobal