Skip to content

Commit

Permalink
安卓版系列更新
Browse files Browse the repository at this point in the history
  • Loading branch information
lemingcen committed Apr 27, 2019
1 parent 1c4da04 commit 497c3a9
Show file tree
Hide file tree
Showing 43 changed files with 15,506 additions and 42,466 deletions.
Binary file removed References/SharpFontCore.dll
Binary file not shown.
Binary file removed References/SixLabors.Core.dll
Binary file not shown.
Binary file removed References/SixLabors.Fonts.dll
Binary file not shown.
Binary file removed References/SixLabors.ImageSharp.Drawing.dll
Binary file not shown.
Binary file removed References/SixLabors.ImageSharp.dll
Binary file not shown.
Binary file removed References/SixLabors.Shapes.dll
Binary file not shown.
Binary file not shown.
Binary file removed References/Win - 副本/Interop.WMPLib.DLL
Binary file not shown.
Binary file removed References/Win - 副本/Lidgren.Network.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed References/Win - 副本/Microsoft.Xna.Framework.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed References/Win - 副本/MonoGame.Framework.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.DXGI.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.Direct2D1.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.Direct3D11.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.Direct3D9.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.MediaFoundation.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.RawInput.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.XAudio2.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.XInput.dll
Binary file not shown.
Binary file removed References/Win - 副本/SharpDX.dll
Binary file not shown.
Binary file removed References/Win - 副本/Steamworks.NET.dll
Binary file not shown.
Binary file removed References/Win - 副本/steam_api64.dll
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="WorldOfTheThreeKingdoms.Android" android:versionCode="2" android:versionName="1.1.5.0" android:installLocation="auto">
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="28" />
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="WorldOfTheThreeKingdoms.Android" android:versionCode="1230" android:versionName="1.2.3.0" android:installLocation="auto">
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="27" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<application android:icon="@drawable/Icon" android:label="中華三國志"></application>
Expand Down
52,978 changes: 10,702 additions & 42,276 deletions WorldOfTheThreeKingdoms.Android/WorldOfTheThreeKingdoms.Android.csproj

Large diffs are not rendered by default.

54 changes: 0 additions & 54 deletions WorldOfTheThreeKingdoms.Pipeline/MessageLProcessor.cs

This file was deleted.

53 changes: 0 additions & 53 deletions WorldOfTheThreeKingdoms.Pipeline/MessageProcessor.cs

This file was deleted.

This file was deleted.

128 changes: 128 additions & 0 deletions WorldOfTheThreeKingdoms.Play/Activity1.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
using Android.App;
using Android.Content;
using Android.Content.PM;
using Android.Net;
using Android.OS;
using Android.Runtime;
using Android.Util;
using Android.Views;
using Android.Widget;
using Microsoft.Xna.Framework;
using Java.Lang;
using Android.Telephony;
using System;
using Android.Graphics;
using Platforms;
using Tools;

