2020-12-16 03:31:05 +00:00
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
2022-06-17 07:37:17 +00:00
|
|
|
#nullable disable
|
|
|
|
|
2020-12-16 03:31:05 +00:00
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
2020-12-25 04:38:11 +00:00
|
|
|
namespace osu.Game.Online.Multiplayer
|
2020-12-16 03:31:05 +00:00
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Interface for an out-of-room multiplayer server.
|
|
|
|
/// </summary>
|
|
|
|
public interface IMultiplayerLoungeServer
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Request to join a multiplayer room.
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="roomId">The databased room ID.</param>
|
|
|
|
/// <exception cref="InvalidStateException">If the user is already in the requested (or another) room.</exception>
|
2021-07-08 15:53:10 +00:00
|
|
|
/// <exception cref="InvalidPasswordException">If the room required a password.</exception>
|
2020-12-16 03:31:05 +00:00
|
|
|
Task<MultiplayerRoom> JoinRoom(long roomId);
|
2021-07-08 15:53:10 +00:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Request to join a multiplayer room with a provided password.
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="roomId">The databased room ID.</param>
|
|
|
|
/// <param name="password">The password for the join request.</param>
|
|
|
|
/// <exception cref="InvalidStateException">If the user is already in the requested (or another) room.</exception>
|
|
|
|
/// <exception cref="InvalidPasswordException">If the room provided password was incorrect.</exception>
|
2021-07-09 07:01:45 +00:00
|
|
|
Task<MultiplayerRoom> JoinRoomWithPassword(long roomId, string password);
|
2020-12-16 03:31:05 +00:00
|
|
|
}
|
|
|
|
}
|