Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (711)
Games in Android Showcase (213)
games submitted by our members
Games in WIP (785)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Isometric item placement?  (Read 2816 times)
0 Members and 1 Guest are viewing this topic.
Offline LordChandar

Junior Devvie

Projects: 1

« Posted 2012-12-15 15:05:48 »


So today I am working on the best way to add items into the world.  Things like tables, chairs etc...

My isometric grid is based on a 64x32 terrain.  Charis are obviously smaller than 64x32, and tables can be larger.

The tile writing method I use basically makes a grid and puts images on the map in a grid.  I am having a little difficulty getting larger items to line up with smaller items etc...

Does anyone have any good solutions they would like to share about this issue?  Trying to place an item on the table is my biggest challenge right now.

Should the tables just be forced to be some large size multiple of 64x32?

Should I create little decoration bundle tiles that take 1,2,3,4 items put them together logically and then decorate with bundles?

Should I try to come up with a way to place items in the world in a pixel-perfect precision manner?

I am kinda stumped and it makes me have sad faces.

Any help would let me turn my frown upside down.

Offline ctomni231

JGO Wizard

Medals: 99
Projects: 1
Exp: 7 years

Not a glitch. Just have a lil' pixelexia...

« Reply #1 - Posted 2012-12-16 02:16:16 »

This problem is really not as big as you are making it seem. There was an old game called XCOM: Terror from the Deep that uses isometrics and item placement. What your game can learn from it is the ability to add floors. Since you are already able to place tiles on an isometric grid, you need to make another grid above that grid that accounts for a step. In other words, you'll have 2 planes stacked one on top the other.

A table will be placed on the lower plane, but the table top will be on a higher plane. All items on the higher plane will contain your items. You can make the upper plane the same length as the height of the front table leg. It'll also make it easier for items to have different levels in your world.

If you need ideas, take a look at some screenshots from that game to help you out.,348919/

Using planes at different heights will help you place objects a lot more easily. Good luck.

Offline Xyle
« Reply #2 - Posted 2012-12-16 12:16:15 »

I have used layers in my tile game in order to place certain things on top of other things. I used a layer called decorations in order to place paintings on walls, candles or plates on tables, etc.

I also create the table using a 64x64 tile. I just put an algorithm in the tile drawing function that starts drawing that tile based on its height.

Hope that helps a bit!

Life is just a game, learn to play!
╬-YellzBellz Games!-╬ Cheesy
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline LordChandar

Junior Devvie

Projects: 1

« Reply #3 - Posted 2012-12-16 13:15:38 »

I appreciate the feedback.  I have 6 layers in the world.

Layer 0 is terrain
Layer 6 is roof
layer 1-5 could be anything.  I guess you are suggesting that layer 0 and layer 6 are drawn as isometric only, and I go back to standard 32x32 tile placement on the layers 1-5, or say layers 1-2 are isometric and layers 3-4-5 are standard 32x32flat tile placement?
Offline Xyle
« Reply #4 - Posted 2012-12-16 17:02:32 »

I use isometric tiles for everything in my game.
I model the object in blender and render it using an isometric camera, then use Gile to give the tile a transparent background.
Depending on the size of the object, it may be 64x32 or 64x64. (I use a sizing algorithm to draw the tile in the right spot when I draw the map)
The object is placed on a layer with a higher zorder or depth than the table.
My layers...
0 = ashpalt/concrete
1 = dirt
2 = grass/ floor
3 = objects (collidable, walls, trees, signs, furniture)
4 = decorations (paintings, candles, plates)
5 = collide layer (for detecting collisions)

I haven't created any objects that are wider than 64, but using the same drawing algo based on size should work with those too.
Heres a pic...

Life is just a game, learn to play!
╬-YellzBellz Games!-╬ Cheesy
Offline LordChandar

Junior Devvie

Projects: 1

« Reply #5 - Posted 2012-12-16 17:35:26 »

You have a beautiful looking game.  I think the artist and I will work out the technical difficulties.  I have decided to keep it all isometric.
Offline LordChandar

Junior Devvie

Projects: 1

« Reply #6 - Posted 2012-12-16 17:37:46 »

My algo using a sizing algo also, For anything larger than default tile height, it starts right justifying it.  It works well. 
Pages: [1]
  ignore  |  Print  
You cannot reply to this message, because it is very, very old.

Archive (61 views)
2017-02-27 19:41:49

Riven (72 views)
2017-02-27 17:26:59

numerical (441 views)
2017-02-21 07:32:16

numerical (444 views)
2017-02-21 07:31:46

theagentd (555 views)
2017-02-18 13:42:33

theagentd (551 views)
2017-02-18 13:35:16

h.pernpeintner (1726 views)
2017-01-24 22:39:11

h.pernpeintner (1685 views)
2017-01-24 22:38:32

Galdo (2266 views)
2017-01-12 13:44:09

Archive (2183 views)
2017-01-02 05:31:41
List of Learning Resources
by elect
2016-09-09 09:47:55

List of Learning Resources
by elect
2016-09-08 09:47:20

List of Learning Resources
by elect
2016-09-08 09:46:51

List of Learning Resources
by elect
2016-09-08 09:46:27

List of Learning Resources
by elect
2016-09-08 09:45:41

List of Learning Resources
by elect
2016-09-08 08:39:20

List of Learning Resources
by elect
2016-09-08 08:38:19

Rendering resources
by Roquen
2016-08-08 05:55:21 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!