Minecraft – How to “fly” with elytra in Minecraft

minecraft-java-edition

In the Minecraft 1.9 snapshots, elytra have been added. They allow you to glide, but they don't allow you to fly. Since you can't fly with elytra, I'm looking for an alternative way to "fly" with them. Has anyone got a good idea?

Best Answer

I've made an item that gives the player a jump boost when held. First, execute the following commands:

/scoreboard objectives add FlyingOrb dummy
/scoreboard objectives add FlyingOrb2 dummy

Then, put the following commands in a command block chain:

/scoreboard players set @a FlyingOrb2 0 {OnGround:1b}
/scoreboard players set @a FlyingOrb2 1 {SelectedItem:{tag:{display:{Name:"Flying Orb"}}}}
/effect @a[score_FlyingOrb_min=1,score_FlyingOrb2=0] clear

/scoreboard players set @a FlyingOrb 0 {OnGround:1b}
/scoreboard players set @a FlyingOrb 1 {OnGround:1b, SelectedItem:{tag:{display:{Name:"Flying Orb"}}}}
/scoreboard players set @a FlyingOrb 2 {OnGround:0b, SelectedItem:{tag:{display:{Name:"Flying Orb"}}}}
/effect @a[score_FlyingOrb_min=1,score_FlyingOrb=1] minecraft:jump_boost 1 40
/effect @a[score_FlyingOrb_min=2,score_FlyingOrb=2] minecraft:jump_boost 1 255

Finally, use an anvil to name a random item "Flying Orb", hold it, jump, and fly away. The code protects you from fall damage, so you won't get hurt if you fall down hard, with or without elytra equipped. The fall damage protection works even if you let go of the item in mid air.

If your computer has trouble running 8 commands each tick, you could remove the first block of code. However, doing so will allow you to jump boosted without fall damage protection if you've just let go of the item, so you have to wait one second after letting go of the item before jumping again.