This is hard for me to explain and even harder for me to visualize how I’d do it, since I don’t know the bounds of communication with websites with Java and C#, so if I banter a lot/make no sense in the process of describing this, I apologize.
Basically, I’m making a ‘bot’ for http://www.plug.dj. This bot is able to do things on command like kick users, ban users, send chat messages, delete chat messages, say random things, etc. As of right now, it’s powered by a simple one-file JavaScript code with a ton of listeners and callbacks using the Plug.dj API to handle them. This is ALL engineered by JS — on the back-end, I think Plug.dj is powered by Python, I could be wrong.
Anyway, what I would LIKE to do is create this bot on a language other than JS. It’s really basic and not super powerful, and there are things like communicate with databases and such that I’d like to implement that aren’t possible/convenient with JS. I just want to know if this is possible, and if so, where should I start looking?
I’d prefer a language like Java or C#. If there’s any more info you need to know in order to answer this, let me know, please! I’d like to start working on this, I think it’d be fun to learn how to communicate with websites with Java/C#/whatever.
If the
botjavascript runs on “their” server, then there is no simple solution. They are providing a mechanism for running “your” javascript on their server, but the chances are that they don’t support other languages. (And the only way to find out would be to ask “them”). Assuming that the answer is “no”, you would need to investigate whether you can implement your “bot”s functionality in client-side code; e.g. a custom client that you implemented from scratch in Java or C# or whatever. That’s a big “if” … because it will only work if they expose the server functionality you need in their external APIs.OTOH, if the
botjavascript runs on “your” server, then you should be able to change it to support other languages. (It wouldn’t necessarily be easy though …)My advice would be to take a deep breath … and stick with Javascript. We all have to use languages that we don’t think are “fun”.