I'm currently implementing a moving AABB vs static AABB collision with the velocity of the box, in a minecraft-like game.
Since the blocks in my game don't have any collider(for performance issue), this is what I do to check the collision.
with the velocity of the moving box, considering it as the direction vector(ray), check if there is a box within the range of the velocity.
If the box is jumping, and moving on +x axis / - z axis.
I check all 6 edges with the vector to see if there is a collision.
But is there a more optimized way to check collision than this method?
Thank you!