windows web xbox mobile … and more! @shahedc wakeupandcode.com

42
By Shahed Chowdhuri Senior Technical Evangelist Game Development with Unity 5 and C# Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Upload: alison-stewart

Post on 29-Dec-2015

217 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

By Shahed ChowdhuriSenior Technical Evangelist

Game Development with Unity 5 and C#Windows Web Xbox Mobile … and more!

@shahedC

WakeUpAndCode.com

Page 2: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Agenda

Introduction

> Getting Started> Choosing a Code Editor> Getting Started with 3D Objects> Adding Scripts, Movement, Input

3D & 2D Demos

Page 3: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Tools & Technologies

Page 4: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Unity: Things to Know

• Learning curve• Create/Import models• Download/purchase models• Asset Store• Publish virtually anywhere!

Page 5: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Personal vs Pro

Page 6: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Agenda

Introduction

> Getting Started> Choosing a Code Editor> Getting Started with 3D Objects> Adding Scripts, Movement, Input

3D & 2D Demos

Page 7: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Getting Started

Page 8: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Launching Unity 5

Pick from Recent Projects, click Open Other, or New Project

Page 9: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

New Project

Name your project, choose 3D/2D, then save it

Page 10: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Unity Game Editor

Page 11: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Choosing a Code Editor

Page 12: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Assign Code Editor

Click Edit PreferencesUnder External Tools, select your Script Editore.g. MonoDevelop or Visual Studio

Tip: Browse for devenv.exe in your Program Files folder if you don’t see Visual Studio"C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe"

Page 13: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Code Editor UI

Editing a Script should launch MonoDevelop or Visual Studio, etc

Page 14: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Getting Started with 3D Objects

Page 15: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Creating Simple 3D Objects

Page 16: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding More 3D Objects

Page 17: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Resetting Objects to Origin (0,0,0)

Page 18: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Changing Position, Rotation, Scale

Page 19: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Creating Materials

Page 20: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Setting Material Properties

Page 21: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Lights

Page 22: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Save Current Scene

• Click File Save Scene• Create “Scenes” folder under Assets• Save scene as .unity file

Page 23: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Scripts, Movement, Input

Page 24: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Scripts to an Object

Page 25: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Create and Add a New Script

Page 26: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Launch Script File

Page 27: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Edit Script Code

Page 28: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Add Components, e.g. RigidBody

Page 29: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Movement Using Inputs

Page 30: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Colliders with Triggers

Page 31: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Adding Tags for Objects

Page 32: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Detecting Collisions

Page 33: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Agenda

Introduction

> Getting Started> Choosing a Code Editor> Getting Started with 3D Objects> Adding Scripts, Movement, Input

3D & 2D Demos

Page 34: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Demos

Page 35: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Demo: Roll-a-ball

Page 36: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Demo: First Person Game

Page 37: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Demo: 2D Game Example

Page 38: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

Agenda

Introduction

> Getting Started> Choosing a Code Editor> Getting Started with 3D Objects> Adding Scripts, Movement, Input

3D & 2D Demos

Page 40: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

• RigidBody Component needs to be retrieved via GetComponent first (Unity 5 auto-fixes this)

• GUIText is a component, not a separate GameObject (video mentions this in popup text)

Roll-a-ball Tutorial Corrections

Page 41: Windows Web Xbox Mobile … and more! @shahedC WakeUpAndCode.com

For More Info:• Unity Indie Devs:

• http://facebook.com/groups/UnityIndieDevs • http://WakeUpAndCode.com/unity

• Xbox One Indie Devs:• http://facebook.com/groups/XboxOneIndieDevs• http://WakeUpAndCode.com/xb1