Coder Social home page Coder Social logo

devoid's People

Contributors

clagraff avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

devoid's Issues

Create an acceptance-test suite

We should have a test harness or something for running acceptance tests which send key events to the client, to cause intents sent to server, to result in mutations, etc etc. Maybe contained as a separate package?

Perception needs to be built into the server

Now
When a client connects, they will be subscribed to their entity ID and current position; a perceive intent is also immediately created to be processed.

The architectural idea seems to be that a Perceive intent will be created and consumed each time something affects an entity; yet, this does not impact the subscribers.

The Problem
Since the Perceive (or any intent) doesn't modify subscribers, it means performing any action has no impact on subscribers, neither adding nor removing.

As an example:

An entity moves to a new location. They immediately perceive their surroundings. But since they have not been subscribed to any of the new Positions they can now perceive, should a monster/player/etc move into their viewpoint, they would not know until they Perceive again.

Future
Create a new subscription/mutator system.

Executing an intent should return server mutators, and then a list of (mutators, identifiers) pairs, where we have a list of mutators and a list of identifiers, possibly multiple times.

Maintain a map of identifiers to connected clients (from when tunnels are created or closed). Using that map and the identifiers, ensure that a given mutator is not sent multiple times for a given client.

As an example, a Move mutator may want to be sent by both the Source ID as well as the new position, but that shouldnt generate two mutations of the same data to the same single client.

Refactor client code

The current client code could certainly contain copious changes culminating collectively in a better developer experience.

Specifically, segregating rendering code, mutation & state mgmt, and GUI event handling into separate structures. Right now it is all combined and makes for a messy, and convoluted codebase.

Client Config to provide cert location

cmd/client/main.go
40:     info := network.MakeConnInfo("localhost", 8080, cfg.ClientID, "/home/clagraff/selfsigned.crt", "")

In the [client main][cmd/client/main.go] file, the certificate path is hardcoded. This should be changed to pull from the configuration file.

Move ASCII client to tcell

The current TUI library used by our ASCII client is termbox, but support for this library has halted. It is suggested to use tcell instead.

Make the switch now, while client-code is minimal.

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.