-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #18 from modio/v2024.11
Syncing v2024.11
- Loading branch information
Showing
135 changed files
with
5,062 additions
and
367 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
Binary file not shown.
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
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
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,14 @@ | ||
using System.Runtime.InteropServices; | ||
|
||
namespace ModIO.Platform.Mobile.iOS | ||
{ | ||
#if UNITY_IOS | ||
|
||
public static class NativeIosBridge | ||
{ | ||
[DllImport("__Internal")] | ||
public static extern long GetAvailableDiskSpace(); | ||
} | ||
#endif | ||
|
||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,50 @@ | ||
using UnityEngine; | ||
|
||
#if MODIO_OCULUS | ||
using Oculus.Platform; | ||
using Oculus.Platform.Models; | ||
#endif | ||
|
||
namespace ModIO.Implementation.Platform | ||
{ | ||
public class ModioPlatformExampleOculus : MonoBehaviour | ||
{ | ||
#if MODIO_OCULUS | ||
void Awake() | ||
{ | ||
// Oculus takes a fair bit of time to initialize and perform the entitlement check. By calling this | ||
// we're telling the plugin to wait until it's ready. | ||
ModioPlatform.SetInitializing(); | ||
|
||
// Ensure you have your game's App Id set up in the Oculus Settings object provided by the Meta Platform SDK | ||
Core.AsyncInitialize().OnComplete(OnInitialize); | ||
} | ||
|
||
void OnInitialize(Message<PlatformInitialize> message) | ||
{ | ||
if (message.IsError) | ||
{ | ||
Logger.Log(LogLevel.Error, $"initializing Oculus Platform: {message.GetError().Message}"); | ||
return; | ||
} | ||
|
||
Logger.Log(LogLevel.Verbose, $"Oculus Platform initialized successfully"); | ||
|
||
Entitlements.IsUserEntitledToApplication().OnComplete(OnEntitled); | ||
} | ||
|
||
void OnEntitled(Message message) | ||
{ | ||
if (message.IsError) | ||
{ | ||
Logger.Log(LogLevel.Error, $"Error checking Oculus Platform entitlement: {message.GetError().Message}"); | ||
return; | ||
} | ||
|
||
Logger.Log(LogLevel.Verbose, $"Oculus Platform verified entitlement successfully"); | ||
|
||
ModioPlatformOculus.SetAsPlatform(); | ||
} | ||
#endif | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.