private void CreateRoomAckEvent(string reqData, Hashtable roomList) { //Send(s, validUid+":"+roomName+":CreateRoomReq", 1000); String[] roomData = reqData.Split(':'); try { /* example of roomList * key: "fc1202" value:"title" * in this case, fc1202 is the user creating a room called "title" */ roomList.Add(roomData[0], roomData[1]); Console.WriteLine("We have " + roomList.Count.ToString() + " Rooms" + "\n" + roomData[0] + " creates room no." + roomData[1]); //make a room class room = new RoomHandler(); room.StartRoom(tcpClient); room.hostName = roomData[0]; /* example of roomClassList * key: "title" value: room that has been created by clicking a create room button */ roomClassList.Add(roomData[1], room); Send(roomData[1] + ":CreateRoomAck"); } //Handle Exception catch (Exception ex) { Console.WriteLine(ex); return; } }