private void dropItem_DropOccurred(DropSlot slot, API.Serialization.Interfaces.IRiotDroppable drop) { int index = this.itemDrops.ToList().IndexOf(slot); ItemInfo item = drop as ItemInfo; this.Model.Build.SetItem(index, item); }
public void UpdateWeighingInventory() { if (this._inventory == null) { return; } LittleFishersHelpers.DestroyAllChilds(this.transform); for (int i = 0; i < this._inventory.inventorySlots.Count; i++) { GameObject slot = GameObject.Instantiate(weighingSlotPrefab, weighingSlotPrefab.transform.position, Quaternion.identity); slot.transform.SetParent(this.transform); WeighingSlot weighingSlot = slot.GetComponent <WeighingSlot>(); if (weighingSlot != null) { weighingSlot.slotIndex = i; weighingSlot.item = this._inventory.inventorySlots[i].InventoryItem; weighingSlot.SetImage(); } DropSlot dropSlot = slot.GetComponent <DropSlot>(); if (dropSlot != null) { dropSlot.OnBackpackItemDroppedOn += _onBackpackItemDroppedOn; } } }
public void Update() { if (isDragging) { mousePos = Camera.main.ScreenToWorldPoint(Input.mousePosition) - transform.position; transform.Translate(new Vector2(mousePos.x - startPosX, mousePos.y - startPosY)); transform.SetParent(canvas, true); transform.SetAsLastSibling(); // check available slots to see if object is being dropped there closestPivot = ClosestPivot(this.transform); if (closestPivot == null) { target = startPos; } else { target = closestPivot.transform.position; } } else if (hasBeenTouched && (transform.position.x != target.x || transform.position.y != target.y)) { transform.position = Vector2.Lerp(transform.position, target, .1f); } }
private void dropItem_LevelObtainedChanged(DropSlot slot, API.Serialization.Interfaces.IRiotDroppable drop, int level) { int index = this.itemDrops.ToList().IndexOf(slot); this.Model.Build.SetItemLevel(index, level); }
void CheckIfOccupied(DropSlot slot) { if (slot.transform.childCount > 0) { slot.ResetCardOccupier().ResetCardPosition(); } slot.SetOccupied(gameObject); transform.SetParent(slot.transform); }
void Awake() { rectTransform = GetComponent <RectTransform>(); canvas = PlayerUI.instance.gameCanvas.GetComponent <Canvas>(); canvasGroup = GetComponent <CanvasGroup>(); inventoryPanel = PlayerUI.instance.inventoryPanel; slot = GetComponent <Slot>(); oldSlot = transform.parent.GetComponent <DropSlot>(); }
public void ClearSlot() { image.sprite = null; image.enabled = false; DropSlot dropSlot = GetComponent <DragDrop>().oldSlot; dropSlot.MySlot = null; Inventory.instance.freeSlots++; slotDataSave.itemName = ""; slotDataSave.count = 0; Debug.Log("Slot cleared"); }
void SpawnDrop(DropSlot slot) { if (slot.drop != null) { GameObject drop = (GameObject)Instantiate(slot.drop, transform.position + slot.startOffset, Quaternion.identity); if (slot.dropTime > 0.0f) { DropAnimation anim = drop.GetComponent <DropAnimation>(); anim.Throw(transform.position + slot.endOffset, slot.dropTime); } } }
//Add slot cell to inventory void AddSlot() { GameObject _slotPrefab = Instantiate(slotPrefab); _slotPrefab.transform.SetParent(PlayerUI.instance.inventorySlotHolder, false); DropSlot dSlot = _slotPrefab.GetComponent <DropSlot>(); Slot slot = _slotPrefab.transform.GetChild(0).GetComponent <Slot>(); dSlot.MySlot = slot; inventory.Add(slot); slot.inventoryIndex = currentSize; freeSlots++; currentSize++; }
private BackpackSlot AddBackpackSlot(InventorySlot slot) { GameObject newBackpackSlot = GameObject.Instantiate(backpackSlotPrefab); newBackpackSlot.transform.SetParent(this.gridLayoutGroup.transform); // Hook listener for backpackitem drops DropSlot dropSlot = newBackpackSlot.GetComponent <DropSlot>(); if (dropSlot != null) { dropSlot.OnBackpackItemDroppedOn += BackpackItemDroppedOn; } BackpackSlot backpackSlot = newBackpackSlot.GetComponent <BackpackSlot>(); return(backpackSlot); }
public List <DropSlot> GenerateDropSlots() { List <DropSlot> slots = new List <DropSlot>(); if (!this.itemRelations.ContainsKey(this.Item)) { return(slots); } foreach (ItemInfo item in this.itemRelations[this.Item]) { DropSlot component_slot = new DropSlot(); component_slot.Set(item); component_slot.ForeColor = Color.FromArgb(225, 225, 225); component_slot.Type = DropSlot.DataTypes.Item; slots.Add(component_slot); } return(slots); }
public void OnBeginDrag(PointerEventData eventData) { if (canBeDragged) { DropSlot ds = this.transform.parent.GetComponent <DropSlot>(); if (ds != null && ds.isOccupied == true) { ds.isOccupied = false; pp.removeCard(eventData.pointerDrag.gameObject); } currentParent = this.transform.parent; Debug.Log("Beggined dragging"); AudioManagerScript.instance.playCardDraw(); //audio this.transform.SetParent(GameObject.Find("Canvas").transform); GetComponent <CanvasGroup>().blocksRaycasts = false; } }
public void OnDrop(PointerEventData eventData) { if (eventData.pointerEnter != null) { RectTransform icon = eventData.pointerDrag.GetComponent <RectTransform>(); Slot draggedSlot = eventData.pointerDrag.GetComponent <Slot>(); DragDrop dragDrop = draggedSlot.GetComponent <DragDrop>(); //Check if can union into One stack Item thisItem = MySlot.TryGetStackItem(); Item draggedItem = draggedSlot.TryGetStackItem(); if (thisItem != null && draggedItem != null) { if (thisItem.name == draggedItem.name) { int countInStack = MySlot.itemStack.Count; int freeSpace = thisItem.maxStack - countInStack; if (freeSpace > 0) { draggedItem.Count = freeSpace; MySlot.AddItem(draggedItem); draggedSlot.Remove(freeSpace); dragDrop.ReturnToPrevPosition(); return; } } } icon.transform.SetParent(transform); icon.anchoredPosition = slotRect.rect.center; int firstIndex = draggedSlot.inventoryIndex; int secondIndex = MySlot.inventoryIndex; //This old to dragged DropSlot draggedOldDrop = dragDrop.oldSlot; draggedOldDrop.MySlot = slot; slot.GetComponent <DragDrop>().oldSlot = draggedOldDrop; RectTransform thisRect = slot.GetComponent <RectTransform>(); thisRect.transform.SetParent(draggedOldDrop.transform); thisRect.anchoredPosition = draggedOldDrop.slotRect.rect.center; //Dragged to this MySlot = draggedSlot; draggedSlot.GetComponent <DragDrop>().oldSlot = this; SwapTwoInvElements(firstIndex, secondIndex); } }
private void OnMouseUp() { if (State != CardState.HOVERED_A || moving) { return; } Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); RaycastHit[] hits = Physics.RaycastAll(ray); foreach (RaycastHit hit in hits) { DropSlot targetSlot = hit.collider.gameObject.transform.GetComponent <DropSlot>(); if (targetSlot) { if (targetSlot.transform == defaultParent || targetSlot.slotParent == SlotParent.ENEMY) { if (State == CardState.HOVERED_A) { State = CardState.ACTIVE; } else if (State == CardState.HOVERED) { State = CardState.OPEN; } ResetPosition(); return; } //string parentSlotId = Enum.GetName(typeof(DropSlotType), defaultParent.GetComponent<DropSlot>().dropSlotType); string targetSlotId = Enum.GetName(typeof(DropSlotType), targetSlot.dropSlotType); Client.Instance.OnDrop(cardInfo.selfCard.slotId, targetSlotId); GameManager.Instance.freezCards.Add(cardInfo); State = CardState.FREEZED; return; } } ResetPosition(); }
public void DoDrops() { Dictionary <string, float> weightSum = new Dictionary <string, float>(); for (int i = 0; drops != null && i < drops.Length; ++i) { DropSlot drop = drops[i]; if (weightSum.ContainsKey(drop.dropGroup)) { weightSum[drop.dropGroup] = weightSum[drop.dropGroup] + drop.probability; } else { weightSum[drop.dropGroup] = drop.probability; } } foreach (var singleSum in weightSum) { float weight = singleSum.Value * Random.value; for (int i = 0; i < drops.Length; ++i) { DropSlot drop = drops[i]; if (drop.dropGroup == singleSum.Key) { if (drop.probability >= weight) { SpawnDrop(drop); break; } else { weight -= drop.probability; } } } } }
public void AddItem(Item item) { for (int i = 0; i < item.Count; i++) { if (item.isStackable) { //not enough of space in stack if (itemStack.Count == item.maxStack) { int AddedCount = i; item.Count -= AddedCount; Inventory.instance.AddItem(item); item.Count += AddedCount; break; } } itemStack.Push(item); Debug.Log("ITEM ADDED"); //First adding if (itemStack.Count == 1) { Debug.Log(item.itemName + " name"); image.sprite = item.sprite; image.enabled = true; } } stackCountText.text = itemStack.Count.ToString(); if (itemStack.Count > 1) { stackCountText.gameObject.SetActive(true); } DropSlot dropSlot = GetComponent <DragDrop>().oldSlot; dropSlot.MySlot = this; slotDataSave = new SlotDataSave(item, itemStack.Count); Inventory.instance.inventoryUpdated?.Invoke(); }
DropSlot ClosestPivot(Transform pos) { DropSlot closest = null; float lastDistance = Mathf.Infinity; float currentDistance; for (int i = 0; i < slotPivots.Length; i++) { if (Mathf.Abs(pos.position.x - slotPivots[i].transform.position.x) < radius && Mathf.Abs(pos.position.y - slotPivots[i].transform.position.y) < radius) { currentDistance = Vector3.Distance(pos.position, slotPivots[i].transform.position); if (currentDistance < lastDistance) { lastDistance = currentDistance; closest = slotPivots[i]; } } } return(closest); }
// Start is called before the first frame update void Start() { target = GameObject.FindGameObjectWithTag("EnemyCardSlot").transform; enemySlot = GameObject.FindGameObjectWithTag("EnemyCardSlot"). GetComponent <DropSlot>(); }
private void InitializeComponent() { this.components = new System.ComponentModel.Container(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(formBuilder)); this.dropChampion = new RiotPls.UI.Controls.DropSlot(); this.dropItem1 = new RiotPls.UI.Controls.DropSlot(); this.dropItem2 = new RiotPls.UI.Controls.DropSlot(); this.dropItem3 = new RiotPls.UI.Controls.DropSlot(); this.dropItem4 = new RiotPls.UI.Controls.DropSlot(); this.dropItem5 = new RiotPls.UI.Controls.DropSlot(); this.dropItem6 = new RiotPls.UI.Controls.DropSlot(); this.gridMain = new RiotPls.UI.Controls.StatGrid(); this.flowTop = new System.Windows.Forms.FlowLayoutPanel(); this.splitVertical = new System.Windows.Forms.SplitContainer(); this.tabsMain = new System.Windows.Forms.TabControl(); this.tabStats = new System.Windows.Forms.TabPage(); this.tabBuys = new System.Windows.Forms.TabPage(); this.buildcolMain = new RiotPls.UI.Controls.BuySetCollectionView(); ((System.ComponentModel.ISupportInitialize)(this.picLoading)).BeginInit(); this.flowTop.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.splitVertical)).BeginInit(); this.splitVertical.Panel1.SuspendLayout(); this.splitVertical.Panel2.SuspendLayout(); this.splitVertical.SuspendLayout(); this.tabsMain.SuspendLayout(); this.tabStats.SuspendLayout(); this.tabBuys.SuspendLayout(); this.SuspendLayout(); // // picLoading // this.picLoading.Location = new System.Drawing.Point(318, 186); // // dropChampion // this.dropChampion.AllowDrop = true; this.dropChampion.BackColor = System.Drawing.Color.Transparent; this.dropChampion.Location = new System.Drawing.Point(20, 20); this.dropChampion.Margin = new System.Windows.Forms.Padding(20, 20, 5, 20); this.dropChampion.MinimumSize = new System.Drawing.Size(80, 110); this.dropChampion.Name = "dropChampion"; this.dropChampion.NullText = "Champion"; this.dropChampion.Size = new System.Drawing.Size(124, 151); this.dropChampion.TabIndex = 22; this.dropChampion.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Champion; this.dropChampion.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropChampion_DropOccurred); // // dropItem1 // this.dropItem1.AllowDrop = true; this.dropItem1.BackColor = System.Drawing.Color.Transparent; this.dropItem1.Location = new System.Drawing.Point(154, 50); this.dropItem1.Margin = new System.Windows.Forms.Padding(5, 50, 0, 5); this.dropItem1.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem1.Name = "dropItem1"; this.dropItem1.NullText = "Item 1"; this.dropItem1.Size = new System.Drawing.Size(96, 121); this.dropItem1.TabIndex = 23; this.dropItem1.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem1.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem1.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // dropItem2 // this.dropItem2.AllowDrop = true; this.dropItem2.BackColor = System.Drawing.Color.Transparent; this.dropItem2.Location = new System.Drawing.Point(250, 50); this.dropItem2.Margin = new System.Windows.Forms.Padding(0, 50, 0, 5); this.dropItem2.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem2.Name = "dropItem2"; this.dropItem2.NullText = "Item 2"; this.dropItem2.Size = new System.Drawing.Size(96, 121); this.dropItem2.TabIndex = 24; this.dropItem2.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem2.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem2.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // dropItem3 // this.dropItem3.AllowDrop = true; this.dropItem3.BackColor = System.Drawing.Color.Transparent; this.dropItem3.Location = new System.Drawing.Point(346, 50); this.dropItem3.Margin = new System.Windows.Forms.Padding(0, 50, 0, 5); this.dropItem3.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem3.Name = "dropItem3"; this.dropItem3.NullText = "Item 3"; this.dropItem3.Size = new System.Drawing.Size(96, 121); this.dropItem3.TabIndex = 25; this.dropItem3.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem3.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem3.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // dropItem4 // this.dropItem4.AllowDrop = true; this.dropItem4.BackColor = System.Drawing.Color.Transparent; this.dropItem4.Location = new System.Drawing.Point(442, 50); this.dropItem4.Margin = new System.Windows.Forms.Padding(0, 50, 0, 5); this.dropItem4.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem4.Name = "dropItem4"; this.dropItem4.NullText = "Item 4"; this.dropItem4.Size = new System.Drawing.Size(96, 121); this.dropItem4.TabIndex = 26; this.dropItem4.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem4.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem4.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // dropItem5 // this.dropItem5.AllowDrop = true; this.dropItem5.BackColor = System.Drawing.Color.Transparent; this.dropItem5.Location = new System.Drawing.Point(538, 50); this.dropItem5.Margin = new System.Windows.Forms.Padding(0, 50, 0, 5); this.dropItem5.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem5.Name = "dropItem5"; this.dropItem5.NullText = "Item 5"; this.dropItem5.Size = new System.Drawing.Size(96, 121); this.dropItem5.TabIndex = 27; this.dropItem5.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem5.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem5.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // dropItem6 // this.dropItem6.AllowDrop = true; this.dropItem6.BackColor = System.Drawing.Color.Transparent; this.dropItem6.Location = new System.Drawing.Point(634, 50); this.dropItem6.Margin = new System.Windows.Forms.Padding(0, 50, 5, 5); this.dropItem6.MinimumSize = new System.Drawing.Size(80, 110); this.dropItem6.Name = "dropItem6"; this.dropItem6.NullText = "Item 6"; this.dropItem6.Size = new System.Drawing.Size(96, 121); this.dropItem6.TabIndex = 28; this.dropItem6.Type = RiotPls.UI.Controls.DropSlot.DataTypes.Item; this.dropItem6.DropOccurred += new RiotPls.UI.Controls.DropSlot.DropOccurredDelegate(this.dropItem_DropOccurred); this.dropItem6.LevelObtainedChanged += new RiotPls.UI.Controls.DropSlot.LevelObtainedChangedDelegate(this.dropItem_LevelObtainedChanged); // // gridMain // this.gridMain.DataSource = null; this.gridMain.Dock = System.Windows.Forms.DockStyle.Fill; this.gridMain.Location = new System.Drawing.Point(0, 0); this.gridMain.Margin = new System.Windows.Forms.Padding(0); this.gridMain.Name = "gridMain"; this.gridMain.Padding = new System.Windows.Forms.Padding(20, 0, 20, 10); this.gridMain.Size = new System.Drawing.Size(756, 287); this.gridMain.TabIndex = 29; this.gridMain.SelectedRowChanged += new RiotPls.UI.Controls.StatGrid.SelectedRowChangedDelegate(this.gridMain_SelectedRowChanged); // // flowTop // this.flowTop.Controls.Add(this.dropChampion); this.flowTop.Controls.Add(this.dropItem1); this.flowTop.Controls.Add(this.dropItem2); this.flowTop.Controls.Add(this.dropItem3); this.flowTop.Controls.Add(this.dropItem4); this.flowTop.Controls.Add(this.dropItem5); this.flowTop.Controls.Add(this.dropItem6); this.flowTop.Dock = System.Windows.Forms.DockStyle.Fill; this.flowTop.Location = new System.Drawing.Point(0, 0); this.flowTop.Name = "flowTop"; this.flowTop.Size = new System.Drawing.Size(756, 183); this.flowTop.TabIndex = 30; this.flowTop.WrapContents = false; // // splitVertical // this.splitVertical.Dock = System.Windows.Forms.DockStyle.Fill; this.splitVertical.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; this.splitVertical.ImeMode = System.Windows.Forms.ImeMode.Off; this.splitVertical.IsSplitterFixed = true; this.splitVertical.Location = new System.Drawing.Point(0, 0); this.splitVertical.Name = "splitVertical"; this.splitVertical.Orientation = System.Windows.Forms.Orientation.Horizontal; // // splitVertical.Panel1 // this.splitVertical.Panel1.BackColor = System.Drawing.Color.Transparent; this.splitVertical.Panel1.Controls.Add(this.flowTop); // // splitVertical.Panel2 // this.splitVertical.Panel2.BackColor = System.Drawing.Color.Transparent; this.splitVertical.Panel2.Controls.Add(this.gridMain); this.splitVertical.Size = new System.Drawing.Size(756, 474); this.splitVertical.SplitterDistance = 183; this.splitVertical.TabIndex = 31; // // tabsMain // this.tabsMain.Controls.Add(this.tabStats); this.tabsMain.Controls.Add(this.tabBuys); this.tabsMain.Cursor = System.Windows.Forms.Cursors.Default; this.tabsMain.Dock = System.Windows.Forms.DockStyle.Fill; this.tabsMain.Location = new System.Drawing.Point(0, 0); this.tabsMain.Multiline = true; this.tabsMain.Name = "tabsMain"; this.tabsMain.SelectedIndex = 0; this.tabsMain.Size = new System.Drawing.Size(764, 501); this.tabsMain.SizeMode = System.Windows.Forms.TabSizeMode.Fixed; this.tabsMain.TabIndex = 29; // // tabStats // this.tabStats.BackColor = System.Drawing.Color.Black; this.tabStats.Controls.Add(this.splitVertical); this.tabStats.Location = new System.Drawing.Point(4, 23); this.tabStats.Margin = new System.Windows.Forms.Padding(0); this.tabStats.Name = "tabStats"; this.tabStats.Size = new System.Drawing.Size(756, 474); this.tabStats.TabIndex = 0; this.tabStats.Text = "Stats"; // // tabBuys // this.tabBuys.BackColor = System.Drawing.Color.Black; this.tabBuys.Controls.Add(this.buildcolMain); this.tabBuys.Location = new System.Drawing.Point(4, 23); this.tabBuys.Margin = new System.Windows.Forms.Padding(0); this.tabBuys.Name = "tabBuys"; this.tabBuys.Size = new System.Drawing.Size(756, 474); this.tabBuys.TabIndex = 1; this.tabBuys.Text = "Buys"; // // buildcolMain // this.buildcolMain.AutoScroll = true; this.buildcolMain.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; this.buildcolMain.BackColor = System.Drawing.Color.Transparent; this.buildcolMain.Build = null; this.buildcolMain.Dock = System.Windows.Forms.DockStyle.Fill; this.buildcolMain.Location = new System.Drawing.Point(0, 0); this.buildcolMain.Name = "buildcolMain"; this.buildcolMain.Size = new System.Drawing.Size(756, 474); this.buildcolMain.TabIndex = 0; // // formBuilder // this.AllowDrop = true; this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(764, 501); this.CloseButtonEnabled = true; this.Controls.Add(this.tabsMain); this.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(225)))), ((int)(((byte)(225)))), ((int)(((byte)(225))))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.MinimumSize = new System.Drawing.Size(780, 400); this.Name = "formBuilder"; this.Text = "Build #1"; this.VisibleChanged += new System.EventHandler(this.formStatSheet_VisibleChanged); this.Controls.SetChildIndex(this.picLoading, 0); this.Controls.SetChildIndex(this.tabsMain, 0); ((System.ComponentModel.ISupportInitialize)(this.picLoading)).EndInit(); this.flowTop.ResumeLayout(false); this.splitVertical.Panel1.ResumeLayout(false); this.splitVertical.Panel2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.splitVertical)).EndInit(); this.splitVertical.ResumeLayout(false); this.tabsMain.ResumeLayout(false); this.tabStats.ResumeLayout(false); this.tabBuys.ResumeLayout(false); this.ResumeLayout(false); }
// Start is called before the first frame update void Start() { target = GameObject.FindGameObjectWithTag("PlayerCardSlot").transform; playerSlot = GameObject.FindGameObjectWithTag("PlayerCardSlot"). GetComponent <DropSlot>(); }
private void dropChampion_DropOccurred(DropSlot slot, API.Serialization.Interfaces.IRiotDroppable drop) { ChampionInfo champ = drop as ChampionInfo; this.Model.Build.SetChampion(champ); }