G'day, Sprites et.al.

new topic     » topic index » view thread      » older message » newer message

G'day all,

        I've been off-line since late September, not that
anyone will have noticed this as I generally just lurk, but
I thought I'd check in anyway.
        I was up until 3am last night wading through the
digests for the last few months; looks like it's all
happening eh? I'm not going to have a go at Euw yet, I'm
just starting to get the hang of 1.5a, but there have been
a number of intriguing projects being discussed. I haven't
had a chance to check any of it out but the modex library
sounds great. I'm personally very interested in hearing
about the traveling salesman bit, but don't have time to
waste on such frivolities (I hate boxing games, but
Choplifter is legendary). There was mention of a Bard's
Tale type RPG graphics engine that sounds good (haven't
checked out the pics). Ralf's nextGFX is no doubt up to
scratch as well  There was also a few bloody good laughs
amongst it; thank Allah for giving us the sense of humor,
which when remaining on the topic is of immeasurable
value to the planet's mental health.

        While I was away I've been working on a sprite
based game system, which is coming along quite nicely.
So far I have written:

        --  A 64x64x64 3D Sprite editor/ray-tracer that
            will calculate ray-traced 2D sprites from a 3D
    sprite at any angle.

        --  A simple and quick image compression routine
            that does a pretty god job on hand-made bitmaps
            and sprites (up to 95% compression for simple
    images), but I suspect would be next to useless
    on digitized photos or data.

-- A sprite engine that so far has; integrated
    background tiling with corner rounding so the
    tiles don't look like Lego blocks; unlimited
    number and size of sprites, maps, tiles, bitmaps,
    etc.; pixel perfect collision detection; a set-and-
    forget internal micro language for pre-
    programming sprite movements, animations and
    other internal functions; works in any graphics
    mode (I hope! - my system crashes trying to use
    any pixel graphics modes other than 19 and 261,
    but it works in those two anyway); built in mouse
    and font support.

-- A map editor for the making background tile maps.

        I am still working on a GUI style sprite program
editor for speedy game writing - at the moment I still have to
scratch my head and figure out the numbers. The program
editor is my first project based on the sprite engine, which
seems to be working well in this capacity. Buttons can be
declared as sprites and checked for collision with the mouse
pointer (which is also a sprite), then animated so they move.

        In writing all of this I have relied heavily on Michael
Bolin's "e_mem_copy" (which is excellent and does NOT
produce causeway errors unless you stuff up), and Pete
Eberlein's "svga.e.", which I have butchered to produce a
Vdisplay_image routine using much the same methods as
Ralf was talking about a while back (2am this morning for
me!).
        Frame rates for the engine so far, are about 220 fps
in mode 19 for 20 animated, pre-programmed 64x64* sprites
with collision detection. It plummets to about 30 fps in mode
261. which is barely adequate (I'll have to do a bit more
head-scratching here). These figures are for my P-120 with
crappy old S3 1Meg card.

        It has a few other nifty little features like a lock()
command to determine whether sprite co-ords are relative
to the background or the screen, and sprite direction registers
for automatic image changing depending on the direction a
sprite is traveling. It takes care of off screen sprites, hiding
them when they are out of view (there is no limit to sprite xy
 positions although so far there is no collision detection
off-screen). The engine works on a single virtual screen that
is completely cleaned up at each update so the parent program
can safely write to it at any time.

*64x64 is a maximum size. Actual sizes vary depending on the
animation frame (all sprites are automatically edge-clipped).

        I can't really post any of this yet as it is all still needs
a few things here and there and it's all integrated using custom
compressed image and map formats. However if anybody is
interested in a particular element, drop me a line and I'll see
if I can rip out a bit of code for you.

        I should have a demo out pretty soon, I work six days
a week as a builders' labourer so I don't have much time. ( it's
now 5 O'clock Sunday afternoon and all I've done is read the
digests and written this post.)

        By the way, as a genuine Australian still roaming free
in my natural habitat, I cannot help but notice the proliferation
of "gidday"s on the list. If you must, it's "g'day" (abbr. of "good
day"). There is no vowel sound in between the G abd the D. Nobody
says gidday, unless you're a Kiwi (-:  --  Hi Jiri, love your work.

If anybody is interested, my new E-Mail address is

       hmi at powerup.com.au

Thanking you all for your continuing contributions that go the
extra hard yards to make Euphoria the brilliant tool that it is.

Graeme.

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu