SilverlightClub.com Home page     All Communities

Labyrin Silverlight Application


Pretty cool game



My Profile 
  • Sign In
  •  
  • Register

  • Links 
  • Message Center
  •  
  • File Manager
  •  
  • Members
  •  
  • Hall Of Fame
  •  
  • Site Configuration





  • Pretty cool game


    Posted Date: 14 Nov 2009      Total Responses: 2

    Posted By: Pirate11       Member Level: Bronze     Points: 1


    pretty cool game....

    can u just tell me how did u achieve collision detection in ur game..
    i.e., the way user can move only between walls n not thru da walls...

    thnx..




    Responses

    Author: Chris    15 Nov 2009Member Level: BronzeRating: 2 out of 52 out of 5     Points: 5
    Hi, glad you enjoy the game.

    As far as the collision detection goes, as I guess you know the the map is actually two dimensional internally. Using the internal representation I simple check the position of the player against the maze walls and do not allow the position change to take the player within a fixed distance from the wall, too be honest the routine is not perfect, it has a few glitches but it is simple.



    Author: Pirate11    16 Nov 2009Member Level: BronzeRating: 2 out of 52 out of 5     Points: 4
    okk... let me guess.. you are mapping a 2D array into maze on the screen..

    so have you defined some boundary for a cell?
    i mean that a cell is a size 20 X 20.. so if user is at 10 X 10, then he is ok. if he tries to go in at 21 X 21, he collides..

    am i right?


    Post Reply
    You must Sign In to post a response.
    Return to Discussion Forum
    Post New Message
    Category: