Monday 7 April 2008

Just thought I'd give people an update since STPPC2x Beta 1. The following features will make it into BETA 2, which would almost be v1.0 if it wasn't for mines not working at all - the only game with remaining gameplay issues.

2008-04-07:
- Fixed map's and inertia's drag-drop display problem.
I'm a pillock. Having your source and destination the wrong way round means
that any amount of checking of your parameter values is useless if you don't
check the ORDER of arguments as well. I still say that the functions use
a "backwards" nomenclature for "blitter save/load" but once I switched them
around, it all started working properly without any other hassles.
- Fixed pegs and sped up all games by putting screen updates in the right places.
I'm still a pillock. Although it still draws lots of primitives, we *now* don't
update on every one of them, just the final "drawing". So instead of many
intra-frame updates, we get one end-of-frame update. The documentation wasn't
at all clear on this but I should have debugged it properly earlier.
Also, implemented proper "partial updates" instead of full updates all the time.
- Implemented re-use of loaded fonts.
Increases speed of text games at a cost of memory. I didn't do this before for
debugging reasons and because it worked without it but for the sake of completeness
it now keeps copies of fonts in multiple sizes in RAM in case it re-uses them rather
than constantly load/destroy/load/destroy fonts as the sizes in use changes.
It still doesn't distinguish "types" of fonts (monospaced etc.) but that's only a
minor addition.
- Better descriptive text for errors/startup.
You won't see them unless you are using Sterm / Telnet to run the games but when
something goes wrong, you're more likely to get a useful error message.
- Removed a few bits of unused / unnecessary SDL code.
e.g. initialising audio, overzealous locking, freeing of surfaces that get freed
anyway,...
- Tested code with proper hardware accelerated surfaces.
Little to no performance difference but strange problems related to dragging in
untangle, for example, which gives "jittery" cursors when using page-flipping.
Reverted until cause can be found (not a high priority given the small advantage).
- More error checking and bailing out with a nicer error on certain failures.
e.g. fonts not being present, blits failing, etc.
- Looking again at mines quickly but it's still weird.
- Made sure that the cursor doesn't linger after the game has quit.

No comments: