void Update() { //handle popup when the stomach wall is burning for (int i = 0; i < 6; i++) { if (i != 3) { StomachCell cell = cellScripts [i]; if ((cell.getCellState() == "burning") && (cellNumber == -1)) { bucketPopUp = true; cellNumber = i; } if (cell.getCellState() == "slimed") { bucketPopUp = false; } } } }
private float maxElapsedTime = 2f; //!< max amount of time allowed to pass before event change /** * Use this for initialization */ void Start() { // get the reference to the main cell script mainCellScript = gameObject.GetComponent <StomachCell> (); }