Code Monkey home page Code Monkey logo

twasi-core's People

Contributors

blechkelle avatar dependabot[bot] avatar diesermerlin avatar laraakaa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

twasi-core's Issues

If you leave the mongodb password empty the server will crash while startup

NPE:

INFORMATION: LoggerImplFactory set to org.mongodb.morphia.logging.jdk.JDKLoggerFactory
Exception in thread "main" java.lang.NullPointerException
	at net.twasi.core.database.Database.connect(Database.java:43)
	at net.twasi.core.Main.main(Main.java:27)

example twasi.yml

database:
  type: MongoDB # Only type that is supported
  hostname: localhost
  port: 27017
  user: root
  password:
  database: twasidb
  port: 27017

Reflinks

We use the Twasi-URL-Shortener for Ref-Links. Every Twasi user can have it's own Ref Link. It's formed like this:
https://twa.si/ref/[twitchname], for example https://twa.si/ref/blechkelle. Upon visiting such a link, you get redirected to the panel with a GET-Parameter ref set.

For example: https://panel.twasi.net/?ref=blechkelle

The frontend will then save the referer in local storage. The latest referer will then be prefilled in the "referer" text field in the setup. The name can be changed of course, but the referer has to be registered at twasi.

Tokens

Create a plugin for rewarding your viewers. Should come with functionalities like AntiAFK. Worth of a token should be customizable.

Other Plugins should have access to an API to add / remove tokens.

A transaction log would be nice too.

Custom variables

Users should be able to add variables with a custom Name and output

TimedMessages

Create a plugin to create timed messages. They should be visible in the web interface and have a countdown until the next execution.

We need to think careful how we handle the custom threads.

Songrequests

Add a generic songrequests-plugin.

The plugin should be able to allow requests across the following platforms:

  • YouTube
  • Spotify

The user should be able to select which platforms he wants to use.

To use spotify he needs to connect his spotify account to twasi. This should be in a seperate Twasi plugin.

Make sure that the API is available to make it accessible from the panel. We need to work with websockets to allow viewers to listen directly to the music. The websocket server should be suited in the songrequests plugin.

Entity Cache bug

Steps to reproduce: Just use some commands that require permission.

What happens: The Entity Cache produces an error that kills the whole permission system until a complete Twasi restart. All commands that require permission won't work except you're a global Twasi Admin (no check for a permission string in this case).

Quotes plugin

Allow mods to save quotes of the streamer. Quotes should be listed on a public page of the twasi-panel.

Impersonate other users

For admins, it should be possible to simulate that they are another user. This is useful for testing and supporting.

Debug plugin

Plugin to provide extensive debug information and functionality at runtime (in channel chat or by whispering the bot).
F. e.:

  • Un-/Install plugins
  • Show active plugins (loaded) and installed plugins (database)
  • Show permissions of chatter
  • Show user Rank and status
  • Do Twitch-API test request (check if token is valid and can be used)
  • Let bot reconnect to a specific channel (Twitch IRC reconnect)
  • Let bot reinitialize for a specific channel (reload Instance and Plugins)

Support tickets

Users should be able to request help in a support ticket system that works like a chat.

Setting up the Twitchbot should be skippable

A user sees the first time setup screen after his first login to twasi. He should there have the ability to "set his account up later". The bot should then ignore this user, but the user should be able to receive permissions to other streamers panels or participate in the "public services", e.g. the songrequests.

Optimise variable system

Variable names should ignore non-alphanumeric chars (They should fit into a sentence like "$sender, you are amazing" instead of "$sender , you are amazing").

They also don't parse args correctly: (name [arg1, arg2, ...])

