Create with Code Prototype 2 Quiz

Create with Code Prototype 2 Quiz

9th - 12th Grade

10 Qs

quiz-placeholder

Similar activities

quiz java job 1-3

quiz java job 1-3

11th Grade

10 Qs

Embed System#3

Embed System#3

10th - 12th Grade

10 Qs

Mid semester kelas XI RPL Konsep pemodelan berorientasi objek

Mid semester kelas XI RPL Konsep pemodelan berorientasi objek

11th Grade

10 Qs

ICT Unit Test Topic : DBMS - Access

ICT Unit Test Topic : DBMS - Access

8th - 12th Grade

15 Qs

Pemrograman Web dan Perangkat Bergerak #1

Pemrograman Web dan Perangkat Bergerak #1

11th Grade

15 Qs

Internal Hardware: CPU

Internal Hardware: CPU

9th Grade

10 Qs

Cell Phone Vocabulary

Cell Phone Vocabulary

9th - 12th Grade

12 Qs

STM BTEC DIT 3- 5. Maintenance, set-up, performance p152

STM BTEC DIT 3- 5. Maintenance, set-up, performance p152

9th - 11th Grade

10 Qs

Create with Code Prototype 2 Quiz

Create with Code Prototype 2 Quiz

Assessment

Quiz

Computers

9th - 12th Grade

Hard

Created by

Neil Boyle

Used 42+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If it says, “Hello there!” in the console, what was the code used to create that message?

Debug(“Hello there!”);

Debug.Log("Hello there!");

Debug.Console(“Hello there!”);

Debug.Log(Hello there!);

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

If you want to destroy an object when its health reaches 0, what code would be best in the blank below?

health > 0

health.0

health < 1

health < 0

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

The code below creates an error that says, “error CS1503: Argument 1: cannot convert from 'UnityEngine.GameObject[]' to 'UnityEngine.Object'”. What could you do to remove the errors?

A. On line 1, change “GameObject[]” to “GameObject”

B. On line 1, change “enemyPrefabs” to “enemyPrefabs[0]”

C. On line 3, change “Start()” to “Update()”

D. On line 5, change “enemyPrefabs” to “enemyPrefabs[0]”

Either A or D

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Which comment best describes the following code?

// If player collides with another object, destroy player

// If enemy collides with another object, destroy the object

// If player collides with a trigger, destroy trigger

// If player collides with another object, destroy the object

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

If you want to move the character up continuously as the player presses the up arrow, what code would be best in the two blanks below:

GetKey(KeyCode.UpArrow)

GetKeyDown(UpArrow)

GetKeyUp(KeyCode.Up)

GetKeyHeld(Vector3.Up)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Read the documentation from the Unity Scripting API and the code below. Which of the following are possible values for the randomFloat and randomInt variables?

randomFloat = 100.0f; randomInt = 0;

randomFloat = 100.0f; randomInt = 100;

randomFloat = 50.5f; randomInt = 100;

randomFloat = 0.0f; randomInt = 50.5;

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

You are trying to randomly spawn objects from an array. However, when your game is running, you see in the console that there was an “error at Assets/Scripts/SpawnManager.cs:5. IndexOutOfRangeException: Index was outside the bounds of the array.” Which line of code should you edit in order to resolve this problem and still retain the random object functionality?

Line 2

Line 3

Line 5

Line 4

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?