Minecraft – How to hover minecraft using command blocks

minecraft-commandsminecraft-java-edition

I'm doing a command block creation and I need to know how to "hover" on block over the ground beneath me in survival if tried putting this is my current command but I just keeps me at the same y axis

/tp @a[score_Hover1_min=1] ~ 57 ~

So I could use some help I guess this is a pretty hard question but does anybody know an answer?

Best Answer

You can place a block under the player 20 times a second. To do this create a command block tick clock that executes the command:

execute @e[name=<player name>,type=Player] ~ ~ ~ setblock ~ ~-1 ~ minecraft:sandstone