using System.Collections; using System.Collections.Generic; using UnityEngine; public class PlayerController : MonoBehaviour { public Transform camTransform; private void Update() { if (Input.GetKeyDown(KeyCode.Mouse0)) { ClientSend.PlayerShoot(camTransform.forward); } } private void FixedUpdate() { SendInputToServer(); } private void SendInputToServer() { bool[] _inputs = new bool[] { Input.GetKey(KeyCode.Z), Input.GetKey(KeyCode.S), Input.GetKey(KeyCode.Q), Input.GetKey(KeyCode.D), Input.GetKey(KeyCode.Space) }; ClientSend.PlayerMovement(_inputs); } }