// Use this for initialization public void CountEverything() { Debug.Log("Run awake"); cRun = GM.currentRun; if (GM.currentRun == null) { return; } juicyCount.text = cRun.juicy.ToString(); crispyCount.text = cRun.crispy.ToString(); perfectCount.text = cRun.perfect.ToString(); int jSum, cSum, pSum; jSum = 5 * cRun.juicy; cSum = 8 * cRun.crispy; pSum = 10 * cRun.perfect; juicySum.text = jSum.ToString(); crispySum.text = cSum.ToString(); perfectSum.text = pSum.ToString(); total = jSum + cSum + pSum; totalText.text = total.ToString(); }
// Use this for initialization public void CountEverything () { Debug.Log("Run awake"); cRun = GM.currentRun; if (GM.currentRun == null) { return; } juicyCount.text = cRun.juicy.ToString(); crispyCount.text = cRun.crispy.ToString(); perfectCount.text = cRun.perfect.ToString(); int jSum,cSum,pSum; jSum = 5*cRun.juicy; cSum = 8*cRun.crispy; pSum = 10*cRun.perfect; juicySum.text = jSum.ToString(); crispySum.text = cSum.ToString(); perfectSum.text = pSum.ToString(); total = jSum + cSum + pSum; totalText.text = total.ToString(); }
public void StartNewGame() { currentRun = new runClass(); currentRun.init(); Debug.Log("new"); Debug.Log(currentRun.chickensleft); StartNewChicken(); }
// Use this for initialization void Start() { UI = GetComponent <uiManager>(); currentRun = new runClass(); currentRun.init(); StartNewChicken(); }
// Use this for initialization void Start () { UI = GetComponent<uiManager>(); currentRun = new runClass(); currentRun.init(); StartNewChicken(); }