public void SmallOpen(int index) { tem temm = new tem(); tem tempTem = temMgr.GetItemList(element.SmallItemIndex[index]); temm = tempTem.DeepCopy(); Open(temm); }
public tem GetItemList(int Index) { tem tem = temDatas.Find(data => data.index == Index); tem copyTem = new tem(); if (tem != null) { copyTem = tem.DeepCopy(); return(copyTem); } else { print(Index + "(이)라는 인덱스는 없어용!"); return(copyTem); } }
public void Combine() { if (CanCombine) { tem item = new tem(); item = element.DeepCopy(); bool canGet = false; if (item.index != 95) { for (int i = 0; i < item.Count; i++) { PlayerItem.DestroyItem(element.SmallItemIndex[0]); PlayerItem.DestroyItem(element.SmallItemIndex[1]); PlayerItem.CombineItem(item.DeepCopy()); canGet = true; } } else { PlayerItem.DestroyItem(element.SmallItemIndex[0]); PlayerItem.DestroyItem(element.SmallItemIndex[1]); transform.parent.transform.parent.GetComponent <Player>().leftBullet.GetBullet(30); canGet = true; } if (canGet) { if (player.PlayerIndex == 6) { transform.parent.transform.parent.GetComponent <Player>().leftBullet.GetBullet(20); } Open(item); starEffect.Play(); player.CombineSound(); } } }