kominetz / elite-tools

Tools and Utilities about Elite Dangerous
Apache License 2.0
3 stars 0 forks source link

Add cubic distance functionality. #19

Open kominetz opened 4 years ago

kominetz commented 4 years ago

Sometimes the game approximates distance using the radius as half the length of a containing cube. Add functions for testing if a system is within the cubic distance given a radius (i.e., half a side) and for finding all systems within a cube.

The latter function could either use the former, like the current nearby function, or it could do a query on the df directly, i.e., "origin_D + r >= D >= origin_D - r" where D: [x, y, z].