We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › Programming a "hitbox" like effect
Page Index Toggle Pages: 1
Programming a "hitbox" like effect (Read 610 times)
Programming a "hitbox" like effect
Apr 25th, 2010, 6:35pm
 
Hi all,

So for a group project for class my team is trying to figure out how to program our game so that our little helicopter avoids walls that are going to be getting bigger and smaller. The part we cannot figure out is how to make it so when our helicopter "hits" the wall we know and can end the game.

The way we are planning the game is that our background is actually scrolling like a side scroller and the helicopter can only move up and down it does not move left or right. So if the helicopter either hits the wall above it or below it the player loses.

ANY help or links to reference on how this logic is done would be SO helpful!
Re: Programming a "hitbox" like effect
Reply #1 - Apr 26th, 2010, 7:51am
 
Hi mateo,

a lot of this depends on how you're drawing your walls. Maybe if you could post this part of the code (or a screenshot) it would help clarify things.

cheers,
Greg
Page Index Toggle Pages: 1