-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Android remote to latest MonoGame
- Loading branch information
1 parent
39e2246
commit 8d97c3a
Showing
18 changed files
with
268 additions
and
1,245 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
{ | ||
"version": 1, | ||
"isRoot": true, | ||
"tools": { | ||
"dotnet-mgcb": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb" | ||
] | ||
}, | ||
"dotnet-mgcb-editor": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-linux": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-linux" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-windows": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-windows" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-mac": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-mac" | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
using Android.App; | ||
using Android.Content.PM; | ||
using Android.OS; | ||
using Android.Views; | ||
using Microsoft.Xna.Framework; | ||
|
||
namespace AndroidTest | ||
{ | ||
[Activity( | ||
Label = "@string/app_name", | ||
MainLauncher = true, | ||
Icon = "@drawable/icon", | ||
AlwaysRetainTaskState = true, | ||
LaunchMode = LaunchMode.SingleInstance, | ||
ScreenOrientation = ScreenOrientation.FullUser, | ||
ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden | ConfigChanges.ScreenSize | ||
)] | ||
public class Activity1 : AndroidGameActivity | ||
{ | ||
private Game1 _game; | ||
private View _view; | ||
|
||
protected override void OnCreate(Bundle bundle) | ||
{ | ||
base.OnCreate(bundle); | ||
|
||
_game = new Game1(); | ||
_view = _game.Services.GetService(typeof(View)) as View; | ||
|
||
SetContentView(_view); | ||
_game.Run(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="AndroidTest.AndroidTest" android:versionCode="1" android:versionName="1.0"> | ||
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="31" /> | ||
<uses-feature android:glEsVersion="0x00020000" android:required="true" /> | ||
<application android:label="AndroidTest"></application> | ||
</manifest> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net6.0-android</TargetFramework> | ||
<SupportedOSPlatformVersion>23</SupportedOSPlatformVersion> | ||
<OutputType>Exe</OutputType> | ||
<ApplicationId>com.companyname.AndroidTest</ApplicationId> | ||
<ApplicationVersion>1</ApplicationVersion> | ||
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<PackageReference Include="MonoGame.Content.Builder.Task" Version="3.8.1.303" /> | ||
<PackageReference Include="MonoGame.Framework.Android" Version="3.8.1.303" /> | ||
</ItemGroup> | ||
<Target Name="RestoreDotnetTools" BeforeTargets="Restore"> | ||
<Message Text="Restoring dotnet tools" Importance="High" /> | ||
<Exec Command="dotnet tool restore" /> | ||
</Target> | ||
</Project> |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
using Microsoft.Xna.Framework; | ||
using Microsoft.Xna.Framework.Graphics; | ||
using Microsoft.Xna.Framework.Input; | ||
|
||
namespace AndroidTest | ||
{ | ||
public class Game1 : Game | ||
{ | ||
private GraphicsDeviceManager _graphics; | ||
private SpriteBatch _spriteBatch; | ||
|
||
public Game1() | ||
{ | ||
_graphics = new GraphicsDeviceManager(this); | ||
Content.RootDirectory = "Content"; | ||
IsMouseVisible = true; | ||
} | ||
|
||
protected override void Initialize() | ||
{ | ||
// TODO: Add your initialization logic here | ||
|
||
base.Initialize(); | ||
} | ||
|
||
protected override void LoadContent() | ||
{ | ||
_spriteBatch = new SpriteBatch(GraphicsDevice); | ||
|
||
// TODO: use this.Content to load your game content here | ||
} | ||
|
||
protected override void Update(GameTime gameTime) | ||
{ | ||
if (GamePad.GetState(PlayerIndex.One).Buttons.Back == ButtonState.Pressed || Keyboard.GetState().IsKeyDown(Keys.Escape)) | ||
Exit(); | ||
|
||
// TODO: Add your update logic here | ||
|
||
base.Update(gameTime); | ||
} | ||
|
||
protected override void Draw(GameTime gameTime) | ||
{ | ||
GraphicsDevice.Clear(Color.CornflowerBlue); | ||
|
||
// TODO: Add your drawing code here | ||
|
||
base.Draw(gameTime); | ||
} | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<resources> | ||
<string name="app_name">AndroidTest</string> | ||
</resources> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
{ | ||
"version": 1, | ||
"isRoot": true, | ||
"tools": { | ||
"dotnet-mgcb": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb" | ||
] | ||
}, | ||
"dotnet-mgcb-editor": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-linux": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-linux" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-windows": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-windows" | ||
] | ||
}, | ||
"dotnet-mgcb-editor-mac": { | ||
"version": "3.8.1.303", | ||
"commands": [ | ||
"mgcb-editor-mac" | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="StompboxAndroid.StompboxAndroid" android:versionCode="1" android:versionName="1.0"> | ||
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="31" /> | ||
<uses-feature android:glEsVersion="0x00020000" android:required="true" /> | ||
<application android:label="StompboxAndroid"></application> | ||
</manifest> |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.