MathBot: Difference between revisions

From Minecraft Parkour Wiki
Content added Content deleted
mNo edit summary
(added SpeedReq)
Line 7: Line 7:
=== Conversion: ===
=== Conversion: ===
{| class="wikitable"
{| class="wikitable"
|RealDistance(bx)
|Real distance of a straight jump, accounting for the player's bounding box.
|-
|RealDistance(bx,bz)
|RealDistance(bx,bz)
|Real distance of a diagonal jump, accounting for the player's bounding box.
|Real distance of a diagonal jump, accounting for the player's bounding box.
If the jump is not diagonal, set bz = 0.
|-
|RealMomentum(bx,bz)
|Real distance of a linear momentum, accounting for the player's bounding box.
If the momentum is not diagonal, set bz = 0.
|-
|-
|Tier(t)
|Tier(t)
Line 66: Line 68:
|-
|-
|Stop(v)
|Stop(v)
|No inputs for one tick, assuming the player is on ground
|No input for one tick, assuming the player is on ground
|-
|-
|Stop_land(v)
|Stop_land(v)
|No inputs for one tick, assuming the player just landed from a jump
|No input for one tick, assuming the player just landed from a jump
|-
|-
|Stop_air(v)
|Stop_air(v)
|No inputs for one tick, assuming the player is and was airborne
|No input for one tick, assuming the player is and was airborne
|}
|}
<br />
<br />


