adonthell-devel
[Top][All Lists]
Advanced

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

Re: [Adonthell-devel] More on z-values (was: first real map gfx)


From: Alexandre Courbot
Subject: Re: [Adonthell-devel] More on z-values (was: first real map gfx)
Date: 15 Mar 2002 15:04:53 +0100

> The more I think about it, the more useful the z value gets. Actually,
> there would be two distinct z values. The distance of an object from the
> ground (let's call it 'z') and an object's height, i.e. how tall it is.
> (let's call that 'level').

I came to about the same conclusion this morning - this will of course
complicate things a little bit - but just a little bit, actually.
Imagine the CPU power we use with the map engine movments currently -
it's nothing compared to a platform game, for example.

All your post makes sense to me, actually. What would eventually happen
is that a character could climb on crates and furnitures that are not
too tall for him. Actually, while thinking more about the map rendering,
I realized we'd need a Z offset. At first I only wanted to apply it to
the different map levels, but in this case, why not applying it to
classic map objects and characters as well? Anyway, if you want a
character to be able to fall, you need to know his Z position too.

Another advantage of the tall parameter is that, too tall characters
couldn't enter a door that is too small for them. Unless, of course,
they crouch ;) (more work for our gfx guys? ^_^)

I also came to the conclusion that the water effet would be impossible
(AFAIK) without any Z offset. Not that a Z offset will make it a piece
of cake, though. You'd still need to draw the water in two parts, in
this order:
-the water that is behind the character's knees,
-the character himself,
-the water that is in front of the character's knees.

As the water is translucent, you can't allow yourself to draw the bottom
part two times.

So the map renderer will have to figure out that a character is on the
water tile, to cut it in two (or more if more than one characters are in
the water) tiles. Honnestly, this won't be the hardest part, and I'd say
I already know how to do it (but don't trust such fresh illusions too
much! ;))

All in all, I like the idea very much. Let's do it. I stabilize the
current map stuff and will continue my efforts to get it to work under
Windows. Then the next item on my TODO list is to get this Z thing to
work.

Will Adonthell turn into a platform game, too? ;)
Alex.
-- 
http://www.gnurou.org





reply via email to

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