Flying: Difference between revisions

8 bytes removed ,  1 August 2023
fix typo
(Created page with "{{Action_infobox |title= Flying |image= |official name= |hex= 0x10880899 |flags= air, diving, attacking, swimming/flying |group= Airborne |id= 0x099 |into= Airborner cancels:...")
 
(fix typo)
Line 7: Line 7:
|group= Airborne
|group= Airborne
|id= 0x099
|id= 0x099
|into= Airborner cancels: [[Water Plunge]], [[Squished]], [[Vertical Wind]] (theoretically), (Technically, because of the flying triple jump code): [[Double Jump Land]], [[Lava Boost]] (theoretically),, non cancel: [[Backwards Air Kb]], [[Lava Boost]] (again) (theoretically)
|into= Airborner cancels: [[Water Plunge]], [[Squished]], [[Vertical Wind]] (theoretically), (Technically, because of the flying triple jump code): [[Double Jump Land]], [[Lava Boost]] (theoretically), non cancel: [[Backwards Air Kb]], [[Lava Boost]] (again) (theoretically)
|out of= [[Shot From Cannon]], [[Flying Triple Jump]], when spawning in some levels like [[Tower of the Wing Cap]]
|out of= [[Shot From Cannon]], [[Flying Triple Jump]], when spawning in some levels like [[Tower of the Wing Cap]]
|animation= 0x5B fly from cannon, 0xCF forwards spinning flip, 0x29 wing cap fly
|animation= 0x5B fly from cannon, 0xCF forwards spinning flip, 0x29 wing cap fly
Line 14: Line 14:


Flying is an action that can occurs when Mario triple jumps or does a cannon shot while wearing the [[wing cap]].
Flying is an action that can occurs when Mario triple jumps or does a cannon shot while wearing the [[wing cap]].
== Entering flying ==
== Entering flying ==
* [[Shot From Cannon|Cannon shot]]: when y vel < 0 (and Mario does not cancel) ('''Action argument: 0''')
* [[Shot From Cannon|Cannon shot]]: when y vel < 0 (and Mario does not cancel) ('''Action argument: 0''')


Line 22: Line 20:


* Spawning in, e.g, [[Tower of the Wing Cap]]: ('''Action argument: 2''')
* Spawning in, e.g, [[Tower of the Wing Cap]]: ('''Action argument: 2''')
== Behavior ==
== Behavior ==
As with all airborne actions, a variety of "cancels" are checked prior to actually performing any airborne action. See [[Jump#Airborne cancels]].
As with all airborne actions, a variety of "cancels" are checked prior to actually performing any airborne action. See [[Jump#Airborne cancels]].
# If Z is pressed
# If Z is pressed
## If Mario's camera mode is CAMERA_MODE_BEHIND_MARIO, set_camera_mode to m->area->camera->defMode
## If Mario's camera mode is CAMERA_MODE_BEHIND_MARIO, set_camera_mode to m->area->camera->defMode
Line 58: Line 53:
### stop holding, stop riding, [[Lava Boost]]
### stop holding, stop riding, [[Lava Boost]]
# finally, play the flying sound (adjust sound for speed)
# finally, play the flying sound (adjust sound for speed)
I am too lazy to describe the exact details of <code>update_flying</code>, so here is the code
I am too lazy to describe the exact details of <code>update_flying</code>, so here is the code
<syntaxhighlight lang="c">
<syntaxhighlight lang="c">
/**
/**
188

edits