Make Games with JavaScript glossary
24 terms you will meet in the free Make Games with JavaScript course, each explained in one or two sentences.
A
- Array
- An ordered list of values, accessed by index starting at 0.
B
- Boolean
- A value that is either true or false, used for yes-or-no game state such as isGameOver.
- Bounding box
- The invisible rectangle around an object used for simple collision checks.
- Bug
- A mistake in code that makes the program behave differently than intended.
C
- Canvas
- An HTML element that gives JavaScript a rectangle of pixels to draw on.
- Collision detection
- Checking whether two game objects overlap.
- Condition
- An expression that is true or false and decides whether an if block runs.
- const
- A JavaScript keyword that creates a variable that cannot be reassigned.
- Coordinate
- A position given by x (pixels from the left) and y (pixels from the top) on the canvas.
E
- Event listener
- Code that waits for an event such as a key press and runs a function when it happens.
F
- Frame
- One single picture drawn by the game loop; many frames per second create motion.
- Function
- A named, reusable block of code that can take inputs (parameters) and return a result.
G
- Game loop
- The cycle of updating the game state and redrawing the screen many times per second.
- Game state
- All the values that describe the game at a moment, such as positions, score and whether it's over.
L
- let
- A JavaScript keyword that creates a variable whose value can change later.
- Loop
- Code that repeats, such as a for loop that runs once for each enemy.
M
- Math.random
- A JavaScript function that returns a random decimal from 0 up to, but not including, 1.
O
- Object
- A group of named properties, such as a player with x, y and speed.
P
- Parameter
- A named input listed in a function definition.
- Property
- A named value stored in an object, read with dot notation like player.x.
R
- requestAnimationFrame
- A browser function that runs your drawing code right before the next screen refresh.
- Return value
- The result a function sends back to the code that called it.
V
- Variable
- A named box that stores a value, such as a score, that the program can read and change.
- Velocity
- How many pixels an object moves per frame (or per second) in a given direction.
Put these terms to work
The Make Games with JavaScript course uses every one of these terms in short lessons with instant-feedback questions. It takes about 120 minutes and ends with a free certificate of completion.
Start the course Course overview