mirror of
https://github.com/chylex/Minecraft-Phantom-Panel.git
synced 2025-10-24 11:23:39 +02:00
21 lines
707 B
C#
21 lines
707 B
C#
namespace Phantom.Common.Data.Replies;
|
|
|
|
public enum InstanceActionFailure : byte {
|
|
AgentDoesNotExist,
|
|
AgentShuttingDown,
|
|
AgentIsNotResponding,
|
|
InstanceDoesNotExist,
|
|
}
|
|
|
|
public static class InstanceActionFailureExtensions {
|
|
public static string ToSentence(this InstanceActionFailure failure) {
|
|
return failure switch {
|
|
InstanceActionFailure.AgentDoesNotExist => "Agent does not exist.",
|
|
InstanceActionFailure.AgentShuttingDown => "Agent is shutting down.",
|
|
InstanceActionFailure.AgentIsNotResponding => "Agent is not responding.",
|
|
InstanceActionFailure.InstanceDoesNotExist => "Instance does not exist.",
|
|
_ => "Unknown error.",
|
|
};
|
|
}
|
|
}
|