Skip to content

Commit cf12767

Browse files
authored
Update README.md
1 parent 6eea5f0 commit cf12767

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public void SendEvents()
5656

5757
```
5858

59-
## NOTE!
59+
## UNMANAGED NOTE!
6060
Unity Events 2.0 requires that events are [unmanaged](https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/generics/constraints-on-type-parameters) types. This is done to allow better compatibility with the burst compiler when using jobs on events and to encourage "better" programming practices since the events are deferred. References may become stale and GameObjects may have been destroyed and are "null" by the time the event is processed. Send the data the event represents rather than a reference to an object. If a reference is needed then create a look up database and send the id of the object for event listeners to look up to process on. If an array/list is needed then consider using something like [ValueTypeLists](https://gist.github.com/cjddmut/cb43af3ee191af78363f41a3188c0f7b).
6161

6262
## Dropped Features

0 commit comments

Comments
 (0)