fscopel To be honest, since you're using exact measurements for checking distance rather than rounding them up, the chances of you getting equal distance between two cannons is very, very low. I tried in your example to get somewhere in the middle of 290.181271743284 (or something equally hard, ha ha) and I couldn't even equalise the .18 part because of mouse sensitivity. If you were rounding up the numbers to whole numbers then yeah, it'd be more of a problem and require solving.
As for your game mechanics, looks fun, I like those games as I'm heavily nostalgic, . Hence why I'm making a space shooter, and possibly an RPG after, ha ha. Keep up the good work!