WorksheetsGame Lab review
Total questions: 31
Worksheet time: 11mins
This block of code draws a circle on the grid.
rect ();
ellipse ();
fill ();
background ();
This block of code draws a square on the grid.
rect ();
ellipse ();
fill ();
background ();
What is NOT one of the parameters for the block of code rect(_, _, _, _);
X
Y
Width
Height
Radius
You can name your variables in Game Lab
True
False
This is NOT one of the rules for naming variables in Game Lab
must start with a capital letter
cannot start with a number
cannot contain spaces
you can use camelcase
Variables can be used multiple times in Game Lab
True
False
A character on the screen with properties that describe its location, movement, and look.
Property
Sprite
Variable
Dot notation
A label for a characteristic of a sprite, such as its location and appearance.
Property
Sprite
Variable
Dot notation
he way that sprites' properties are used in Game Lab, by connecting the sprite and property with a dot.
Property
Sprite
Variable
Dot notation
This block of code displays the value of the variable health.
text("health", 100, 200);
text(health, 100, 200);
This block of code displays the word health on the grid.
text("health", 100, 200);
text(health, 100, 200);
The lines of code contained inside this block of code are continuously executed until the program is stopped.
World.frameRate
function draw (){}
randomNumber();
drawSprites ();
Block of code that behaves the same way as the following lines of code:
sprite.x=sprite.x+1;
VelocityX=1;
VelocityY = 1;
rotationSpeed = 1;
Block of code that behaves the same way as the following lines of code:
sprite.rotation=sprite.rotation +1;
VelocityX=1;
VelocityY = 1;
rotationSpeed = 1;
in programming, an expression that evaluates to True or False.
Boolean expression
Condition
Conditionals
Something a program checks to see whether it is true before deciding to take an action.
Boolean expression
Condition
Conditionals
Statements that only run when certain conditions are true.
Boolean expression
Condition
Conditionals
Executes a block of statements if the specified condition is true.
if () {}
function draw () {}
var sprite
keyDown
a simplified representation of something more complex.
if statement
Abstraction
Condition
Debug
Checks if the sprite is touching the target sprite or any sprite in the target group.
sprite.debug=();
sprite.collider=();
sprite.isTouching ();
Part of a program that does not work correctly.
Bug
Mistake
Debug
Program
Finding and Fixing problems in an algorithm or program
Bug
Mistake
Debug
Program
An algorithm that has been coded into something that can be run by a machine
Bug
Mistake
Debug
Program
A label for a piece of information used in a program
Parameter
Variable
An extra piece of information passed to a function to customize it for a specific need
Parameter
Variable
Less than operation
_ < _
_ > _
_ -_
_ + _
Greater than operation
_ < _
_ > _
_ -_
_ + _
Checks if the key specified is pressed.
keyDown()
keyWentDown
keyWentUp()
Checks if the key specified was pressed.
keyDown()
keyWentDown
keyWentUp()
Lines of code that move the fish to the left once the fish gets to the right-hand side of the screen
if (fish.x > 400) { fish.velocityX = -2; }
if (fish.x <0 ) { fish.velocityX = 2; }
Lines of code that move the fish to the right once the fish gets to the left-hand side of the screen
if (fish.x > 400) { fish.velocityX = -2; }
if (fish.x <0 ) { fish.velocityX = 2; }