namespace WorldOfTheThreeKingdoms.Android
{
[Activity(Label = "中華三國志"
, MainLauncher = true
, Icon = "@drawable/icon"
, Theme = "@android:style/Theme.NoTitleBar" //Translucent" //NoTitleBar "@style/Theme.Splash"
, AlwaysRetainTaskState = true
, ScreenOrientation = ScreenOrientation.Landscape
//, LaunchMode = Android.Content.PM.LaunchMode.SingleInstance
//, ScreenOrientation = ScreenOrientation.SensorLandscape
, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden | ConfigChanges.ScreenSize)]
public class Activity1 : Microsoft.Xna.Framework.AndroidGameActivity
{
protected override void OnCreate(Bundle bundle)
{
try
{
this.Window.AddFlags(WindowManagerFlags.Fullscreen);
this.Window.AddFlags(WindowManagerFlags.KeepScreenOn);

Platform.Activity1 = this;

base.OnCreate(bundle);

SetFullScreen();

AndroidEnvironment.UnhandledExceptionRaiser += (sender, args) =>
{
WebTools.TakeWarnMsg("UnhandledExceptionRaiser", "", args != null ? args.Exception : null);
//Season.SeasonGame.err = args.Exception.ToString();
//SeasonTools.SendErrMsg("UnhandledExceptionRaiser", args != null ? args.Exception : null);
//Game1.SendErrMsg("", args.Exception);
// Do something...
};

var g = new MainGame();

var view = (View)g.Services.GetService(typeof(View));

SetContentView(view);//SetContentView(g.Window); //temple remove
g.Run();

}
catch (System.Exception ex)
{
//WebTools.TakeWarnMsg("OnCreate", "", ex);
}
}

public void SetFullScreen()
{
View decorView = Window.DecorView;
var uiOptions = (int)decorView.SystemUiVisibility;
var newUiOptions = (int)uiOptions;
//newUiOptions |= (int)SystemUiFlags.LowProfile;
//newUiOptions |= (int)SystemUiFlags.Fullscreen;
//newUiOptions |= (int)SystemUiFlags.HideNavigation;
//newUiOptions |= (int)SystemUiFlags.Immersive;
//newUiOptions |= (int)SystemUiFlags.Fullscreen;
//newUiOptions |= (int)SystemUiFlags.LayoutStable;
//newUiOptions |= (int)SystemUiFlags.LayoutHideNavigation;
//newUiOptions |= (int)SystemUiFlags.LayoutFullscreen;
newUiOptions |= (int)SystemUiFlags.Fullscreen;
newUiOptions |= (int)SystemUiFlags.HideNavigation;
newUiOptions |= (int)SystemUiFlags.ImmersiveSticky;
//("setSystemUiVisibility", SYSTEM_UI_FLAG_FULLSCREEN | SYSTEM_UI_FLAG_HIDE_NAVIGATION | SYSTEM_UI_FLAG_IMMERSIVE_STICKY);
decorView.SystemUiVisibility = (StatusBarVisibility)newUiOptions;
}

public override void OnConfigurationChanged(global::Android.Content.Res.Configuration newConfig)
{
base.OnConfigurationChanged(newConfig);
}

protected override void OnPause()
{
//Session.PauseGame();
try
{
base.OnPause();
}
catch (System.Exception ex)
{
WebTools.TakeWarnMsg("游戏暂停处理失败:" + "Activity1.OnPause", "Activity1.OnPause:", ex);
}
}

protected override void OnResume()
{
SetFullScreen();

//if (Session.InitReady)
//{
// Session.ResumeGame();
//}
base.OnResume();
}

protected override void OnDestroy()
{
// Call base method
base.OnDestroy();
}

protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
{
Platform.Current.HandleActivityResult(requestCode, resultCode, data);
}
}
}

7 changes: 7 additions & 0 deletions WorldOfTheThreeKingdoms.Play/Properties/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.zhsan.threekingdoms" android:versionCode="1220" android:versionName="1.2.2.0" android:installLocation="auto">
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="27" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<application android:icon="@drawable/Icon" android:label="中華三國志"></application>
</manifest>
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using Android.App;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("WorldOfTheThreeKingdoms.Pipeline")]
[assembly: AssemblyProduct("WorldOfTheThreeKingdoms.Pipeline")]
[assembly: AssemblyTitle("WorldOfTheThreeKingdoms.Android")]
[assembly: AssemblyProduct("WorldOfTheThreeKingdoms.Android")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyCompany("")]
Expand All @@ -20,7 +21,7 @@
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("cf57131e-7bd4-46e4-8eb3-a04486980b3b")]
[assembly: Guid("025bbfe5-413f-4a4e-8fe2-61019517917f")]

// Version information for an assembly consists of the following four values:
//
Expand All @@ -34,3 +35,7 @@
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

// Add some common permissions, these can be removed if not needed
[assembly: UsesPermission(Android.Manifest.Permission.Internet)]
[assembly: UsesPermission(Android.Manifest.Permission.WriteExternalStorage)]
Loading

0 comments on commit 497c3a9

Please sign in to comment.