Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

A couple of tests

Discussion in 'Made With Unity' started by technicat, May 26, 2008.

  1. technicat

    technicat

    Joined:
    Nov 22, 2006
    Posts:
    1,278
  2. EducaSoft

    EducaSoft

    Joined:
    Sep 9, 2007
    Posts:
    650
    Would you be willing to post some contents of the scripts which determine the stats ?

    like the script which tells which gfx card is in the pc ? The one which tells about the system.

    Also. What is that TEXT TO SPEECH doing there ?



    kind regards,

    Bart
     
  3. technicat

    technicat

    Joined:
    Nov 22, 2006
    Posts:
    1,278
    The pause menu is already on the wiki:

    http://www.unifycommunity.com/wiki/index.php?title=PauseMenu

    Originally, I wanted to have controls for all the individual Quality settings in the menu instead of just the Quality slider, but only the newer settings are exposed in Javascript (at least in the doc)

    Text-to-speech is something new, and not in the wiki, but it's pretty simple (no plugin), just some convenience functions for calling the MacOSX /usr/bin/say command (if you haven't seen it, just type "say anything" in a Terminal window)

    I used the .Net Process class to run the say command, there mentions in the forum, I believe, and I used this wiki script to get started:

    http://www.unifycommunity.com/wiki/index.php?title=Shell

    That's not going to work in the browser, but for widgets, I use a combination of Application.ExternalEval with widget.system to run the say command. I found lengthy doc on setting up widget.system in the Apple reference doc via XCode, and one thing to watch out for is you need to set the AllowSystem key in info.plist to true. I tried out text-to-speech in my typing widget:

    http://www.apple.com/downloads/dashboard/games/fugutype.html

    so you can inspect that if you're doing widgets. I just discovered it behaves terribly on my old Mac Mini, which is why I added the option to turn it off (just a flag that disables my convenience functions)
     
  4. Aras

    Aras

    Unity Technologies

    Joined:
    Nov 7, 2005
    Posts:
    4,537
    Are you looking for a SystemInfo class?
     
  5. EducaSoft

    EducaSoft

    Joined:
    Sep 9, 2007
    Posts:
    650
    actually yes :)

    Thanks