Search Unity

What is the RuntimePlatform for Windows Store apps.

Discussion in 'Windows' started by bakno, Aug 6, 2013.

  1. bakno

    bakno

    Joined:
    Mar 18, 2007
    Posts:
    604
    What is the value returned by Application.platform when running the game after build?
     
  2. BFS-Kyle

    BFS-Kyle

    Joined:
    Jun 12, 2013
    Posts:
    883
    An easy way to find out is to do a build and simply debug out what it returns.

    But I would imagine it is going to be RuntimePlatform.MetroPlayerX86 for x86, and RuntimePlatform.MetroPlayerARM for ARM.
     
  3. bakno

    bakno

    Joined:
    Mar 18, 2007
    Posts:
    604
    Thanks Kyle

    How do you debug when running the built version?

    I tried looking at the debug output file but it is not there.
     
  4. BFS-Kyle

    BFS-Kyle

    Joined:
    Jun 12, 2013
    Posts:
    883
    Just use Debug.Log(Application.platform); then you can see it in the output window in Visual Studio.

    If you don't see the Debug statement, check the FAQ at http://docs.unity3d.com/Documentation/Manual/windowsstore-faq.html
     
  5. bakno

    bakno

    Joined:
    Mar 18, 2007
    Posts:
    604
    Hi Kyle

    Let me confirm that RuntimePlatform.MetroPlayerX86 is the one. Thank you.

    I am not familiar with VS, but the output window is clearly marked and selecting "Debug" as the output to show does not show the Debug.Log from the JavaScript. Maybe it debugs from C# but not JS. However, this time I was able to find the debug on the UnityPlayer log file.
     
  6. BFS-Kyle

    BFS-Kyle

    Joined:
    Jun 12, 2013
    Posts:
    883
    Just a heads up about JavaScript - its not yet supported for passing WACK, which means you cannot submit a game using Javascript to the Windows 8 store. Only C# scripts will pass WACK.

    See http://docs.unity3d.com/Documentation/Manual/windowsstore-gettingstarted.html for more details.
     
  7. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,822
    The log file is stored under
    C:\Users\<yourusername>\AppData\Local\Packages\<gamename>\TempState\UnityPlayer.log
     
  8. bakno

    bakno

    Joined:
    Mar 18, 2007
    Posts:
    604
    I know Kyle. That is the worst problem of Unity for Win8.

    Anyway, I am trying to get a game up to that point where JS is my only problem.

    Most of my scripts are JS and conversion to C# will be a pain. Hopefully Unity solves this problem soon or MS widens the WACK restrictions.

    Thank you Meltdown, I was able to find that file.