adonthell-artwork
[Top][All Lists]
Advanced

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

[Adonthell-artwork] Floor tiles (was "Graphics repository")


From: James Nash
Subject: [Adonthell-artwork] Floor tiles (was "Graphics repository")
Date: Wed, 27 Apr 2011 20:51:41 +0100

Hi again,

Just branching off this thread to pick up on something Kai mentioned earlier:

> In general, a few pixels overlap does not matter. In most cases it's
> handled correctly and when it isn't, it's barely noticeable. What
> kills the renderer is complete overlap, where one object ends up
> inside another, such as might happen with a corner wall piece.
> 
> 
> With that in mind, we might want to make the floor an extra layer that
> does not overlap with walls below or above. The current WE map does
> not do this, and so far it's okay, but in the long run it might be
> better to do it right in the beginning. But that would either require
> special "border" floor tiles that contain a bit of wall, or additional
> wall pieces that are just as high as the floor. Would only be required
> for front walls, as you wouldn't notice any gaps at the back.


Is the issue here that floor tiles need to have some thickness and therefore 
will intersect with the current wall pieces? A picture probably explains more 
clearly what I mean:

PNG image


(I've deliberately used a more 3D-ish view to illustrate this. Obviously in the 
game you can't see things from this angle.)

The blue/pink bit is a corner wall (pink is meant to be inside, blue outside - 
if you look closely at the grid on the ground, you'll see that each side sits 
on a different floor tile). The turquoise piece is the ceiling that sits on top.

We want the ceiling tiles to be aligned with the grid on the ground and 
therefore they will intersect with top of the inside portion of the wall - 
highlighted in red on the right.

If I've understood Kai correctly this situation can confuse the renderer. @Kai: 
Is that right or did you mean something entirely different?

Assuming I've got this right, then one solution is to produce specialised floor 
tiles that are a bit smaller and sit between the walls and "normal" floor tiles 
without intersecting either.

I suppose another way might be to cut the offending section of the inside wall 
away like so:

PNG image


If that would work too, it may actually be preferable for the following reasons:

- It keeps making floor tiles simple. Making walls is already fiddly anyway, so 
making it a little bit more so is the lesser evil IMHO.
- We can start using separate graphics & models for the inner & outer portions 
of walls (perhaps we'd have to anyway. Kai?) which would benefit re-usability 
since you can combine different kinds of wall any way you like.*

What do you think?

Regards,
                        - James

*) To be fair, we can do this regardless of whether the inside walls need to be 
less tall or not.


On 8 Apr 2011, at 23:30, James Nash wrote:

> Hello!
> 
> I've just pushed up most of the roof graphics - 
> https://github.com/ksterker/wastesedge/commit/c23893bec60ec50559a222bc1573cd430d4757ea
> 
> I still need to make a set of outer corner pieces but then we'll have a 
> complete set to make roofs of any shape. :-)
> 
> Once I've done that I'll set about chopping up the T-shaped walls like you 
> asked.
> 
>       - James
> 
> 
> On 7 Apr 2011, at 20:35, Kai Sterker wrote:
> 
>> On Thu, Apr 7, 2011 at 12:11 PM, James Nash <address@hidden> wrote:
>> 
>>> I made some good progress on them last night. Won't be home tonight but
>>> should start uploading some more PNGs over the weekend.
>> 
>> Nice. Should be able to free some time on the weekend for doing stuff,
>> too. Will be gone on vacation starting the weekend after that,
>> however. Only for a week, though :-(.
>> 
>> 
>>> I've been keeping track of the measurements on scraps of paper so can
>>> provide any missing ones. IIRC the walls should always 8px thick
>>> horizontally and 6px thick vertically.
>> 
>> That's what I figured out, too.
>> 
>> 
>>>> Touching up the editors is certainly a priority ;-).
>>> 
>>> Once I've used them for a bit I can hopefully provide some feedback &
>>> suggestions.
>> 
>> There'll be many, I guess. But it will be good to bring the editors
>> into a usable shape, as I think that will be important for getting Dun
>> Barethsol done.
>> 
>> 
>>>> On the bright side, the corner model "merges" the two (or more)
>>>> images, so during map making, this artificial split is of little
>>>> concern.
>>> 
>>> Shouldn't be a problem to do. Could you explain a little why this is so I
>>> can cater for it in future gfx?
>> 
>> The problem is that the renderer works on sprites when it gets to
>> determine what to draw and in what order. So if you build a corner
>> tile out of a single sprite, you get a fairly big bounding box that
>> might overlap with objects that are placed in the corner. When that
>> happens, the renderer has a hard time figuring out what should be
>> drawn first and what second. But if you split the sprite in two, you
>> end up with two bounding boxes that match exactly the area covered by
>> the walls. Any object inside the corner will not overlap with the wall
>> parts and the result will be much better.
>> 
>> There are some parts where overlap cannot be avoided completely:
>> 
>> * Objects that are not rectangular, like sloped ground or diagonal
>> walls. Even if you'd model precise wireframes for those, the renderer
>> will always only look at their rectangular bounding boxes.
>> * Since the collision detection system treats characters as
>> ellipsoids, they might actually overlap with scenery objects such as
>> stairs.
>> 
>> In general, a few pixels overlap does not matter. In most cases it's
>> handled correctly and when it isn't, it's barely noticeable. What
>> kills the renderer is complete overlap, where one object ends up
>> inside another, such as might happen with a corner wall piece.
>> 
>> 
>> With that in mind, we might want to make the floor an extra layer that
>> does not overlap with walls below or above. The current WE map does
>> not do this, and so far it's okay, but in the long run it might be
>> better to do it right in the beginning. But that would either require
>> special "border" floor tiles that contain a bit of wall, or additional
>> wall pieces that are just as high as the floor. Would only be required
>> for front walls, as you wouldn't notice any gaps at the back.
>> 
>> Kai
> 


reply via email to

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