using an item in offhand to spawn an entity tames to the player holding the item

Started by Dioxann on

Topic category: Help with Minecraft modding (Java Edition)

Joined Nov 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
using an item in offhand to spawn an entity tames to the player holding the item

so I'm trying to make an item that when you hold it in your offhand will spawn a "cursor" entity that'll attack nearby mobs and protect the player holding the item but I can't figure out how to make sure the entity is tamed to the player so that it follows you around. I'd also like to have a gui you can open to tell the cursor to do different things such as attack on sight, retaliate, or mine