Releases: KleeSup/KleeSwept
Faster, Smarter, Faster!
With the Version 1.1.0 comes a lot of new features and additions to SimpleCollisionWorld, ISweptBody and CollisionResponse. The new additions where added after hours and hours of bug fixing, creating a lot of collisions at the same time and playing around with new collision resoultion algorithms.
Changelog:
CollisionResponse:
- Normal is now a byte to reduce variable size
- isHit was removed (as non-hitting collisions shouldn't be tracked anyway)
- Added isOverlapping for collisions that currently overlap
SimpleCollisionWorld:
- Collisions are now pooled to reduce gc heat
- Methods to free collision objects by hand were added
- Chunk movement recognition (reduces chunk modifications)
- Empty chunks or chunks only containing the targeted Body get skipped
- If movement happend in one chunk and ended in the same without touching others, chunk checks are heavily reduced
- If the movement area doesn't overlap the AABB of a Body, skip collision check
Collision sorting:
- Can be enabled/disabled now
- Changed the sorting from CollisionComparatorBuilder to CollisionSorter implementation (doesn't require Comparator object creation)
- Added more default sorting implementations to use
SweptBody:
- The interface now has a checkCollision(Body) method to be able to skip collision checks entirly for certain bodies. This is much faster than resolveCollision() because it happens before the collision check, but on the other Hand doesn't generate a collision (which can be useful to reduce lag with entities that shouldn't collide anyway).
EfficientChunkManager:
- Now uses LongMap from LibGDX
Also upgraded to GDX Version 1.12.1.
v1.0.4 Collision resolve adjustments
IMPORTANT!
Version 1.0.4 changes the usage of how ISweptBody#resolveCollision(ISweptBody, CollisionResponse.Collision)
is used in SimpleCollisionWorld
. The method will now by called on the collision CAUSING body and checks against COLLIDING bodies instead of the other way around.
v1.0.3 Resolution control
Whats new in Version 1.0.3?
- Added a method to ISweptBody to decide whether a collision should be resolved or not
- It's now possible to decide how collisions should be sorted and resolved by setting a unique Comparator in SimpleCollisionWorld
- Fixed a minor collision resolution and performance issue
v1.0.2 Small fixes
Changes in Version 1.0.2:
- Fixed a HashMap issue in SimpleCollisionWorld
- Renamed ISweptAABB and SweptAABB to ISweptBody and SweptBody
- More code commented
v1.0.1 World implementation
With version 1.0.1 world implementation is now added!
You can create a SimpleCollisionWorld<>
and then add custom AABB bodies to it.
These can be moved via SimpleCollisionWorld#update(aabb,displacement)
or SimpleCollisionWorld#forceUpdate(aabb,goalX,goalY)
.
Furthermore, it is possible to only simulate a movement with SimpleCollisionWorld#simulate(aabb,displacement)
. Both update
and simulate
return a CollisionResponse
object with detailed information of each collision that occurred.
v1.0.0 First Release
After some work: The first release of KleeSwept!
Features of version 1.0.0:
- swept collision detection between two AABBs
- swept collision detection between multiple AABBs with sorted outcome
- high velocity collision detection
- fixed tunneling problem
- detailed output with hit-position, normal, hit-time, etc.