The Daily Click ::. Forums ::. Klik Coding Help ::. Tiles & Scrolling
 

Post Reply  Post Oekaki 
 

Posted By Message

Sketchy

Cornwall UK

Registered
  06/11/2004
Points
  1852

VIP Member
20th October, 2008 at 16:22:15 -

In a nutshell;

Which is better when scrolling - one large backdrop or many small ones?



In full;

I was looking at "Mr Map Maker" the other day, and it got me to thinking.
"Mr Map Maker" uses tiles to create a map, but then exports the map as a single large image, which you use as a background in your game.

Initially, I thought that couldn't be good - scrolling a big image the size of the frame is going to really hurt the framerate isn't it? That is, after all, half the reason why tiles are used in games - it uses less memory because you can basically forget about the offscreen tiles.

But then I realized that I don't know if this is true in MMF2. You can't use "paste into background" to create your tiles, because then they'd disappear when you scroll, which only leaves "add to backdrop". I'd guess that if you don't test for collisions outside the frame, then this would be better, but I don't know. Perhaps MMF just uses one big background image itself (that can't be right or you wouldn't be able to delete a specific backdrop).

Also, do invisible objects affect framerate when scrolling? It seems to me that if some tiles are obstacles/platfroms/etc, then you'd need extra invisible collision boxes in addition to the one large image anyway.

 
n/a

OMC

What a goofball

Registered
  21/05/2007
Points
  3334

KlikCast Musician! Guy with a HatSomewhat CrazyARGH SignLikes TDCHas Donated, Thank You!Retired Admin
20th October, 2008 at 18:23:45 -

Different applications call for different techniques. As far as I know, TGF and MMF1.5 conglomerated all backdrops into one image at runtime. (Can't verify MMF1.5, never had it.) I'm not exactly sure which way MMF2 goes, as I haven't been using TGF2 much since I got it, but it could conceivably go either way, considering our faster computers and whatnot.

Using tiles doesn't necessarily mean less memory. Indeed, sometimes it is worse. It depends on the setup.



 

  		
  		

Klikmaster

Master of all things Klik

Registered
  08/07/2002
Points
  2599

Has Donated, Thank You!You've Been Circy'd!VIP MemberPS3 Owner
20th October, 2008 at 21:55:24 -

Yeah I'm pretty sure backdrops get treated as 1 image anyway at runtime, hence the option "Add TO backdrop"

 
n/a

Sketchy

Cornwall UK

Registered
  06/11/2004
Points
  1852

VIP Member
20th October, 2008 at 22:45:40 -

I can believe that's what "paste into background" does.

However, MMF2 must be keeping track of individual backdrops still because there's the action "Delete created backdrops at..." (to delete a single backdrop object at a given x,y).
I think "add to backdrop" must do something more fundamentally different than just preserving objects after scrolling.

 
n/a
   

Post Reply



 



Advertisement

Worth A Click