We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0d61ea6 commit 4b0660eCopy full SHA for 4b0660e
src/legacy/api/EventAPI.cpp
@@ -838,7 +838,11 @@ void InitBasicEventListeners() {
838
}
839
840
// Other Cmd
841
- IF_LISTENED(EVENT_TYPES::onConsoleCmd) { CallEvent(EVENT_TYPES::onConsoleCmd, String::newString(cmd)); }
+ IF_LISTENED(EVENT_TYPES::onConsoleCmd) {
842
+ if (!CallEvent(EVENT_TYPES::onConsoleCmd, String::newString(cmd))) {
843
+ ev.cancel();
844
+ }
845
846
IF_LISTENED_END(EVENT_TYPES::onConsoleCmd);
847
848
} else if (ev.commandContext().mOrigin->getOriginType() == CommandOriginType::Player) {
0 commit comments