Professional Documents
Culture Documents
Concepts To Learn: Lecture 3: Developing Our First Game - Roller Madness
Concepts To Learn: Lecture 3: Developing Our First Game - Roller Madness
Concepts to learn
• Asset Pipeline
• Standard Assets and Assets Packages
• More Editors Features
• Project Organization
Lecture 3: Developing our first game – Roller • Physics
Madness
1
2/22/2016
2
2/22/2016
3
2/22/2016
4
2/22/2016
5
2/22/2016
Pickups Pickups
• Go to prototyping standard assets • Now we can add some points for coin
▫ Select models – PickupPrototyping 01 *01 * 01 ▫ Add Treasure script
▫ Drag it to scene and name it coin • You can see that Rollerball has a Tag of Player
▫ Position (0,1,0) scale (.4,.4,.4) ▫ A Tag is a word which you link to one or more GameObjects.
▫ Change material to something like yellow (Note : you
can make new material ) • Lets make a new tag (pickup) and attached this tag to
▫ Add a new component from physics- Sphere collider coin
▫ Make it a rigid body (is kinematic with no gravity) • Make coin a prefab as we want multiple copies of it
▫ Add from scripts the Rotate script • Through some coins in the scene
Speed (180)
6
2/22/2016
UI Basics UI Basics
• Under the hierarchy select UI – Text • For the game over Under the hierarchy select UI –
• In Canvas Scalar Script attached (Canvas) Text
▫ Make it scale with Screen Size • In Canvas Scalar Script attached (Canvas)
• Now select the text as we want it at the top Press F and ▫ Make it scale with Screen Size
also go in to 2D mode • Copy values from the Score text to GameOver Text
• From the Anchor Presets Select Top ▫ It should be in the middle
• From the Text you can write text and can change fonts ▫ Font should be 100 (a little big)
• From the Paragraph ▫ Set it in middle
▫ Select overflow from both Horizontal and Vertical
▫ Select font color to EEFFFB9B
7
2/22/2016
Enemies Enemies
• Create a new 3D object cube and place it to origin (0,1,0) • We need to add a script Damage
• Create a new material for the enemy name it enemy ▫ Select damage on collision
material • Add script of Health therefore it also dies
▫ Change it to orange albedo • Make enemy a prefab
▫ Apply it to enemy object
▫ Add two more enemies
• Add Script Chaser
▫ select speed to 4 and distance 0 and target RollerBall
• Make it away from the player
• Make it rigid body
• Box Collider physical material should be bouncy
8
2/22/2016
Questions