adonthell-devel
[Top][All Lists]
Advanced

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

[Adonthell-devel] Re: Update on collision work


From: Kai Sterker
Subject: [Adonthell-devel] Re: Update on collision work
Date: Sat, 5 Jan 2008 00:03:00 +0100

On Dec 19, 2007 10:17 AM, Kai Sterker <address@hidden> wrote:

> There needs to be some glue that aligns the sprite with the object
> model during rendering. Looking at the examples here
> http://lists.nongnu.org/archive/html/adonthell-devel/2007-08/jpg4iqxtf0Ec4.jpg,
> it appears that this alignment cannot be computed by the engine, but
> must be specified explicitly for each individual object model. (Of
> course, an object editor will be able to do that automatically.)

After looking more at the code, I figured that alignment of 3D models
and sprites was already pretty much built in :-). All it took was
changing the origin of the cube-shapes from 0,0,0 to whatever offset
fitted best. A little extra code was required to get it working, but
the result looks good to me (see attachment).

With the synchronization out of the way, I can continue with other
remaining issues. For that, I made some more improvements to the
collision debugging code (also shown on the image below). This doesn't
completely eliminate the need to use gdb to track down issues, but it
helps a lot :-).

Get the code from CVS and have a look yourself, if you want. Help is
also welcome, of course, but I can understand that it is quite hard to
get into the current code without much documentation around it.
Something I should change soon ... at least I would like to get some
sketches up on the wiki that demonstrate the placement of objects on
the map and the alignment between the images and underlying models.

Kai

Attachment: collision-demo.jpg
Description: JPEG image


reply via email to

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