Game Design

Game Logic

Once we have our random countdown time figured out, the game logic is very simple:

  1. Turn off all of the NeoPixels.
  2. Wait the determined countdown time.
  3. If a player presses a button during this time, they drew too soon (misdraw).
  4. Once countdown time has elapsed, turn on all of the NeoPixels.
  5. Look for the first (quickest) button press.
  6. Which ever button was pressed first is the Quick Draw winner.

Player Buttons

This is pretty straight forward. We've got two players, we've got two buttons. So we can assign them as shown in the figure below.

Countdown NeoPixels

This could be anything, but to keep it simple we'll just turn on all the NeoPixels to white when the countdown completes.

DRAW!

When all of the lights come on (all white), press your button as fast as you can.

Player NeoPixels

We can use the NeoPixels on the left to indicate Player 1's outcome, and the NeoPixels on the right to indicate Player 2's outcome. There are two possible outcomes: a misdraw if a player draws too soon, or a game with a winning outcome.

PLAYER 1 MISDRAW!

If all of the lights on the Player 1 side turn red, Player 1 misdrew (pressed the button too soon).

PLAYER 2 MISDRAW!

If all of the lights on the Player 2 side turn red, Player 2 misdrew (pressed the button too soon).

PLAYER 1 WON!

If all of the lights on the Player 1 side turn green, Player 1 was the quickest.

PLAYER 2 WON!

If all of the lights on the Player 2 side turn green, Player 2 was the quickest.

This guide was first published on Dec 29, 2016. It was last updated on Dec 29, 2016.
This page (Game Design) was last updated on Aug 14, 2020.