Request : XNA Trial Mode

Monkey Forums/Monkey Programming/Request : XNA Trial Mode

Raz(Posted 2011) [#1]
For Xbox games, it would be useful if we could check whether the game was in trial mode or not.

XNA provides the bool
Guide.IsTrialMode


For testing when running on a PC, the command
Guide.SimulateTrialMode

would also be useful (basically you set it during game load up and it sets IsTrialMode to True.

Would this be possible?

Ta


marksibly(Posted 2011) [#2]
Hi,

Quick 'n' dirty way for now...

Import mojo

Extern

Global IsTrialMode?="Guide.IsTrialMode"

Public

Function Main()
	If IsTrialMode
		Print "Yes!"
	Else
		Print "No!"
	Endif
End



Soap(Posted 2011) [#3]
What about ShowMarketplace and AllowPurchaseContent?

Guide.ShowMarketplace = present an offer to purchase the full version of the game.

AllowPurchaseContent = check if an account is allowed to purchase (for example child accounts are unable to) without this a project will fail review.

http://msdn.microsoft.com/en-us/library/microsoft.xna.framework.gamerservices.guide.showmarketplace.aspx

http://msdn.microsoft.com/en-us/library/microsoft.xna.framework.gamerservices.gamerprivileges.allowpurchasecontent.aspx


Raz(Posted 2011) [#4]
To add to this

Game.IsActive


would be useful too (an Xbox game is not active when the guide is being shown). Using your logic above Mark, could I just do...

Import mojo

Extern

Global IsActive?="Game.IsActive"

Public

Function Main()
	If IsActive
		Print "Yes!"
	Else
		Print "No!"
	Endif
End