Archived

This topic is now archived and is closed to further replies.

Doddler

Wham! style terrain, but with D3D?

Recommended Posts

Has anyone here ever played the game Wham! ? It was one of those really fun cave flying action games, side view, 2d action games where the two players try to kick the crap out of each other. Anyways, a real neat thing about the game is that when your bullets missed the opponent, it would colide with a wall, taking a chunk out of the wall. Depending on your settings, some of the dirt would fall down and become more wall below. It was a memory intensive system, so I needed a 233 at the time, for 320x240, but it was really fun. Anyways, the whole point of my posting, is, well, could something like that be possible in Direct3D? Would it be feasable to code such a system to run in D3D, not to mention without screwing people over for processing power? Any ideas about how such a thing would be coded? Anyways, Thank you for your time. -Doddler

Share this post


Link to post
Share on other sites
I think it''s not possible in D3D because direct access to video-memory isn''t allowed. DDraw is possibly the only way to go.

Any other thoughts?? I''d also like to hear something...

Share this post


Link to post
Share on other sites
hmm... sure...
when a bullet hits the ceiling, move some nearby vertices up, so it looks like there is a chunk missing. then, make a "chunk-like" thing (a separate object) fall down until it collides with the floor. then, get rid iof it and raise some of those nearby floor vertices up, so the floor is higher right around there.
i''m sure you will have to work out a method of finding which vertices should be moved on the ceiling and floor, and figure out a way to make a nice looking lump of dirt, but it can be done i think.

--- krez (krezisback@aol.com)

Share this post


Link to post
Share on other sites
hmm... interesting ideas. Another example, which came to mind a bit later, was the Worms games. They used deformable terrain. I like krez''s idea. It sounds like it would work if I could get it to deform properly. Thanks for the help.

-Doddler

Share this post


Link to post
Share on other sites
quote:
Original post by Doddler
It sounds like it would work if I could get it to deform properly. Thanks for the help.

that is the hard part i have no clue...
no problemo...

--- krez (krezisback@aol.com)

Share this post


Link to post
Share on other sites
Hi. I''m working on a Wings/Wham/Auts/Kops/Liero/Molez style game too. I''m using DirectX8 (D3D) for drawing. I have a huge .tga file which is the level. I think it would be possible to load the whole image to system memory and then alter it there. I have a quadtree and a lru cache in the video memory. When needed I load pieces of the level to cache. I haven''t yet completed the whole system so I don''t know if it would work. Any thoughts?

Share this post


Link to post
Share on other sites
It would look ok, if not nice to have a 2d textured mesh, but as mentioned deformation is a problem. I''m not sure if this would work, but if you use the x/y co-ords as texture co-ordinates, and then deform the mesh, then it would look ok if you deform it. But there are a few problems. First, you''d need to remove poly''s as the mass of earth shrunk. Adding poly''s would be annoying. There''s also the issue with the deformed mesh with accuracy, because you''ll need a damn fine mesh if the player is going to like what he see''s.

For poly removal, I''m sure what you could do is define a maximum distance between indices, and then drop poly''s from the mesh if other indices move too close.

I''m currently thinking of a method to split textures up into smaller chunks. There''s no way you can store the whole levels texture in vid memory. However, if the levels mesh was layed out in a grid like fashion, then one wouldn''t have any problems.

None of this solves my dirt falling problem, because I''d actually add an extra layer of difficulty by spesifying the min distance between indices. This means I can''t stick in subtle differences in the mesh. The dirt falling could also be a potentially different color from the mesh it''s trying to attach itself to, so there''s another small problem.

What does everyone think? Am I on the right track? Am I just being a fool?

-Doddler

Share this post


Link to post
Share on other sites