The Gate Escape
7-01
7-01
Set up time: about 1 hour 15 minutes
Game pieces included:
Task locations- house, water pump, garden, tool shed, junk yard, and library. Built with card stock paper. Only scissors were used to cut out pieces. Scotch tape holds them together.
Gate attached to motor wheel/case. Gate built with card stock and everything else with cardboard. The gate door and the motor disk are attached with string. Scissors and an Exacto knife were used to cut out these pieces. Staples, tape, and paper clips hold them together.
Player pieces- calculator, salt and pepper packets, cup noodles, ghost, monster energy drink, bunny, goldfish, hand sanitizer, among us character, dog, and the Northeastern ‘N.’ (Printing all eleven pieces is not necessary for gameplay)
If you are playing this game remotely or in person, you only need to make one board, one set of task locations, one gate, one game piece per player, and one arduino set up. When playing on zoom, players will see the copy of the board on the camera and can communicate where they are moving their pieces. However, if you would like to, it is possible to play that game remotely where all players have their own board, game pieces, arduino set up, etc, but this is not necessary.
Game play time: about 20 minutes
Recommended number of players: 3-9
The central goal of this game is different depending on your role: the hunter or the hunted. The hunter wins by defeating all of the other players before they can escape, and the hunted win by completing tasks to unlock the gate and escaping.
The players are divided into two main roles: the escapees and the hunter. There is only one hunter who is randomly assigned by the computer. If there are more than 7 players, there will be two hunters. The hunter’s goal is to eliminate all players. The main objective for the players is to escape through a gate without getting eliminated by the hunter. In order to escape, players have to complete tasks at locations indicated by game pieces located around the board. The task locations are randomized using a C++ code.
To Start:
Decide which player is player 1, player 2, player 3, etc. Run the C++ code. The program will ask you to enter the number of players. Once this is done, the program will randomly assign the role of the hunter(s) to one or more players, depending on the number of players. Then the program will tell the players and the hunters where their game pieces will start. The players can choose any blue space, and the hunter(s) will be assigned red spaces to start on. Finally, the program will give an index number for each task location. Place the task locations on the board so that at least one square is on the number that was given by the program. The gate should be placed off the board behind the middle red square.
Movement:
The players roll to move first, then the hunter rolls to move, with the roll corresponding to the number of spaces the player or hunter has to move. The hunter may move up to the number of spaces indicated by their roll, and they cannot move to a space they have already visited in their turn. The player either has to move the exact number of spaces they rolled or may choose to stay where they are. The players also may not move to a space they have already visited in their turn. To roll, the red (top) button on the Arduino board is pressed and the number of spaces the player should move is displayed on the LCD screen also on the Arduino board.
Tasks:
Once a player completes a task at a task location no other players need to complete a task at that particular location, so this means that the non hunter players work together to complete all six tasks. To enter a task location with a door a player must enter through the door and to enter a task location with an open roof the player can enter through any space where the roof is open. Completing any task causes the player to lose their next turn leaving them vulnerable to the hunter who can also enter task locations. In order to complete a task, once the non-hunter enters the task location, they must spend one whole turn within the task location. After that turn, the player is free to move and that task has been completed.
Hunter-player interactions and eliminations:
When a player and the hunter meet or when they occupy the same space, both hunter and player roll dice. The player always rolls a six sided die (top button), but the hunter(s)' dice roll varies on each encounter with a specific player. To eliminate the player, the hunter has to have a higher roll than the player. If there is a tie, the player is not eliminated.
Hunter dice rolls by encounter:
First encounter: Hunter rolls 1-6 by pressing the red (top) button.
Second encounter: Hunter rolls 1-12 by pressing the blue (bottom) button.
Third encounter: The hunter automatically kills that player.
What to do once tasks are complete (how to escape):
Once all tasks are completed the gate is opened by a servo motor and all remaining players must make their way towards the gate to escape. The potentiometer on the Arduino board is used to operate the servo motor. During this time players can still be eliminated by the hunter, but the hunter cannot occupy the space directly in front of the gate. Once the player has made it through the gate they have individually won. If the hunter eliminates all players before they can escape then the hunter wins.
To assemble the game board, use the diagram provided as a guide. Cut the 12 inch by 12 inch board out of cardboard and draw 1 inch by 1 inch squares across the entire board. You may have to tape two pieces of cardboard together for the board. The blue colored squares are where the players can start. The center red squares are where the gate sits, and the other red spaces are where the hunter can start. The center 10 by 8 grid should be numbered, as these numbers will be used by the C++ program to randomize the positions of the task locations.
Using the diagrams above and a ruler draw the task location and gate layout on card stock paper. Measurements were done in inches. Cut out the layouts with scissors or an Exacto knife and fold the sides up and the top parts towards each other. Scotch tape was used on the inside of the tasks and gate to hold the sides and top parts together. The pump and the library have unsecured, open tops even though there is a top part. The task locations and gate can be decorated however the assembler wishes but each piece has a name so if the piece is decorated it should be decorated according to its name. The motor case and disk should be made of cardboard using the templates above and cut out using scissors and an Exacto knife. String should be used to tie the gate door and the motor disk together through holes as shown in the template and cut out using an Exacto knife. The cardboard pieces are held together by tape, paperclips, and staples as indicated by the pictures above. The servo motor propeller is slid through the small cut outs made on one of the disk pieces and can be taken out if needed. The servo motor wires go under the bottom of the motor case and the overhanging “tabs” on the servo motor should extend over the cardboard case. (For larger pictures of the task locations and diagrams see the link at the bottom of the page).
If setting up the three dimensional task locations is taking too long then two dimensional pieces can be made with either regular computer paper, cardstock, or cardboard. The material doesn’t matter as much for these pieces since the two dimensional task locations will not have to stand up or be folded. The task locations that have doors in their three dimensional versions have marks on one side of their two dimensional versions where the doors would have been to indicate what side the player must enter through.
Printouts for these 2D task locations are available at the bottom of the page.
There are eleven game pieces that were designed for this game. If there are less than eleven players, it is not necessary to assemble every single game piece, just the pieces that the players want to use. Print out the game pieces attached at the end of the page and cut out the pieces. An x-acto knife is best for cutting out the game pieces. For the bases of the pieces, slits (which are included in the diagram) need to be cut into the two base pieces, and the slits will overlap so the base pieces form an ‘X.’
// Include servo library
#include <Servo.h>
// Include library for LCD
#include <LiquidCrystal.h>
//Declare and initialize variables
int potPosition;
int servoPosition;
int count = 0;
int button1PIN = 2;
int button2PIN = 3;
int randomRED = 0;
int randomBLUE = 0;
int randomGREEN = 0;
// Create servo object
Servo myservo;
//Set pins for LCD
LiquidCrystal lcd(13, 12, 11, 10, 9, 8);
void setup() {
// Servo is attached to pin 0
myservo.attach(0);
//Pins where the LCD begins
lcd.begin(16, 2);
// Clear the LCD screen
lcd.clear();
//Set pin modes
pinMode (button1PIN,INPUT_PULLUP);
pinMode (button2PIN,INPUT_PULLUP);
}
void loop() {
// If the red button is pressed, print a random number from 1-6
if (digitalRead(button1PIN) == LOW) {
randomRED = random(1, 7);
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Your roll is: ");
lcd.print (randomRED);
Serial.print(randomRED);
}
// Else if the blue button is pressed, print a random number from 1-12
else if (digitalRead(button2PIN) == LOW) {
randomBLUE = random(1,13);
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Your roll is: ");
lcd.print(randomBLUE);
Serial.print(randomBLUE);
}
// Measure position of potentiometer from 0-1023
potPosition = analogRead(A0);
// Convert potentiometer position to a servo position from 20-160
servoPosition = map(potPosition, 0,1023,20,160);
// Moves the servo
myservo.write(servoPosition);
}
Button 1- e1,f1,e3,f3
Button 2 - e4,f4,e6,f6
Button 3- e7,f7,e9,f9
Potentiometer - f22,f23,f24
Micro Servo Motor- power to +, signal to Pin 0, ground to -
LCD- ground a15, LED cathode a30
Breadboard wires- j3 to -, j6 to -, j9 to -, b15 to -, b16 to +, b17 to i23, b19 to -, h22 to -, h24 to +, b29, to +, b30 to -
Breadboard and Arduino Uno wires- j1 to GND2, j4 to GND3, j7 to GND4, b18 to GND13, + to 5v, - to GND, b20 to GND12, j23 to A0, b25 to GND11, b26 to GND10, b27 to GND9, b28 to GND8
#include <iostream>
#include <time.h>
using namespace std;
int randomNum();
int randomNum2();
int checkIndex(int I1, int I2, int I3, int I4);
void chooseSpace();
int main () {
srand(time(NULL));
int arrayRandom [8] [10];
int placeHolder;
int k = 1;
int index1;
int index2;
int index3;
int index4;
int index5;
int index6;
int index7;
int index8;
int index9;
int index10;
int index11;
int index12;
chooseSpace();
for (int i=0; i < 8; ++i) {
for (int j=0; j < 10; ++j) {
arrayRandom [i] [j] = k;
k = k + 1;
}
}
index1 = randomNum();
index2 = randomNum2();
cout << "The garden will be placed on the index " << arrayRandom [index1][index2] << endl;
do {
index3 = randomNum();
index4 = randomNum2();
placeHolder = checkIndex(index1, index2, index3, index4);
} while ((placeHolder == 1));
cout << "The scrapyard will be placed on the index " << arrayRandom [index3][index4] << endl;
do {
index5 = randomNum();
index6 = randomNum2();
placeHolder = checkIndex(index1, index2, index5, index6);
} while ((placeHolder == 1));
do {
index5 = randomNum();
index6 = randomNum2();
placeHolder = checkIndex(index3, index4, index5, index6);
} while ((placeHolder == 1));
cout << "The tool shed will be placed on the index " << arrayRandom [index5][index6] << endl;
do {
index7 = randomNum();
index8 = randomNum2();
placeHolder = checkIndex(index1, index2, index7, index8);
} while ((placeHolder == 1));
do {
index7 = randomNum();
index8 = randomNum2();
placeHolder =checkIndex(index3, index4, index7, index8);
} while ((placeHolder == 1));
do {
index7 = randomNum();
index8 = randomNum2();
placeHolder =checkIndex(index5, index6, index7, index8);
} while ((placeHolder == 1));
cout << "The library will be placed on the index " << arrayRandom [index7][index8] << endl;
do {
index9 = randomNum();
index10 = randomNum2();
placeHolder =checkIndex(index1, index2, index9, index10);
} while ((placeHolder == 1));
do {
index9 = randomNum();
index10 = randomNum2();
placeHolder =checkIndex(index3, index4, index9, index10);
} while ((placeHolder == 1));
do {
index9 = randomNum();
index10 = randomNum2();
placeHolder =checkIndex(index5, index6, index9, index10);
} while ((placeHolder == 1));
do {
index9 = randomNum();
index10 = randomNum2();
placeHolder =checkIndex(index7, index8, index9, index10);
} while ((placeHolder == 1));
cout << "The water pump will be placed on the index " << arrayRandom [index9][index10] << endl;
do {
index11 = randomNum();
index12 = randomNum2();
placeHolder =checkIndex(index1, index2, index11, index12);
} while ((placeHolder == 1));
do {
index11 = randomNum();
index12 = randomNum2();
placeHolder =checkIndex(index3, index4, index11, index12);
} while ((placeHolder == 1));
do {
index11 = randomNum();
index12 = randomNum2();
placeHolder =checkIndex(index5, index6, index11, index12);
} while ((placeHolder == 1));
do {
index11 = randomNum();
index12 = randomNum2();
placeHolder =checkIndex(index7, index8, index11, index12);
} while ((placeHolder == 1));
do {
index11 = randomNum();
index12 = randomNum2();
placeHolder =checkIndex(index9, index10, index11, index12);
} while ((placeHolder == 1));
cout << "The house will be placed on the index " << arrayRandom [index11][index12] << endl;
cout << "These are the placements of the tasks for the game board, have fun!!" << endl;
return 0;
}
void chooseSpace() {
int numPlayers = 2;
int numHunters;
int hunter1;
int hunter2;
int hunter3;
cout << "Enter number of players: ";
cin >> numPlayers;
srand(time(NULL));
if (numPlayers == 6 || numPlayers == 7) {
numHunters = 2;
hunter1 = rand()%numPlayers+1;
hunter2 = rand()%numPlayers+1;
while (hunter1 == hunter2) {
hunter2 = rand() % numPlayers + 1;
}
cout << "The Two hunters for this game are players " << hunter1 << " and " << hunter2 << endl;
}
else {
if (numPlayers >= 8) {
numHunters = 3;
hunter1 = rand() % numPlayers + 1;
hunter2 = rand() % numPlayers + 1;
hunter3 = rand() % numPlayers + 1;
while (hunter1 == hunter2 || hunter1 == hunter3 || hunter3 == hunter2) {
hunter1 = rand() % numPlayers + 1;
hunter2 = rand() % numPlayers + 1;
hunter3 = rand() % numPlayers + 1;
}
cout << "The Three hunters for this game are players " << hunter1 << ", " << hunter2 << ", and " << hunter3 << endl;
} else {
numHunters = 1;
hunter1 = rand() % numPlayers + 1;
cout << "The hunter for this game is player " << hunter1 << endl;
}
}
cout << "The Players can choose any space located at the top of the game board that is shaded blue." << endl;
if (numHunters == 2) {
cout << "The two hunters will be placed on the two red spaces at the bottom of the board on the right and left side. The middle red space should be left open." << endl;
}
else {
if (numHunters == 3) {
cout << "The Three hunters will be placed on the three red spaces at the bottom of the board" << endl;
}
else {
cout << "The hunter should be placed on the middle bottom red space of the gameboard." << endl;
}
}
cout << "Here are the spaces for the task locations" << endl;
}
int randomNum() {
int indexA;
indexA = rand()%7+0;
return indexA;
}
int randomNum2() {
srand(time(NULL));
int indexB;
indexB = rand()%9+0;
return indexB;
}
int checkIndex(int I1, int I2, int I3, int I4) {
if (((I1 == I3) && (I2 == I4)) || ((I1 == I3+1) && (I2 == I4+1)) || ((I1 == I3-1) && (I2 == I4-1)) || ((I1 == I3+1) && (I2 == I4-1)) || ((I1 == I3-1) && (I2 == I4+1)) ) {
return 1;
}
else {
return 2;
}
}
Below are files that hold full page printouts of the 2D versions of each task location and game pieces. These files must be printed out in order to play the game as they hold vital pieces of the game. Once printed out, the game can begin.
Only one copy of the task locations and game pieces need to be printed, whether you're playing remotely or in person. Everyone can print copies to play remotely, however it is not necessary.