Skip to content

Commit 972d7d0

Browse files
committed
Fixing PVP errors
1 parent 60ad877 commit 972d7d0

26 files changed

+86
-86
lines changed

com.unity.netcode.gameobjects/Documentation~/advanced-topics/custom-serialization.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ You can also optionally use the same method to add support for `BufferSerializer
4444
```csharp
4545
// The class name doesn't matter here.
4646
public static class SerializationExtensions
47-
{
47+
{
4848
public static void SerializeValue<TReaderWriter>(this BufferSerializer<TReaderWriter> serializer, ref Url url) where TReaderWriter: IReaderWriter
4949
{
5050
if (serializer.IsReader)
@@ -66,7 +66,7 @@ To add custom serialization support in `NetworkVariable`, follow the steps from
6666

6767
```csharp
6868
UserNetworkVariableSerialization<Url>.WriteValue = SerializationExtensions.WriteValueSafe;
69-
UserNetworkVariableSerialization<Url>.ReadValue = SerializationExtensions.ReadValueSafe;
69+
UserNetworkVariableSerialization<Url>.ReadValue = SerializationExtensions.ReadValueSafe;
7070
```
7171

7272
You can also use lambda expressions here:

com.unity.netcode.gameobjects/Documentation~/advanced-topics/fastbufferwriter-fastbufferreader.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ void Serialize(FastBufferWriter writer)
2525
{
2626
if(!writer.TryBeginWrite(sizeof(float) + sizeof(bool) + sizeof(i)))
2727
{
28-
throw new OverflowException("Not enough space in the buffer");
28+
throw new OverflowException("Not enough space in the buffer");
2929
}
3030
writer.WriteValue(f);
3131
writer.WriteValue(b);
@@ -38,7 +38,7 @@ void Serialize(FastBufferWriter writer)
3838
{
3939
if(!writer.TryBeginWrite(sizeof(ExampleStruct)))
4040
{
41-
throw new OverflowException("Not enough space in the buffer");
41+
throw new OverflowException("Not enough space in the buffer");
4242
}
4343
writer.WriteValue(this);
4444
}
@@ -135,8 +135,8 @@ To address that, `FastBufferReader` and `FastBufferWriter` don't, themselves, ha
135135
FastBufferWriter writer = new FastBufferWriter(256, Allocator.TempJob);
136136
using(var bitWriter = writer.EnterBitwiseContext())
137137
{
138-
bitWriter.WriteBit(a);
139-
bitWriter.WriteBits(b, 5);
138+
bitWriter.WriteBit(a);
139+
bitWriter.WriteBits(b, 5);
140140
} // Dispose automatically adds 2 more 0 bits to pad to the next byte.
141141
```
142142

com.unity.netcode.gameobjects/Documentation~/advanced-topics/inscene_parenting_player.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Here is an example script that we recommend using to achieve this:
2424
using Unity.Netcode;
2525

2626
public class ParentPlayerToInSceneNetworkObject : NetworkBehaviour
27-
{
27+
{
2828
public override void OnNetworkSpawn()
2929
{
3030
if (IsServer)

com.unity.netcode.gameobjects/Documentation~/advanced-topics/message-system/reliability.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ void MyReliableServerRpc() { /* ... */ }
2020
void MyUnreliableServerRpc() { /* ... */ }
2121
```
2222

23-
Reliable RPCs will be received on the remote end in the same order they are sent, but this in-order guarantee only applies to RPCs on the same `NetworkObject`. Different `NetworkObjects` might have reliable RPCs called but executed in different order compared to each other. To put more simply, **in-order reliable RPC execution is guaranteed per `NetworkObject` basis only**. If you determine an RPC is being updated often (that is, several times per second), it _might_ be better suited as an unreliable RPC.
23+
Reliable RPCs will be received on the remote end in the same order they are sent, but this in-order guarantee only applies to RPCs on the same `NetworkObject`. Different `NetworkObjects` might have reliable RPCs called but executed in different order compared to each other. To put more simply, **in-order reliable RPC execution is guaranteed per `NetworkObject` basis only**. If you determine an RPC is being updated often (that is, several times per second), it _might_ be better suited as an unreliable RPC.
2424

2525
> [!NOTE]
2626
> When testing unreliable RPCs on a local network, the chance of an unreliable packet being dropped is reduced greatly (sometimes never). As such, you might want to use [`UnityTransport`'s Simulator Pipeline](https://docs-multiplayer.unity3d.com/transport/current/pipelines#simulator-pipeline) to simulate poor network conditions to better determine how dropped unreliable RPC messages impacts your project.

com.unity.netcode.gameobjects/Documentation~/advanced-topics/network-update-loop-system/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ After injection, the player loops follows these stages. The player loop executes
2424
In all `NetworkUpdateStages`, it iterates over an array and calls the `NetworkUpdate` method over `INetworkUpdateSystem` interface, and the pattern is repeated.
2525

2626
<Mermaid chart={`
27-
graph LR;
28-
A(Initialization)
27+
graph LR;
28+
A(Initialization)
2929
B(EarlyUpdate)
3030
C(FixedUpdate)
3131
D(PreUpdate)

com.unity.netcode.gameobjects/Documentation~/advanced-topics/network-update-loop-system/network-update-loop-reference.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# NetworkUpdateLoop reference
1+
# NetworkUpdateLoop reference
22

33
The following diagrams provide insight into the Network Update Loop process and APIs.
44

com.unity.netcode.gameobjects/Documentation~/advanced-topics/object-pooling.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ See [Introduction to Object Pooling](https://learn.unity.com/tutorial/introducti
66

77
## NetworkPrefabInstanceHandler
88

9-
You can register your own spawn handlers by including the `INetworkPrefabInstanceHandler` interface and registering with the `NetworkPrefabHandler`.
9+
You can register your own spawn handlers by including the `INetworkPrefabInstanceHandler` interface and registering with the `NetworkPrefabHandler`.
1010
```csharp
1111
public interface INetworkPrefabInstanceHandler
1212
{

com.unity.netcode.gameobjects/Documentation~/advanced-topics/ways-to-synchronize.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The Netcode for GameObjects messaging system allows you to send and receive mess
1616

1717
### Remote procedure calls (RPCs)
1818

19-
RPCs are a way of sending an event notification as well as a way of handling direct communication between a server and a client, or between clients and the [distributed authority service](../terms-concepts/distributed-authority.md). This is sometimes useful when the ownership scope of the `NetworkBehavior`, that the remote procedure call is declared within, belongs to the server but you still want one or more clients to be able to communicate with the associated NetworkObject.
19+
RPCs are a way of sending an event notification as well as a way of handling direct communication between a server and a client, or between clients and the [distributed authority service](../terms-concepts/distributed-authority.md). This is sometimes useful when the ownership scope of the `NetworkBehavior`, that the remote procedure call is declared within, belongs to the server but you still want one or more clients to be able to communicate with the associated NetworkObject.
2020

2121
Usage examples:
2222

com.unity.netcode.gameobjects/Documentation~/basics/custom-networkvariables.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ This example shows a custom `NetworkVariable` type to help you understand how yo
164164
{
165165
// Do nothing for this example
166166
}
167-
}
167+
}
168168

169169
/// Bare minimum example of generic NetworkVariableBase derived class
170170
[Serializable]

com.unity.netcode.gameobjects/Documentation~/basics/deferred-despawning.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ public class ExplodingProjectile : NetworkBehaviour
155155
m_SpawnedExplosion.SetParticlePlayingState(true);
156156
}
157157
m_ExplosionFx.OnValueChanged -= OnExplosionFxChanged;
158-
}
158+
}
159159
base.OnNetworkDespawn();
160160
}
161161
}

0 commit comments

Comments
 (0)