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

feat(dns): Add dns hostname resolving #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Tarensaror
Copy link

Softens character limit for input and resolves dns if necessary so dynamic ip-lookup can be used

@thomaswp
Copy link
Owner

thomaswp commented Nov 16, 2024

Hey, thanks for the PR! Just to confirm, this PR:

  • Allows for longer entries to the Join Game input box
  • Allows the user to input a port, and parses that out if provided (overriding the config or default port)
  • Uses DNS lookup if a domain name is provided instead of an IP

This makes sense. Out of curiosity, what is your use case that you need DNS lookup? My assumption was that people would only be hosting from personal computers, which wouldn't be mapped to a domain name. Is there a VPN tool that provides DNs instead of IPs?

Also, good news: steam networking support is in the works (really just needs to be tested more and smoothed out), so that should solve a lot of these problems.

@Cilyena
Copy link
Contributor

Cilyena commented Nov 16, 2024

Hello. I use a dns to simplify the connection with my friends or when i want to access my computer remotely, i don't have a static ip.

@Tarensaror
Copy link
Author

The usecase is in this case that the host uses a DNS Service in this case dyndns.
This provides him with a Domain which he can route different ports to different devices in his network.
So the PC that hosts Timberborn ist adressable via Domainname and a specific Port. The default Port was already in use in his end so I added the Port selection as well. (Correct me but it is 25565 which ist the same that Minecraft uses)

Sadly the Input Box Limit ist kinda hacky because I'm new to unity and Game Dev stuff. Feel free to find a better solution for it. Needed because the DNS Service makes it kinda long. I set it to 100 chars but its just an arbitrary number.

If the address provided is resolvable by the DNS resolver it will use the first resolved entry. Its just for the client. The server would still need to change the config to use a different port.

Yes also looking forward to steam networking. :) if you have more questions feel free to ask.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants