2 ms·
In the original game, triangles are bucketed in a grid perpendicular to gravity. So to do collision, you take Mario’s position on that plane, do a 2d array look
by cylon13 5y ago
In the original game, triangles are bucketed in a grid perpendicular to gravity. So to do collision, you take Mario’s position on that plane, do a 2d array lookup into a bucket, and then iterate over the few triangles that touch that bucket.
In the library version I just cut that system out to make my life easier while refactoring that stuff, but it would certainly be nice to do something better than ripping over every triangle at some point.