This commit is contained in:
2024-08-21 16:15:22 +02:00
parent cd5f473460
commit 35af9ffc97
38 changed files with 1122 additions and 1090 deletions

View File

@@ -0,0 +1,15 @@
import { system, world } from "@minecraft/server";
function runEntityEventOnTag(tag: string, event: string) {
system.run(() => {
world.getDimension("overworld").runCommand(`/event entity @e[tag=${tag}] ${event}`);
});
}
function setNPCDialog(npcTag: string, dialogId: string) {
system.run(() => {
world.getDimension("overworld").runCommand(`/dialogue change @e[tag=${npcTag}] ${dialogId} @a`);
});
}
export { runEntityEventOnTag, setNPCDialog };