Banner
Views: 802,232,203
Time:
14 users online: chickaDEE Magazine, Elek, imamelia, joeyisepic123, Mediocre Espurr,  Ninja Boy, rafaelfutbal,  RussianMan, SammmUuU, Sillymel, Sixcorby, sss cs, The Evil Murderer, Veck - Guests: 44 - Bots: 142 Users: 41,940 (1,748 active)
Latest: Franciscrack06
Tip: Don't place Yoshi coins near a goal post because they keep glowing when a level fades out.Not logged in.
Details for Wall Kick
SMW Patches - Wall Kick
File Name: Wall Kick
Added:
Version History: View
Authors: MarioE
Tool: Asar
Requires Free Space: Yes
Bug Fix: No
Featured: No
Description: This patch enables the player to wall kick off walls by pressing the B button while sliding along the wall.

Just a minor change to allow the option of being able spinjump off a wall.

Now compatible with Lunar Magic 3.00.
Tags: lorom, physics, sa-1, wall, walljump, wallkick
Download: Download - 1.37 KiB
1,093 downloads
Screenshots
Previous 
 Next
jonerror42
cool #tb{^V^}
Posted by: jonerror42 - | Link
HammerBrother
Note: this patch disables you from sliding and jumping off the last wall that you have jumped off of (or the last “direction” you jump away from). This is not the case on the other Mario games on the method of preventing the player from gaining height from the same wall by merely relying on a timer that prevents the player from returning back to the wall too soon.

The culprit is the RAM address !flags ($61 by default) stores its data bitwise like this: ----LRlr
  • r is when you are sliding down a left-facing wall (you hold right on the D-pad), value will be #$01 (#%00000001)
  • l is when you are sliding down a right-facing wall (you hold left on the D-pad), value will be #$02 (#%00000010)
  • R is when you jumped off left-facing wall (you jump towards the left), value will be #$04 (#%00000100)
  • L is when you jumped off right-facing wall (you jump towards the right), value will be #$08 (#%00001000)

After jumping off the wall, the value in RAM defined as !flags remains #$04 or #$08 until the player is on the ground. While the RAM is in this state, the player cannot jump off the wall of the direction he have jumped off of:
  • If #$04, disable sliding and jumping off a leftwards-facing wall
  • If #$08, disable sliding and jumping off a rightwards-facing wall

See here (I added comments):
Code
		LDA !flags              ;\>----LRlr
		LSR                     ;|>0----LRl
		LSR                     ;|>00----LR
		AND $77                 ;|>Blocked status: SxxMUDLR
		BNE .return             ;/>If result both bits 0 and 1 clear, return (not touching any walls)
		LDA $15                 ;\Controller: byetUDLR
		AND #$03                ;|>000000LR
		CMP #$03                ;|\If both L and R pressed, return.
		BEQ .return             ;//
		LDA $15                 ;\Return if ((PressingLeft and BlockedLeft being set)||(PressingRight and BlockedRight being set)).
		AND $77                 ;|
		BEQ .return             ;/

Delete whats underlined to remove this quirk, or use this Uberasm version instead.

EDIT: Being in the water does not reset the flag. I'll ask the moderators about this.
Posted by: HammerBrother - | Link
Ramon
I was wondering if there's a way to prevent Mario from sliding on the screen edges? (Doesn't happen consistently.)
Posted by: Ramon - | Link
LucasMegaStriker
Strange loud songs when i use this one.
Posted by: LucasMegaStriker - | Link
Aqua-Grove-Prod
Definitely a lot better now. Plus it fixed MSWB (max speed wall-kick bug)
Posted by: Aqua-Grove-Prod - | Link
Maarfy
Changed the hijack and merged into one patch. Tested on pre- and post-3.00 Lunar Magic, with and without SA-1 with no errors observed.

The implementation and physics of the wall kick provided by this patch are very well done, and I frequently use it as a base myself. I kind of wish it had a couple more configurable options, like allowing jumping off the same wall twice, or allowing sliding down a wall even if you can't jump off of it. I'd also like to see the wall jump flags reset if the player falls into water or climbs on something. Even without these extras, though, this patch is well-built and worth considering for any project looking to spice up its movement options.

EDIT: Fixed a small error that crept up right after approval, my mistake. Everything ought to be in order now.
Posted by:  Maarfy - | Link
Vitor Vilela
Add compatibility with Lunar Magic 3.00
Posted by: Vitor Vilela - | Link

The purpose of this site is not to distribute copyrighted material, but to honor one of our favourite games.

Copyright © 2005 - 2020 - SMW Central
Legal Information - Privacy Policy - Link To Us


Total queries: 7

Menu

Follow Us On

  • YouTube
  • Twitch
  • Twitter

Affiliates

  • SMBX Community
  • ROMhacking.net
  • MFGG