Damage Boost/zh: Difference between revisions

From Minecraft Parkour Wiki
Content added Content deleted
(Created page with "* 当玩家的速度与服务器'''同步'''时,玩家在受到伤害时保持近似相同的速度。")
(Created page with "目前还不清楚玩家的速度何时和如何失去同步,但这里有一些已知的情况:")
Line 23: Line 23:




目前还不清楚玩家的速度何时和如何失去同步,但这里有一些已知的情况:
<div lang="en" dir="ltr" class="mw-content-ltr">
It's not clear when and how the player's velocity gets desynchronized, but here are some known cases:
</div>


* 跑出一个方块,并在最后一刻跳跃
<div lang="en" dir="ltr" class="mw-content-ltr">

* Running off a block and jumping at the last tick
* 跳到黏液块上
* Jumping on a slime block

* Getting off a ladder
* 从梯子上下来
* Being in water or lava

</div>
* 处于水中或岩浆中


<div lang="en" dir="ltr" class="mw-content-ltr">
<div lang="en" dir="ltr" class="mw-content-ltr">

Revision as of 12:42, 11 June 2022

Other languages:

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

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

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

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

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



介绍:

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

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


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

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

It's suspected that desynchronisation is linked to the fact that the NetHandler calls the jump() method independently from the movement code.


Notes:

  • 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.

The idea is to use this speed conservation to maintain as much upward speed as possible, which is at the very start of a jump (0.42m/t). When done optimally, the peak of the jump reaches ~1.6685m, allowing the player to jump up 1.625 blocks.


Desynchronized Damage Boost

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.