When we run the method to change the display name to “My New Name”, it seems to be a 4 step process:
- call SetMyName
- which calls the Command CmdSetDisplayName
- which calls the Server method SetDisplayName
- which updates the SyncVar, calling HandleDisplayTextUpdated
In trying to wrap my head around why so many steps, I modified SetMyName to call the Server method SetDisplayName directly, skipping the Command. This seems to work also. So why exactly do we need the Command?