Jump to content
  • Advertisement
Sign in to follow this  
xuele91

Help! Thank you

This topic is 2993 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

Just some basic information:
we are doing a jigsaw puzzle game using the multi-touch capability, XNA and C#.

The problem now is that, in each puzzle piece, there will be a center point which touchdown is done and user will be able to drag the pieces around the screen. however, in every puzzle pieces, there will be their own center point, which if let say, i drag the 1st puzzle piece over the 2nd puzzle piece, it will overlap and the 2nd puzzle piece will move together with the 1st one.
therefore, we wish to solve this problem by detecting the overlapped puzzle pieces and do not want the overlapping problem to happen.

Can anyone help us by creating new class? or codings to solve the overlapping puzzle pieces problem?

Thank you so much!

Share this post


Link to post
Share on other sites
Advertisement
Don't select pieces while one piece is being dragged.

If you want more specific help, or code, we could negotiate a percentage I receive of your income you make with the game.

Share this post


Link to post
Share on other sites
Quote:
Original post by szecs If you want more specific help, or code, we could negotiate a percentage I receive of your income you make with the game.


LOL, I like you :P

Anyway, to stop dragging the "underneith" piece, you could perform a check to determine whether or not a piece is being "dragged" if the result is true do not pick up any more pieces else pick up piece.

Share this post


Link to post
Share on other sites
Quote:
Original post by CodeCriminal
Quote:
Original post by szecs If you want more specific help, or code, we could negotiate a percentage I receive of your income you make with the game.


LOL, I like you :P

Anyway, to stop dragging the "underneith" piece, you could perform a check to determine whether or not a piece is being "dragged" if the result is true do not pick up any more pieces else pick up piece.


Is you a girl? If so, we could negotiate...

Share this post


Link to post
Share on other sites
Quote:
Original post by szecs
Quote:
Original post by CodeCriminal
Quote:
Original post by szecs If you want more specific help, or code, we could negotiate a percentage I receive of your income you make with the game.


LOL, I like you :P

Anyway, to stop dragging the "underneith" piece, you could perform a check to determine whether or not a piece is being "dragged" if the result is true do not pick up any more pieces else pick up piece.


Is you a girl? If so, we could negotiate...


Haha no sorry, straight dude :P

Share this post


Link to post
Share on other sites
The problem with all your suggestions about not picking up another piece if you're already dragging one is obvious from the OP. He's using multi-touch. Which usually means that they'll want to be able to pick up one piece, and then maybe another.

You'd need to detect the touch, and then have a sort of no-touch zone around it. Just a simple radius. If the centre of another piece falls into this no-touch zone, then don't pick it up. Otherwise do pick it up.

Share this post


Link to post
Share on other sites
Um...
Multitouch or not,
does the OP want to be able to drag more pieces at a time or not? If not: have a flag that indicated that a piece is currently being touched, and don't perform any selection.

What do I misunderstand? If the OP wants more pieces to be able to be dragged then yes, AndyEsser's idea is good.

Share this post


Link to post
Share on other sites
Well chances are they do want control multiple pieces simultaneously because the only other use of multitouch in an app like this would be for rotating the pieces, which to do that as well you still need to define a region around the central touch point that is deemed a 'correct' place for the 2nd finger.

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!