Rocky590

Member
  • Content count

    0
  • Joined

  • Last visited

Community Reputation

104 Neutral

About Rocky590

  • Rank
    Newbie
  1. This is not working for me not sure where everything went wrong :/  // if there was no collision if (entryTime > exitTime || xEntry < 0.0f && yEntry < 0.0f || xEntry > 1.0f || yEntry > 1.0f) { normalx = 0.0f; normaly = 0.0f; return 1.0f; // My code always returns this when collision occurs } // if there was a collision,, It never checks for this since its returns 1.0 all the time else {          // calculate normal of collided surface if (xEntry > yEntry) { if (xInvEntry < 0.0f) { normalx = 1.0f; normaly = 0.0f; }      else { normalx = -1.0f; normaly = 0.0f; } } else { if (yInvEntry < 0.0f) { normalx = 0.0f; normaly = 1.0f; }      else { normalx = 0.0f;          normaly = -1.0f; } } // return the time of collision return entryTime; }