示例#1
0
    public void SetGadget(int index)
    {
        if (Gadget)
        {
            Destroy(Gadget.gameObject);
        }

        Gadget = Instantiate(weaponManager.GetGadget(index), weaponParent);
        Gadget.Init(player);
    }