Description
QUESTION: Web Game We will build a simple multi user web dungeon crawler-like game. You or your team must build it cooperatively with your classmates. You can only use HTML, CGI and C. No CSS. No JS, etc. The goal of the game will be to get 100 gold pieces. You start the game with 10 gold pieces. Each dungeon room you enter results in a win of 10 gold pieces or a loss of 5 gold pieces. You will gain or lose gold by engaging in a Q/A activity. Each room will have either a single COMP206 question or a single Zelda question. If the player answers correctly they get 10 gold pieces. If they answer incorrectly, they lose 5 gold pieces. When you cannot pay, you die. When you get 100 gold pieces, you win. This is an equal opportunity dungeon, so you can start from any room. Simply type the URL of anyone’s room to start the game. Your room does not need to be pretty. It only needs to be functional. If you want to make it pretty, then please go ahead, but stick to HTML, CGI and C. Have fun with this. Each room is responsible to (1) show a question, (2) a picture, (3) be able to process the user’s response to the question, (4) award 10 gold or (5) remove 5 gold, (6) display how much gold the user has, (7) display a DIE and (8) WIN message. Each room will have a textbox input field and a submit button. In that textbox the user can either answer the question posed by the room to win 10 gold pieces or lose 5 gold pieces, or they can input a command. Valid commands are: NORTH, SOUTH, EAST, WEST, or GOLD. Each of the directions is connected to another classmate’s room. This means that your room must connect to four other rooms. If we do this right, a player will be able to travel to all 250-500 rooms. You only need to make sure that your room connects to four other rooms. Once the user has 100 gold they win. When a user presses submit with 0 gold a lose message is automatically displayed. If the user has some gold, even 1 gold piece, the game validates the attempt. If the person got it correct, then they get 10 more gold pieces, otherwise they lose 5 gold pieces. If they do not have enough gold pieces to pay for the loss, then they automatically die. McGill Mini Assignment #7 COMP 206 Vybihal School of Computer Science Page 2 of 7 This is what you need to do: STEP 0 – The public_html directory Lab J shows you how to create the public_html directory. Please do this. You will need to create four files: index.html, answers.c, addgold.c and a picture. The index.html file will be your dungeon room. The rest of the files are described below. STEP 1 – Build the room using HTML and CGI Your dungeon room must look like this: You can center your NAME OF ROOM with the tag