Code Monkey home page Code Monkey logo

pung's Introduction

Pung

Command line multiplayer pong game


Table of Contents



Installation

  1. Install Node.js (version 16 recommended)
  2. Clone or download (and unzip) the game to get the latest snapshot
  3. Open a terminal in the game's folder, where the package.json file is located
  4. Run npm start or node client to start the game normally

    Run npm run server or node server to start a dedicated server instance



Security

  • The default proxy server encrypts traffic with HTTPS.
  • The only directly identifying information that is transmitted is your username.
    It will not be stored by the server, but it will be stored by other users, so be aware of that.
  • All authentication (who is who & which player is the lobby's admin) is done through cryptographically securely generated unique session IDs.
    If you feel like your connection is compromised, change your username in the menu or re-launch the game to regernerate the session ID.

If you have any other questions or would like to report a security issue, please refer to our security policy.



FAQ

This section contains additional information about this project, in FAQ style:


Why?

  • I wanted to make a project using websockets
  • I wanted to make a multiplayer CLI game
  • Why not?

How?

This project includes some client, server and common / shared code.

When you launch this game, the index.js file in the client folder is executed.
It prompts you to enter your username, after which the client contacts the server to initialize the session (this is internally called "handshake").
The server now generates a cryptographically secure session ID, sanitizes your username, and returns that data to your client.

Now your client has its session ID, which is used by the server to uniquely identify clients and for example know who the lobby admin is.
Nothing uniquely identifying is saved on the server, it doesn't even know the usernames of the clients after the lobby was initially set up.


Help!

If you need help, please join my Discord server or send me an E-Mail.
If your issue is with code, please open a GitHub issue.



Legal stuff


License

This game is licensed under the MIT license. Click here to view the full license text.

pung's People

Contributors

sv443 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.