SlideShare uma empresa Scribd logo
1 de 17
OUYA for Unity3D Devs
What is OUYA?
• New games console
• Costs £99
• Tegra 3 Mobile Chipset
• Runs on Android
• Every device is a devkit
• Has its own app store (no Google Play)
Designed for TV
• HDMI Out
• HD resolutions:
– 1080p (1920 x 1080) default
– 720p (1280 x 720) also supported
Designed for TV
• Controller Input Scheme
– Some games are just not designed for a controller
– On Screen Buttons Behave Differently
– Consider Xbox 360 support
Designed for TV
• Overscan affects UI design
Free to Try
• All games must have a free part
– Up to developers how they do that
• All purchases use IAP
– No prices displayed on store
– Up to developers how they monetize
– But adverts are discouraged
• Not all monetization models will work
– Low install base (vs. mobile/PC)
– App prices higher on average
Let’s get Technical
1. Download ODK from ouya.tv
2. Install Drivers
– Windows/Mac/Linux Supported
– Works with ADB. Acts like any other Android device
1. Clone OUYA-Unity packages from github
– https://github.com/ouya/ouya-unity-plugin
Build Packages
4. Open OUYA-Unity git clone as a unity
project
5. Use “OUYA” menu to
export OUYA packages
6. Import OuyaSDK-Core to existing project
Android Settings
7. Edit > Project Settings > Player >
Android
8. Default Orientation > Landscape Left
9. Min API Level > Api 16 (Jellybean)
OUYA Panel
10.Window > Open OUYA Panel
11.Set Android SDK / NDK / JDK paths
12.Set package name & Sync Bundle IDs
13.Compile in reverse order : NDK > Plugin > Java >
Compile
14.Make sure OUYA is only android device connected
15.Build & Run Pro only. Otherwise, File > Build Settings >
Switch to Android
Most Important
• Only 1 OuyaGameObject per game/app
• Must be in first scene
• Accessed statically from other scenes
Input Handling
public class ouyaInputExample : MonoBehaviour {
void Awake(){
OuyaInputManager.OuyaButtonEvent.addButtonEventListener(HandleButtonEvent);
}
void OnDestroy(){
OuyaInputManager.OuyaButtonEvent.removeButtonEventListener(HandleButtonEvent);
}
private bool isDown = false;
public string nextScene = "ouyagametest";
private void HandleButtonEvent(OuyaSDK.OuyaPlayer p, OuyaSDK.KeyEnum b,
OuyaSDK.InputAction bs){
if(b==OuyaSDK.KeyEnum.BUTTON_U){
if(bs==OuyaSDK.InputAction.KeyUp){
if(isDown){
// button released
isDown = false;
GameObject.Find("text1").guiText.text = “U up";
// Application.LoadLevel(nextScene);
}
} else if(bs==OuyaSDK.InputAction.KeyDown){
if(!isDown){
// button pressed down
isDown = true;
GameObject.Find("text1").guiText.text = “U down";
} } } } }
Get Axis Input
public class ouyaGetAxisValues : MonoBehaviour {
public GUIText text4;
public GUIText text3;
private float mSensitivity = 0.005f;
void Update () {
float LS_X = OuyaInputManager.GetAxis("LX",OuyaSDK.OuyaPlayer.player1);
float LS_Y = OuyaInputManager.GetAxis("LY",OuyaSDK.OuyaPlayer.player1);
float stickMagf = stickMag(LS_X,LS_Y);
if(!isStickCentred(stickMagf)){
float speed = stickMagf * mSensitivity;
text4.transform.Translate(LS_X*speed,LS_Y*speed,0);
}
text3.text = "LS_X:" + LS_X.ToString() + " LS_Y:" + LS_Y.ToString();
}
private float stickMag(float axisX, float axisY) {
float stickMagf = (float) Mathf.Sqrt(axisX * axisX + axisY * axisY);
return stickMagf;
}
private float c_minStickDistance = 0.35f;
private bool isStickCentred(float stickMagf) {
return !(stickMagf >= c_minStickDistance);
}
}
If All Else Fails
Copy/Paste The Example App
1. Create new project
2. Import Package > Custom Package >
OuyaSDK-Examples
3. OUYAPanel > Build Settings >
SceneShowUnityInput > Switch to Example
4. Scene Hierarchy > OuyaShowUnityInput.cs
End
• Dedicated OUYA-Unity team:
– Tim Graupmann @tgraupmann
• Google Hangouts Every Week
• Lots of youtube videos
• Active Community
End
Main forums:
• http://forums.ouya.tv/categories/unity-on-ouya
Docs:
• https://github.com/ouya/docs
General Android Primer:
• http://gamedev.tutsplus.com/articles/how-to-
learn/how-to-learn-ouya-gamedev/
Performance
• Roughly equivalent to Nexus 7
• Drawcalls kill performance
– Texture Atlassing
– BEAST Lightmapping
• Mobile Unlit Shaders
• Consider manual culling
• If desperate, use 720p
http://forums.ouya.tv/discussion/comment/12291/
http://forums.ouya.tv/discussion/1520/making-3d-games-performant-on-ouya/p1

Mais conteúdo relacionado

