Giter Club home page Giter Club logo

human-ramen's Introduction

Build Status
[WIP] Toolkit for Human Ramen games

HumanRamen.Scenario

Lua scripts driven scenario tool. Code some talks, mutate some world's vars and start a fight.

Here you can see how it works. Ok, would work.

Characters:Add("Karen", "ChrKaren")
Background = "BgKitchen"

startNode = Scenario:CreateNode("Karen", "Hello, Human")

okNode = Scenario:CreateNode("Karen", "Hey :)")
notOkNode = Scenario:CreateNode("Karen", "Karen, of course!")

startNode:AddResponse("Hello", okNode)
startNode:AddResponse("Who are you?", notOkNode)

...

Shove it in a system and watch results.

HumanRamen.Battle

Turn-based battle system. Here battle setup. If everyone is ready just throw battle entity:

var battle = _world.CreateEntity();
battle.Attach(new BattleComponent(enemies, player));

And we're ready to dance.

Tests shows something like predefined fight.

HumanRamen.UI

Barebone Visual Novel / JRPG style ui system. Has big black rectangle, can show letters and lights up some choices.

beautiful ui

HumanRamen.Entities

Musthave systems for showing some sprites and taken some keyboard presses.

RenderSystem

Renders SpriteComponent and SpriteFontComponent. Doing some work with resizing and positioning stuff.

ControlSystem

Parse lua script with keyboard->command maps and with presses throw commands through HumanRamen.Essentials.Commander.

kbd.Q = "Exit"
kbd.Space = "Continue"
kbd.F = "Fullscreen"
kbd.D = "ToggleDebugConsole"
kbd.Enter = "Enter"
kbd.J = "Down"
kbd.K = "Up"
kbd.Down = "Down"
kbd.Up = "Up"
...

ScenarioSystem

See HumanRamen.Scenario package. This system makes scenarios work.

HumanRamen.Essentials

Essentials tools for everyone.

Commander

Create commander and throw it in systems where you want to receive or send commands:

_commander = new Commander();

new SomeSystem(_commander);

If your system wants to receive commands it must be registered to it and implement ICommandHandler interface.

public class SomeSystem : ICommandHandler
{
    private Commander _commander;

    public SomeSystem(Commander commander)
    {
        _commander = commander;
    
        _commander.RegisterHandler("control", this)
    }
    
    public void HandleCommand(string topic, string command)
    {
        if (topic == "control" && command == "Shoot")
        {
            // do stuff
            
            return;
        }
    }
}

And you can command from everywhere with commander:

_commander.Command("control", "shoot")

HumanRamen.Graphics

ColoredTexture

SpriteBatch helper for creation simple 1x1 texture with one color.

Primary = new ColoredTexture(graphicDevice, Color.Blue);

human-ramen's People

Contributors

xdefrag avatar

Stargazers

 avatar  avatar

Watchers

 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.