PieManager.cs 669 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PieManager : MonoBehaviour {

    public static int pieCount = 3;
    public static bool pieInScene = false;
    public static bool start = true;
10
    public static int numTargets;
11

12
13
    private void Update()
    {
astatham's avatar
astatham committed
14
15
        if(pieCount == 0){
            return;
16
17
18
19
20
21
22
23
24
25
26
        }
    }

    void Start()
    {
        numTargets = Random.Range(1, 9);
        for (int i = 0; i < 9 - numTargets; i++)
        {
            PieTarget target = FindObjectOfType<PieTarget>();
            target.transform.parent.gameObject.SetActive(false);
        }
27
28
    }
}