So I'm trying to make a player teleport to a rabbit mob but the tp command seems to have been updated in some way in the more recent updates.
All the forum threads on a similar subject I've seen suggest that /tp @p @e[tag=test] , which is what I initially tried using, was indeed a functioning command at some point in an older version but for all I've tried so far, it doesn't anymore. I tried executing a command as the mob to tp the player to it but it seems teleporting players to entities has been disabled entirely. Executing a command as the rabbit to tp to me tho works just fine, but that doesnt serve me much purpose. Is there anything I'm missing? Maybe I can use some other commands or like scoreboards or something? I know for a fact those could be used to store data but I haven't delved too deep into them to know if it could be useful here.
So I'm trying to make a player teleport to a rabbit mob but the tp command seems to have been updated in some way in the more recent updates.
All the forum threads on a similar subject I've seen suggest that /tp @p @e[tag=test] , which is what I initially tried using, was indeed a functioning command at some point in an older version but for all I've tried so far, it doesn't anymore. I tried executing a command as the mob to tp the player to it but it seems teleporting players to entities has been disabled entirely. Executing a command as the rabbit to tp to me tho works just fine, but that doesnt serve me much purpose. Is there anything I'm missing? Maybe I can use some other commands or like scoreboards or something? I know for a fact those could be used to store data but I haven't delved too deep into them to know if it could be useful here.
I recently faced the same problem, and read somewhere you have to use the 'limit' argument, because '/tp' expects 1 target:
/tp @p @e[tag=test,limit=1]
Yes, that worked. Apparently all the head scratching it took me to solve this wasn't enough. Thank you so much, couldn't have figured that out myself!
To teleport a player to an entity, simply do
execute at @a run tp @e[type="entity of your choice"] ~ ~ ~
If it is an entity with a name you just add the "name=" tag.
If there is multiple entities, add the "limit=" tag but it will teleport the player to a random one.