2

Player Y Velocity?

Drake__archer's Avatar Drake__archer4/1/24 3:09 pm
4/1/2024 9:17 pm
ScotsMiser's Avatar ScotsMiser
In my data pack, I want to make it so after the player falls for more than 3 blocks, they will explode.

I figured out how to detect their Y velocity, but I just need to know one thing. What is a minecraft player's Y velocity after falling for 3 blocks?

Not including Slow Falling, Cobwebs, or anything like that. Just falling.

Any help would be greatly appreciated!
Posted by Drake__archer's Avatar
Drake__archer
Level 10 : Journeyman Modder
9

Create an account or sign in to comment.

1

1
04/01/2024 9:17 pmhistory
Level 37 : Artisan Miner
ScotsMiser
ScotsMiser's Avatar
You can find th emath needed in the falling discussion here: https://minecraft.wiki/w/Transportation#Methods

Assuming you don't require a perfect answer this spread sheet:
https://docs.google.com/spreadsheets/d/1lDSubbLtuQZCu2JJf7-WMs8NdaVhVSVunLd0WhhwmGI/edit#gid=0
shows that a fall of 3 blocks (starting with a zero Y velocity) would take between 8 & 9 ticks with an end velocity of between -11.700 and -13.034 blocks /sec (-0.585 and -.652 blocks per game tick)
Simple linear interpolation would give

(3-2.695) / (3.346-2.695) X (-0.652- -0.585) + -0.652
0.305 / 0.651 X 0.067 + -0.652
0.469 X 0.067 + -0.652
0.0314 + -0.652
-0.6206 blcoks per game tick

-5/8 ths blocks per game tick (-0.625) is probably close enough for most purposes
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome