public void firstInit()
 {
     KeyController      = new KeyControl();
     _shipBanner.alpha  = 0f;
     _slotItemTex.alpha = 0f;
     mArsenalManager    = ArsenalTaskManager.GetLogicManager();
     _breakMaterialManager.init();
     Close();
 }
 public void firstInit()
 {
     this.KeyController      = new KeyControl(0, 0, 0.4f, 0.1f);
     this._shipBanner.alpha  = 0f;
     this._slotItemTex.alpha = 0f;
     this.mArsenalManager    = ArsenalTaskManager.GetLogicManager();
     this._breakMaterialManager.init();
     base.Close();
 }
 protected override void OnCallDestroy()
 {
     base.OnCallDestroy();
     MessageSlot             = null;
     mArsenalManager         = null;
     mOnBackListener         = null;
     mKeyController          = null;
     mOnItemSelectedListener = null;
 }
 internal void Initialize(ArsenalManager arsenalManager, SlotitemModel[] items, Camera camera)
 {
     _isFirst        = true;
     _before_focus   = 0;
     mArsenalManager = arsenalManager;
     ArsenalScrollSlotItemListChoiceModel[] models = GenerateModels(arsenalManager, items);
     base.ChangeImmediateContentPosition(ContentDirection.Hell);
     Initialize(models);
     SetSwipeEventCamera(camera);
     Message(items);
 }
Example #5
0
 internal void Initialize(ArsenalManager arsenalManager, SlotitemModel[] items, Camera camera)
 {
     this._isFirst        = true;
     this._before_focus   = 0;
     this.mArsenalManager = arsenalManager;
     ArsenalScrollSlotItemListChoiceModel[] models = this.GenerateModels(arsenalManager, items);
     base.ChangeImmediateContentPosition(UIScrollList <ArsenalScrollSlotItemListChoiceModel, ArsenalScrollItemListChildNew> .ContentDirection.Hell);
     base.Initialize(models);
     base.SetSwipeEventCamera(camera);
     this.Message(items);
 }
        private ArsenalScrollSlotItemListChoiceModel[] GenerateModels(ArsenalManager manager, SlotitemModel[] slotItemModels)
        {
            List <ArsenalScrollSlotItemListChoiceModel> list = new List <ArsenalScrollSlotItemListChoiceModel>();

            foreach (SlotitemModel slotitemModel in slotItemModels)
            {
                bool selected = manager.IsSelected(slotitemModel.MemId);
                ArsenalScrollSlotItemListChoiceModel item = new ArsenalScrollSlotItemListChoiceModel(slotitemModel, selected);
                list.Add(item);
            }
            return(list.ToArray());
        }
Example #7
0
        private ArsenalScrollSlotItemListChoiceModel[] GenerateModels(ArsenalManager manager, SlotitemModel[] slotItemModels)
        {
            List <ArsenalScrollSlotItemListChoiceModel> list = new List <ArsenalScrollSlotItemListChoiceModel>();

            for (int i = 0; i < slotItemModels.Length; i++)
            {
                SlotitemModel slotitemModel = slotItemModels[i];
                bool          selected      = manager.IsSelected(slotitemModel.MemId);
                ArsenalScrollSlotItemListChoiceModel arsenalScrollSlotItemListChoiceModel = new ArsenalScrollSlotItemListChoiceModel(slotitemModel, selected);
                list.Add(arsenalScrollSlotItemListChoiceModel);
            }
            return(list.ToArray());
        }
Example #8
0
        private void Awake()
        {
            ArsenalTaskManager._clsInputKey = new KeyControl(0, 0, 0.4f, 0.1f);
            ArsenalTaskManager._clsInputKey.useDoubleIndex(0, 5);
            ArsenalTaskManager._clsTasks = base.get_gameObject().SafeGetComponent <SceneTasksMono>();
            GameObject gameObject  = base.get_transform().FindChild("TaskArsenalMain").get_gameObject();
            GameObject gameObject2 = gameObject.get_transform().FindChild("Task").get_gameObject();

            ArsenalTaskManager._clsArsenal   = gameObject2.get_transform().FindChild("Arsenal").GetComponent <TaskMainArsenalManager>();
            ArsenalTaskManager._clsConstruct = gameObject2.get_transform().FindChild("Construct").GetComponent <TaskConstructManager>();
            ArsenalTaskManager._clsList      = gameObject2.get_transform().FindChild("TaskArsenalListManager").GetComponent <TaskArsenalListManager>();
            ArsenalTaskManager.logicManager  = new ArsenalManager();
            ArsenalTaskManager.dialogPopUp   = new BaseDialogPopup();
        }
