How to make a Java server interact with a JS game

Im making a javascript game, but i want to be able to make it multiplayer. should i make the server using java or node.js? not only do i want to make it online so 2 players are playing together, but i also want the application to save their progress onto files, and idk if node.js can do that.
5 Replies
JavaBot
JavaBot9mo ago
This post has been reserved for your question.
Hey @mochatitan! Please use /close or the Close Post button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
szatkus
szatkus9mo ago
Both Java and Node.js could do all those things just fine. Java might be easier to scale if you're not going beyond a single machine.
mochatitan
mochatitanOP9mo ago
how can i make them connect to eachother do you know i cant find really documentation online about it
szatkus
szatkus9mo ago
Without knowing the details it's hard to say. Probably some websocket endpoints and maybe a dedicated pubsub to send messages between them?
JavaBot
JavaBot9mo ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one. In case your post is not getting any attention, you can try to use /help ping. Warning: abusing this will result in moderative actions taken against you.

Did you find this page helpful?