mirror of
https://github.com/openeggbert/mobile-eggbert-core.git
synced 2025-03-25 15:47:49 +01:00
Fixed for non KNI
This commit is contained in:
parent
99910d425d
commit
62241e8f94
15
Worlds.cs
15
Worlds.cs
@ -6,12 +6,14 @@ using System.Globalization;
|
|||||||
using System.IO;
|
using System.IO;
|
||||||
using System.IO.IsolatedStorage;
|
using System.IO.IsolatedStorage;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using Microsoft.JSInterop;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
using WindowsPhoneSpeedyBlupi;
|
using WindowsPhoneSpeedyBlupi;
|
||||||
|
#if KNI && Web
|
||||||
|
using Microsoft.JSInterop;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
using static System.Runtime.InteropServices.JavaScript.JSType;
|
using static System.Runtime.InteropServices.JavaScript.JSType;
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace WindowsPhoneSpeedyBlupi
|
namespace WindowsPhoneSpeedyBlupi
|
||||||
{
|
{
|
||||||
@ -41,8 +43,8 @@ namespace WindowsPhoneSpeedyBlupi
|
|||||||
string worldFilename = GetWorldFilename(gamer, rank);
|
string worldFilename = GetWorldFilename(gamer, rank);
|
||||||
|
|
||||||
string text = null;
|
string text = null;
|
||||||
if (Env.IMPL.isNotKNI() && Env.PLATFORM.isNotWeb())
|
#if !(KNI && Web)
|
||||||
{
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
Stream stream = TitleContainer.OpenStream(worldFilename);
|
Stream stream = TitleContainer.OpenStream(worldFilename);
|
||||||
@ -56,11 +58,10 @@ namespace WindowsPhoneSpeedyBlupi
|
|||||||
Debug.Write("Fatal error. Loading world failed: " + worldFilename + "\n");
|
Debug.Write("Fatal error. Loading world failed: " + worldFilename + "\n");
|
||||||
//Environment.Exit(1);
|
//Environment.Exit(1);
|
||||||
}
|
}
|
||||||
}
|
#else
|
||||||
else
|
|
||||||
{
|
|
||||||
text = WorldTxt.getWorld(rank);
|
text = WorldTxt.getWorld(rank);
|
||||||
}
|
#endif
|
||||||
if (text == null)
|
if (text == null)
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user