Skip to content

Commit

Permalink
filter -> find fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Lethalchip authored and RReverser committed Jun 18, 2024
1 parent 2bede0b commit d9a5fad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/unity/part-3.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ public class RemotePlayer : MonoBehaviour
canvas.worldCamera = Camera.main;

// Get the username from the PlayerComponent for this object and set it in the UI
PlayerComponent? playerComp = PlayerComponent.FilterByEntityId(EntityId);
PlayerComponent playerComp = PlayerComponent.FindByEntityId(EntityId);
if (playerComp is null)
{
string inputUsername = UsernameElement.text;
Expand All @@ -216,7 +216,7 @@ public class RemotePlayer : MonoBehaviour
Username = playerComp.Username;

// Get the last location for this player and set the initial position
EntityComponent entity = EntityComponent.FilterByEntityId(EntityId);
EntityComponent entity = EntityComponent.FindByEntityId(EntityId);
transform.position = new Vector3(entity.Position.X, entity.Position.Y, entity.Position.Z);

// Register for a callback that is called when the client gets an
Expand Down

0 comments on commit d9a5fad

Please sign in to comment.