private void ExecuteEvent(PlayerMovementEvent playerMovementEvent) { eventEmitter.EmitPlayerMovedEvent( playerObjects[playerMovementEvent.Profile], playerMovementEvent.Position ); }
// Update is called once per fram void Update() { if (!isLocalPlayer) { return; } Vector3?position = ExtractPosition(); if (position == null) { return; } _eventEmitter.EmitPlayerMovedEvent(this.gameObject, position.Value); }