Example #1
0
 public void makeAllDissapear()
 {
     Leslie.SetActive(false);
     Jona.SetActive(false);
     Ashita.SetActive(false);
     Catarine.SetActive(false);
     Ramsey.SetActive(false);
     Drogas.SetActive(false);
     Sylvia.SetActive(false);
     Bjin.SetActive(false);
     Xavier.SetActive(false);
 }
Example #2
0
    public void switchChar(Collider2D collin)
    {
        switch (collin.name)
        {
        case "CenterDiamond":
            //if (!CD.GetComponent<Collider2D>().isTrigger)
            //{
            //    CD.GetComponent<Collider2D>().isTrigger = true;
            //}
            makeAllDissapear();
            Leslie.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Leslie";
            curChar = SelectableCharacters.Leslie;
            break;

        case "NorthDiamond":
            makeAllDissapear();
            Jona.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Jona";
            curChar = SelectableCharacters.Jona;
            break;

        case "NorthEastDiamond":
            makeAllDissapear();
            Ashita.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Ashita";
            curChar = SelectableCharacters.Ashita;
            break;

        case "EastDiamond":
            makeAllDissapear();
            Catarine.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Catarine";
            curChar = SelectableCharacters.Catarine;
            break;

        case "SouthEastDiamond":
            makeAllDissapear();
            Ramsey.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Ramsey";
            curChar = SelectableCharacters.Ramsey;
            break;

        case "SouthDiamond":
            makeAllDissapear();
            Drogas.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Drogas";
            curChar = SelectableCharacters.Drogas;
            break;

        case "SouthWestDiamond":
            makeAllDissapear();
            Sylvia.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Sylvia";
            curChar = SelectableCharacters.Sylvia;
            break;

        case "WestDiamond":
            makeAllDissapear();
            Bjin.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Bjin";
            curChar = SelectableCharacters.Bjin;
            break;

        case "NorthWestDiamond":
            makeAllDissapear();
            Xavier.SetActive(true);
            TextObject.GetComponentInChildren <Text>().text = "Xavier";
            curChar = SelectableCharacters.Xavier;
            break;

        default:
            break;
        }
    }