Beispiel #1
0
        //------------------------------------------------------------
        public void Awake()
        {
            playerInventory = FindObjectOfType<Widget_Inventory>();
            store = FindObjectOfType<StoreFront>();
            _weaponManager = FindObjectOfType<WeaponManager>();

            if (!playerInventory)
                Debug.Log("No link to player's inventory.");
            if (!_weaponManager)
            {
                Debug.Log("No link to players weapons.");
            }
        }
Beispiel #2
0
        public void Start()
        {
            var widgetPlayer = GameObject.FindWithTag("Player");
            _inventory = widgetPlayer.GetComponent<Widget_Inventory>();
            //			_laser = GameObject.FindGameObjectWithTag("Laser");
            //			_taser = GameObject.FindGameObjectWithTag("Taser");
            _weaponManager = FindObjectOfType<WeaponManager>();

            _weaponManager.HasTaser = true;
        }
Beispiel #3
0
 public void BuyFrom(Widget_Inventory inventory)
 {
     inventory.UseItem(InventoryItem.BOSS_TRAY, bossitem);
     inventory.UseItem(InventoryItem.SCREW, screws);
     inventory.UseItem(InventoryItem.NUT, nuts);
 }
Beispiel #4
0
 // Initialize Player Info------------------
 public void Start()
 {
     playerInfo = FindObjectOfType<Widget_Status>();
     customControls = FindObjectOfType<GUI_CustomControls>();
     playerInvo = FindObjectOfType<Widget_Inventory>();
     playerAttack = FindObjectOfType<Widget_AttackController>();
     player = GameObject.FindWithTag("Player");
 }