Reader small image

You're reading from  Ouya Unity Game Development

Product typeBook
Published inOct 2013
Reading LevelIntermediate
PublisherPackt
ISBN-139781783559701
Edition1st Edition
Languages
Tools
Right arrow
Author (1)
Gary Riches
Gary Riches
author image
Gary Riches

Gary Riches is a longstanding member of the iOS developer community. He has a keen interest not only in established sections of the industry such as gaming but also in emerging technologies such as Ouya, GameStick, and others. Filled with a passion to program on new systems, he has just become a registered Wii U developer and will also create content for Xbox One and PlayStation 4. To target so many platforms he uses Unity, which he learned while working on the Augmented Reality SBook for Saddington Baynes. When not building software for other companies, he builds his own business by creating photo manipulation apps such as Zombify Me, games such as Aztec Antics and Amazed, and also works on educational apps and games such as Nursery Rhymes: Volume 1, 2, and 3.
Read more about Gary Riches

Right arrow

Adding a background


There is still a lot of black in the background and as the game has a space theme, let's add some stars in there. The way we'll do this is to add a sphere that we can map the stars texture to, so click on Game Object | Create Other | Sphere, and position it at X: 0, Y: 0, Z: 0. We also need to set the size to X: 100, Y: 100, Z: 100. Drag the stars texture, located at Textures/stars, on to the new sphere that we created in our scene. That was simple, wasn't that? Unity has added the texture to a material that appears on the outside of our sphere while we need it to show on the inside. To fix it, we are going to reverse the triangle order, flip the normal map, and flip the UV map with C# code. Right-click on the Scripts folder and then click on Create and select C# Script. Once you click on it, a script will appear in the Scripts folder; it should already have focus and be asking you to type a name for the script, call it SkyDome. Double-click on the script in Unity and...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Ouya Unity Game Development
Published in: Oct 2013Publisher: PacktISBN-13: 9781783559701

Author (1)

author image
Gary Riches

Gary Riches is a longstanding member of the iOS developer community. He has a keen interest not only in established sections of the industry such as gaming but also in emerging technologies such as Ouya, GameStick, and others. Filled with a passion to program on new systems, he has just become a registered Wii U developer and will also create content for Xbox One and PlayStation 4. To target so many platforms he uses Unity, which he learned while working on the Augmented Reality SBook for Saddington Baynes. When not building software for other companies, he builds his own business by creating photo manipulation apps such as Zombify Me, games such as Aztec Antics and Amazed, and also works on educational apps and games such as Nursery Rhymes: Volume 1, 2, and 3.
Read more about Gary Riches