Beispiel #1
0
 // Use this for initialization
 void Awake()
 {
     CustomerInteractionUI = FindObjectOfType <CustomerInteractionUI>();
     pcTrig          = FindObjectOfType <PcTrigger>();
     ShopInventoryUi = FindObjectOfType <ShopInventoryUi>();
     orderui         = orderP.GetComponent <OrderUI> ();
 }
Beispiel #2
0
    private void Awake()
    {
        // Singleton
        if (Instance != null && Instance != this)
        {
            Destroy(gameObject);
        }
        Instance = this;

        moreMoneyButton.gameObject.SetActive(false);
        goAwayButton.gameObject.SetActive(false);
    }
Beispiel #3
0
    void Start()
    {
        cusInt        = FindObjectOfType <CustomerInteractionUI>();
        currentAmount = 0;
        cat           = Enum.GetNames(typeof(ItemCategory));
        max           = cat.Length - 1;
        category.SetText(cat [currentAmount].ToString());
        //butons
        AddShopItems();
        inventoryType = 0;

        shop.GetComponent <Button> ().onClick.AddListener(delegate { SetShopInventory(); });
        inventory.GetComponent <Button>().onClick.AddListener(delegate { SetInventory(); });
        nothing.GetComponent <Button>().onClick.AddListener(delegate { SetNothing(); });
    }
 void Awake()
 {
     cusI    = FindObjectOfType <CustomerInteractionUI> ();
     spawner = FindObjectOfType <AiSpawnManager> ();
 }