Skip to content

Commit 3aa0c41

Browse files
committed
Merge branch 'main' into develop
# Conflicts: # Packages/com.unity.multiplayer.samples.coop/CHANGELOG.md # Packages/com.unity.multiplayer.samples.coop/package.json # Packages/manifest.json # Packages/packages-lock.json
2 parents d075129 + 554bbeb commit 3aa0c41

6 files changed

Lines changed: 17 additions & 33 deletions

File tree

Packages/com.unity.multiplayer.samples.coop/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@
1111
### Fixed
1212
*
1313

14+
## [1.3.1-pre] - 2022-09-13
15+
16+
### Fixed
17+
* Updating ClientNetworkTransform for latest NGO 1.0.1+ (#726) This fixes the new behaviour where both RPCs and netvars were sending the same data. Now CNT is netvar based only, making it send on tick just like NetworkTransform and other network variables would.
18+
1419
## [1.3.0-pre] - 2022-06-23
1520

1621
### Added

Packages/com.unity.multiplayer.samples.coop/Utilities/Net/ClientAuthority/ClientNetworkTransform.cs

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
11
using Unity.Netcode.Components;
2-
using Unity.Netcode;
32
using UnityEngine;
43

54
namespace Unity.Multiplayer.Samples.Utilities.ClientAuthority
65
{
7-
// TODO inherit from `NetworkBehaviour` instead of `NetworkTransform` to cut direct relationship between two
8-
// TODO change to owner netvar instead of RPC based
96
/// <summary>
107
/// Used for syncing a transform with client side changes. This includes host. Pure server as owner isn't supported by this. Please use NetworkTransform
118
/// for transforms that'll always be owned by the server.
@@ -15,31 +12,8 @@ public class ClientNetworkTransform : NetworkTransform
1512
{
1613
/// <summary>
1714
/// Used to determine who can write to this transform. Owner client only.
18-
/// Changing this value alone will not allow you to create a NetworkTransform which can be written to by clients.
19-
/// We're using RPCs to send updated values from client to server. Netcode doesn't support client side network variable writing.
2015
/// This imposes state to the server. This is putting trust on your clients. Make sure no security-sensitive features use this transform.
2116
/// </summary>
22-
// This is public to make sure that users don't depend on this IsClient && IsOwner check in their code. If this logic changes in the future, we can make it invisible here
23-
24-
public override void OnNetworkSpawn()
25-
{
26-
base.OnNetworkSpawn();
27-
CanCommitToTransform = IsOwner;
28-
}
29-
30-
protected override void Update()
31-
{
32-
CanCommitToTransform = IsOwner;
33-
base.Update();
34-
if (NetworkManager.Singleton != null && (NetworkManager.Singleton.IsConnectedClient || NetworkManager.Singleton.IsListening))
35-
{
36-
if (CanCommitToTransform)
37-
{
38-
TryCommitTransformToServer(transform, NetworkManager.LocalTime.Time);
39-
}
40-
}
41-
}
42-
4317
protected override bool OnIsServerAuthoritative()
4418
{
4519
return false;
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
{
22
"name": "com.unity.multiplayer.samples.coop",
33
"displayName": "Multiplayer Samples Utilities",
4-
"version": "1.3.0-pre",
4+
"version": "1.3.1",
55
"type": "template",
66
"host": "hub",
77
"unity": "2020.3",
88
"description": "Utilities package built on top of Netcode for GameObjects, providing useful scripts and tools.",
99
"dependencies": {
1010
"com.unity.learn.iet-framework": "1.2.1",
1111
"com.unity.multiplayer.tools": "1.0.0",
12-
"com.unity.netcode.gameobjects": "1.0.1",
12+
"com.unity.netcode.gameobjects": "1.0.2",
1313
"com.unity.services.relay": "1.0.3"
1414
}
1515
}

Packages/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"com.unity.learn.iet-framework": "2.2.1",
1111
"com.unity.memoryprofiler": "0.5.0-preview.1",
1212
"com.unity.multiplayer.tools": "1.0.0",
13-
"com.unity.netcode.gameobjects": "1.0.1",
13+
"com.unity.netcode.gameobjects": "1.0.2",
1414
"com.unity.performance.profile-analyzer": "1.1.1",
1515
"com.unity.postprocessing": "3.2.1",
1616
"com.unity.render-pipelines.universal": "12.1.6",

Packages/packages-lock.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@
122122
"dependencies": {
123123
"com.unity.learn.iet-framework": "1.2.1",
124124
"com.unity.multiplayer.tools": "1.0.0",
125-
"com.unity.netcode.gameobjects": "1.0.1",
125+
"com.unity.netcode.gameobjects": "1.0.2",
126126
"com.unity.services.relay": "1.0.3"
127127
}
128128
},
@@ -140,7 +140,7 @@
140140
"url": "https://packages.unity.com"
141141
},
142142
"com.unity.netcode.gameobjects": {
143-
"version": "1.0.1",
143+
"version": "1.0.2",
144144
"depth": 0,
145145
"source": "registry",
146146
"dependencies": {

README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
![Banner](Documentation/Images/Banner.png)
2-
# Boss Room - Co-op multiplayer RPG built with Unity Netcode for GameObjects
2+
# Boss Room - Co-op multiplayer RPG and utilities built with Unity Netcode for GameObjects
33

44
| Solutions architects are available on [Discord](https://discord.gg/mNgM2XRDpb) and [forums](https://forum.unity.com/forums/multiplayer.26/) to help you work through issues you may encounter when using Boss Room. |
55
| -- |
@@ -8,6 +8,11 @@ Boss Room is a fully functional co-op multiplayer RPG made with Unity Netcode. I
88

99
You can use everything in this project as a starting point or as bits and pieces in your own Unity games. The project is licensed under the Unity Companion License. See [LICENSE.md](LICENSE.md) for more legal information.
1010

11+
This repo also contains a [Utilities](Packages/com.unity.multiplayer.samples.coop) package, containing sample scripts reusable in your own projects. You can install it using the following manifest file entry:
12+
13+
`"com.unity.multiplayer.samples.coop": "https://github.com/Unity-Technologies/com.unity.multiplayer.samples.coop.git?path=/Packages/com.unity.multiplayer.samples.coop",
14+
`
15+
1116
See [ART_NOTES.md](Documentation/ART_NOTES.md) for more information on the art of Boss Room.
1217

1318
> __IMPORTANT__:
@@ -91,7 +96,7 @@ For an overview of the project's architecture please check out our [ARCHITECTURE
9196

9297
---------------
9398

94-
For a deep dive in Unity Netcode and Boss Room, visit our [doc](https://docs-multiplayer.unity3d.com/) and [Unity Multiplayer Resources](https://docs-multiplayer.unity3d.com/netcode/current/learn/introduction) sections.
99+
For a deep dive in Unity Netcode and Boss Room, visit our [docs site](https://docs-multiplayer.unity3d.com/).
95100

96101
## Bite-size Samples
97102
This repository contains a collection of bitesize sample projects and games that showcase different sub-features of NGO. You can review these samples with documentation to understand APIs and features better.

0 commit comments

Comments
 (0)