Example #9
0
        private void Awake()
        {
            _clsInputKey = new KeyControl();
            _clsInputKey.useDoubleIndex(0, 5);
            _clsTasks = base.gameObject.SafeGetComponent <SceneTasksMono>();
            GameObject gameObject  = base.transform.FindChild("TaskArsenalMain").gameObject;
            GameObject gameObject2 = gameObject.transform.FindChild("Task").gameObject;

            _clsArsenal   = ((Component)gameObject2.transform.FindChild("Arsenal")).GetComponent <TaskMainArsenalManager>();
            _clsConstruct = ((Component)gameObject2.transform.FindChild("Construct")).GetComponent <TaskConstructManager>();
            _clsList      = ((Component)gameObject2.transform.FindChild("TaskArsenalListManager")).GetComponent <TaskArsenalListManager>();
            logicManager  = new ArsenalManager();
            dialogPopUp   = new BaseDialogPopup();
        }
 private void StartHaiki(ArsenalManager arsenalManager)
 {
     if (mArsenalManager.IsValidBreakItem())
     {
         if (mArsenalManager.BreakItem())
         {
             ItemScroll.LockControl();
             SoundUtils.PlaySE(SEFIleInfos.CommonEnter1);
             mStateManager.PushState(State.SlotItemDestroying);
         }
         else
         {
             CommonPopupDialog.Instance.StartPopup("ロックされている装備があります");
         }
     }
 }
        private void StartHaiki(ArsenalManager arsenalManager)
        {
            bool flag = this.mArsenalManager.IsValidBreakItem();

            if (flag)
            {
                bool flag2 = this.mArsenalManager.BreakItem();
                if (flag2)
                {
                    this.ItemScroll.LockControl();
                    SoundUtils.PlaySE(SEFIleInfos.CommonEnter1);
                    this.mStateManager.PushState(TaskArsenalListManager.State.SlotItemDestroying);
                }
                else
                {
                    CommonPopupDialog.Instance.StartPopup("ロックされている装備があります");
                }
            }
        }
Example #12
0
 private void OnDestroy()
 {
     arsenalManager = null;
     for (int i = 0; i < dockMamager.Length; i++)
     {
         dockMamager[i] = null;
     }
     Mem.DelAry(ref _dock);
     commonDialog = null;
     Mem.DelAry(ref dockMamager);
     _hexMenu               = null;
     _speedDialogManager    = null;
     _dockOpenDialogManager = null;
     _tankerDialog          = null;
     _MainObj               = null;
     _bgObj                    = null;
     _ConstructObj             = null;
     _DismantleObj             = null;
     mLabel_ListHeaderCategory = null;
 }
