// Use this for initialization void Start() { main = GameObject.Find ("Main"); mainkawashima = main.GetComponent<MainKawashima> (); splingObj = GameObject.Find ("NumberSplingText"); splingTxt = splingObj.GetComponent<Text>(); splingTxt.text = cubeSpling.ToString(); splingBtn = GameObject.Find ("ButtonDropSpling"); dropcubeJ = splingBtn.GetComponent<DropCubBtnKawashima> (); straightObj = GameObject.Find ("NumberStraightText"); straightTxt = straightObj.GetComponent<Text>(); straightTxt.text = cubeStraight.ToString(); straightBtn = GameObject.Find ("ButtonDropStraight"); dropcubeS = straightBtn.GetComponent<DropCubBtnKawashima> (); leftObj = GameObject.Find ("NumberLeftText"); leftTxt = leftObj.GetComponent<Text>(); leftTxt.text = cubeLeft.ToString(); leftBtn = GameObject.Find ("ButtonDropLeft"); dropcubeL = leftBtn.GetComponent<DropCubBtnKawashima> (); rightObj = GameObject.Find ("NumberRightText"); rightTxt = rightObj.GetComponent<Text>(); rightTxt.text = cubeRight.ToString(); rightBtn = GameObject.Find ("ButtonDropRight"); dropcubeR = rightBtn.GetComponent<DropCubBtnKawashima> (); //********************************************* 0629 igarashi start bombObj = GameObject.Find ("NumberBombText"); bombTxt = bombObj.GetComponent<Text>(); bombTxt.text = cubeBomb.ToString(); bombBtn = GameObject.Find ("ButtonDropBomb"); dropcubeB= bombBtn.GetComponent<DropCubBtnKawashima> (); //********************************************* 0629 igarashi end if (cubeSpling <=0) { dropcubeJ.isSplingNoMore = true; mainkawashima.isSelected = true; } if (cubeStraight <=0) { dropcubeS.isStraightNoMore = true; mainkawashima.isSelected = true; } if (cubeLeft <=0) { dropcubeL.isLeftNoMore = true; mainkawashima.isSelected = true; } if (cubeRight <=0) { dropcubeR.isRightNoMore = true; mainkawashima.isSelected = true; } if (cubeBomb <=0) { dropcubeB.isBombNoMore = true; mainkawashima.isSelected = true; } }
// Use this for initialization void Start() { main = GameObject.Find ("Main"); mainkawashima = main.GetComponent<MainKawashima> (); splingObj = GameObject.Find ("NumberSplingText"); splingTxt = splingObj.GetComponent<Text>(); splingTxt.text = cubeSpling.ToString(); splingBtn = GameObject.Find ("ButtonDropSpling"); dropcubeJ = splingBtn.GetComponent<DropCubBtnKawashima> (); straightObj = GameObject.Find ("NumberStraightText"); straightTxt = straightObj.GetComponent<Text>(); straightTxt.text = cubeStraight.ToString(); straightBtn = GameObject.Find ("ButtonDropStraight"); dropcubeS = straightBtn.GetComponent<DropCubBtnKawashima> (); leftObj = GameObject.Find ("NumberLeftText"); leftTxt = leftObj.GetComponent<Text>(); leftTxt.text = cubeLeft.ToString(); leftBtn = GameObject.Find ("ButtonDropLeft"); dropcubeL = leftBtn.GetComponent<DropCubBtnKawashima> (); rightObj = GameObject.Find ("NumberRightText"); rightTxt = rightObj.GetComponent<Text>(); rightTxt.text = cubeRight.ToString(); rightBtn = GameObject.Find ("ButtonDropRight"); dropcubeR = rightBtn.GetComponent<DropCubBtnKawashima> (); //********************************************* 0629 igarashi start bombObj = GameObject.Find ("NumberBombText"); bombTxt = bombObj.GetComponent<Text>(); bombTxt.text = cubeBomb.ToString(); bombBtn = GameObject.Find ("ButtonDropBomb"); dropcubeB= bombBtn.GetComponent<DropCubBtnKawashima> (); //********************************************* 0629 igarashi end }