public void Initialize() { for (var i = 0; i < m_poolSize; i++) { var itemDropObj = new ItemDropObj("Coin_Sprite"); itemDropObj.Visible = false; m_itemDropPool.AddToPool(itemDropObj); } }
public void DestroyItemDrop(ItemDropObj itemDrop) { if (this.m_itemDropPool.ActiveObjsList.Contains(itemDrop)) { itemDrop.Visible = false; itemDrop.TextureColor = Color.White; this.m_physicsManager.RemoveObject(itemDrop); this.m_itemDropPool.CheckIn(itemDrop); } }
public void DestroyItemDrop(ItemDropObj itemDrop) { if (m_itemDropPool.ActiveObjsList.Contains(itemDrop)) { itemDrop.Visible = false; itemDrop.TextureColor = Color.White; m_physicsManager.RemoveObject(itemDrop); m_itemDropPool.CheckIn(itemDrop); } }
public void Initialize() { for (int i = 0; i < this.m_poolSize; i++) { ItemDropObj itemDropObj = new ItemDropObj("Coin_Sprite"); itemDropObj.Visible = false; this.m_itemDropPool.AddToPool(itemDropObj); } }