Skip to content

Static pure function interface

Pre-release
Pre-release
Compare
Choose a tag to compare
@hamaluik hamaluik released this 15 Feb 22:58
· 2 commits to master since this release

Added

  • Added TestResult type which is returned from test() and can be checked directly
    for collisions or passed to intersect() to further calculate an intersection
  • Added IntersectResult type which is returned from intersect() and can be used
    to calculate collision normals, separation distances, etc
  • Added Headbutt.testAndIntersect() function which is a shortcut for testing and
    then calculating the intersection if a collision is found

Changed

  • Changed Headbutt interface from interacting with an object with internal state
    to static pure functions (i.e. call Headbutt.test() instead of new Headbutt().test())