marineks / 42-ft_transcendence

Prompt: Code a full-stack SPA that provides for its users multiple features such as a chat, an online multi-player game or a social page.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FT_Transcendence

Subject Subject

Table of contents ๐Ÿ“–

Table of contents generated with markdown-toc

About ๐Ÿงฌ

FT_Transcendence is the last project of 42's common core. This project is about building a website which hosts a Pong competition. Thanks to this website, users will be able to play Pong with each other. They will have a user interface, a chat and in-realtime online multiplayer games.

Tech stack โŒจ

  • Backend : NestJS
  • Database : PostgreSQL
  • ORM : Prisma
  • Frontend : Typescript ReactJS
  • Libraries worth to mention:
    • Data-fetching, API | React-query : asynchronous state management library (handles caching, background updates and stale data ),
    • Data-fetching, API | Axios: a promise-based HTTP Client
    • Friends search bar | Meilisearch : open-source, lightning-fast, and hyper-relevant search engine
    • Frontend part of our game | PixiJS : 2D WebGL renderer
    • Websockets for game + chat | Socket.io : library that enables low-latency, bidirectional and event-based communication (websockets) between a client and a server.

Mandatory requirements ๐Ÿ“

1. A Single Page Application (S.P.A.) โ€ฆ

  • Code a dynamic website with a single web page

  • design must be responsive

  • the user must be able to use the back et forward buttons of the browser

  • must be compatible with Chrome and another web browser of your choice

  • no errors or warnings in the console

    โ€ฆ who is secure ๐Ÿ”

  • all the passwords given by a user must be hashed

  • the website must be protected against SQL injections

  • โš ๏ธ all credentials, API keys and other sensible info must not be online, on github or else!

2. An Elaborate User Account ๐Ÿ’ซ

  • Login must be done through the 42 API (OAuth system)
  • 2FA (Two-Factor Authentication) must be possible
  • Each username must be unique
  • You should be able to choose an avatar and have a default one
  • Possibility to add other friends
  • Ability to see the status of your friends (online, offline, in a game...)
  • Collection and display of stats
    • Wins and losses
    • Elo level
    • Achievements and milestones
  • Catalog the Match History of a user, viewable by anyone

3. A Complete Chat ๐Ÿ—จ๏ธ๐Ÿ˜ผ

  • A user must be able to send a direct private message to another user
  • A user must be able to block another user
  • Presence of channels
    • Which can be public or private
    • Or protected by a password
  • A user who creates a channel automatically becomes the owner
  • The owner of a channel:
    • Is also a channel admin and can grant this privilege to other regular users
      • A channel admin can kick, ban, or temporarily mute all users except the owner.
    • Can add, modify, or delete a password to access the channel
  • A user must be able to invite another to a game of Pong via the chat
  • A user must be able to access the profiles of other users via the chat

4. A Triple-A Game ๐ŸŽฎ

  • The game must be a Pong
  • Real-time play against another player must be possible
  • There must be a match-making system with a queue
  • Visually, we have free cards
  • Additional features can be added to the game, but a vanilla mode must be present!
  • The game must also be responsive

Demo ๐Ÿ”ฌ

Subject Subject Subject Subject Subject Subject Subject

Authors ๐Ÿชง

This was a group project made with ๐Ÿค by four people:

Some great resources to get you started ๐Ÿ“

About

Prompt: Code a full-stack SPA that provides for its users multiple features such as a chat, an online multi-player game or a social page.


Languages

Language:TypeScript 77.9%Language:CSS 20.0%Language:Handlebars 0.8%Language:Dockerfile 0.6%Language:JavaScript 0.3%Language:Makefile 0.2%Language:HTML 0.1%Language:Shell 0.0%