public static RoomState GetRoomInfo(int channel) { string result; string page = $"https://osu.ppy.sh/api/get_match?k={MainWindow.apiKey}&mp={channel}"; using (WebClient wc = new WebClient()) { result = wc.DownloadString(page); } RoomState room = JsonConvert.DeserializeObject <RoomState>(result); return(room); }
private void invitePlayers() { roomState = APIThing.GetRoomInfo(channel); }