File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -11,24 +11,26 @@ void is_player_falling() {
1111void ship_movement (){
1212 is_player_falling ();
1313
14- if (controllingplayer -> a || controllingplayer -> up ) { // holding
14+ tmp2 = (controllingplayer -> a || controllingplayer -> up ); // input
15+
16+ if (tmp2 ) { // holding
1517 tmpgravity = SHIP_GRAVITY_BASE (currplayer_table_idx );
1618 } else if (
17- !( controllingplayer -> a || controllingplayer -> up ) && // not holding
19+ !tmp2 && // not holding
1820 !tmp1 // not falling
1921 ){
2022 tmpgravity = SHIP_GRAVITY_AFTER_HOLD (currplayer_table_idx );
2123 } else {
2224 tmpgravity = SHIP_GRAVITY (currplayer_table_idx );
2325 }
2426
25- if (( controllingplayer -> a || controllingplayer -> up ) && // holding
27+ if (tmp2 && // holding
2628 tmp1 // falling
2729 ){
2830 tmpgravity = SHIP_GRAVITY_HOLD_FALL (currplayer_table_idx );
2931 }
3032
31- if (( controllingplayer -> a || controllingplayer -> up ) ^ (currplayer_gravity ? 1 : 0 )) {
33+ if (tmp2 ^ (currplayer_gravity ? 1 : 0 )) {
3234 tmpgravity = - tmpgravity ;
3335 }
3436
@@ -46,6 +48,8 @@ void ship_movement(){
4648 tmpfallspeed = (currplayer_gravity ? tmpfallspeedtop : tmpfallspeedbot );
4749 if (currplayer_vel_y > tmpfallspeed ) currplayer_vel_y = tmpfallspeed ;
4850
51+ tmpfallspeed = tmpfallspeedtop ;
52+
4953 #undef tmpfallspeedtop
5054 #undef tmpfallspeedbot
5155
You can’t perform that action at this time.
0 commit comments