Minecraft villagers spawn with fear?

Wo
- in Worlds
7

I'm currently building a casino in my single player world and would like to do something like a horse race only with villagers. However, I have the problem that the villagers do not run away from the zombies all the time and that they drag the race too far. Can someone help me how to spawn villagers in the "state of fear" by command?

oc

Phew, I know quite a few secret commands, only I can't think of one that puts them in a state of fear. Try to set the level of difficulty to difficult?

ob

Maybe try to fence in the villagers (they should have 1 block of space). And then you do it the other way around, i.e. The zombies run to the villagers. This option should go a little better.

Wo

Seems to be working, thanks.

Wo

Hm… I'll try it, good idea ^^

ob

Unfortunately, the solution is not the way you wanted it, sorry.

Wo

Yes, just tried it, they all actually run "together" to the villagers

ob

Oh okay, I see you found another solution:-)