Minecraft / Blogs

Make entities WALK via command blocks! 1.11+

  • 7
  • 2
  • comment7
  • playlist_add
  • share
  • more_horiz
avatar CreeperLadMC
Level 47 : Master Slime Tamer
39
A problem that many adventure map makers come across: trying to make entity movement in their maps cooler than a simple /tp command. I mean, that is neither attractive nor realistic, not to mention very lame and does not fit in very well. Thus, learn to make entities such as villagers, animals or even players walk at a designated pace and direction via command blocks in this tutorial!


Steps:


1. Get a command block, make it a repeating one

2. Type in this command:

/execute @e[type=*chosen entity*,c=1*] ~ ~ ~ tp @e[r=1,c=1] ~0.1 ~ ~ -90 0 (You can also add parameters such as customname to specify your entity should it be necessary.)

3. Run the command block, and your designated entity will walk at a pace of 0.1 block per tick (0.1 seconds) along the x-axis, facing east! You can change the rotation of your entity by altering the last two numbers, which are rotations along the x-axis(north, which is negative along the z-axis, is 0) and y-axis respectively.


Voila! Then, simply configure your circuit to control the duration of the walking, and you have yourself a contraption that makes mobs walk!


Leave a diamond if this is useful to you!
Tags

Comments : 7

star Login or register to post a comment.

Show Comments

1 - 7 of 7

It's very usefull, but how can I add a custom name? I mean a need to set up each single villager to move in a certain area and in a certain direction. How can i specify that?
Does it work for player entities?
  • Acayrin
  • Level 4
  • Apprentice Network
  • July 4, 2017, 7:23 pm
i think that Dragnoz have a better one that make entity move in directions using execute detect command. the video published since version 1.8.

command: execute ENTITY ~ ~ ~ detect ~ ~-1 ~ BLOCK_ID /tp CORDINATES Motion:( ENTITY FACING)
Also you can add more cmd blocks to make entity move multiple directions with facing the same way they moving.
  • CreeperLadMC
  • Level 47
  • Master Slime Tamer
  • July 7, 2017, 2:20 am
Actually the two commands are basically identical but whatever xD
  • bvx
  • Level 21
  • Expert Cowboy
  • July 2, 2017, 9:38 am
Very good! This will definitely be useful!

1 - 7 of 7

Show Comments

Planet Minecraft

Browse

Site

© 2010 - 2019
planetminecraft.com

Welcome