I finally took the time to change all zero page variable declarations from
var = $02to
var ds.b 1and removed all variables which aren't used any more. I suspected I would end up with 30 to 40 free zero page locations, but it turned out to be about 70 bytes! I swiftly used half of it for the two most used object variable tables (16 bytes each), which makes accessing them both faster and smaller. I guess those tables really are accessed a lot, code size was reduced by over 100 bytes... I still have room for another two tables there, but I have to find the ones which gain most cycles/bytes.
Complete list of bug fixes since the previous release:
- Droid teleportation doesn't send them outside the deck any more.
- Waypoint chars are placed onto deck map every time when exiting lift, meaning no more completely confuzed droid army.
- Door status is restored when exiting lift, so droids won't get stuck against them any more.
- The first deck entered after load had waypoint magic chars visible, as they aren't hidden in EnterShip() routine but in EnterDeck(). Instead of wasting three bytes to add one JSR call, I changed the font so magic chars are there after load :)
- Background stars are now really disabled during the intro sequence, that avoids random colors for lower half of "7" char. I disabled them earlier, but that broke when I added more run-time randomizing.
Important bits here.
Update
Two more bugs fixed, one remains... Intro text scrolled beyond the end of page sometimes, and out-of-sight droids were paralyzed on C128. The remaining bug allows droid go through wall in certain conditions, something which I didn't notice on emulator.
3 comments:
Eh, when talking about the twinking stars I was thinking about something a bit faster, like every second frame ;)
By the way, your version numbering is quite interesting to say the least. Fortunately there's a date, otherwise I couldn't tell which version is which.
It does change star color every second display frame, but it does it for one random star each time...
I need to replace "Version" with "Build", as that's what the number really is. "06-080907" would be 6th assembly on September 8th this year. Build number is increased even if assembly fails, as it's there just to tell me if I'm really testing the latest version or some older one which happened to be on the memory card ;)
No one has reported bugs in the latest release, which is wierd as there is one which hangs the game for certain under the right (wrong?) conditions. If you want to go bug hunting, guess which bug fix added completely new code and then try to break it.
I changed stars to flicker faster (every 8th display frame, four times faster than the current release) but that made them too busy for my liking, so I made them only one pixel wide. Let's see how people like them when I release the next version.
Post a Comment