View Single Post
Old January 5, 2011, 16:26   #25
Shockbolt's Avatar
Join Date: Jan 2011
Location: Norway
Posts: 632
Shockbolt is on a distinguished road
Send a message via MSN to Shockbolt
Originally Posted by d_m View Post

(the +, | and - are used only to show the edges -- they should be empty tiles)

We should be able to generate this image just by pasting in your empty floor graphic tile and the 16 different wall tiles--this is how the game actually uses tiles. I suspect that having walls of varying thickness (for now) isn't going to work, but that it should be possible to give walls a somewhat 3D look like you did by figuring out whether they are "attached on" a side or not.

EDIT2: Yeah, it's hard to get the 3D look you want without knowing about diagonal adjacency. Otherwise, it's hard to get these two cases done correctly for X:

+--+ +--+
|X#| |X#|
|# | |##|
+--+ +--+
In the first case, you want X to have a little bit from the lower right missing, since presumably you're going to have some angling/3D effect on the two adjacent walls. In the second case, you definitely don't want a bit missing from the lower right, because it needs to flow into the diagonally adjacent square.

However, I think you only care about diagonally adjacent walls when both of the compass directions are filled, meaning you don't need 256 wall tiles, but only 47 wall tiles (the base 16, plus an additional +1x4 tiles for the elbow cases (2/4 not in a line), an additional +3x4 for the cases for the tiles blocked on 3/4 sides, and +1x15 cases for the wall that is blocked on 4/4 sides). It's late and I might be tired, but I'm pretty sure this is mostly right.

I will try to finish up my simple graphics example and post it here.
I'm not exactly sure what 16 tiles You refer to for the standard walls, do they include all 3 shade versions of each tile?

Can the dungeon be rendered using only two (or three tile types) as in my second version posted instead of the 3D'ish first version at the beginning of this thread? I've put together a better example that show the new wall tiles and how they are put together, I even used one of Your examples from a previous reply

When I wrote 3 tiles, I was referring to a third wall tile that really isn't needed, but can be there for an added "3D feel", as that tiletype partially hides the player behind it. See the left most part in the attached image to this reply.

Edit: For the filler wall tile(wall tile 1) You'd have to code into the game that it'd have to be replaced by tile 2, once the tile type 2 was tunelled away infront of it, if You know what I mean.

Last edited by Shockbolt; April 15, 2014 at 20:38.
Shockbolt is offline   Reply With Quote