Jump to content


Photo

Fix for the 'Nine lives in the light' bug


  • Please log in to reply
2 replies to this topic

#1 IRF

IRF

    Advanced Member

  • Contributor
  • 3,272 posts

Posted 07 March 2017 - 01:18 PM

In 'Solar Power Generator', Miner Willy isn't always killed if he runs out of air supply at a time whilst he is standing in the solar beam:

 

http://skoolkid.gith...LivesInTheLight

 

This is because the 'Solar Power Beam' routine calls up 'Decrease the air supply' as a subroutine eight times in succession (four for each character of Willy's sprite that the beam passes through in a given time-frame), without checking whether the air in the cavern has run out.  As a result, the air supply can 'wrap around' past zero, causing the final character of air on the status bar to be replenished with another eight pixels!

 

Anyway, I've come up with a twelve-POKE fix for this:

 

At #88FC, insert '18 F4 E1'.

 

At #8D89, insert '06 04 C5'.

(Incidentally, the operand '04' is the number of times the Air Supply is depleted by the Solar Beam in the original MM; it could be altered to make the Solar Beam less deadly, or even more so!)

 

[The CALL at #8D8C remains in situ.]

 

Finally, at #8D8F, insert 'C1 CA FE 88 10 F6'.


Edited by IRF, 07 March 2017 - 02:21 PM.


#2 jetsetdanny

jetsetdanny

    Advanced Member

  • Contributor
  • 1,709 posts

Posted 11 March 2017 - 10:51 AM

Interesting, I didn't know about this bug until now. It's also cool to be able to control the lethality of the Solar Beam  :) .


  • IRF likes this

#3 IRF

IRF

    Advanced Member

  • Contributor
  • 3,272 posts

Posted 11 March 2017 - 10:58 AM

I've since noticed that John Elliott came up with a similar method on Yahoo! to control the lethality, although not in the context of fixing the bug.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users