Splitting that into its own topic, as it's a separate issue. > The second issue is the shadow when going down the stairs. It appears > the shadow position is based on an object's global bounding box, not > the fine grained shape used for collision detection. Since the > staircase is a single object (unlike the one in the old test map, > which is one object per stair). So here we have two solutions: > > Improve rendering of the shadow (although I fear this isn't a small > task) or updating the staircase object, so that each stair is an > individual sprite.
Tried this out today and created my first composite object, i.e. a map object consisting of multiple sprites/models. (see models/map/ground/inside/wood-stairs2.xml) Everything looked fine in modeller, but (a) it is not correctly rendered in mapedit, which seems to suggest that it's overall bounding box has the wrong proportions. It does appear on the map, although it faces the same problems as in mapedit, plus collision detection for it is broken. Again, issue might be the same, as I believe the overall bbox is what is checked for overlap first before the detailed collision detection kicks in. I've already fixed a problem with loading composite objects (only every second part was loaded), but I won't be able to look at the bbox thing tonight. I assume the issue is to be found in placeable::add_model and/or placeable::set_state. Hopefully, fixing the bounding box will automatically solve any rendering and collsiion issues too. One piece of information, as placeable might look confusing at first. There are basically 4 bounding boxes, each one specified by their position and size: 'Cur' and 'Max', each in the flavour 'Entire' and 'Solid'. The 'Max' variant includes the extension of all possible states an object can have. It is used for keeping the object on the map as this value will never change, so we never have to update the map structure either. The 'Cur' variant is the extension of the objects actual state, used for rendering, pathfinding and collision detection. The 'Solid' variant includes only parts of the object that are marked as solid. It's used for pathfinding and collision detection (as non-solid parts of objects don't have to be considered for those). The 'Entire' variant finally includes the non-solid bits too. Used for rendering and keeping stuff on the map. (A bit messy, I admit. Not sure if there'd be a nice way to clean this up a little). So feel free to have a look at this issue. Just let me know if you do, so that I won't accidently duplicate the effort. Won't look at stuff before tomorrow evening. Kai _______________________________________________ Adonthell-devel mailing list Adonthell-devel@nongnu.org http://lists.nongnu.org/mailman/listinfo/adonthell-devel