Input Parsed to (currently) Parsed to (should) Reason
$hello(world,123) hello ['world', '123'] hello ['world', '123'] Alright
$hello(world, 123) hello ['world'] hello ['world', '123'] Whitespace behind 'world,'
$hello(world,123 hello ['world', '123'] hello ['world', '123'] Parameter list is unclosed (dirty and error prone)

To prevent unexpected behavior they should have a smarter system that searches the closing bracket (if it has brackets, irrelevant if it hasn't) and automatically remove whitespaces between arguments.

They also need a system to prevent double variable registration.

Introduction

The user should see a quick getting started guide. He should feel comfortable.

The welcome screen should be splitted into several steps:

Step 1:

  • Welcome the User
  • Thank him for trying out twasi
  • Information about migration (if coming from Twasi 1.0)
  • Information about our support if he struggles somewhere
  • Information that we sent an email

Step 1.5 (Optional, only when wants to migrate):

  • Show migration information and process.
  • Let user select which data to migrate.
  • User can only continue after the data is migrated.
    This step will be removed in the future.

Step 2:

  • Select which plugins he wants to have installed per default (some plugins are enforced and can't be changed).

Step 3:
Clarify that twasi is an open-source project created in spare time. It was created for fun, the whole code is open source.

The user should only have access to the panel after he went trough all steps.

Optimize database synchronization

At the moment, all users are downloaded to the local ram on startup.

This is not optimal, since it does not allow to change user data from "outside". Other changes to the database will be ignored and overwritten.

This makes also no sense performance-wise.

What would be a better option to avoid concurrency? There should only be one Object at the time.

Allow plugins to not provide a userplugin class (dependency)

Not everything is a plugin, and thus not everything should be listed in the plugin store. If plugins do not specify dependency: true, they won't have to specify a user plugin class. This is often used for libraries that only need to interact with other plugins, but don't have a direct connection to the user interface.

Streamtracker

Create a plugin that tracks streams over time.

The following information should be gathered (in an interval of 1 minute):

Data structure: We create an object for Every stream. Inside this object is an array of StreamRecords that hold values during the stream. Example:

{
  streams: [{
    id: 'TwitchID',
    isLive: true,
    duration: null, // is Null because the stream is live, should be calculated
    started: '2018-04-23 11:51:00',
    streamRecords: [{
      time: '2018-04-23 11:51:00',
      viewer: 14,
      game: 'Counter Strike: Global Offensive'
    }]
  }]
}

Translation API bug

Sometimes (but rarely) the translations of plugins (not all, it's random!) cannot be loaded for any reason. They will keep returning the requested translation key even if there's a translation for en_gb. It can be fixed by a Twasi restart. Should be fixed anyway.

Spendendose 4

Muss:

  • Commands (Create, Read, Update, Execute, Delete) (commands)
  • Songrequest, auf Extraseite für Streamer abspielen (songrequest)
  • Variablen (Create, Read, Update, Execute, Delete) (variables)
  • Variable für den aktuellen Spendendstand (integriert mit dem Counter) (spendendose)
  • Variable für aktuellen und nächsten Streamer (spendendose)
  • Giveaways (giveaways)
  • Geschriebene Nachrichten (message-logger) (in progress)

Nice to have:

  • Filter (Timeout/Purge bei Links/Capslock etc.)
  • Zuschauerdauer (Coin-System ohne "Coins")

Anonymous Authentication / View Streamer Profile

I should be able to view another streamers profile. There I should see his general twitch data (follower, views etc.) and the songrequests list, the quotes etc. (if the streamer wants that). Later should also be the player there.

  • Implement a System / Extend the GraphQL API to allow anonymous access to this data)
  • Create the pages in the frontend, only show the user data at the moment.
  • Create login logic (the user should be able to log in but doesn't have to, but he has to to request songs e.g.)

If a first time user views a page of a streamer and chosses to log in, he should not need to sign up for the bot and have the option to skip the setup of the twitch bot.

Dependency Injection System

Twasi Plugins should specify on which other plugins (or dependencies) they depend on.
Twasi Core must not enable them before all of their dependencies are enabled.

Otherwise some plugins might not enable correctly when they use a service of another plugin.

Update README.md file

The README file should contain a complete list of all plugins that are currently in use. Also it should link the Homepage, the documentation and the panel.

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.