private void CompleteClearMatch(object result) { var data = (Hashtable)result; var returnedGameObject = (GameObject)data["GameObject"]; returnedGameObject.transform.localScale = Vector3.one; ((IItemUI)data["IItemUI"]).Clear(); _pool.ReturnToPool(returnedGameObject); _startedAnims--; if (_startedAnims == 0) { if (OnCompleteAllAnimations != null) { OnCompleteAllAnimations.Invoke(); } } }
private void CompleteShuffle(object result) { var data = (Hashtable)result; var returnedGameObjectFirst = (GameObject)data["GameObjectFirst"]; var returnedGameObjectSecond = (GameObject)data["GameObjectSecond"]; ((IItemUI)data["IItemUIFirst"]).Clear(); ((IItemUI)data["IItemUISecond"]).Clear(); ((ICellUI)data["ICellUIToFirst"]).SetItemVisibleStatus(true); ((ICellUI)data["ICellUIToSecond"]).SetItemVisibleStatus(true); _pool.ReturnToPool(returnedGameObjectFirst); _pool.ReturnToPool(returnedGameObjectSecond); if (OnCompleteAllAnimations != null) { OnCompleteAllAnimations.Invoke(); } }