Skip to content

chore: update NGO, tools, authentication and relay packages #690

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

Merged
merged 8 commits into from
Jul 6, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Additional documentation and release notes are available at [Multiplayer Documen
### Added
*
### Changed
* Updated tools, authentication and relay packages (#690)
* Replaced our dependency injection solution with VContainer. (#679)
### Removed
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace Unity.Multiplayer.Samples.BossRoom
{
public static class UnityRelayUtilities
{
private const string kDtlsConnType = "dtls";
const string k_KDtlsConnType = "dtls";

public static async
Task<(string ipv4address, ushort port, byte[] allocationIdBytes, byte[] connectionData, byte[] key, string
Expand All @@ -20,7 +20,7 @@ public static async

try
{
allocation = await Relay.Instance.CreateAllocationAsync(maxConnections, region);
allocation = await RelayService.Instance.CreateAllocationAsync(maxConnections, region);
}
catch (Exception exception)
{
Expand All @@ -31,14 +31,14 @@ public static async

try
{
joinCode = await Relay.Instance.GetJoinCodeAsync(allocation.AllocationId);
joinCode = await RelayService.Instance.GetJoinCodeAsync(allocation.AllocationId);
}
catch (Exception exception)
{
throw new Exception($"Creating join code request has failed: \n {exception.Message}");
}

var dtlsEndpoint = allocation.ServerEndpoints.First(e => e.ConnectionType == kDtlsConnType);
var dtlsEndpoint = allocation.ServerEndpoints.First(e => e.ConnectionType == k_KDtlsConnType);
return (dtlsEndpoint.Host, (ushort)dtlsEndpoint.Port, allocation.AllocationIdBytes,
allocation.ConnectionData, allocation.Key, joinCode);
}
Expand All @@ -50,7 +50,7 @@ public static async
JoinAllocation allocation;
try
{
allocation = await Relay.Instance.JoinAllocationAsync(joinCode);
allocation = await RelayService.Instance.JoinAllocationAsync(joinCode);
}
catch (Exception exception)
{
Expand All @@ -61,7 +61,7 @@ public static async
Debug.Log($"host: {allocation.HostConnectionData[0]} {allocation.HostConnectionData[1]}");
Debug.Log($"client: {allocation.AllocationId}");

var dtlsEndpoint = allocation.ServerEndpoints.First(e => e.ConnectionType == kDtlsConnType);
var dtlsEndpoint = allocation.ServerEndpoints.First(e => e.ConnectionType == k_KDtlsConnType);
return (dtlsEndpoint.Host, (ushort)dtlsEndpoint.Port, allocation.AllocationIdBytes,
allocation.ConnectionData, allocation.HostConnectionData, allocation.Key);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
"references": [
"Unity.Netcode.Components",
"Unity.Netcode.Runtime",
"Unity.Services.Core",
"Unity.Services.Authentication",
"Unity.Services.Relay"
],
"includePlatforms": [],
Expand All @@ -17,4 +15,4 @@
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}
}
8 changes: 3 additions & 5 deletions Packages/com.unity.multiplayer.samples.coop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@
"description": "Utilities package built on top of Netcode for GameObjects, providing useful scripts and tools.",
"dependencies": {
"com.unity.learn.iet-framework": "1.2.1",
"com.unity.multiplayer.tools": "1.0.0-pre.7",
"com.unity.netcode.gameobjects": "1.0.0-pre.10",
"com.unity.services.authentication": "1.0.0-pre.4",
"com.unity.services.lobby": "1.0.0-pre.6",
"com.unity.services.relay": "1.0.2"
"com.unity.multiplayer.tools": "1.0.0",
"com.unity.netcode.gameobjects": "1.0.0",
"com.unity.services.relay": "1.0.3"
}
}
8 changes: 4 additions & 4 deletions Packages/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
"com.unity.ide.vscode": "1.2.5",
"com.unity.learn.iet-framework": "2.2.1",
"com.unity.memoryprofiler": "0.5.0-preview.1",
"com.unity.netcode.gameobjects": "1.0.0-pre.10",
"com.unity.multiplayer.tools": "1.0.0-pre.7",
"com.unity.multiplayer.tools": "1.0.0",
"com.unity.netcode.gameobjects": "1.0.0",
"com.unity.postprocessing": "3.2.1",
"com.unity.render-pipelines.universal": "12.1.6",
"com.unity.services.authentication": "1.0.0-pre.4",
"com.unity.services.authentication": "2.1.1",
"com.unity.services.lobby": "1.0.0-pre.6",
"com.unity.services.relay": "1.0.2",
"com.unity.services.relay": "1.0.3",
"com.unity.test-framework": "1.1.31",
"com.unity.textmeshpro": "3.0.6",
"com.unity.timeline": "1.6.4",
Expand Down
37 changes: 18 additions & 19 deletions Packages/packages-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,15 +121,13 @@
"source": "embedded",
"dependencies": {
"com.unity.learn.iet-framework": "1.2.1",
"com.unity.multiplayer.tools": "1.0.0-pre.7",
"com.unity.netcode.gameobjects": "1.0.0-pre.10",
"com.unity.services.authentication": "1.0.0-pre.4",
"com.unity.services.lobby": "1.0.0-pre.6",
"com.unity.services.relay": "1.0.2"
"com.unity.multiplayer.tools": "1.0.0",
"com.unity.netcode.gameobjects": "1.0.0",
"com.unity.services.relay": "1.0.3"
}
},
"com.unity.multiplayer.tools": {
"version": "1.0.0-pre.7",
"version": "1.0.0",
"depth": 0,
"source": "registry",
"dependencies": {
Expand All @@ -142,7 +140,7 @@
"url": "https://packages.unity.com"
},
"com.unity.netcode.gameobjects": {
"version": "1.0.0-pre.10",
"version": "1.0.0",
"depth": 0,
"source": "registry",
"dependencies": {
Expand All @@ -160,7 +158,7 @@
},
"com.unity.nuget.newtonsoft-json": {
"version": "3.0.2",
"depth": 2,
"depth": 1,
"source": "registry",
"dependencies": {},
"url": "https://packages.unity.com"
Expand Down Expand Up @@ -210,18 +208,19 @@
"url": "https://packages.unity.com"
},
"com.unity.services.authentication": {
"version": "2.0.0",
"depth": 1,
"version": "2.1.1",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.nuget.newtonsoft-json": "3.0.2",
"com.unity.services.core": "1.3.1",
"com.unity.modules.unitywebrequest": "1.0.0"
"com.unity.services.core": "1.4.2",
"com.unity.modules.unitywebrequest": "1.0.0",
"com.unity.ugui": "1.0.0"
},
"url": "https://packages.unity.com"
},
"com.unity.services.core": {
"version": "1.4.0",
"version": "1.4.2",
"depth": 1,
"source": "registry",
"dependencies": {
Expand All @@ -248,32 +247,32 @@
"url": "https://packages.unity.com"
},
"com.unity.services.qos": {
"version": "1.0.0",
"version": "1.0.1",
"depth": 1,
"source": "registry",
"dependencies": {
"com.unity.services.core": "1.3.2",
"com.unity.services.core": "1.4.0",
"com.unity.modules.unitywebrequest": "1.0.0",
"com.unity.nuget.newtonsoft-json": "3.0.1",
"com.unity.nuget.newtonsoft-json": "3.0.2",
"com.unity.services.authentication": "2.0.0",
"com.unity.collections": "1.2.3"
},
"url": "https://packages.unity.com"
},
"com.unity.services.relay": {
"version": "1.0.2",
"version": "1.0.3",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.services.core": "1.4.0",
"com.unity.services.authentication": "2.0.0",
"com.unity.services.qos": "1.0.0",
"com.unity.services.qos": "1.0.1",
"com.unity.modules.unitywebrequest": "1.0.0",
"com.unity.modules.unitywebrequestassetbundle": "1.0.0",
"com.unity.modules.unitywebrequestaudio": "1.0.0",
"com.unity.modules.unitywebrequesttexture": "1.0.0",
"com.unity.modules.unitywebrequestwww": "1.0.0",
"com.unity.nuget.newtonsoft-json": "3.0.1",
"com.unity.nuget.newtonsoft-json": "3.0.2",
"com.unity.transport": "1.0.0"
},
"url": "https://packages.unity.com"
Expand Down