From ab5826be3cf09f68f663babae1ec93670ed40f5a Mon Sep 17 00:00:00 2001 From: Oliver Date: Sat, 8 Nov 2025 13:36:33 +0100 Subject: [PATCH] docs: Add npc rotate command and inverted need_permission --- docs/src/fancynpcs/commands/npc.md | 7 +++++++ docs/src/fancynpcs/tutorials/action-system.md | 4 ++++ plugins/fancynpcs/CHANGELOG.md | 4 +++- 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/docs/src/fancynpcs/commands/npc.md b/docs/src/fancynpcs/commands/npc.md index 390b8f84..188aee85 100644 --- a/docs/src/fancynpcs/commands/npc.md +++ b/docs/src/fancynpcs/commands/npc.md @@ -177,6 +177,13 @@ Teleports NPC to specified location. - **Syntax**: `/npc move_to (npc) (x) (y) (z) [world] [--look-in-my-direction]` - **Permissions**: `fancynpcs.command.npc.move_to` +### Rotate npc + +Sets the yaw and pitch of the specified NPC. + +- **Syntax**: `/npc rotate (npc) (yaw) (pitch)` +- **Permissions**: `fancynpcs.command.npc.rotate` + ### Center npc location Centers the NPC to the specified location. diff --git a/docs/src/fancynpcs/tutorials/action-system.md b/docs/src/fancynpcs/tutorials/action-system.md index 7030e233..f7f6a54c 100644 --- a/docs/src/fancynpcs/tutorials/action-system.md +++ b/docs/src/fancynpcs/tutorials/action-system.md @@ -122,6 +122,10 @@ Syntax: `need_permission (permission)` Example: `/npc action (npc) (trigger) add need_permission my.cool.permission` +!!!info +If you add the `!` prefix to the permission, the action will be inverted. This means that the action list will be canceled if the player has the permission. +!!! + ### play_sound Plays a sound to the player. This action is useful for creating audio feedback for the player when interacting with the NPC. diff --git a/plugins/fancynpcs/CHANGELOG.md b/plugins/fancynpcs/CHANGELOG.md index 7f523934..d9c6b6fe 100644 --- a/plugins/fancynpcs/CHANGELOG.md +++ b/plugins/fancynpcs/CHANGELOG.md @@ -1,4 +1,6 @@ - Added support for 1.21.11 - Fixed skin mirroring for 1.21.9 +- Added inverted permission check for `need_permission` action (use prefix `!` to invert) +- Added `/npc rotate ` command to set NPC orientation - Added `swing_arm_on_update` config option -- Added `use-minecraft-usercache` feature flag \ No newline at end of file +- Added `use-minecraft-usercache` feature flag