Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nakama client implementation (online multiplayer) #1616

Closed
DreadKnight opened this issue Feb 5, 2020 · 79 comments
Closed

Nakama client implementation (online multiplayer) #1616

DreadKnight opened this issue Feb 5, 2020 · 79 comments
Assignees
Labels
coding This issue requires some programming 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt Hacktoberfest T-shirt https://hacktoberfest.digitalocean.com multiplayer Problems that occur in online multiplayer pipeline Affects how the project is being developed priority This should get fixed as soon as possible!

Comments

@DreadKnight
Copy link
Member

DreadKnight commented Feb 5, 2020

Issuehunt badges

Nakama is an open source server that has plenty of features that we'll need and also supports JavaScript implementation, so we should make use of it rather than reinventing the wheel.

It might even be implemented with Node.js heroiclabs/nakama-js#23

https://github.com/heroiclabs/nakama
https://heroiclabs.com
https://heroiclabs.com/docs/javascript-client-guide

For this implementation the server can be set up locally for development purposes.
https://heroiclabs.com/docs/install-docker-quickstart
We'll be using the user system, allowing players to connect to servers and join lobbies in order to play versus other people online, 1vs1 or 2vs2.

The main menu will need some tweaks, described that in #1624 to keep things somewhat tidy.


IssueHunt Summary

rianconley rianconley has been rewarded.

Backers (Total: $225.00)

Submitted pull Requests


Tips

@DreadKnight DreadKnight added coding This issue requires some programming priority This should get fixed as soon as possible! labels Feb 5, 2020
@DreadKnight DreadKnight added this to the 0.4 - Bounty Hunter milestone Feb 5, 2020
@DreadKnight DreadKnight changed the title nakama client implementation (online multiplayer) Nakama client implementation (online multiplayer) Feb 5, 2020
@DreadKnight DreadKnight added the pipeline Affects how the project is being developed label Feb 5, 2020
@issuehunt-oss
Copy link

issuehunt-oss bot commented Feb 6, 2020

@dreadknight has funded $200.00 to this issue.


@issuehunt-oss issuehunt-oss bot added the 💵 Funded on Issuehunt This issue has been funded on Issuehunt label Feb 6, 2020
@dq-mlnck
Copy link

It’d be great to help out on this one..I was randomly playing around Nakama last month so it’s still somewhat fresh :)

What are the requirements to close this?
• Spinning up a local environment only
• Porting everything as-is from the current env to Nakama
• Creating the server and moving integrating all aspects
• Something completely different / etc

Thanks!

@DreadKnight
Copy link
Member Author

DreadKnight commented Mar 11, 2020

@dq-mlnck The game should still be playable hotseat/offline as well, just like now, without an account.
The pre-match screen should be tweaked and have a new tab or so where you would do stuff like logging in, browsing existing game rooms or creating new one; when joining a room you should see other players (nickname/avatar) and chat/log (should use same UI for that as the in-game combat log).

So probably the pre-match screen will have a tab for settings, one combat locations and one for players (where stuff listed above will go if going online), while the chat-log thingy will be visible at the bottom.

@dq-mlnck
Copy link

@DreadKnight Nice!
I should be able to start breaking into this today :)

@DreadKnight
Copy link
Member Author

DreadKnight commented Mar 14, 2020

@dq-mlnck Good to hear! I just remembered, someone made a guide on how to enable nodejs support for it, you should probably go this route if it's still relevant heroiclabs/nakama-js#23 as I can't quite figure out if their JS installation guide deprecates all that; yeah, I'm pretty bad at this kind of stuff.

@mlnck
Copy link

mlnck commented Mar 19, 2020

@DreadKnight Sorry for the delay ... Covid stuff has me running a few days behind.
I've got it up and running with a script that auto-applies the "moneky-patch" after install so you won't overwrite the changes each time you run it.

I haven't had a chance to look into the user management piece yet. But if I can't get to it tonight should be able to dive in tomorrow.

@DreadKnight
Copy link
Member Author

@mlnck Understood, thought that might be the case. Thanks for the update, let me know how it goes 👍

DreadKnight added a commit that referenced this issue Apr 11, 2020
Deploy speed-up and server cleanup #1616
@DreadKnight
Copy link
Member Author

Since I haven't seen any progress in over a month or getting any replies back, I'm guessing this issue is up for taking again...

@rianconley
Copy link
Contributor

Hey @DreadKnight , any progress on this task? It seems like this would be the crucial update for AB since it needs to have a multiplayer component. I took a look and was able to get the server running locally through docker. I can continue looking at it if no one else is currently working on it.

@DreadKnight
Copy link
Member Author

@rianconley No progress, last guy vanished. So hopefully someone else (perhaps you) can pick this up.

@DreadKnight DreadKnight pinned this issue Apr 22, 2020
@rianconley
Copy link
Contributor

rianconley commented May 27, 2020

Hey @DreadKnight , do you have any cloud hosting solutions picked out yet for the game (linode, digital ocean, etc). I've been able to get authentication and socket connections working locally but I'm at an impasse until there's an cloud environment where I can test multiple users.
Thanks

@DreadKnight
Copy link
Member Author

@rianconley I got current stuff hosted using Heroku, but obviously, no Nakama stuff yet. Just register for Heroku or something and throw the Nakama server on it so you can test things out properly, as it has nice free tier.

@rianconley
Copy link
Contributor

I'll take a look at Heroku. Thanks.

@DreadKnight
Copy link
Member Author

@rianconley Alright, cool. You can easily clone existing GH repos and deploy them. Compared to the alternatives, it has very simple UI, though it's supposedly more expensive in the long run, so I might eventually have to properly learn the alternatives as well, but they sure like to nitpick on every single resources, which makes things tedious.

