Exemple #1
0
 private void HideSplashScreen()
 {
     if (mLoadingGui != null)
     {
         mLoadingGui.Dispose();
         mLoadingGui = null;
     }
 }
Exemple #2
0
 private void CleanupLevelCompleteGui()
 {
     if (mLevelCompleteGui != null)
     {
         mLevelCompleteGui.Dispose();
         mLevelCompleteGui = null;
     }
 }
Exemple #3
0
 private void CleanupFirstTimeGui()
 {
     if (mFirstTimeLevelGui != null)
     {
         mFirstTimeLevelGui.Dispose();
         mFirstTimeLevelGui = null;
     }
 }
Exemple #4
0
        private void GetMoreEnergyPressed()
        {
            mOutOfEnergyGui.Dispose();

            InventoryProxy inventoryProxy = GameFacade.Instance.RetrieveProxy <InventoryProxy>();

            inventoryProxy.GetStoreInventory
            (
                InventoryGlobals.ENERGY_STORE_CASH,
                ItemType.ENERGY_REFILL,
                0,
                1,
                delegate(Message buyEnergyResponseMessage)
            {
                XmlDocument xml = new XmlDocument();
                xml.LoadXml((string)buyEnergyResponseMessage.Data[0]);

                List <object> args = new List <object>();
                args.Add(FashionGameTranslation.BUY_ENERGY);
                args.Add
                (
                    String.Format
                    (
                        FashionGameTranslation.REFILL_ENERGY_MESSAGE,
                        (int)float.Parse(xml.SelectSingleNode                                 // stupid floor action
                                         (
                                             "Response/store/itemOffers/itemOffer/price/money/@amount"
                                         ).InnerText)
                    )
                );
                Hangout.Shared.Action okcb = delegate()
                {
                    BuyEnergy(xml.SelectSingleNode("Response/store/itemOffers/itemOffer/@id").InnerText);
                };
                Hangout.Shared.Action cancelcb = ShowOutOfEnergyGui;
                args.Add(okcb);
                args.Add(cancelcb);
                args.Add(FashionGameTranslation.BUY);
                args.Add(FashionGameTranslation.CANCEL);

                GameFacade.Instance.SendNotification(GameFacade.SHOW_CONFIRM, args);
            }
            );
        }
Exemple #5
0
        public override void Dispose()
        {
            base.Dispose();
            mNametag.Dispose();

            if (mPlayIdle != null)
            {
                mPlayIdle.Exit();
            }
        }
        public override void ExitState()
        {
            GameObject.Destroy(mMusicGameObject);
            foreach (KeyValuePair <View, float> kvp in mCameraViews)
            {
                kvp.Key.StopTracking();
            }
            foreach (GameObject cameraTransform in mCameraTransforms)
            {
                GameObject.Destroy(cameraTransform);
            }
            mRunwaySequenceGuiController.Dispose();
            if (mRetrievingPathsCoroutine != null)
            {
                mRetrievingPathsCoroutine.Exit();
            }
            if (mManageShowTask != null)
            {
                mManageShowTask.Exit();
            }
            if (mSwitchViewsTask != null)
            {
                mSwitchViewsTask.Exit();
            }
            if (mRunwayLoopTask != null)
            {
                mRunwayLoopTask.Exit();
            }
            if (mSmoothlyAnimateTask != null)
            {
                mSmoothlyAnimateTask.Exit();
            }

            foreach (KeyValuePair <View, float> kvp in mCameraViews)
            {
                kvp.Key.StopTracking();
            }

            foreach (ITask task in mActiveModelTasks)
            {
                if (task != null)
                {
                    task.Exit();
                }
            }

            if (mActiveCameraTarget != null)
            {
                CleanUpModel(mActiveCameraTarget.gameObject);
            }

            if (mRunwayGameObject != null)
            {
                GameObject.Destroy(mRunwayGameObject);
            }

            if (GameFacade.Instance.HasMediator <FashionGameGui>())
            {
                foreach (ITopLevel fashionGui in GameFacade.Instance.RetrieveMediator <FashionGameGui>().AllGuis)
                {
                    fashionGui.Showing = true;
                }
            }

            if (GameFacade.Instance.HasMediator <ToolbarMediator>())
            {
                GameFacade.Instance.RetrieveMediator <ToolbarMediator>().TopBar.Showing        = true;
                GameFacade.Instance.RetrieveMediator <ToolbarMediator>().NavigationBar.Showing = true;
            }
        }
Exemple #7
0
 public override void Dispose()
 {
     CleanupAsyncFunctions();
     mNametag.Dispose();
     base.Dispose();
 }
Exemple #8
0
 private void RemoveLoadingScreen()
 {
     mLoadingGui.Dispose();
 }
 public override void OnRemove()
 {
     mLoadingGui.Dispose();
     base.OnRemove();
 }