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

Direct IP connection UI #116

Draft
wants to merge 1 commit into
base: sample/api-diorama
Choose a base branch
from

Conversation

RikuTheFuffs
Copy link
Contributor

@RikuTheFuffs RikuTheFuffs commented Mar 27, 2023

Description

[UI] Added possibility to specify the IP address of the server you want to connect to

Format of IP address is automatically checked whenever the user finishes writing it

Contribution checklist

[ ] Tests have been added for the project and/or any internal package N/A
[ ] Release notes have been added to the project changelog file N/A

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
    [ ] JIRA ticket ID is in the PR title or at least one commit message N/A
    [ ] Include the ticket ID number within the body message of the PR to create a hyperlink N/A

@RikuTheFuffs RikuTheFuffs changed the base branch from develop to sample/api-diorama March 27, 2023 13:32
@RikuTheFuffs RikuTheFuffs changed the title Sample/api diorama direct ip Direct IP connection UI Mar 27, 2023
@RikuTheFuffs RikuTheFuffs requested a review from a team March 27, 2023 13:33
@@ -9,6 +10,10 @@ namespace Unity.Netcode.Samples.APIDiorama.Common

public class NetworkManagerUI : MonoBehaviour
{
static readonly Regex s_IPRegex = new Regex("\\b(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(\\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}\\b");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UTP has NetworkEndpoint.TryParse which returns whether it was successful or not, might be worth using that instead of custom implementation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh nice, I didn't know it! Will do

@fernando-cortez fernando-cortez mentioned this pull request Mar 27, 2023
3 tasks
@RikuTheFuffs RikuTheFuffs marked this pull request as draft September 29, 2023 11:31
@RikuTheFuffs
Copy link
Contributor Author

marking as draft as this was done before the UI conversion to UITK, so the UI part must be redone, see https://jira.unity3d.com/browse/MTT-7497

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.

None yet

2 participants