mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
fix(SyncSet): Change Callback to Action
This commit is contained in:
parent
bed7e81555
commit
527b754061
@ -6,8 +6,7 @@ namespace Mirror
|
||||
{
|
||||
public class SyncSet<T> : SyncObject, ISet<T>
|
||||
{
|
||||
public delegate void SyncSetChanged(Operation op, T item);
|
||||
public event SyncSetChanged Callback;
|
||||
public Action<Operation, T> Callback;
|
||||
|
||||
protected readonly ISet<T> objects;
|
||||
|
||||
|
@ -112,7 +112,7 @@ public void CallbackTest()
|
||||
{
|
||||
bool called = false;
|
||||
|
||||
clientSyncSet.Callback += (op, item) =>
|
||||
clientSyncSet.Callback = (op, item) =>
|
||||
{
|
||||
called = true;
|
||||
|
||||
@ -131,7 +131,7 @@ public void CallbackRemoveTest()
|
||||
{
|
||||
bool called = false;
|
||||
|
||||
clientSyncSet.Callback += (op, item) =>
|
||||
clientSyncSet.Callback = (op, item) =>
|
||||
{
|
||||
called = true;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user