Page 1 of 3

[RFD]cell based, freeform or something in between ?

Posted: 31 Jan 2005 14:13
by PJayTycy
This issue keeps popping up in several threads, and as far as I know, we haven't agreed on anything yet.

So, the question is, how "freeform" do we want this game to go?

btw, if I talk about track, I mean track, road and canals.

Cell-based
  • landscape cells = building units
  • each building has a footprint which is a collection of a few complete cells (eg: 1 house = 1 cell)
  • each building can be rotated in 4 orientations (if we use squares) or 6 orientations (if we use triangles)
  • track also have 8 orientations in square systems and 6 in triangle systems (maybe 12?)
  • Each tracksection either goes border-to-border or center-to-center, but is essetially always 1 cell long.
  • tunnels / bridges are cell-based (1 cell = start & 1 cell = end), some kind or Rollercoaster Tycoon / Locomotion system.
  • cargo is transported between those cells
  • clearly visible grid, players will calculate in grid-units
freeform
  • the landscape cells are not = building units
  • each building has a footprint which is a collection of a lot of such units (eg: 1 house = 8*8 units).
  • buildings can be rotated in any direction
  • tracks can also be rotated in any direction
  • tracksections are treated as normal buildings, they have a certain footprint (eg 8*4) and can be rotated in any direction.
  • tunnels/bridges are not restricted to cells. They start/stop like any other track.
  • cargo is transported between ???
  • most players won't care about the grid, but it can be turned on for more control.

The biggest advantage of a cell-based system = less memory used. If we compare equal size of maps (eg: 1 K houses²), the cell based one uses 1024*1024 cells, where the freeform one would need a building unit grid of 8192*8192. The later uses 64 times more memory.

The biggest advantage of a freeform system = you are not restricted to 4 orientations for buildings and 8 orientations for tracks + it looks more realistic.

Another thing, if we use a cell-based system, we can use sprites because of the limited number of orientations. If we use the freeform system, everything has to be fully rotatable 3D model. Usually sprites look better and use less resources.

I haven't made my mind up yet...

Posted: 31 Jan 2005 14:25
by Hellfire
One of the constants during the development of this game was that it's going to be 3D!

I've seen what your track laying prototype can do. I strongly believe that this is the best way to go. Have a tile map (triangle/quad/whatever. Doesn't matter in this post), divide each tile into a small grid and allow track section ends to snap to this small grid.

So I guess I'm for a semi-freeform cell based approach ;)
PJayTycy wrote:track also have 8 orientations in square systems and 6 in triangle systems (maybe 12?)
Track can have 4 orientations in square systems and 6 in triangle systems.
It can have 8 directions in square systems and 12 directions in triangle systems. :)

Posted: 31 Jan 2005 14:31
by uzurpator
How much memory does it going to eat?

Posted: 31 Jan 2005 16:04
by Steve
As mentioned in another thread by someone, having different scales of units may be the best approach. Track uses the small units, for the most flexibilty whilst buildings may use the bigger scales as they don't need to be precisely places.
Ultimately, the landscape is going to be the most memory. I'd love to see a freeform landscape using smaller units, but that may be unreasonable. I'd hate to see it be as bad as TTD though. In cases like TTD and Loco, Iso is the way to go, not 3D.

Posted: 31 Jan 2005 19:07
by Zuu
In the cellbased way, as we are in 3D, cant we allow construction of tracks between any two cell midpoints that is resonable close to eachother using your 360 degree of freedome.

Steve and others:
I remember one of the arguments for 3D was that creating content will be esier, as the computer will take care of rendering. While using a 2D iso engine with sprites you have to work more to create content. This does not favor non iso like landscape. Just a note.

Posted: 21 Feb 2005 20:00
by Steve
Meeting Decisions:

- Choices between:
- Tile based solution
- Complete freeform
- Limited freeform with smaller grid
- To be continued on forum.

Status: Continue discussion on forum.

Posted: 21 Feb 2005 21:45
by Arathorn
I would go for something between full or maybe a little restricted freeform.

Posted: 22 Feb 2005 09:57
by Zuu
We decided to have 5 snap points on each side of a tile. But after some thoghts I cant agree with that, becuse we have decided that 4 lanes or 4 tracks should fit side by side on one tile.

