Page 1 of 1

Map Layers

Posted: Fri Mar 26, 2010 11:01 pm
by mattheweston
What would you guys suggest for layers for a map?

I'm thinking at least a Base Layer, Object Layer, and a transition layer, but what else am I not thinking of?

Re: Map Layers

Posted: Fri Mar 26, 2010 11:38 pm
by GroundUpEngine
Collision layer?

Re: Map Layers

Posted: Fri Mar 26, 2010 11:41 pm
by mattheweston
yeah I forgot to include that. Anything else?

Re: Map Layers

Posted: Sat Mar 27, 2010 5:17 am
by MrDeathNote
mattheweston wrote:yeah I forgot to include that. Anything else?
You may want to have 2 object layers, it gives you more flexibility.

Re: Map Layers

Posted: Sat Mar 27, 2010 1:38 pm
by xiphirx
I believe that you would want 2 tile layers, for trees and other things that are above a characters head...

Re: Map Layers

Posted: Sat Mar 27, 2010 4:45 pm
by XianForce
Well how I usually do it is something along the lines of:

Tile layer
Object layer 1
Item layer

Object layer 2

Where the first three are rendered before other sprites are rendered, and the last one is rendered after everything else.

Re: Map Layers

Posted: Sat Mar 27, 2010 6:11 pm
by avansc
there a reason you have to have it be a set number of layers?

Re: Map Layers

Posted: Sat Mar 27, 2010 7:39 pm
by K-Bal
You should make a decision based on what your game idea needs.

Re: Map Layers

Posted: Sat Mar 27, 2010 9:25 pm
by MrDeathNote
avansc wrote:there a reason you have to have it be a set number of layers?
None at all, it's completely a design choice i just find that in a tile based game, theres very little point having more than 1 tile layer because they contain no transparency and an extra object layer gives you more flexibility. But your right its completely personal, dont add layers you wont use.

Re: Map Layers

Posted: Sat Mar 27, 2010 10:31 pm
by Falco Girgis
K-Bal wrote:You should make a decision based on what your game idea needs.
YES.

People need to quit asking questions around here that are 100% subjective to a particular game/application.

Re: Map Layers

Posted: Sun Mar 28, 2010 9:32 pm
by eatcomics
For my next project... It won't be 2D, but I"m going to have 3 layers at least. One for tiles, one for enemies, and one for items :D