/kam command

For Scripted Command
+ Added to Hooks
+ Moved to Player Scripts Tab
This commit is contained in:
Kam committed 2024-03-29 03:38:04 -04:00
1 parent 9c2faa4dce
commit 8952adc444
3 files changed
+4 -6

No files matched your search

@@ -31,7 +31,6 @@ public class CommandCommand extends CommandKamkeelBase {
}
String commandId = args[0];
String[] commandArgs = new String[args.length - 1];
System.arraycopy(args, 1, commandArgs, 0, args.length - 1);
+3 -5
View File
@@ -578,11 +578,9 @@ public class EventHooks {
return false;
}
public static void onScriptedCommand(CustomNPCsEvent.ScriptedCommandEvent event) {
ForgeDataScript handler = ScriptController.Instance.forgeScripts;
if (handler.isEnabled()) {
handler.callScript(EnumScriptType.SCRIPT_COMMAND, event);
}
public static boolean onScriptedCommand(CustomNPCsEvent.ScriptedCommandEvent event) {
ScriptController.Instance.playerScripts.callScript(EnumScriptType.SCRIPT_COMMAND, event);
return NpcAPI.EVENT_BUS.post(event);
}
public static void onCustomGuiButton(IPlayer player, ICustomGui gui, int buttonId) {
@@ -59,6 +59,7 @@ public class GuiScriptPlayers extends GuiScriptInterface {
hookList.add("dialogOpen");
hookList.add("dialogOption");
hookList.add("dialogClose");
hookList.add("scriptCommand");
hookList.add("customGuiClosed");
hookList.add("customGuiButton");
hookList.add("customGuiSlot");