可点击实体
通过 entityclick 命令为实体添加左键和右键点击功能
这个模组有什么用?
如果你有一个包含 NPC 的服务器,并且希望实现一个可交互的 NPC——当玩家点击它时执行特定命令,你可以使用本模组将命令绑定到实体上。就像 Hypixel 等大型服务器那样。
你可以将此模组与 proxycommand(适用于 Velocity)配合使用,以便在不同服务器之间切换。
/entityclick 命令如何工作?
entityclick 命令分为两类:
添加命令绑定:
/entityclick add hand entity command
- hand:玩家需要按下的鼠标按键,可以是左键或右键
- entity:要绑定命令的实体,可以是 UUID 或选择器
- command:将要执行的命令,不一定需要带 / 前缀
移除命令绑定:
/entityclick remove hand entity
- hand:玩家需要按下的鼠标按键,可以是左键或右键
- entity:要绑定命令的实体,可以是 UUID 或选择器
命令示例
当玩家右键点击最近的盔甲架时添加一条命令:
/entityclick add right @e[type=minecraft:armor_stand, limit=1, sort=nearest] tp @p 100 100 100
当玩家右键点击最近的盔甲架时移除一条命令:
/entityclick remove right @e[type=minecraft:armor_stand, limit=1, sort=nearest]
数据位置
实体的数据存储于 config/clickable-entities/RegisteredEntities.yaml
Clickable Entities
Adds left and right click functionality to entities with the entityclick command
For what would I use this mod?
If you have a server with npc's and you want an interactable npc that executes a command when it is clicked, you can bind a command with this mod to the entity. Just like big servers such as Hypixel.
You can pair this mod with something like proxycommand for velocity to change between servers
How does the /entityclick command work?
The entityclick command is divided in 2 categories
Add a command binding:
/entityclick add hand entity command
- hand: the mouse button the player has to press, can be left or right
- entity: the entity the command will be bound to, can be a UUID or a selector
- command: the command that will be executed, doesn't necessarily need the / prefix
Remove a command binding:
/entityclick remove hand entity
- hand: the mouse button the player has to press, can be left or right
- entity: the entity the command will be bound to, can be a UUID or a selector
Command Examples
To add a command when the player right-clicks the nearest armor stand
/entityclick add right @e[type=minecraft:armor_stand, limit=1, sort=nearest] tp @p 100 100 100
To remove a command when the player right-clicks the nearest armor stand
/entityclick remove right @e[type=minecraft:armor_stand, limit=1, sort=nearest]
Data Location
Data about the entities is stored under config/clickable-entities/RegisteredEntities.yaml
评论 0
登录后参与评分
还没有评论,来抢沙发吧