Exemple #1
0
        private void Awake()
        {
            stockPortfolioScript = GetComponent <UpdateStockPortfolio>();
            purchaseStockScript  = GetComponent <PurchaseStock>();

            currentStockValue     = 1000;
            StockChangePercentage = 0;
            StockChangeValue      = 0;
            NumberOfOwnedStocks   = 0;
        }
Exemple #2
0
        private void Awake()
        {
            stockScript          = GetComponent <Stock>();
            stockPortfolioScript = GetComponent <UpdateStockPortfolio>();
            stockName            = stockScript.gameObject.name.ToUpper();

            purchaseButtonText      = purchaseButton.GetComponentInChildren <Text>(true);
            addFiveStocksButtonText = addFiveStocksButton.GetComponentInChildren <Text>(true);
            addTenStocksButtonText  = addTenStocksButton.GetComponentInChildren <Text>(true);
            addMaxStocksButtonText  = addMaxStocksButton.GetComponentInChildren <Text>(true);

            numberOfStocksToPurchase = 0;
            hasOpenedPurchasePanel   = false;
        }