コード例 #1
0
 // Use this for initialization
 void Start()
 {
     if (isBlue)
     {
         blueCharacter = this.GetComponent("BlueCharacterActions") as BlueCharacterActions;
         //blueButtons = GameObject.FindGameObjectsWithTag("BlueButton");
         otherCharacter = GameObject.Find("RedCharacter").transform;
     }
     else if (isRed)
     {
         redCharacter = this.GetComponent("RedCharacterActions") as RedCharacterActions;
         //redButtons = GameObject.FindGameObjectsWithTag("RedButton");
         otherCharacter = GameObject.Find("BlueCharacter").transform;
     }
     locationForButton = GetButtonLocations();
     Warnings();
 }
コード例 #2
0
 // Use this for initialization
 void Start()
 {
     beltScript    = transform.parent.GetComponent("BeltScript") as BeltScript;
     blueCharacter = player.GetComponent("BlueCharacterActions") as BlueCharacterActions;
     beltDirection = beltScript.debugNum;
 }