Code Monkey home page Code Monkey logo

Comments (5)

devinacker avatar devinacker commented on May 20, 2024

ARRRRGHGHHHH

1F:F756:A5 17     LDA $0017 = #$68
1F:F758:C9 68     CMP #$68
1F:F75A:90 17     BCC $F773
1F:F75C:C9 74     CMP #$74
1F:F75E:B0 13     BCS $F773

when this code runs, the value at $0017 equals the current screen number (times 3/4?) plus $68 (whatever that represents). When you're on the very last screen possible (i.e. $0F), that value equals $74, triggering an off-by-one error which bypasses tile collision checks completely whenever the player is on this screen. Thanks, HAL!

I'll probably add some stupid hack to the editor to silently fix this (just need to make sure this code is in the same place in every ROM revision...)

from kale.

devinacker avatar devinacker commented on May 20, 2024

�<��einstein95��>� devin: US (1.0, 1.1) , EU, FR, DE: 1F:F756; CA: 1F:F773; JP: 1F:F770�

from kale.

devinacker avatar devinacker commented on May 20, 2024

i also need to make sure this really was an off-by-one error and that there wasn't a valid reason for using those bounds (the value at $0017 is taken from a lookup table which maps 16 screen numbers to the values $68 through $74).

Changing the CMP #$74 in the above code to $75 makes screen 15 collision work fine for both Kirby and other sprites and doesn't seem to have any ill effects that I can see, though

from kale.

devinacker avatar devinacker commented on May 20, 2024

fixed by 79ab41a (hopefully without affecting anything else)

from kale.

sneakernets avatar sneakernets commented on May 20, 2024

It's amazing that you're finding these. Keep it up!

from kale.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.