From bab0d82cfc759788227d00292a9666765236fecb Mon Sep 17 00:00:00 2001 From: Sara Montecino Date: Wed, 8 Nov 2023 14:54:54 -0800 Subject: [PATCH] Initial commit --- camera-test.html | 54 ++++++++++++++++++++++++++ notes.txt | 98 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 152 insertions(+) create mode 100644 camera-test.html create mode 100644 notes.txt diff --git a/camera-test.html b/camera-test.html new file mode 100644 index 0000000..dc1b0e7 --- /dev/null +++ b/camera-test.html @@ -0,0 +1,54 @@ + + + + Your Game + + + +
+ + Uploaded Image + +
+ + + + diff --git a/notes.txt b/notes.txt new file mode 100644 index 0000000..0b7fc47 --- /dev/null +++ b/notes.txt @@ -0,0 +1,98 @@ +# Description +A party game of sexual ambitions. + +Which Shrek character does your friend secretly want to bang? Wanna hint? It's not the ogre. + +# Requirements +A web browser based game. + + +Workflow: + A. Landing page + --> Create new game + --> Join existing game + B. Create new game + 1. Click button + - Make an https request to server + POST + /games + RESPONSE + UUID game_id + - Parse game_id from response + --> Open game screen. + C. Join existing game + 1. Enter game_id into input box + 2. Click enter / hit button + --> Open game screen. + D. Open game screen. + - Validate game exists + - Make https request to server + GET + /games/ + OK -> proceed + 404 -> error + - Join game + 1. Enter Name (string) + 2. Take picture (html & javascript) + 3. Join game + - Upload image to server + POST + /images + RESPONSE + OK -> image_id + - Make https request to server + PUT + /games/ + { + "name": "", + "avatar": "image_id" + } + +Ok, I found the hard part. What is the structure of data for each game? + +Model + +Image + - uuid + - filepath? + +Game + - uuid + - code: alpha-numeric 6 figure string + - active: bool + - player_ids: list of players + - round_ids: list of rounds + +Player + - uuid + - display_name + - avatar_id: image_id + - is_prompt: bool + +Round + - uuid + - active: bool + - answer_player_id: player_uuid + - prompts: list of prompt_ids + +Prompt + - uuid + - prompt_id: player_uuid + - answers: list of answer_ids + +Answers + - uuid + - player_id: player_uuid + - would_smash: bool + +Each game has: + 1. player_ids - UUIDs for players participating. + - is_prompt = false + 2. rounds - list, n = number of players (each player goes once) + - answer_player: player uuid + - active: bool + - prompts: list, n = 10. + - player_id: uuid, where is_prompt = true + - answers: list, n = number of players + - player_id: UUID of player that submitted + - would_smash: bool