Minecraft execute random command [duplicate]
Update: To be clear, I've got 3 commands, and I want 1 of the 3 to execute, effectively on loop.
I've got a couple command blocks, each with some commands, and I want them to execute at random intervals.
My strategy so far is to use chickens that wonder in a pen stepping on pressure plates, but they don't move often enough and I'd rather not just resort to duplicting commands:
I've tried a lot of ideas with the chickens, (speed effects, spawning an entity holding seeds), but I think I'll need something better.
Any ideas?
I've found a potential solution that uses a chicken and an ocelot. Summon a chicken with Speed II and Instant Health II and a regular ocelot - the ocelot will chase the chicken around continuously, triggering pressure plates, and the chicken will never die.
Command to spawn a chicken (1.15): /summon chicken ~ ~1 ~ {PersistenceRequired:1,CustomName:"\"Always running 2\"",ActiveEffects:[{Id:1,Amplifier:1,Duration:999999},{Id:6,Amplifier:1,Duration:999999}]}