void FixedUpdate() { if (createShootAction) { var action = new ShootAction(this, mousePos); loopTracker.RegisterAction(action); action.PlayAction(); createShootAction = false; if (loopTracker.IsPlayerControlled) { AudioManager.PlayClip(shootAudio, audioVolume, 0.3f); } else { AudioManager.PlayClip(shootAudio, 0.15f, 0.3f); } } if (currFixedFrame % mousePosTrackingInterval == 0) { loopTracker.RegisterMousePos(mousePos); //Debug.Log("Registering mouse pos at fixed frame: " + currFixedFrame); } currFixedFrame++; }