* Changed oldColor to underscore in hook in RandomColor
* WIP
* feat: Updated Basic Example
- PlayerUI is now separated from player object
- PlayerUI is event driven from the Player object
- PlayerUI is locally instantiated, instead of networked
- added border to players panel
* fixed code smells
* moved playersList to BasicNetManager
* fixed compile error and improved layout
* fixed tooltips
Co-authored-by: MrGadget1024 <chris@clevertech.net>
Having near identical lines in these functions is confusing at first glace. Having RegisterWriteFunc call Register makes it more clear exactly what is going on
* formatting
* moving comment about buffer next to buffer
* moving comment to doc comment
* doc comment position
* doc comments for Length
* doc comments for ReadBlittable
* doc comments for ReadBytes
* doc comments for ReadBytesSegment
* doc comments for ToString
* doc comments for NetworkReaderExtensions
* comments for ReadString
* exception comments for read bytes/segement
* fixing comment
* fix(weaver): Warning for multiple write/read functions for the same type
Adding warning message when trying to register a write or read function for a type that is already in dictionary. Previously weaver would be silent about this making it hard to know when an extension method overrides another one.
* test for warnings
* checking buffer length is atleast 2
disconnect if invalid message
* using const instead of magic number
Adding test to make sure that writing id is the same size as IdSize
* adding comment
* renaming to HeaderSize
* delegate and callbacks instead of unityevent
* using callbacks in Mirror
* Using new callbacks instead of events
* moving methods next to each other in NetworkClient
* moving add/remove to methods in NetworkServer
* replacing uses of events within transports and tests
* fixing tests
* fixing more tests
* replacing delegates with actions
* adding comments to show what action variable's are
* removing extra function created in rebase
* renaming callbacks
* adding reset methods so that actions arn't null
* fixing rename
* breaking defines
* Update Assets/Mirror/Runtime/Transport/KCP/MirrorTransport/KcpTransport.cs
* Update KcpTransport.cs
* Update Transport.cs
* removing ResetHandlers methods
transports can now call events after stop is called
Co-authored-by: vis2k <info@noobtuts.com>
* adding try/catch to hanlder
user code can throw errors.
* Update Assets/Mirror/Runtime/MessagePacker.cs
* Update Assets/Mirror/Runtime/MessagePacker.cs
* test for command that throws
* disconnecting client after Exception in message handler
Co-authored-by: vis2k <info@noobtuts.com>
Generating readers and writers for structs in other assemblies
could sometimes cause a
```
System.ArgumentException: Member 'xxx' is declared in another module and needs to be imported
```
This in particular affected unity mathematics.
fixes#2406