Guide.IsTrialMode on Windows Phone

Kluch posts important info about the performance of Guide.IsTrialMode on Windows Phone:

  • Can take ~60 milliseconds to query while in trial mode
  • So don't call it every frame!
  • This delay only occurs when downloaded from Marketplace, not when testing with SimulateTrialMode
  • Consider checking it once on startup, then again whenever the Game.Activated event fires

Comments (8)

  1. Niklas Rother says:

    Maybe you should do this caching for us. 😉 Would be a great help for people who don´t know this!

  2. ShawnHargreaves says:

    > Maybe you should do this caching for us

    This is something we'd love to improve in the future, but for now, afraid it is what it is.

  3. Erzengel says:

    Alternately, it would be nice if SimulateTrialMode induced a Thread.Sleep(60) to accurately simulate trial mode.

  4. Mike says:

    Out of curiosity, why does it take so long?

  5. Luke says:

    Looks like somebody broke the golden rule that property accessors should always be fast 😉

  6. Danimal says:

    Will there be a way to test this in the real world scenario?  For example, on Xbox you must use SimulateTrialMode when deploying from the IDE, but you can test the real world trial mode scenario by exiting Game Studio Connect and starting your game via the dash, and choosing "Trial Mode".  I don't know the WP7 tools that well but such a thing would seem necessary.  Anyway thanks for the heads-up.

  7. Steve Williams says:

    There is a performance hit from calling Guide.IsTrialMode with SimulateTrialMode on the device even when the app was not downloaded from Marketplace, but its up to several ms instead of 60.  We found this a few months back and started caching the trial mode value at that point.

  8. jasond says:

    As I mentioned here…/387998.aspx Guide.IsTrialMode is always true on game start (and fixed at a later time), so the recommendation to checking it on startup is wrong UNLESS Game.Activated fires when it's set to the proper value.  So… is that what happens?

Skip to main content