@rianconley
Copy link
Contributor

rianconley commented May 28, 2020

@DreadKnight , it doesn't look like Heroku is an option. Nakama needs cockroachdb database server to be installed and Heroku doesn't appear to have support for deploying custom database servers. Nakama has a tutorial to install Nakama using digital ocean. I also found an article where nakama is installed using Google Compute Enrine. Both these options appear suited for Nakama's dependencies but it isn't free. I guess I'll look around to see if there are any other inexpensive possibly free cloud options.

@DreadKnight
Copy link
Member Author

DreadKnight commented May 28, 2020

@rianconley I see. Well, I probably know the tuts. Digital Ocean has 100$ credit for new accounts for 60 days, you could give that ago. I might see about getting some paid hosting if/when it comes down to that and hopefully will be able to invite to that (I think Google stuff has teams and even free tier).

@rianconley
Copy link
Contributor

I also saw that 100$ credit for 60 days; it looks legit. I'll give it a go.

@ktiedt
Copy link
Collaborator

ktiedt commented May 28, 2020

If you are looking at Digital Ocean, I have a referal link that benefits my pet project as well (it would cover 1 month of our hosting).

https://m.do.co/c/0e803bfcf0d2

@DreadKnight
Copy link
Member Author

@rianconley Google Compute Engine or even Digital Ocean should be fine, if you finish this month you'll even get a t-shirt from them :D

@rianconley
Copy link
Contributor

rianconley commented Oct 4, 2020

Hmm, well AB multiplayer is already running on a digital ocean server droplet. This is where you've been testing the multiplayer.

@rianconley
Copy link
Contributor

Should I go ahead and make a pull request? Wherever you decide to deploy it can be part of another task?

@DreadKnight
Copy link
Member Author

Yes, go ahead, as I said before. Though for PR review would ideally need to get it hosted to try it out, so would go for any of those that work and might need some very basic guiding to smooth out the process I haven't used them before, otherwise docs/googling/youtube/communities are my friends.

@rianconley
Copy link
Contributor

rianconley commented Oct 10, 2020

Allright @DreadKnight , pull request was made and the conflicts should be resolved.
I added an example .env file. When you decide on a provider, the variables will need to be updated accordingly.

I also added the docker compose file. This can be used for local set up.

FYI I may be canceling digital ocean account soon. Once you start setting up the server on a cloud provider, if you have any questions, I'll do my best to provide guidance.

Looking forward to getting the shirt.

@DreadKnight
Copy link
Member Author

Allright @DreadKnight , pull request was made and the conflicts should be resolved.
I added an example .env file. When you decide on a provider, the variables will need to be updated accordingly.

@rianconley Took a peek at it last night and it was a bit problematic with the pre-match, kinda squishing another recent PR.
So wanted to see if you would fix on your own and then provide you with feedback. Gonna test it out soon and see if that was solved, otherwise will suggest how the new multiplayer button should be handled in the pre-match screen between its modes.

I also added the docker compose file. This can be used for local set up.

Good there's a docker for this, this will probably fix #1344 issue as well in the process 👍 - will just have to get some exp with them.

FYI I may be canceling digital ocean account soon. Once you start setting up the server on a cloud provider, if you have any questions, I'll do my best to provide guidance.

I understand about the DO subscription, makes sense. Save them bucks asap 💸

Looking forward to getting the shirt.

Maybe I'll get one of those t-shirts as well soon. Anyway, doing some research on (AB) t-shirts and will start pushing that stuff as well in the near future, so there should be one of those for you as well if project will finally start scaling up thanks to online multiplayer :)

DO picked kind of a strange time (or strategical money wise?) to give out t-shirts as it's autumn and chilly in a lot of places.

@rianconley
Copy link
Contributor

Sounds good. Yeah, I noticed pre-match was messed up as well. I fixed all the issues that I saw.

@rianconley
Copy link
Contributor

rianconley commented Oct 10, 2020

Looks like I spoke too soon. The discord link was removed somehow. I re-added it back in in a new commit

@DreadKnight DreadKnight added the Hacktoberfest T-shirt https://hacktoberfest.digitalocean.com label Oct 12, 2020
DreadKnight added a commit that referenced this issue Oct 17, 2020
DreadKnight added a commit that referenced this issue Oct 17, 2020
DreadKnight added a commit that referenced this issue Oct 17, 2020
@DreadKnight DreadKnight reopened this Oct 17, 2020
@issuehunt-oss
Copy link

issuehunt-oss bot commented Oct 17, 2020

@dreadknight has funded $5.00 to this issue.


@issuehunt-oss
Copy link

issuehunt-oss bot commented Oct 17, 2020

@dreadknight has rewarded $202.50 to @rianconley. See it on IssueHunt

  • 💰 Total deposit: $225.00
  • 🎉 Repository reward(0%): $0.00
  • 🔧 Service fee(10%): $22.50

@issuehunt-oss issuehunt-oss bot added 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt and removed 💵 Funded on Issuehunt This issue has been funded on Issuehunt labels Oct 17, 2020
@DreadKnight
Copy link
Member Author

Fixed in #1765 woot!

DreadKnight added a commit that referenced this issue Oct 19, 2020
@DreadKnight DreadKnight added the multiplayer Problems that occur in online multiplayer label Nov 4, 2020
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
CyberBishop pushed a commit to CyberBishop/AncientBeast that referenced this issue Apr 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
coding This issue requires some programming 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt Hacktoberfest T-shirt https://hacktoberfest.digitalocean.com multiplayer Problems that occur in online multiplayer pipeline Affects how the project is being developed priority This should get fixed as soon as possible!
Projects
None yet
Development

No branches or pull requests

5 participants