コード例 #1
0
 public void LogPartsBuild(GameWebAPI.Common_MessageData data)
 {
     CMD_ChatWindow.instance.nowPartsCount++;
     ClassSingleton <ChatData> .Instance.CurrentChatInfo.groupLastHistoryId = data.chatMessageHistoryId.ToString();
     if (base.selectCollider != null)
     {
         GameObject          gameObject = base.AddBuildPart();
         GUIListChatLogParts component  = gameObject.GetComponent <GUIListChatLogParts>();
         if (component != null)
         {
             component.SetOriginalPos(new Vector3(0f, this.ypos, -5f));
             component.RespDataChatMessageDataResult = data;
             this.allListHight += component.listColliderHeight;
         }
         this.hsize = this.allListHight + this.verticalBorder * 2f - this.verticalMargin;
         this.ypos  = this.hsize / 2f - this.startPartH / 2f;
         foreach (GUIListPartBS guilistPartBS in this.partObjs)
         {
             guilistPartBS.gameObject.transform.localPosition = new Vector3(guilistPartBS.gameObject.transform.localPosition.x, this.ypos, guilistPartBS.gameObject.transform.localPosition.z);
             BoxCollider component2 = guilistPartBS.gameObject.GetComponent <BoxCollider>();
             this.ypos -= component2.size.y;
         }
         base.height        = this.hsize;
         base.initEffectFlg = true;
         base.InitMinMaxLocation(-1, 0f);
     }
 }
コード例 #2
0
 public override void ClosePanel(bool animation = true)
 {
     base.ClosePanel(animation);
     CMD_ProfileFriend.friendData     = null;
     CMD_ProfileFriend.chatMemberData = null;
     CMD_ProfileFriend.chatLogData    = null;
 }
コード例 #3
0
        public static Vector3 GetColliderSize(GameWebAPI.Common_MessageData resp, BoxCollider bc, GameObject tmpTxtOb, out string outStr)
        {
            string txt = resp.message;

            if (resp.ngwordFlg == 1)
            {
                txt = StringMaster.GetString("ChatLog-04");
            }
            else if (BlockManager.instance().blockList != null && resp.type != 3)
            {
                int count = BlockManager.instance().blockList.Where((GameWebAPI.FriendList item) => item.userData.userId == resp.userId).ToList <GameWebAPI.FriendList>().Count;
                if (count > 0)
                {
                    txt = StringMaster.GetString("ChatLog-05");
                }
            }
            int num;

            if (resp.type == 4)
            {
                num = 60;
                if (resp.message != null)
                {
                    outStr = resp.message;
                }
                else
                {
                    outStr = string.Empty;
                }
            }
            else if (resp.type == 3)
            {
                num = ChatTools.CheckCommentSize(txt, 635, tmpTxtOb, out outStr) + 30;
            }
            else
            {
                num = ChatTools.CheckCommentSize(txt, 635, tmpTxtOb, out outStr);
            }
            if (resp.type == 3)
            {
                return(new Vector3(bc.size.x, bc.size.y + (float)(num - 30 - 40 - 30), bc.size.z));
            }
            return(new Vector3(bc.size.x, bc.size.y + (float)(num - 30), bc.size.z));
        }