Skip to main content
GameDev.net gamedev.net
๐Ÿ”’ Locked

Deformable 2D terrains

Started by krumms Apr 5, 2005 at 4:43 AM 1 replies 1.7k views
Original Post
krumms
krumms
I've been trying to think of a way to implement deformable 2D pixel terrains, much like worms/liero/etc. I can't seem to get my head around how you'd check for collisions of a sprite with the terrain - would it really be necessary to do a pixel-by-pixel collision test for the entire terrain? there has to be a better way.
refrain_from_stupidity( &me );
pim
pim
You could divide the terrain into a grid and check for collisions (pixel perfect) against only the grid cells that are fully or partially covered by the object..

http://freespace.virgin.net/hugo.elias/models/m_colide.htm

this link is for particles, but you get the idea..
dsage
dsage
http://no-skill.kbs-design.net/drupal/gamedev/jnrdev/pixellandscapes

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.