I have looked through the scripts in the first person controller from the standed assets but can’t find where it says what keys do what I need to get it to work with the Ouya’s analoge sticks. docs for the Ouya’s controller can be found here if it helps https://devs.ouya.tv/developers/docs/controllers
You are missing the point.
- All the types of input are handled with the Input Manager : Unity - Manual: Input
- You set up axis and button inputs for each controller : Joystick Buttons (from a specific joystick): “joystick 1 button 0”, “joystick 1 button 1”, “joystick 2 button 0”, …
- you build a test project, to check if the inputs are working : eg http://www.alucardj.net16.net/JoystickTest/JoystickTest.html
For example :
Input Manager Settings :
Script :
function TriggerInputs()
{
var offset : float = 1.5;
// - Triggers -
if ( Input.GetAxis( "Left Trigger" ) > 0.02 )
{
leftTrigger.position.y = leftTriggerStartPos.y + ( offset * Input.GetAxis( "Left Trigger" ) );
SetRendererColour( leftTrigger.renderer, selectedColour );
}
else
{
leftTrigger.position.y = leftTriggerStartPos.y;
SetRendererColour( leftTrigger.renderer, defaultColour );
}
if ( Input.GetAxis( "Right Trigger" ) > 0.02 )
{
rightTrigger.position.y = rightTriggerStartPos.y + ( offset * Input.GetAxis( "Right Trigger" ) );
SetRendererColour( rightTrigger.renderer, selectedColour );
}
else
{
rightTrigger.position.y = rightTriggerStartPos.y;
SetRendererColour( rightTrigger.renderer, defaultColour );
}
}
function BumperInputs()
{
// - Left Bumper -
if ( Input.GetButton( "Left Bumper" ) )
{
SetRendererColour( leftBumper, selectedColour );
}
else
{
SetRendererColour( leftBumper, defaultColour );
}
// - Right Bumper -
if ( Input.GetButton( "Right Bumper" ) )
{
SetRendererColour( rightBumper, selectedColour );
}
else
{
SetRendererColour( rightBumper, defaultColour );
}
}
By the way, don’t use my inputs, for the OUYA you’ll need to setup an input for each joystick , eg :
joystick 1 button 5
joystick 3 button 1
etc etc