伤害跳跃

From Minecraft Parkour Wiki
Revision as of 12:51, 11 June 2022 by Pjx1314 (talk | contribs) (Created page with "我们的想法是利用这种速度守恒来保持尽可能多的垂直速度,这是一个跳跃的开始(0.42m/t)。在最佳情况下,跳跃高度的最大值达到约1.6685米,允许玩家跳上1.625高的方块。")
Other languages:

伤害跳跃是一种机制,涉及以某种方式受到伤害以提升跳跃高度。

本页面仍需要一个清晰的解释以及代码分析,但主要的想法列在此处。

玩家可以由自然因素受到伤害:坠落,火焰,仙人掌,药水等等……

有意思的是,溺水并不影响玩家的速度。在旧版本的游戏中,溺水会不断地将玩家向下压而使他们困在水中。但是在 1.8 中受到其他种类的伤害,例如药水,同样会使你面对这样的困境。

在跑酷服务器中通常禁用伤害,但这个机制在其它地方有很大作用,例如速通跑酷地图。



介绍:

当受伤时,信息会通过数据包传递给服务器,然后再返回给玩家。对于集成服务器(单人)和专用服务器(多人)都是如此。在这个过程中,玩家的运动被修改:

  • 当玩家的速度与服务器同步时,玩家在受到伤害时保持近似相同的速度。
  • 当玩家的速度与服务器不同步时,玩家似乎会在受到伤害时加速,因为它是以预期的速度更新的。


目前还不清楚玩家的速度何时和如何失去同步,但这里有一些已知的情况:

  • 跑出一个方块,并在最后一刻跳跃
  • 跳到黏液块上
  • 从梯子上下来
  • 处于水中或岩浆中

我们怀疑,失去同步与 NetHandler 独立于移动代码调用 jump() 方法有关。


注意:

  • The phrase "approximately" captures the fact that speed is rounded by 1/8000 towards 0, due to how doubles are stored in the velocity packet
  • Damage taken from natural causes is not the same as knockback, which is applied when the player is hit by an entity.


Synchronized Damage Boost

Taking damage while synchronized with the server conserves the player's velocity over the next tick.

我们的想法是利用这种速度守恒来保持尽可能多的垂直速度,这是一个跳跃的开始(0.42m/t)。在最佳情况下,跳跃高度的最大值达到约1.6685米,允许玩家跳上1.625高的方块。


不同步时的伤害提升

Desynchronized damage makes the player "accelerate in place" (in reality the player's velocity is simply updated). This downward acceleration can be used by redirecting it the other way around by bouncing on a slime block (or a bed, in 1.12+).

Note that you can take fall damage on a slime block and still bounce, by landing on the outline of the block.

Taking damage in a desynchronized state can have other effects which have yet to be fully understood. In particular, the player can prematurely land from a jump, or even activate an artificial jump.


Interaction with Jump Boost

Obviously, the jump boost effect can be combined with damage boost to jump or bounce even higher. What isn't obvious is how the game handles jump boost past level 129, which wraps around to become negative. The exact mechanics involved are still blurry.

In that case, when the player jumps or lands from a jump and takes damage, they can be be flung upwards, with up to 3.9 m/t of initial speed (this upper bound is hard-coded into the velocity packet).

Specifically, for jump boost levels 252 - 256, the player is able to jump, though with less initial speed. In this situation, the glitch can be activated very easily.


Note: jump boost levels 129 - 249 can be abused on slime blocks by simply jumping, as the negative speed is converted into a massive bounce.