Jump to content
  • Advertisement
Sign in to follow this  
twoaterisn

2D maps

This topic is 4443 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hello y'all :) I was thinking of making a game containing a destructable 2D map, type worms/lemmings. All i've done untill now are tile-based games, for this should I consider the map as being tile-based, with each pixel being a tile? This way I have to keep track of every pixel, what would be quite slow I think. Is there a better way of doing it? Just tell me what to google for :) thanks, TH

Share this post


Link to post
Share on other sites
Advertisement
Any other way of storing it will take a chunk of CPU work each frame to handle. I'd store the terrain as a 2d array of bytes and use a palletized color source. I think that's how games like Worms where done. A 640x480 map would still be under 300k.

Share this post


Link to post
Share on other sites
If you want pixel perfect destruction, you'll need pixel perfect information. You could do a true-color map and use alpha channel for handelling destruction.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!