I suggest that we use 4 snap points per side. Optionally we can add a fift in the center, if there is a need to place biggger things in the center of the tile. Or just only ine extra in the middle.


The dark blue line is the tile border, and the light blue lines are just help lines that I used to know where to put the red dots. And I thoght that you might have use of them too, so I didn't hide them. The red spots are snap points.

Posted: 22 Feb 2005 12:19
by Hellfire
I vote:
Steve wrote:- Limited freeform with smaller grid

Posted: 22 Feb 2005 12:23
by Zuu
Hellfire wrote:I vote:
Steve wrote:- Limited freeform with smaller grid
That was the result of the voting at the meeting.

Posted: 22 Feb 2005 14:03
by Hyronymus
I vote for a limited freeform with smaller grid too, I think it will be able to serve our demands well.

Posted: 22 Feb 2005 16:20
by Steve
zuu wrote:We decided to have 5 snap points on each side of a tile. But after some thoghts I cant agree with that, becuse we have decided that 4 lanes or 4 tracks should fit side by side on one tile.
That just depends on how you build them. If you build them as 2 sets of 2 lanes, then they'll fit. See attached. Your method seems a strange pattern rather than a regular pattern that will work more fluently.

Posted: 24 Feb 2005 16:15
by PJayTycy
Zuu, your pattern is strange... It's a 9*9 pattern with half of the points removed. Although it's strange, I think it would work, but wouldn't it be easier to just use a "normal" rectangular grid inside cells too (like Steve's example).

Posted: 24 Feb 2005 22:13
by Zuu
Maybe, but how to you place a single track or a single lane on the 5x5 variant in Stevs post?

Posted: 25 Feb 2005 00:38
by Grunt
Like this.

Posted: 25 Feb 2005 01:26
by jfs
zuu's grid suggestion is not an option at all, for the simple reason that rotating it 90 degrees gives a different grid, so the restrictions on building are different on each axis.

Posted: 25 Feb 2005 01:58
by PJayTycy
jfs wrote:zuu's grid suggestion is not an option at all, for the simple reason that rotating it 90 degrees gives a different grid, so the restrictions on building are different on each axis.
nope, rotating it 90° gives the exact same grid.

SGrunt : if you build your single lane like that, you won't fit 4 lanes onto 1 tile.


After all, I don't really care if the cell is divided into 9*9 or 5*5 or 4*4 points. The first important issue is if we will have snappoints inside a cell or only on the edges (see other thread, in discussion with uzurpator).

Posted: 25 Feb 2005 02:03
by jfs
PJayTycy wrote:
jfs wrote:zuu's grid suggestion is not an option at all, for the simple reason that rotating it 90 degrees gives a different grid, so the restrictions on building are different on each axis.
nope, rotating it 90° gives the exact same grid.
Whoops you're right. I need to rest my eyes for the night ;)

Posted: 25 Feb 2005 04:06
by Grunt
PJayTycy wrote:
SGrunt : if you build your single lane like that, you won't fit 4 lanes onto 1 tile.
...that's because I built two lanes there, not one. ;) Seriously, though, running a single lane down the centre of the tile like that doesn't preclude building more lanes in the tile. It just means you don't put down a completely new strip of pavement, but expand on what you've already got so that you could, say, start with two lanes and then expand it out further to give four lanes.

Just kind of envision filling the rest of my diagram there widthwise with pavement to get an idea of what I mean - you'd then slap a median in the middle and get what zuu's diagram looks like...

Posted: 25 Feb 2005 09:12
by Zuu
SGrunt wrote:Like this.
I said a single line or track.

For roads I can accept what you (not only SGrunt) have purposed later on in this thread. But rails, dont you ever want to place a single track next to the border of a cell for example?


PJayTycy, and snappoints on ther border vs whole cell:
Lets ask ous is snappoints on the border enoght? Are there any situation where that yould be too restrictive?

Perhaps we can use my grid, but with only snappoints on the edges. (for track[1] laying)
For buildings I think we have to decide if they need to be placed on a finir grid than the cells. And if so I beleve that edge points are to restrective, as you might want to place it in the middle of a square.


[1]Track = lanes and railway tracks. (which I think should be the only meaning of tracks in our design discussions.)