Code Monkey home page Code Monkey logo

text_mp_adventure's Introduction

Raising Gonthu

This is a work-in-progress deception game that you play in the console. It is multiplayer. See the design folder for details about how that game functions.

The working name for the game is "Raising Gonthu" which comes from the goal for demons - to raise Gonthu. The game is heavily inspired by Town of Salem, its spiritual successor Throne of Lies, the series Wynonna Earp, and various contemporary storylines.

Design Considerations

The game is designed to be as friendly to developers as possible, so every client gets the entire state of the game and there are easy tools (/inspect, /runfile) to run custom code during the game or to inspect the state of the game. The only unacceptable hack would be remote code execution, which is avoided through the event system (assuming the json library doesn't have any security issues)

Running the Game

If you are on windows and have lua installed already, then just do "lua host_game.lua" and follow the prompts.

Installing lua is a challenge on windows. One way to save some headache is installing ZeroBrane Studio just for the lua binaries. It comes with most of the popular lua libraries (this project requires LuaSocket and json).

For this project I am using Lua 5.1.5 on the standard interpreter. If you are not familiar with installing lua I encourage you not to use LuaJIT since it lost it's main maintainer in 2016.

Platform

Currently the game runs on Windows only - this is just because I have a windows machine and that's what I'm testing on. If you want to port the game to other platforms, you need a new way to fetch available keys without blocking. The current version (GetAvailableKeys.exe) is:

namespace IsKeyAvailableFramework
{
    class Program
    {
        static void Main(string[] args)
        {
            while (Console.KeyAvailable)
            {
                var key = Console.ReadKey(true); 
                var keyCode = (int)key.Key;

                Console.Write(keyCode.ToString());
                Console.Write(" ");
                Console.Write(key.KeyChar);
                Console.WriteLine();
            }
        }
    }
}

Additionally there are several locations (search for os.execute) where we use windows command prompt to do stuff like determine console width. In most cases the linux version of doing it is actually easier, so porting shouldn't take very long if you can make the available keys thing work.

text_mp_adventure's People

Contributors

tjstretchalot avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  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.