コード例 #1
0
    public void ShowInventory()
    {
        Inventories = GameManager.Inst().UiManager.InventoryScroll.GetComponent <InventoryScroll>();
        Inventories.transform.SetParent(InventoryArea.transform, false);
        Inventories.SetSlotType(2);
        Inventories.ShowInventory();

        Sort();
    }
コード例 #2
0
    void ShowInventory()
    {
        SelectableType = 0;

        Inventories = GameManager.Inst().UiManager.InventoryScroll.GetComponent <InventoryScroll>();
        Inventories.transform.SetParent(InventoryArea.transform, false);
        Inventories.SetSlotType(1);

        Inventories.ShowInventory();
    }
コード例 #3
0
    public void ShowInventory()
    {
        gameObject.SetActive(true);

        Inventories = GameManager.Inst().UiManager.InventoryScroll.GetComponent <InventoryScroll>();
        Inventories.transform.SetParent(InventoryArea.transform, false);
        Inventories.SetSlotType(0);

        ShowInventoryCount();
        Inventories.ShowInventory();
    }
コード例 #4
0
    void ShowInventory()
    {
        Inventories = GameManager.Inst().UiManager.InventoryScroll.GetComponent <InventoryScroll>();
        Inventories.transform.SetParent(InventoryArea.transform, false);
        Inventories.SetSlotType(1);

        Inventories.ShowInventory();

        for (int i = 0; i < Constants.MAXBULLETS; i++)
        {
            if (GameManager.Inst().UpgManager.BData[i].GetEquipIndex() != -1)
            {
                InventorySlot slot = Inventories.GetSlot(Inventories.GetSwitchedIndex(GameManager.Inst().UpgManager.BData[i].GetEquipIndex()));
                slot.EMark.SetActive(true);
            }
        }
    }
コード例 #5
0
    public void SetInventory()
    {
        InventoryScroll inventory = UiManager.InventoryScroll.GetComponent <InventoryScroll>();

        for (int i = 0; i < Player.MaxInventory; i++)
        {
            GameObject inventorySlot = ObjManager.MakeObj("InventorySlot");
            inventory.SetPhysicalInventory(i, inventorySlot);
            inventorySlot.transform.SetParent(inventory.Contents.transform, false);
            InventorySlot slot = inventorySlot.GetComponent <InventorySlot>();
            slot.SetIndex(i);
            slot.SetType(-1);
            inventory.SetInventory(i, slot);
            inventorySlot.name = i.ToString();
        }

        inventory.Contents.SetActive(false);
    }