Vectors & chance
At least once: 1 − (chance of missing)ⁿ. A 2% drop misses 0.98 of the time. Expected value = add up chance × value. ms per frame = 1,000 ÷ fps.
Loot boxes are built around chance. The odds never “owe” you. Set a budget with an adult before you buy, and never chase losses.
One step
Vectors, frames and pixels.Move it
A player at (200, 150) moves by (8, −6) in one frame. Where is it now, and how long is the vector?
Frame time
How many milliseconds per frame at 90 fps? At 30 fps?
Loot weights
A loot table has weights 120, 60, 18 and 2. What percent chance does each have?
Pixels
How many pixels are on a 2560 × 1440 screen? How many times as many as 1080p (2,073,600)?
Two or three steps
Write the probability or formula first.At least once
A rare drop has a 2% chance. What is the chance of getting it at least once in 50 tries? Round to a whole percent.
Fifty-fifty
For the same 2% drop, how many tries until you reach a 50% chance? Test n = 34 and n = 35.
Is the box worth it?
A box costs 75 coins: 60% common (10), 30% rare (50), 9% epic (200), 1% legendary (2,000). Find its expected value. Who wins on average?
DPS
A weapon does 60 damage, 2 hits a second, with a 20% chance to crit for double. Find its average DPS. How long does a 1,800 HP boss last?
Armour
Use damage = attack × 100 ÷ (100 + armour) (p.12). A 150 attack hits armour 50, then armour 200. Find both.
Gem maths
A bundle is 1,200 gems for $11.99. What is the dollar price of a 900-gem item? Two items need how many bundles, and how many gems are left over?
Equations
Lines and jump arcs (pp.17–18).Runner
A runner starts at x = 60 and moves 250 px a second: x = 60 + 250t. When does it reach a door at x = 1,060?
The chase
An enemy starts at x = 760 and runs the same way at 150 px/s. When, and where, does the runner catch it?
Jump arc
A jump has height h = 10f − 0.25f² after f frames. Find the height at f = 20 and when the player lands.
Clear the ledge
When is the player 64 px up? Solve 10f − 0.25f² = 64. Why are there two answers?
Your turn to be the game designer
- Invent a mechanic: a drop, a jump, a weapon, a shop.
- Write a question that uses a vector, a probability or an equation.
- Solve it, then ask: is it fair to the player?
My problem, and my worked answer:
Try every problem first, then check here. Wrong answers are useful: find the step where your work and the key split apart.
The key never prints with Print my work or Print blank. Open it to get its own Print the answer key button.
Answer key
Worked solutions. Odds and prices are examples, not from a real game. Need to talk? Kids Help Phone: 1-800-668-6868.