Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Project Specification and Implementation Draft #3

Open
MusicOnline opened this issue Aug 1, 2020 · 2 comments
Open

Project Specification and Implementation Draft #3

MusicOnline opened this issue Aug 1, 2020 · 2 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@MusicOnline
Copy link
Collaborator

Albatrosses' Hub

Main hub features:

  • Newsletters
  • Party Games
    • Mafia/Werewolf-inspired name TBD
  • Selectable Themes (one of these Priority 2)
    • AOL
    • msn
    • Yahoo Messenger
    • earlier?
    • maybe new.albatrosses-hub.com for a modern UI
  • Discord integration (because we want something usable...)

Hub quirks:

  • Sounds for everything
  • WordArt-like titles
  • Serif everywhere
  • Quirky graphics
  • GIFs
  • Custom cursor

Hub accessibility (a11y):

  • At least one theme where everything is readable and not headache-inducing to most audiences
  • Handle no JavaScript situations
  • Redirect HTTP to HTTPS
  • Is it at least possible to support IE in the early themes?
  • Mobile responsiveness is absolutely not needed

albatrosses-hub.com

Priority 0

Index page of Albatrosses' Hub with choices. See Space Jam.

albatrosses-hub.com/games

Priority 0

Index page of available games. Only Mafia will be unlocked. See Space Jam.

albatrosses-hub.com/games/mafia-name-tbd

Priority 0

JavaScript is required due to WebSocket requests.

On loading this page,

  1. If this is the first time (based on session cookie), you can
    • Join a session using a code
    • Create a new session
    • Input player name
  2. If this is a subsequent visit,
    • If a session you were in is still ongoing (e.g. page refreshed), you can rejoin it
    • Join another session using a code
    • Create a new session
    • Player name should be remembered

Creating a session

  1. Session creation menu
    • Session name
    • Number of players
    • Theme (Werewolf, Mafia, Name-TBD)
    • Role distribution (advanced)
    • Options
      • Authorize players before joining
      • Password
  2. Player creation menu (name input)
  3. Session created dialog (copy to clipboard)
  4. Enter session

Joining a session

  1. Session can be joined by url albatrosses-hub.com/games/mafia-name-tbd/session-code-here or inputting the code in the screen
  2. Player creation menu (name input)
  3. Enter session

When there are sufficient (how many?) players, the session host may start the game with 5 seconds countdown. After that, roles are distributed to each player.

A matrix or circle of "avatars" of the players can be seen on the left (like a roundtable).
One or two chatboxes can seen stacked on the right. (Commoner and Faction Chat)

There are stats displayed such as round timer, number of remaining players, Friendly faction and Opposite faction members.

Gameplay

Several roles are distributed during at the start of the session:

  • Citizen/Commoner/Innocent (friendly, no night action, should help day discussion)
  • Sheriff/Detective/Seer (friendly, can investigate a player at night)
  • Mafia/Werewolf/??? (hostile, can kill a player at night)
  • Witness (friendly, is told who the Mafia/Werewolf/??? are on the first night)
  • Doctor (friendly, has 3 syringes, can do one injection per night, an injection saves from death, two consecutive injections kill)
  • unique: Albatross (friendly, inflicts Albatross' Curse on their killer, cursed will die after the next Night Phase)
  • ...

Hosts can have set different themes which give different roles. An advanced section can be added to modify role distribution and stats.

The session immediately starts with the first Night Phase. During the Night Phase,
0. Players with abilities will vote who to use them on in 10 seconds.

  1. Mafia/Werewolf/??? kills and Sheriff/Detective/Seer investigations are done simultaneously.
  2. Doctor's injection.
  3. (other roles)...

On the next day, players are to discuss and have a majority vote on who to execute in 90 seconds. After 50 seconds, players will be asked whether to confirm or abstain their votes.

Players killed by Mafia/Werewolf/??? and executed by a majority vote may leave a dying declaration (dying message) in 30 seconds. Their roles may be immediately revealed on death.

Gameplay implementation

Each player's browser session is given a mafia_session_id and player_name in Django.

MafiaSession model

  • id
  • game options...

TBA

albatrosses-hub.com/news

Priority 2

Sources from Google News RSS feed on specific topics (such as?).

albatrosses-hub.com/news/subscribe

Priority 3

Client can POST email here to subscribe to a regular (how regular?) newsletter.

Engineering required:

  • Storing email to database
  • Broadcast email (how?) every so often (how?)
  • Allowing unsubscription
@MusicOnline MusicOnline added the documentation Improvements or additions to documentation label Aug 1, 2020
@MusicOnline MusicOnline changed the title Project Specification Project Specification and Implementation Draft Aug 2, 2020
@Iqrar99
Copy link
Collaborator

Iqrar99 commented Aug 2, 2020

For the web mockups, I put the link here

https://drive.google.com/file/d/1dYasCzJ_GDSMqygRrFGTkvl9ifNktGF3/view?usp=sharing

@MusicOnline
Copy link
Collaborator Author

MusicOnline commented Aug 2, 2020

Database Relationship Diagram
image
Generated using this code on dbdiagram.io:

TABLE BrowserSessionManagedByDjango {
  id_managed_by_django INTEGER [pk]
  mafia_session_id INTEGER [ref: > MafiaSession.id]
  player_name TEXT
  role TEXT
  mafia_session_attributes JSON
}

TABLE MafiaSession {
  id INTEGER [pk]
  game_options "..."
}

TABLE User {
  id INTEGER [pk, increment]
  email TEXT
  password_hash TEXT
  discord_user "DiscordUser" [note: "OneToOneField", ref: - DiscordUser.id]
}

TABLE DiscordUser {
  id INTEGER
}

TABLE MafiaPlayer {
  user User [pk, note: "OneToOneField", ref: - User.id]
  mafia_session_id INTEGER [ref: > MafiaSession.id]
  player_name TEXT
  role TEXT
  mafia_session_attributes JSON
  "Game scores, statistics" "..."
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants