[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Adonthell-devel] Map implementation ...

From: Kai Sterker
Subject: Re: [Adonthell-devel] Map implementation ...
Date: Mon, 21 May 2007 12:29:15 -0700

On 5/21/07, Tyler Nielsen <address@hidden> wrote:

Nice :-). My other mail should fit to most of what you wrote here ...

As for gfx::image, I'm not sure about that one. It's basically a
wrapper around surface, so it could be used in character_with_gfx
without changing it to a pointer. (Since surface is abstract and the
concrete class used depends on the backend, there is no way around
that). So I think when going over the world code more thoroughly, it
might be good to get rid of gfx::image again and use surface directly.

I had some thoughts about the sprite code too, but wanted to keep them
for later. But since you bring it up, I find the way it's implemented
in world right now is too limiting. I think the state names should not
be hardcoded in world, as that dictates what kind of animations are
allowed in your sprite. But what about Bjarn weeping at the end of
Waste's Edge, for example?

You don't want to have the engine tell you the sprite is either
walking or running. (But it's a start, so I wasn't worried about it
too much). So if you start thinking about sprites, you should probably
consider that as well.

I personally like sprites being at gfx level, as they might also be
useful for gui, not just world. And the current implementation already
allows to have any possible animation included, making it more
flexible than the sprite stuff in world.


So I've been looking at the stuff in world a little bit, and gfx/animation
is basically a subset of world/character_with_gfx.  The only things in
animation worth 'saving' is the XML load/save stuff, and the caching (which
should be in it's own class anyway).  Unfortunatly I noticed I never
finished the XML load function.  So I will do that now.  Ultimately there
needs to be a decision on where the 'sprite' code should live (world or
gfx).  And either way it needs to be connected up with image stuff in gfx
(this may already be done, I didn't look).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]