Skip to content

Group game project for Codaisseur Bootcamp using ExpressJS, Sequelize, PostgreSQL, Server-Sent Events

Notifications You must be signed in to change notification settings

mnezmah/wheel-of-fortune-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wheel of fortune server

What this project is about

This is a server-side of group project building multiplayer game Wheel of Fortune using new Server-sent Events technology. You can find a client-side repository here

Try deployed version on

Table of contents:

Technologies used

Click links to view some samples in this project👇

Goals for this project

  • To practice teamwork
  • To create a full-stack-app with the given features in a given time
  • To learn the server-sent events
  • To practice disciplined git usage with correct branching

Server Sent Events

In this project, we are allowing multiple game rooms to be streamed simultaneusly through the user of server sent events (json-sse).

The project initializes an object which populates stream data for each game room. Each stream data is an object that contains an array of clients (user ids) and a stream object. Stream datas are indexed by game id and they are dynamically created when a new game room is created.

Features built so far

Endpoints in this API

These are the available endpoints of the API @root : http://mywebsite.com.

  • POST @root/users:
    Creates a new user.

  • POST @root/logins:
    Logs in the user and returns an identification token valid for 2 hours.

  • POST @root/category:
    Creates a new category for a game.

  • GET @root/category:
    Returns a list of available categories in the game.

  • GET @root/category/:id:
    Returns a single category with given id.

  • GET @root/stream:
    Returns the stream of all games.

  • GET @root/game/:id:
    Returns single game with given id with belonging players and category.

  • POST @root/game:
    Creates a new game.

  • PUT @root/game/:id:
    Changes the game parameters (wheelValue, gussed array and given letters).

  • GET @root/letters:
    Returns a list of all available letters.

  • POST @root/letters:
    Creates a set of letters for guessing the word.

  • GET @root/scoreboard:
    Returns a list of players with beloning scores.

  • GET @root/players/:id:
    Returns a single player with beloning score.

  • POST @root/players:
    Creates a single player with given name.

  • PUT @root/players/:id:
    Updates a single player with the current score.

  • POST @root/category/:id:
    Creates a word with given description and hint that belongs to the given category

About

Group game project for Codaisseur Bootcamp using ExpressJS, Sequelize, PostgreSQL, Server-Sent Events

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published