Map Size - Tiled Map Size ? How Big?

Hey Guys,

I was wondering if you could shed some light on a question I have with using Lime. I’m trying to make a map 3 screens across and 5 screens down
so (1440x1600)

Is this size possible in Lime? and will I have any speed issues? already purchased the software and want to start the design phase but don’t want to get 1/2 way through coding and then have issues with the game running slow ext.

Any help would be much appreciated. [import]uid: 40417 topic_id: 11671 reply_id: 311671[/import]

I would imagine part of the answer is going to depend on how large your tiles are.

If your tiles are 1440x1600 you won’t have any trouble at all because Lime will only be pushing around 1 tile. :slight_smile:

On the other hand, if your tiles are 16x16 that means a total of 9,000 tiles (display objects) and I would imagine some chugging would take place.

What size tiles are you going to use?

Jay
[import]uid: 9440 topic_id: 11671 reply_id: 42444[/import]

Dear Jay,

Thanks for the reply, my tiles are 32x32. Would that be OK. [import]uid: 40417 topic_id: 11671 reply_id: 42450[/import]

Hopefully someone will come along who knows – I’m a *very* beginner newbie with Lime. I was just pointing out there probably wasn’t enough info in your first post for someone to give you a decent answer.

Now there probably is enough info. :slight_smile: But you’re still talking about 4,500 display objects to shuffle around. I think you’ll see problems.

Anyone with Lime experience want to jump in?

Jay
[import]uid: 9440 topic_id: 11671 reply_id: 42451[/import]

Dear Jay,

May I ask how you came across the number 9000?

If I had a screen 1440 in length by 32 in height I would have 32 tiles
then 1600 /32 = 50
x 50 = 2250 tiles
[import]uid: 40417 topic_id: 11671 reply_id: 42452[/import]

16x16 tiles is 9,000 objects.

Double the size of the tiles, so just halve the number of objects. Easy.

Of course, now that you point it out and I shift my brain into gear, it’s wrong. :slight_smile:

Divide the original by 4 is what I should have done since 32x32 tiles are 4 times the size of 16x16, not twice.

Just simple carelessness on my part. I’m very good at that. :slight_smile:

Still, 2,250 tiles is a lot. But better than 4,500. :slight_smile:

Jay
[import]uid: 9440 topic_id: 11671 reply_id: 42453[/import]

Indeed Jay 2250 is still a tonne of objects lol and I would say at least 2000 of them are going to need to be checked for collisions lol, any Lime veterans able to provide a defiant answer? [import]uid: 40417 topic_id: 11671 reply_id: 42455[/import]

Hey Danny, currently that many objects will probably kill the device. I am experimenting with a dynamic loading method however haven’t worked out fully how I will bring over all the main features of Lime to it. [import]uid: 5833 topic_id: 11671 reply_id: 43187[/import]

I have a map that is 90 tiles wide and 60 tiles tall

This is using a 32x32 tile size. It works wonderfully IF you use Lime sparingly.
Basically this is what I did, a birds eye if you will…

Use lime to create the borders of the map and physical bodies (isGround, bodyType static etc) on on the left,right,top,bottom.

Save the map.

Now, using whatever tile set (doesn’t matter) draw out loosely where you want things.

Then I go to corona and map out the coordinates.

Then load the file and see if what you coded matches what you place things in tiled, once they match remove the objects from tiled.

Rinse and repeat for all the platforms.

Since the default of any display object is the center reference point of an object I calculate (this isn’t precision science, just what I do lol) I count how many tiles over on X the object is and how many tiles down on Y the object is, then I map that to an X and Y coordinate.

Then I code that into my main.lua file (or if you are fancy pants and have modularized code, then put it there)

That’s one way to do it.

The other way is to go online and make your own graph paper. I made mine 90x60 and I can free hand draw stuff and then use that to code into corona and NOT use lime at all. This way is a longer way.

Seems like for me doing things in tiled, using lime to call the borders of the map and SOME objects and then code natively in Corona (and also using PhysicsEd) seems to give me the best performance

Gives me large maps, good performance and a moderate build speed. Keep in mind this is for straight up mario type maps. If you want things like Bezier curves and weird things like that, then you have to get SVG Level builder in the mix which will make life SO much easier.

*Keep in mind that on SVG level builder, you CAN draw free hand curves, but each pixel becomes a physics body and that becomes 100’s of bodies for a simple line. Instead use the bezier curve thing.

I will say that if you use the graph paper method and just purely go Corona sdk all the way, it will run REALLY fast. Just takes a while and you have to get your camera to follow your character and you need to put a background that has reference points on it so you know where you are at vs using tiled where you can just SEE. I guess it’s whatever trade off you want.

that’s my 2.5 cents on that lol.

Basically Lime (sparingly) + Svg level builder (Sparingly) + Physics Ed (sparingly) + Corona (80%) = love

Basically the moral of my story is Rather than try to get around your limitations, embrace those limitations and make it work. :slight_smile: Works for me.

-Nick G [import]uid: 61600 topic_id: 11671 reply_id: 47714[/import]

“Rather than try to get around your limitations, embrace those limitations and make it work.”

I like that a lot, basically rather than thinking outside the box just think inside the box and you can get things going very well :slight_smile: [import]uid: 5833 topic_id: 11671 reply_id: 48156[/import]

So what I’m reading here is that Lime may not be the best solution for rather large maps? I’m wanting to use a map that’s about 200x200 tiles. The emulator seems to load the map OK, but it takes several seconds before it finally displays. [import]uid: 77723 topic_id: 11671 reply_id: 48361[/import]

What you have to remember is 200*200 is 40,000 tiles. That is a whole lot of objects by any game engines standards.

Culling will help to a certain degree but that is still a lot of objects for the engine to deal with.

What Lime needs is some kind of dynamic loading system so only a screen of tiles is ever actually created and then the images of the tiles just change to emulate movement. I have a test of this working however developing it into a full featured library like Lime rather than just a tile loader and displayer is proving difficult. [import]uid: 5833 topic_id: 11671 reply_id: 48437[/import]

I am using 625 high x 20 tiles wide which is 12500 tiles. 32x32 tile size. (20,000 pixel hieght x 640 pixel width)
I cheat though. I use tiled to create the images to png, then I chop it up to the maximum length corona will take which is 2048x2048 or in my case is 2048 high, by 640 wide and I create my background with that.
Then for static objects, I use tiled. Then I use corona for spinning animated things, elevator platforms etc etc.

I posted in another section about maybe breaking out the maps to 2048 high x 10 and loading 10 tiled maps per level…I dunno yet though, it’s all experimental right now :slight_smile:

The trick is when you use groups and start grouping display objects that are animated, elevators, whatever and making it play nice with Lime.

I really, really like lime though. It’s just working WITH all the limitations I have (like I said before, I embrace those limitation hehe).

-ng [import]uid: 61600 topic_id: 11671 reply_id: 51645[/import]