Kevin Vance - Bernard the Bard, baby! 1.9MB of MegaZeuxy goodness. I got…

Entries | Archive | Friends | Friends' Friends | User Info

11:43 pm

Saturday, September 15th, 2007
Previous Entry Share Next Entry
Tags, ,

BtB screenshot Bernard the Bard, baby! 1.9MB of MegaZeuxy goodness.

I got the extra memory working using Lick's RAM unlocking API and the dlmalloc memory manager. My strategy was to use the extra memory for storing the arrays of types, colors, overlays, etc. When a board is used, the memory is copied into main RAM, and when it's finished, it's copied back into extra RAM. This slows down loading, saving, teleporting, etc. due to unnecessary copying, but it saves me from having to make thousands of lines of code 16-bit write safe. It's still to glitchy to use, but I expect it to be easy to debug now that my red screens of death are working again.

Once I do the same thing with per-board robot memory, you should be able to play any world so long as it doesn't have a board that needs more than 1MB of main memory.
Link )Reply )

Comments
[User Picture]From: myth
2007-09-16 05:13 am (UTC)
Still trying for Xenogenesis?
(Reply) (Thread)
[User Picture]From: kvance
2007-09-16 05:30 am (UTC)
Xenogenesis seemed to be working as of build 1. It stopped running out of memory once I started freeing the leaky sound memory.
(Reply) (Parent) (Thread)
[User Picture]From: myth
2007-09-16 06:35 am (UTC)
Awesome.
(Reply) (Parent) (Thread)
[User Picture]From: noodleboi
2007-09-16 08:03 am (UTC)
This is awesome!
(Reply) (Thread)
[User Picture]From: kvance
2007-09-17 08:40 pm (UTC)
Thanks!
(Reply) (Parent) (Thread)
[User Picture]From: kvance
2007-09-17 08:42 pm (UTC)
Wow, that's a year longer than my Lite lasted. If you're gonna buy one, don't forget the new red 'n black (oh, sorry: crimson and onyx) Lite was released a few weeks ago.
(Reply) (Parent) (Thread)
From: ex_md744
2007-09-16 04:06 pm (UTC)
kev levelled up his hacking, he's now a level 21 hacker, epic.
(Reply) (Thread)
[User Picture]From: kvance
2007-09-17 08:42 pm (UTC)
:D
(Reply) (Parent) (Thread)
[User Picture]From: terryn
2007-09-16 07:55 pm (UTC)
Excellent.

"Once I do the same thing with per-board robot memory, you should be able to play any world so long as it doesn't have a board that needs more than 1MB of main memory."

Too bad that's not a theoretical boundary right now. =< One game, Doom Spire, has went over 1MB in board size for me during its level generation multiple times (taking up numbers like 1,063K and 1,109K after generation). That's pretty much the only one as far as I know, though!
(Reply) (Thread)
[User Picture]From: kvance
2007-09-17 08:43 pm (UTC)
It could be more or less than that, I haven't checked in a while. If it ever gets stable enough for normal use, I definitely want to look at shaving a few hundred KB off of the executable.
(Reply) (Parent) (Thread)
(Deleted comment)
[User Picture]From: kvance
2007-10-09 08:22 pm (UTC)
My pleasure!

BtB is one of my favorite MZX games of all time. I need to hurry up and get the rest of this working so I can play it again :P
(Reply) (Parent) (Thread)