Can you give more specifics as to your plugin setup, and whatever you are doing upon initialization?
I posted this in the official Ouya dev forums but got no response. Can anyone here shed some light on this?
I used the Unity3d Pro OUYA Panel to build and send my game to the Ouya. When it starts, it sits at the Unity3d screen for about 30-60 seconds then goes back to the PLAY menu.
Thoughts?
Is there any way to see what's going on there in an effort to figure out what the problem is?
My log is filled with this, repeating ad nauseum (developerId redacted):
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: OuyaGameObject send RequestUnityAwake
I/OuyaUnityPlugin( 1102): setDeveloperId developerId: XXXXXXXXX
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: m_unityOuyaFacade is null
I/OuyaUnityPlugin( 1102): InitializeTest: m_developerId is set, requesting init
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: OuyaGameObject send RequestUnityAwake
I/OuyaUnityPlugin( 1102): setDeveloperId developerId: XXXXXXXXX
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: m_unityOuyaFacade is null
I/OuyaUnityPlugin( 1102): InitializeTest: m_developerId is set, requesting init
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: OuyaGameObject send RequestUnityAwake
I/OuyaUnityPlugin( 1102): setDeveloperId developerId: XXXXXXXXX
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: m_unityOuyaFacade is null
I/OuyaUnityPlugin( 1102): InitializeTest: m_developerId is set, requesting init
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: OuyaGameObject send RequestUnityAwake
I/OuyaUnityPlugin( 1102): setDeveloperId developerId: XXXXXXXXX
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: m_unityOuyaFacade is null
I/OuyaUnityPlugin( 1102): InitializeTest: m_developerId is set, requesting init
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: OuyaGameObject send RequestUnityAwake
I/OuyaUnityPlugin( 1102): setDeveloperId developerId: XXXXXXXXX
I/OuyaUnityPlugin( 1102): OuyaUnityPlugin.InitializeTest: m_unityOuyaFacade is null
I/OuyaUnityPlugin( 1102): InitializeTest: m_developerId is set, requesting init
Last edited by Schizophretard; 09-20-2014 at 05:42 AM.
Can you give more specifics as to your plugin setup, and whatever you are doing upon initialization?
OK, I've got the latest Ouya Unity3d plugin installed. I did a git pull from their github repo yesterday and exported the Ouya packages. That said, I didn't delete the old one first... Do I just delete the Plugins and OUYA folders?
I also use InControl for my control scheme. I updated to the latest one (again without removing the old one first, they really should get on a package manager, here...). The latest version adds support for Ouya Everywhere on the Ouya console, so I've followed the instructions to set that up.
Here's my main initialization code:
void Start () {
// Generate wormholes.
for (var i = 0; i < numberOfWormholes; i++) {
GameObject wormhole = Instantiate (Wormhole, new Vector3 (Random.Range (minWormholeRangeX, maxWormholeRangeX), 0.0f, Random.Range (minWormholeRangeZ, maxWormholeRangeZ)), Quaternion.identity) as GameObject;
this.wormholes.Add (wormhole);
}
// Generate asteroids.
// xxx
}
void Update () {
// Detect any button press or controller action.
InputDevice device = InputManager.ActiveDevice;
InputControl control = device.GetControl (InputControlType.Action1);
// A NEW CHALLENGER HAS ARRIVED
if (control.WasPressed) {
if (players.Count > 0) {
// Compare the hash code of the current device vs. the ones we know.
if (!players.Exists (p => p.GetComponent<SpaceshipController> ().playerController.GetHashCode () == device.GetHashCode ())) {
SpawnPlayer (device);
}
} else {
SpawnPlayer (device);
}
}
}
/// <summary>
/// Spawns the player.
/// </summary>
/// <param name="playerController">The device that the player is using to play.</param>
void SpawnPlayer (InputDevice playerController) {
Debug.Log ("New player: " + playerController.GetHashCode ());
GameObject player = Instantiate (PlayerPrefab, Vector3.zero, Quaternion.identity) as GameObject;
player.GetComponent<SpaceshipController> ().playerController = playerController;
players.Add (player);
}
Got it!
Thank you so much. I had to delete the Ouya and Plugins folder then re-import. Some of my code was referencing an old file that had been deleted.
Specifically, OuyaInput.CalculateJoystickAngle, which I need to find an alternative to
Help?
For those that come after me: https://github.com/rendermat/OuyaInp...Input.cs#L2124
Last edited by Schizophretard; 09-22-2014 at 01:12 PM.
same thing happened to me. Glad you got it worked out.
"You can make a big impression or
Go through life unseen
You might wind up restricted and over seventeen
It's so hard to be careful, so easy to be lead
Somewhere beyond the pavement
You'll find the living dead
Dancin' at the Zombie Zoo..."
~Tom Petty
I am glad you worked out your issues Rocky. For future reference you can tweet, email , or even directly question Tim Graupmann, who handles the documentation on the github. If you do notice anything that is incorrect or outdated, let him know and he will fix it. You can submit questions directly to him weekly on the Monday Ouya Dev hours broadcast or contact him via the methods below.
Tim Graupmann
http://twitter.com/tgraupmann
tgraupmann@ouya.tv
"You can make a big impression or
Go through life unseen
You might wind up restricted and over seventeen
It's so hard to be careful, so easy to be lead
Somewhere beyond the pavement
You'll find the living dead
Dancin' at the Zombie Zoo..."
~Tom Petty
Bookmarks