=== Jump Speed ===
=== Jump Speed ===
'''v''' is the input speed, '''t''' is the duration. '''Output''' is a speed value (in m/t).
'''v''' is the input speed, '''t''' is the jump duration. '''Output''' is a speed value (in m/t).
{| class="wikitable"
{| class="wikitable"
|Vh(v,t,J,M)
|Vh(v,t,J,M)
Line 105: Line 107:


=== Chained Jumps Speed ===
=== Chained Jumps Speed ===
'''v''' is the input speed, '''t''' is the duration, '''n''' is the number of jumps. '''Output''' is a speed value (in m/t).
'''v''' is the input speed, '''t''' is the jump duration, '''n''' is the number of jumps. '''Output''' is a speed value (in m/t).
{| class="wikitable"
{| class="wikitable"
|Vchain(v,t,J,M,n)
|Vchain(v,t,J,M,n)
Line 127: Line 129:


=== Jump Distance ===
=== Jump Distance ===
'''v''' is the input speed, '''t''' is the duration. '''Output''' is a distance value (in meters).
'''v''' is the input speed, '''t''' is the jump duration. '''Output''' is a distance value (in meters).
{| class="wikitable"
{| class="wikitable"
|Dist(v,t,J,M)
|Dist(v,t,J,M)
Line 150: Line 152:
|Dist_Strafejump45(v,t)
|Dist_Strafejump45(v,t)
|Distance of a strafejump, facing 45° after jumping
|Distance of a strafejump, facing 45° after jumping
|}
Add '''''_del''''' at the end of the function if the jump is delayed (previous tick was on ground).

<br />

=== Required Speed ===
'''d''' is the input distance, '''t''' is the jump duration. '''Output''' is a speed value (in m/t).
{| class="wikitable"
|SpeedReq(d,t,J,M)
|Required speed for a jump of distance t, and duration t.
J is the jump bonus, M is the movement multiplier.
|-
|SpeedReq_Sprintjump(d,t)
|Required speed for a sprintjump
|-
|SpeedReq_Sprintjump45(v,t)
|Required speed for a sprintjump, facing 45° after jumping
|-
|SpeedReq_Walkjump(v,t)
|Required speed for a no-sprint jump
|-
|SpeedReq_Walkjump45(v,t)
|Required speed for a no-sprint jump, facing 45°
|-
|SpeedReq_Strafejump(v,t)
|Required speed for a strafejump (like on rex bwmm)
|-
|SpeedReq_Strafejump45(v,t)
|Required speed for a strafejump, facing 45° after jumping
|}
|}
Add '''''_del''''' at the end of the function if the jump is delayed (previous tick was on ground).
Add '''''_del''''' at the end of the function if the jump is delayed (previous tick was on ground).

Revision as of 22:15, 30 August 2020

This page lists parkour-related functions defined in MathBot (source).

MathBot sometimes clears functions and variables from memory. To easily redefine functions, use the commands !math1, !math2, and !math3.


Conversion:

RealDistance(bx,bz) Real distance of a diagonal jump, accounting for the player's bounding box.

If the jump is not diagonal, set bz = 0.

RealMomentum(bx,bz) Real distance of a linear momentum, accounting for the player's bounding box.

If the momentum is not diagonal, set bz = 0.

Tier(t) Tier of a jump from its duration in ticks, or vice-versa.


Jump Height:

Vy(t) Vertical speed t ticks after jumping. (t >= 1)
Height(t) Relative height t ticks after jumping. (t >= 0)
Duration(h) Duration of a jump of height h. (h <= max jump height)

Add _new at the end of the function to get 1.9+ values.


Actions:

v is the input speed. Output is a speed value (in m/t).

Sprint(v) Apply a sprint tick, assuming the player is on ground
Sprint_land(v) Apply a sprint tick, assuming the player just landed from a jump
Sprint_air(v) Apply a sprint tick, assuming the player is and was airborne
Sprint45(v) Apply a 45° sprint tick, assuming the player is on ground
Sprint45_land(v) Apply a 45° sprint tick, assuming the player just landed from a jump
Sprint45_air(v) Apply a 45° sprint tick, assuming the player is and was airborne
Walk(v) Apply a walk tick, assuming the player is on ground
... ... (same syntax)
Sneak(v) Apply a sneak tick, assuming the player is on ground
... ... (same syntax)
Stop(v) No input for one tick, assuming the player is on ground
Stop_land(v) No input for one tick, assuming the player just landed from a jump
Stop_air(v) No input for one tick, assuming the player is and was airborne


Jump Speed

v is the input speed, t is the jump duration. Output is a speed value (in m/t).

Vh(v,t,J,M) Apply a jump of duration t, with initial speed v.

J is the jump bonus, M is the movement multiplier.

Sprintjump(v,t) Apply a sprintjump
Sprintjump45(v,t) Apply a sprintjump, facing 45° after jumping
Walkjump(v,t) Apply a no-sprint jump
Walkjump45(v,t) Apply a no-sprint jump, facing 45°
Strafejump(v,t) Apply a strafejump (like on rex bwmm)
Strafejump45(v,t) Apply a strafejump, facing 45° after jumping

Add _del at the end of the function if the jump is delayed (previous tick was on ground).


Chained Jumps Speed

v is the input speed, t is the jump duration, n is the number of jumps. Output is a speed value (in m/t).

Vchain(v,t,J,M,n) Apply n jumps of duration t, with initial speed v.

J is the jump bonus, M is the movement multiplier.

Chain_Sprintjump(v,t,n) Apply a sprintjump
Chain_Sprintjump45(v,t,n) Apply a sprintjump, facing 45° after jumping
Chain_Walkjump(v,t,n) Apply a no-sprint jump
Chain_Walkjump45(v,t,n) Apply a no-sprint jump, facing 45°

Add _del at the end of the function if the first jump is delayed (previous tick was on ground).


Jump Distance

v is the input speed, t is the jump duration. Output is a distance value (in meters).

Dist(v,t,J,M) Distance of jump of duration t, with initial speed v.

J is the jump bonus, M is the movement multiplier.

Dist_Sprintjump(v,t) Distance of a sprintjump
Dist_Sprintjump45(v,t) Distance of a sprintjump, facing 45° after jumping
Dist_Walkjump(v,t) Distance of a no-sprint jump
Dist_Walkjump45(v,t) Distance of a no-sprint jump, facing 45°
Dist_Strafejump(v,t) Distance of a strafejump (like on rex bwmm)
Dist_Strafejump45(v,t) Distance of a strafejump, facing 45° after jumping

Add _del at the end of the function if the jump is delayed (previous tick was on ground).


Required Speed

d is the input distance, t is the jump duration. Output is a speed value (in m/t).

SpeedReq(d,t,J,M) Required speed for a jump of distance t, and duration t.

J is the jump bonus, M is the movement multiplier.

SpeedReq_Sprintjump(d,t) Required speed for a sprintjump
SpeedReq_Sprintjump45(v,t) Required speed for a sprintjump, facing 45° after jumping
SpeedReq_Walkjump(v,t) Required speed for a no-sprint jump
SpeedReq_Walkjump45(v,t) Required speed for a no-sprint jump, facing 45°
SpeedReq_Strafejump(v,t) Required speed for a strafejump (like on rex bwmm)
SpeedReq_Strafejump45(v,t) Required speed for a strafejump, facing 45° after jumping

Add _del at the end of the function if the jump is delayed (previous tick was on ground).