Último

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 

Último (20)

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 

Destaque

Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellSaba Software
 

Destaque (20)

Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
 

Introduction to Ouya for unity3D Developers

  • 2. What is OUYA? • New games console • Costs £99 • Tegra 3 Mobile Chipset • Runs on Android • Every device is a devkit • Has its own app store (no Google Play)
  • 3. Designed for TV • HDMI Out • HD resolutions: – 1080p (1920 x 1080) default – 720p (1280 x 720) also supported
  • 4. Designed for TV • Controller Input Scheme – Some games are just not designed for a controller – On Screen Buttons Behave Differently – Consider Xbox 360 support
  • 5. Designed for TV • Overscan affects UI design
  • 6. Free to Try • All games must have a free part – Up to developers how they do that • All purchases use IAP – No prices displayed on store – Up to developers how they monetize – But adverts are discouraged • Not all monetization models will work – Low install base (vs. mobile/PC) – App prices higher on average
  • 7. Let’s get Technical 1. Download ODK from ouya.tv 2. Install Drivers – Windows/Mac/Linux Supported – Works with ADB. Acts like any other Android device 1. Clone OUYA-Unity packages from github – https://github.com/ouya/ouya-unity-plugin
  • 8. Build Packages 4. Open OUYA-Unity git clone as a unity project 5. Use “OUYA” menu to export OUYA packages 6. Import OuyaSDK-Core to existing project
  • 9. Android Settings 7. Edit > Project Settings > Player > Android 8. Default Orientation > Landscape Left 9. Min API Level > Api 16 (Jellybean)
  • 10. OUYA Panel 10.Window > Open OUYA Panel 11.Set Android SDK / NDK / JDK paths 12.Set package name & Sync Bundle IDs 13.Compile in reverse order : NDK > Plugin > Java > Compile 14.Make sure OUYA is only android device connected 15.Build & Run Pro only. Otherwise, File > Build Settings > Switch to Android
  • 11. Most Important • Only 1 OuyaGameObject per game/app • Must be in first scene • Accessed statically from other scenes
  • 12. Input Handling public class ouyaInputExample : MonoBehaviour { void Awake(){ OuyaInputManager.OuyaButtonEvent.addButtonEventListener(HandleButtonEvent); } void OnDestroy(){ OuyaInputManager.OuyaButtonEvent.removeButtonEventListener(HandleButtonEvent); } private bool isDown = false; public string nextScene = "ouyagametest"; private void HandleButtonEvent(OuyaSDK.OuyaPlayer p, OuyaSDK.KeyEnum b, OuyaSDK.InputAction bs){ if(b==OuyaSDK.KeyEnum.BUTTON_U){ if(bs==OuyaSDK.InputAction.KeyUp){ if(isDown){ // button released isDown = false; GameObject.Find("text1").guiText.text = “U up"; // Application.LoadLevel(nextScene); } } else if(bs==OuyaSDK.InputAction.KeyDown){ if(!isDown){ // button pressed down isDown = true; GameObject.Find("text1").guiText.text = “U down"; } } } } }
  • 13. Get Axis Input public class ouyaGetAxisValues : MonoBehaviour { public GUIText text4; public GUIText text3; private float mSensitivity = 0.005f; void Update () { float LS_X = OuyaInputManager.GetAxis("LX",OuyaSDK.OuyaPlayer.player1); float LS_Y = OuyaInputManager.GetAxis("LY",OuyaSDK.OuyaPlayer.player1); float stickMagf = stickMag(LS_X,LS_Y); if(!isStickCentred(stickMagf)){ float speed = stickMagf * mSensitivity; text4.transform.Translate(LS_X*speed,LS_Y*speed,0); } text3.text = "LS_X:" + LS_X.ToString() + " LS_Y:" + LS_Y.ToString(); } private float stickMag(float axisX, float axisY) { float stickMagf = (float) Mathf.Sqrt(axisX * axisX + axisY * axisY); return stickMagf; } private float c_minStickDistance = 0.35f; private bool isStickCentred(float stickMagf) { return !(stickMagf >= c_minStickDistance); } }
  • 14. If All Else Fails Copy/Paste The Example App 1. Create new project 2. Import Package > Custom Package > OuyaSDK-Examples 3. OUYAPanel > Build Settings > SceneShowUnityInput > Switch to Example 4. Scene Hierarchy > OuyaShowUnityInput.cs
  • 15. End • Dedicated OUYA-Unity team: – Tim Graupmann @tgraupmann • Google Hangouts Every Week • Lots of youtube videos • Active Community
  • 16. End Main forums: • http://forums.ouya.tv/categories/unity-on-ouya Docs: • https://github.com/ouya/docs General Android Primer: • http://gamedev.tutsplus.com/articles/how-to- learn/how-to-learn-ouya-gamedev/
  • 17. Performance • Roughly equivalent to Nexus 7 • Drawcalls kill performance – Texture Atlassing – BEAST Lightmapping • Mobile Unlit Shaders • Consider manual culling • If desperate, use 720p http://forums.ouya.tv/discussion/comment/12291/ http://forums.ouya.tv/discussion/1520/making-3d-games-performant-on-ouya/p1