Esempio n. 1
0
    private IEnumerator RoundPlaying()
    {
        CameraRigControl.RoundStart();

        CanvasControl.MessageText.text = string.Empty;

        EnableControls();

        float timeLeft = PlayTime;

        while (timeLeft >= 0f)
        {
            timeLeft -= Time.deltaTime;
            CanvasControl.UpdateTimer(timeLeft, PlayTime);

            Vector3 pos = CameraRigControl.TopDownCamera.ScreenToWorldPoint(Input.mousePosition);
            pos.y = 1.7f;

            // Vector3 mousePos = Input.mousePosition;
            Player.position = pos;
            Debug.Log(pos);
            yield return(new WaitForEndOfFrame());
        }
    }