Example #13
0
 private void OnDestroy()
 {
     TaskMainArsenalManager.arsenalManager = null;
     for (int i = 0; i < TaskMainArsenalManager.dockMamager.Length; i++)
     {
         TaskMainArsenalManager.dockMamager[i] = null;
     }
     Mem.DelAry <BuildDockModel>(ref this._dock);
     this.commonDialog = null;
     Mem.DelAry <UiArsenalDock>(ref TaskMainArsenalManager.dockMamager);
     this._hexMenu                   = null;
     this._speedDialogManager        = null;
     this._dockOpenDialogManager     = null;
     this._tankerDialog              = null;
     TaskMainArsenalManager._MainObj = null;
     this._bgObj                    = null;
     this._ConstructObj             = null;
     this._DismantleObj             = null;
     this.mLabel_ListHeaderCategory = null;
 }
 private void OnDestroy()
 {
     this._bgPanel                           = null;
     this._materialObj                       = null;
     this._dismantleBtn                      = null;
     this._dismantleBtnLight                 = null;
     this._shipBanner                        = null;
     this._slotItemTex                       = null;
     this.ShipScroll                         = null;
     this.ItemScroll                         = null;
     this.mCamera_TouchEventCatch            = null;
     this.mTransform_OverlayButtonForConfirm = null;
     this._breakMaterialManager              = null;
     this.mUIShipSortButton                  = null;
     this.mStateManager                      = null;
     this.mArsenalManager                    = null;
     this.KeyController                      = null;
     this._uiOverlay3                        = null;
     this._uiOverlay4                        = null;
 }
        public void showHighSpeedDialog(int dockNum)
        {
            base.get_transform().GetComponent <UIPanel>().alpha = 1f;
            this.IsShow = true;
            this.Index  = 0;
            this.updateSpeedDialogBtn(0);
            this._maskPanel.get_transform().set_localPosition(Vector3.get_zero());
            this._maskBg.SafeGetTweenAlpha(0f, 0.5f, 0.5f, 0f, UITweener.Method.Linear, UITweener.Style.Once, base.get_gameObject(), string.Empty);
            base.get_transform().set_localPosition(Vector3.get_zero());
            ArsenalTaskManager.GetDialogPopUp().Open(base.get_gameObject(), 0f, 0f, 1f, 1f);
            this._uiOverlayBtn.GetComponent <Collider2D>().set_isTrigger(true);
            ArsenalManager arsenalManager = new ArsenalManager();

            arsenalManager.LargeState = arsenalManager.GetDock(dockNum + 1).IsLarge();
            int buildKit  = arsenalManager.GetMaxForCreateShip().BuildKit;
            int buildKit2 = ArsenalTaskManager.GetLogicManager().Material.BuildKit;

            this._fromLabel.textInt = buildKit2;
            this._toLabel.textInt   = buildKit2 - buildKit;
        }
Example #16
0
        public void showHighSpeedDialog(int dockNum)
        {
            ((Component)base.transform).GetComponent <UIPanel>().alpha = 1f;
            IsShow = true;
            Index  = 0;
            updateSpeedDialogBtn(0);
            _maskPanel.transform.localPosition = Vector3.zero;
            _maskBg.SafeGetTweenAlpha(0f, 0.5f, 0.5f, 0f, UITweener.Method.Linear, UITweener.Style.Once, base.gameObject, string.Empty);
            base.transform.localPosition = Vector3.zero;
            ArsenalTaskManager.GetDialogPopUp().Open(base.gameObject, 0f, 0f, 1f, 1f);
            _uiOverlayBtn.GetComponent <Collider2D>().isTrigger = true;
            ArsenalManager arsenalManager = new ArsenalManager();

            arsenalManager.LargeState = arsenalManager.GetDock(dockNum + 1).IsLarge();
            MaterialInfo maxForCreateShip = arsenalManager.GetMaxForCreateShip();
            int          buildKit         = maxForCreateShip.BuildKit;
            int          buildKit2        = ArsenalTaskManager.GetLogicManager().Material.BuildKit;

            _fromLabel.textInt = buildKit2;
            _toLabel.textInt   = buildKit2 - buildKit;
        }
Example #17
0
 private void OnDestroy()
 {
     UserInterfacePortManager.ReleaseUtils.Releases(ref this.mTextures_Preload, false);
     UserInterfacePortManager.ReleaseUtils.Releases(ref this.mParticleSystems_Managed);
     ArsenalTaskManager._uiCommon     = null;
     ArsenalTaskManager._clsInputKey  = null;
     ArsenalTaskManager._clsTasks     = null;
     ArsenalTaskManager._clsArsenal   = null;
     ArsenalTaskManager._clsConstruct = null;
     ArsenalTaskManager._clsList      = null;
     ArsenalTaskManager.logicManager  = null;
     ArsenalTaskManager.soundManager  = null;
     ArsenalTaskManager.dialogPopUp   = null;
     ArsenalTaskManager.asyncObj      = null;
     ArsenalTaskManager.commonPopup   = null;
     ArsenalTaskManager._uiBgPanel    = null;
     Mem.DelAry <DeckModel>(ref ArsenalTaskManager._deck);
     Mem.DelAry <ShipModel>(ref ArsenalTaskManager._ship);
     Mem.DelAry <ShipModel>(ref ArsenalTaskManager._allShip);
     Mem.DelAry <BuildDockModel>(ref ArsenalTaskManager.dock);
     UIDrawCall.ReleaseInactive();
 }
