Ejemplo n.º 1
0
    public void SelectedHand()
    {
        string whatHand = RPS_InputManager.GetName();

        if (whatHand != null && intUserHand == -1)
        {
            if (whatHand == "Rock")
            {
                gameObject.GetComponent <SpriteRenderer>().sprite  = RPS_ComputerHands.HandSprite[0];
                gameObject.GetComponent <SpriteRenderer>().enabled = true;
                intUserHand = 0;
            }
            else if (whatHand == "Paper")
            {
                gameObject.GetComponent <SpriteRenderer>().sprite  = RPS_ComputerHands.HandSprite[1];
                gameObject.GetComponent <SpriteRenderer>().enabled = true;
                intUserHand = 1;
            }
            else if (whatHand == "Scissors")
            {
                gameObject.GetComponent <SpriteRenderer>().sprite  = RPS_ComputerHands.HandSprite[2];
                gameObject.GetComponent <SpriteRenderer>().enabled = true;
                intUserHand = 2;
            }

            //RPS_InputManager.IsNotCatched();
        }
    }
Ejemplo n.º 2
0
    public void TouchBubble()
    {
        string name = RPS_InputManager.GetName();

        if (name == "Bubble")
        {
            sayChar();
            s_idx++;

            RPS_InputManager.IsNotCatched();
        }

        //배열이 없어지면 클릭 막기
        if (s_idx > strArrDiscription.Length - 1)
        {
            isFinished = false;
            this.gameObject.SetActive(isFinished);
            BubbleImage.gameObject.SetActive(false);
        }
    }