2018-04-13 17:19:50 +08:00
|
|
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
|
|
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|
|
|
|
|
|
|
using OpenTK.Graphics;
|
|
|
|
using osu.Game.Graphics;
|
|
|
|
|
|
|
|
namespace osu.Game.Users
|
|
|
|
{
|
|
|
|
public abstract class UserStatus
|
|
|
|
{
|
|
|
|
public abstract string Message { get; }
|
|
|
|
public abstract Color4 GetAppropriateColour(OsuColour colours);
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public class UserStatusOnline : UserStatus
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
2018-04-26 18:57:24 +08:00
|
|
|
public override string Message => @"Online";
|
2018-04-13 17:19:50 +08:00
|
|
|
public override Color4 GetAppropriateColour(OsuColour colours) => colours.BlueDarker;
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public abstract class UserStatusBusy : UserStatusOnline
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
|
|
|
public override Color4 GetAppropriateColour(OsuColour colours) => colours.YellowDark;
|
|
|
|
}
|
|
|
|
|
|
|
|
public class UserStatusOffline : UserStatus
|
|
|
|
{
|
|
|
|
public override string Message => @"Offline";
|
|
|
|
public override Color4 GetAppropriateColour(OsuColour colours) => colours.Gray7;
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public class UserStatusSpectating : UserStatusOnline
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
|
|
|
public override string Message => @"Spectating a game";
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public class UserStatusInLobby : UserStatusOnline
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
|
|
|
public override string Message => @"in Multiplayer Lobby";
|
|
|
|
}
|
|
|
|
|
|
|
|
public class UserStatusSoloGame : UserStatusBusy
|
|
|
|
{
|
|
|
|
public override string Message => @"Solo Game";
|
|
|
|
}
|
|
|
|
|
|
|
|
public class UserStatusMultiplayerGame : UserStatusBusy
|
|
|
|
{
|
|
|
|
public override string Message => @"Multiplaying";
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public class UserStatusModding : UserStatusOnline
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
|
|
|
public override string Message => @"Modding a map";
|
|
|
|
public override Color4 GetAppropriateColour(OsuColour colours) => colours.PurpleDark;
|
|
|
|
}
|
|
|
|
|
2018-04-26 18:57:24 +08:00
|
|
|
public class UserStatusDoNotDisturb : UserStatusBusy
|
2018-04-13 17:19:50 +08:00
|
|
|
{
|
|
|
|
public override string Message => @"Do not disturb";
|
|
|
|
public override Color4 GetAppropriateColour(OsuColour colours) => colours.RedDark;
|
|
|
|
}
|
|
|
|
}
|