1,811
edits
mNo edit summary |
(WIP but i am out of time) |
||
Line 4: | Line 4: | ||
Steps are also responsible for detecting collision with [[surfaces]], updating Mario's [[referenced surfaces]], and updating Mario's [[Water|water level]]. However, quarter steps don't detect warps. | Steps are also responsible for detecting collision with [[surfaces]], updating Mario's [[referenced surfaces]], and updating Mario's [[Water|water level]]. However, quarter steps don't detect warps. | ||
== Air Step == | |||
When an action performs an air step, the first thing Mario does is update his horizontal velocity/sideways position via [[straining]]. | |||
After that is updated, the movement is split into "quarter-steps" that breakdown Mario's movement and determine what his outcome of each step is. The checks for the quarter-steps are as follows: | |||
# The position a quarter of Mario's velocity ahead of Mario is checked for cancels/outcomes. Anything in bold is an exit out of the rest of the checks. | |||
## If the position is above OOB but below Mario's current floor height, Mario's height is changed to the floor height and he '''lands'''. | |||
## If the position is above OOB but not below Mario's current floor height, Mario's height is set to the new height and he '''hits a wall'''. | |||
## If the action has the "riding shell" flag and the water level at the position is above the position's floor (up to 78 units above the position): | |||
##* The floor height from here on is the water height. | |||
##* The floor from this point on is a "fake" floor on the surface of the water. | |||
##* The floor's origin offset is set to the water height. | |||
## If the position's height is 78 units or less below a floor and there is not a ceiling 160 units or less above it (because of how variable types an [[overflow jump]] may occur here): | |||
##* Mario's position horizontally is updated to the new position. | |||
##* Mario's height is set to that of the floor's height. | |||
##* Mario's floor and floor height are updated. | |||
##* Mario '''lands'''. | |||
## If the position's height is 78 units or less below a floor and there is a ceiling 160 units or less above it (because of how variable types an [[overflow jump]] may occur here): | |||
##* Mario's height is set to that of the floor's height. | |||
##* Mario '''lands'''. (Because Mario's floor is not updated, this is where a [[Pedro Spot|pedro spot]] may occur) | |||
## If the position's height is 160 units under, at, or above a ceiling and his vertical velocity is positive or zero: | |||
##* Mario's vertical velocity is set to zero. | |||
##* If the ceiling above Mario is hangable and the air step has the "check hang" flag, Mario '''hangs'''. (Since this did not use the new position's ceiling/location, this is potentially a [[Hangable-Ceiling Upwarp|hangable-ceiling upwarp.]]) | |||
##* Otherwise, '''nothing happens'''. | |||
## If the position's height is 160 units under, at, or above a ceiling and his vertical velocity is negative: | |||
##* If the position's height is at or below Mario's floor height, Mario's height is set to the floor height, and he '''lands'''. | |||
##* Otherwise, Mario's height is set to the new height and he '''hits a wall'''. | |||
## If there is a wall 30 units above the position but not 150 units above the position and the air step has the "check ledge grab" flag: | |||
##* If Mario's velocity is positive, Mario is pushed by the wall opposite the velocity direction, and there is a floor 60 units behind the wall within 238 units upward, Mario '''ledge grabs'''. (Potentially a [[GLG]]) | |||
##* Otherwise Mario's position is set to the new position, his floor and floor height are updated, and '''nothing happens'''. | |||
## Mario's position is set to the new position and his floor and floor height are updated. | |||
## If Mario is colliding with a wall 150 or 30 units up and the upper or only wall is lava, he '''lava wall boosts'''. | |||
## If Mario is colliding with a wall 150 or 30 units up and Mario is facing perpendicular to 0x6000 units away, he '''hits a wall'''. | |||
## If no other exit has occurred, '''nothing happens'''. | |||
# This repeats until Mario encounters something besides '''nothing happens''', up to four times including the initial time. | |||
From here, the outcome chooses the next action and some other things are applied. |