Example #18
0
 private void OnDestroy()
 {
     UserInterfacePortManager.ReleaseUtils.Releases(ref mTextures_Preload);
     UserInterfacePortManager.ReleaseUtils.Releases(ref mParticleSystems_Managed);
     _uiCommon     = null;
     _clsInputKey  = null;
     _clsTasks     = null;
     _clsArsenal   = null;
     _clsConstruct = null;
     _clsList      = null;
     logicManager  = null;
     soundManager  = null;
     dialogPopUp   = null;
     asyncObj      = null;
     commonPopup   = null;
     _uiBgPanel    = null;
     Mem.DelAry(ref _deck);
     Mem.DelAry(ref _ship);
     Mem.DelAry(ref _allShip);
     Mem.DelAry(ref dock);
     UIDrawCall.ReleaseInactive();
 }
Example #19
0
        protected override bool Init()
        {
            if (!_isCreate)
            {
                IsControl      = true;
                _isEnd         = false;
                isDockSelect   = false;
                CurrentMode    = Mode.MENU_FOCUS;
                KeyController  = ArsenalTaskManager.GetKeyControl();
                arsenalManager = ArsenalTaskManager.GetLogicManager();
                dockMamager    = new UiArsenalDock[4];
                _dock          = arsenalManager.GetDocks();
                _MainObj       = base.scenePrefab.gameObject;
                _bgObj         = base.transform.parent.parent.transform.FindChild("BackGroundPanel").gameObject;
                if (_hexMenu == null)
                {
                    _hexMenu = ((Component)_bgObj.transform.FindChild("HexMenu")).GetComponent <ArsenalHexMenu>();
                }
                if (_speedDialogManager == null)
                {
                    _speedDialogManager = GameObject.Find("TaskArsenalMain/HighSpeedPanel").GetComponent <UiArsenalSpeedDialog>();
                }
                if (_dockOpenDialogManager == null)
                {
                    _dockOpenDialogManager = GameObject.Find("TaskArsenalMain/DockOpenDialog").GetComponent <UiArsenalDockOpenDialog>();
                }
                if (_tankerDialog == null)
                {
                    _tankerDialog = commonDialog.dialogMessages[0].GetComponent <ArsenalTankerDialog>();
                }
                uiCamera = GameObject.Find("Arsenal Root/Camera").GetComponent <UICamera>();
                _hexMenu.Init();
                _speedDialogManager.init();
                _dockOpenDialogManager.init();
                int numOfKeyPossession = arsenalManager.NumOfKeyPossessions;
                for (int i = 0; i < 4; i++)
                {
                    dockMamager[i] = _bgObj.transform.FindChild("Dock" + (i + 1)).SafeGetComponent <UiArsenalDock>();
                    dockMamager[i].init(this, i);
                    dockMamager[i].EnableParticles();
                    if (_dock.Length > i)
                    {
                        dockMamager[i]._setShow();
                        dockMamager[i].HideKeyLock();
                    }
                }
                for (int j = 0; j < 4; j++)
                {
                    if (!dockMamager[j].SelectDockMode())
                    {
                        dockMamager[j].ShowKeyLock();
                        break;
                    }
                }
                Animation component = _bgObj.GetComponent <Animation>();
                component.Stop();
                component.Play();
                if (SingletonMonoBehaviour <PortObjectManager> .exist())
                {
                    SoundUtils.SwitchBGM(BGMFileInfos.PortTools);
                    SingletonMonoBehaviour <PortObjectManager> .Instance.PortTransition.EndTransition(delegate
                    {
                        isCreated();
                    });
                }
                else
                {
                    isCreated();
                }
            }
            else if (!isDockSelect)
            {
                _hexMenu.UpdateButtonForcus();
            }
            if (_dock.Any((BuildDockModel x) => x.Ship != null && x.CompleteTurn != 0))
            {
                SingletonMonoBehaviour <TutorialGuideManager> .Instance.CheckAndShowFirstTutorial(ArsenalTaskManager.GetLogicManager().UserInfo.Tutorial, TutorialGuideManager.TutorialID.SpeedBuild, null);
            }
            TutorialModel tutorial = arsenalManager.UserInfo.Tutorial;

            if (tutorial.GetStep() == 2 && !tutorial.GetStepTutorialFlg(3) && Tutorial == null)
            {
                Tutorial = Util.InstantiatePrefab("TutorialGuide/TutorialGuide3_3", base.gameObject);
                this.DelayActionFrame(2, delegate
                {
                    setTutorialCat();
                });
            }
            setTutorialVisible(isVisible: true);
            IsControl = true;
            return(true);
        }