DisplayPlayerInfo
This will watch a connected ClientConnection for changes and update a series of connected Text and Image elements to match that ClientConnection's values. This is meant to be part of a dynamically spawned object and the spawner will be in charge of assigning the ClientConnection this component should watch.
Public Virtual Methods
| Method | Description |
|---|---|
| void SetTargetConnection(ClientConnection conn) | Will start watching the ClientConnection that is passed in and immediatly update the assigned Text string values and Image fill values to match what is currently set in that ClientConnection. |
| void UpdateImageSize(int currentHealth) | Will change the health image's fill value between 0 - 1 to match the percentage that the health currently is |
| void UpdateLocationText(string newScene) | Sets the location text to match the input string. |
| void UpdateNameText(string name) | Sets the playerName text to match the input string. |