Giter Site home page Giter Site logo

Comments (3)

Vgr255 avatar Vgr255 commented on August 11, 2024 1

Hey! We agree, and in fact this is something we want to be doing. Unfortunately, the current IRC library we use is not async, meaning the code isn't made to support other transports. The first step towards making this happens is to move libraries, and update the code to be async. Once that's done, the rest should be relatively easy!

from lykos.

skizzerz avatar skizzerz commented on August 11, 2024 1

Although I note "pluggable" isn't an explicit goal here; all the transport code would live in the bot itself. There's a fair amount of work to be made to make the game code agnostic to what transport is used, rough sketch as follows:

  1. Common abstraction layer that all transports must implement, that will call into game code (via Events) and be called by the game code (via async calls)
  2. Refactor the User and Channel concepts to be more generic; only capturing game-relevant info at the top level and having transport-specific subclasses. Right now both inherit from IRCContext, and while the existing implementations would likely be mostly used as-is for the IRC-specific subclass there would need to be a higher-level abstract User and Channel that exposes a smaller API for gameplay
  3. Migrate IRC library to something that supports async in order to fit in with the new abstractions created by the above steps. We've already identified a suitable library for this called ircrobots, but no migration work has been made yet.

Once those steps are complete, using a different transport should be a simple matter of changing botconfig; the botconfig aspect is already designed to be transport-agnostic in preparation for the above steps.

from lykos.

farooqkz avatar farooqkz commented on August 11, 2024

Yeah transport agnostic is a much better phrase. I didn't mean explicit pluggeable. Maybe label this issue as feature request?

from lykos.

Related Issues (20)

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.