K5 patch invalid? (F10 + J)

Request patches for Keens 4-6.
Post Reply
User avatar
Nisaba
Posts: 320
Joined: Fri Jan 01, 2016 11:15 pm
Location: patch.pat
Contact:

K5 patch invalid? (F10 + J)

Post by Nisaba »

The following patch (F10 + J) shows a differing result than proclaimed. This patch should alter what key activates the jump cheat. But to me it seems, that the pointer is invalid. This is because albeit which Scancode is defined (for e.g. $BCF7W = J), you only have to press the "F10" to activate the jump cheat. no second key combination needed. in result all other cheat codes are unfeasible, because of this.

this is the patch code in question:

Code: Select all

#Jump cheat key (K5)
%patch $7539 $BCF7W
and you can find it here:
http://www.shikadi.net/keenwiki/Patch:F ... ates_cheat

can someone help finding the right pointer, please?!
levellass
Posts: 3001
Joined: Wed Oct 11, 2006 12:03 pm
Location: Ngaruawahia New Zealand

Re: K5 patch invalid? (F10 + J)

Post by levellass »

Aaah minor errors. What you want is:

Code: Select all

#Jump cheat key (K5)
%patch $7538 $BCF7W
User avatar
Nisaba
Posts: 320
Joined: Fri Jan 01, 2016 11:15 pm
Location: patch.pat
Contact:

Re: K5 patch invalid? (F10 + J)

Post by Nisaba »

great!
thanks!

how did you manage to track down the problem? trial and error? knowledge? magic? I wanna know, cause I need to learn how to take care of things like this next time myself...
levellass
Posts: 3001
Joined: Wed Oct 11, 2006 12:03 pm
Location: Ngaruawahia New Zealand

Re: K5 patch invalid? (F10 + J)

Post by levellass »

I opened a dump of the game in a hex editor and looked at the address where the patch was. Then it was immediately obvious that the value in the patch was one off from where it should have been.

If it had been more random then I would have looked in the dump for the value in the patch, $BCF7W which only appears once, at the proper location. Small errors like this pop up in patches from time to time if they're not all thoroughly tested.
User avatar
Nisaba
Posts: 320
Joined: Fri Jan 01, 2016 11:15 pm
Location: patch.pat
Contact:

Re: K5 patch invalid? (F10 + J)

Post by Nisaba »

Oh, well. that was way too easy. I should have done this myself instead of bothering... next time I will do more research, promised.
Post Reply