Hi there!
I’m building a Windows Store version of our game, but have some problems with the Pointer/Mouse mode control from Unity. For Xbox, the pointer is obviously not ment to even be there, so I use this code to do so (based on this article):
public App()
{
this.InitializeComponent();
if (Windows.System.Profile.AnalyticsInfo.VersionInfo.DeviceFamily == "Windows.Xbox")
this.RequiresPointerMode = Windows.UI.Xaml.ApplicationRequiresPointerMode.WhenRequested;
SetupOrientation();
appCallbacks = new AppCallbacks();
}
However, I have to enter it manually to the App.xaml.cs file every time I make a new Unity build, which is a pain.
- Is there a way to handle this from within Unity?
- Can I also show and hide the cursor/pointer from within Unity whenever I need it? There are certain scenarios where virtual mouse makes more sense than gamepad controls.
Thanks a lot for any help!