Ejemplo n.º 1
0
    private void SetCommonUI_A_Stage()
    {
        this.goSelectPanelA_StageL = GUIManager.LoadCommonGUI("SelectListPanel/SelectListPanelA_StageL", base.gameObject);
        this.csSelectPanelA_StageL = this.goSelectPanelA_StageL.GetComponent <GUISelectPanelA_StageL>();
        int depth = this.txEVENT_BG.gameObject.GetComponent <UIWidget>().depth - 1;

        DepthController.SetWidgetDepth_Static(this.csSelectPanelA_StageL.transform, depth);
        if (CMD_QuestTOP.AreaData.data.type == "3" || CMD_QuestTOP.AreaData.data.type == "4")
        {
            GameObject gameObject = UnityEngine.Object.Instantiate(Resources.Load("UISelectPanelParam/SelectPanelParamUD_A_StageL_Point")) as GameObject;
            gameObject.transform.parent = base.transform;
            this.csSelectPanelA_StageL.SetSelectPanelParam(gameObject);
        }
        else if (CMD_QuestTOP.AreaData.data.worldAreaId == "3" && this.isScheduleBannerActive)
        {
            GameObject gameObject2 = UnityEngine.Object.Instantiate(Resources.Load("UISelectPanelParam/SelectPanelParamUD_A_StageL_Point")) as GameObject;
            gameObject2.transform.parent = base.transform;
            this.csSelectPanelA_StageL.SetSelectPanelParam(gameObject2);
        }
        else if (CMD_QuestTOP.AreaData.data.type == "6")
        {
            GameObject gameObject3 = UnityEngine.Object.Instantiate(Resources.Load("UISelectPanelParam/SelectPanelParamUD_A_StageL_Detiles")) as GameObject;
            gameObject3.transform.parent = base.transform;
            this.csSelectPanelA_StageL.SetSelectPanelParam(gameObject3);
        }
        Vector3     localPosition = this.goLP_SATGE.transform.localPosition;
        GUICollider component     = this.goSelectPanelA_StageL.GetComponent <GUICollider>();

        component.SetOriginalPos(localPosition);
        this.csSelectPanelA_StageL.selectParts        = this.goLP_SATGE;
        this.csSelectPanelA_StageL.ListWindowViewRect = this.GetRectWindowArea(localPosition);
    }
Ejemplo n.º 2
0
 public void SetMonsterIcon(MonsterData md, bool active)
 {
     if (!active)
     {
         if (this.monsterIcon != null)
         {
             UnityEngine.Object.Destroy(this.monsterIcon.gameObject);
             this.monsterIcon = null;
         }
     }
     else
     {
         if (this.monsterIcon != null)
         {
             UnityEngine.Object.Destroy(this.monsterIcon.gameObject);
         }
         GameObject gameObject = this.charaIcon.gameObject;
         this.monsterIcon = GUIMonsterIcon.MakePrefabByMonsterData(md, gameObject.transform.localScale, gameObject.transform.localPosition, gameObject.transform.parent, true, false);
         UIWidget component = gameObject.GetComponent <UIWidget>();
         if (component != null)
         {
             DepthController.SetWidgetDepth_Static(this.monsterIcon.gameObject.transform, component.depth + 2);
         }
     }
 }
Ejemplo n.º 3
0
    public static GUIMonsterIcon MakeQuestionPrefab(Vector3 vScl, Vector3 vPos, int depth, Transform parent)
    {
        GameObject gameObject = GUIManager.LoadCommonGUI("ListParts/ListPartsThumbnail", null);

        gameObject.SetActive(true);
        GUIMonsterIcon component = gameObject.GetComponent <GUIMonsterIcon>();

        component.transform.parent        = parent;
        component.transform.localScale    = vScl;
        component.transform.localPosition = vPos;
        DepthController.SetWidgetDepth_Static(component.transform, depth);
        component.SetQuestionIcon();
        return(component);
    }
Ejemplo n.º 4
0
    private void SetCommonUI_S_Dungeon()
    {
        this.goSelectPanelS_DungeonR = GUIManager.LoadCommonGUI("SelectListPanel/SelectListPanelS_DungeonR", base.gameObject);
        this.csSelectPanelS_DungeonR = this.goSelectPanelS_DungeonR.GetComponent <GUISelectPanelS_DungeonR>();
        int depth = this.txEVENT_BG.gameObject.GetComponent <UIWidget>().depth - 1;

        DepthController.SetWidgetDepth_Static(this.csSelectPanelS_DungeonR.transform, depth);
        Vector3 localPosition = this.goLP_DNG.transform.localPosition;

        this.goSelectPanelS_DungeonR.transform.localPosition.y = localPosition.x;
        GUICollider component = this.goSelectPanelS_DungeonR.GetComponent <GUICollider>();

        component.SetOriginalPos(localPosition);
        this.csSelectPanelS_DungeonR.selectParts        = this.goLP_DNG;
        this.csSelectPanelS_DungeonR.ListWindowViewRect = this.GetRectWindow(localPosition);
    }
Ejemplo n.º 5
0
        public void Initialize(int baseDepth)
        {
            GameObject original   = AssetDataMng.Instance().LoadObject("UI/Common/CharacterModelViewer", null, true) as GameObject;
            GameObject gameObject = UnityEngine.Object.Instantiate <GameObject>(original);
            Transform  transform  = gameObject.transform;

            transform.parent        = this.viewRoot;
            transform.localScale    = Vector3.one;
            transform.localPosition = this.modelViewPosition;
            transform.localRotation = Quaternion.identity;
            DepthController.SetWidgetDepth_Static(transform, this.modelViewDepth + baseDepth);
            this.modelViewer = gameObject.GetComponent <UI_CharacterModelViewer>();
            Animator component = this.animationRoot.GetComponent <Animator>();

            this.openAnimationEvent  = component.GetBehaviour <ModelViewerOpenAnimationEvent>();
            this.closeAnimationEvent = component.GetBehaviour <ModelViewerCloseAnimationEvent>();
            this.openAnimationEvent.Initialize(component, new Action(this.OnOpendViewer));
            this.closeAnimationEvent.Initialize(component, new Action(this.OnClosedViewer));
            this.OnInitialized();
        }
    private void SetInitLabel()
    {
        this.lbUserName.text    = this.friendData.userData.nickname;
        this.lbUserComment.text = this.friendData.userData.description;
        this.lbLastLogin.text   = this.friendData.userData.loginTime;
        TitleDataMng.SetTitleIcon(this.friendData.userData.titleId, this.goTitleIcon.GetComponent <UITexture>());
        MonsterData monsterData = MonsterDataMng.Instance().CreateMonsterDataByMID(this.friendData.monsterData.monsterId);

        if (monsterData != null)
        {
            GUIMonsterIcon guimonsterIcon = GUIMonsterIcon.MakePrefabByMonsterData(monsterData, this.goMonsterIcon.transform.localScale, this.goMonsterIcon.transform.localPosition, this.goMonsterIcon.transform.parent, true, false);
            if (guimonsterIcon.transform.parent != null)
            {
                UIWidget component = guimonsterIcon.transform.parent.gameObject.GetComponent <UIWidget>();
                if (component != null)
                {
                    DepthController.SetWidgetDepth_Static(guimonsterIcon.transform, component.depth + 2);
                }
            }
        }
    }