Esempio n. 1
0
 public bool doScene(string topic, List <string> memberList)
 {
     if (((memberList == null) || (memberList.Count == 0)) || string.IsNullOrEmpty(topic))
     {
         Log.d("NetSceneCreateChatRoom", "doScene,invalid input para");
         return(false);
     }
     Log.i("NetSceneCreateChatRoom", "doscene begin");
     base.beginBuilder();
     base.mBuilder.BaseRequest = NetSceneBase.makeBaseRequest(0x25);
     base.mBuilder.Topic       = Util.toSKString(topic);
     foreach (string str in memberList)
     {
         base.mBuilder.MemberListList.Add(MemberReq.CreateBuilder().SetMemberName(Util.toSKString(str)).Build());
     }
     base.mBuilder.MemberCount = (uint)memberList.Count;
     base.mSessionPack.mCmdID  = 0x25;
     base.endBuilder();
     return(true);
 }
 public bool doScene(string chatroomName, List <string> usernameList)
 {
     Log.i("NSInviteChatRoomMember", "doscene begin");
     if (string.IsNullOrEmpty(chatroomName) || (usernameList == null))
     {
         return(false);
     }
     base.beginBuilder();
     base.mBuilder.BaseRequest = NetSceneBase.makeBaseRequest(0);
     base.mBuilder.SetChatRoomName(Util.toSKString(chatroomName));
     foreach (string str in usernameList)
     {
         base.mBuilder.MemberListList.Add(MemberReq.CreateBuilder().SetMemberName(Util.toSKString(str)).Build());
     }
     base.mBuilder.SetMemberCount((uint)usernameList.Count);
     base.mSessionPack.mCmdUri      = "/cgi-bin/micromsg-bin/invitechatroommember";
     base.mSessionPack.mConnectMode = 2;
     base.endBuilder();
     return(true);
 }