編輯:在調試中,你可以設置Guide.SimulateTrialMode
爲了測試這種方式或其他,看起來。
因此,這裏是在Windows 8商店應用程式有關信息試用模式:
Create a trial version of your app
LicenseInformation class
基本上,它利用一個布爾標誌licenseInformation.IsTrial
。如果再深入到MonoGame source code on GitHub,我們可以看到他們是如何實施檢查:
#if WINDOWS_STOREAPP
var licenseInformation = CurrentApp.LicenseInformation;
...
isTrialMode = !licenseInformation.IsActive || licenseInformation.IsTrial;
#endif
所以,看來你licenseInformation或者未設置爲活動的,或者如果你有問題測試設置爲審判。第一個鏈接有關於如何測試它的信息,但我不確定如何將其擴展到MonoGame:
現在,使用模擬調用許可證服務器來測試您的應用程序。在JavaScript,C#,Visual Basic或Visual C++中,用應用程序的初始化代碼中的CurrentAppSimulator替換對CurrentApp的引用。 CurrentAppSimulator從位於\ Microsoft \ Windows Store \ ApiData的名爲「WindowsStoreProxy.xml」的XML文件中獲取特定於測試的許可信息。如果此路徑和文件不存在,則必須在安裝期間或運行時創建它們。如果您嘗試訪問CurrentAppSimulator.LicenseInformation屬性而沒有在該特定位置存在WindowsStoreProxy.xml,則會出現錯誤。
我想在最壞的情況下,你可以自己構建MonoGame,將CurrentApp
更改爲CurrentAppSimulator
。
這可能有助於https://monogame.codeplex.com/discussions/318106 – craftworkgames
我已經看過,但它已經過了一年多了(WP7'IsTrialMode'現在可以工作)。我開始認爲我需要一個單獨的Windows應用程序代碼路徑。 –