Search:

Type: Posts; User: Norm

Search: Search took 0.23 seconds.

  1. Replies
    7
    Views
    3,180

    Re: Collision Detection Between Two Squares

    This is a confusing way to compare locations:
    (stillObject.getX() - 100) + playerObject.getX()) < -200)
    what is the code supposed to be doing?
  2. Replies
    7
    Views
    3,180

    Re: Collision Detection Between Two Squares

    In general its better to use variables. There might be a time when they will be changed.
    Using a named variable also makes the code more understandable.

    You will have to know which way is...
  3. Replies
    7
    Views
    3,180

    Re: Collision Detection Between Two Squares

    The way I debug these kinds of problems is by taking a piece of paper and drawing the shapes all the different ways that there can be a collision and then looking at the x,y & width,height of both...
Results 1 to 3 of 3