Refactored GlobalEventBus

This commit is contained in:
lieght
2025-09-10 14:21:01 +02:00
parent 76ddb0d6b8
commit b722e8fd31
11 changed files with 152 additions and 42 deletions

View File

@@ -0,0 +1,23 @@
package org.toop.eventbus;
import org.toop.server.Server;
/**
* Events that are used in the GlobalEventBus class.
*/
public class Events {
public static class ServerEvents {
/**
* Triggers when a command is sent to a server.
*/
public record OnCommand(Server.Command command, String[] args, Server.Message result) {}
/**
* Triggers on changing the server backend.
*/
public record OnChangingServerBackend(Server.ServerBackend backend) {}
}
}