public void ClearBuffer() { if (monitorControl == null) { Debug.Log("No MonitorLevel in Scene!"); return; } bool values = monitorControl.VerifyValues(); Text errorLog = GameObject.FindGameObjectWithTag("TVErrorLog").GetComponent <Text>(); if (values) { errorLog.text = "Saved Successfully!!!"; CurrentBuffer = null; temp = null; return; } errorLog.text = "Invalid Input!!!"; }
public void RunIsClicked() { if (GameObject.FindGameObjectWithTag("MonitorLevel") == null) { Debug.Log("No MonitorLevel in scene!"); return; } MonitorControl mc = GameObject.FindGameObjectWithTag("MonitorLevel").GetComponent <MonitorControl>(); bool value = mc.VerifyValues(); if (value == false) { return; } BlanketControl bc = GameObject.FindGameObjectWithTag("MonitorLevel").GetComponent <BlanketControl>(); value = bc.AllBlanketHasSheet(); if (value == false) { Debug.Log("Blanket Does not have any sheets"); return; } if (!ButtonIsActive) { _frontOperation.SetRunTrue(); Debug.Log("Operation Buttons: ButtonIsActive true"); ButtonIsActive = true; } else { _frontOperation.SetRunFalse(); ButtonIsActive = false; Debug.Log("Operation Buttons: ButtonIsActive false"); } }