To download this library for your Linux/Mac installation, enter this on your command line:
DreamDownload byond://Kaiochao.Hypot##version=0 Emulator users, in the BYOND pager go to File | Open Location and enter this URL:byond://Kaiochao.Hypot##version=0 |
This library consists of a single proc: hypot(x, y).
It's often used to calculate the distance between points in 2D. That is, the straight Euclidean distance, rather than the "Chessboard" distance of get_dist() and bounds_dist(). Said another way, this computes the magnitude of your everyday 2D vector (x, y). See here for more information: https://en.wikipedia.org/wiki/Hypot This is where the implementation comes from. Apparently, it's not as simple as sqrt(x * x + y * y). |
![]() Please support BYOND through Membership or a donation!
|
Related Libraries
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
More Libraries by Kaiochao
|
Copyright © 2024 BYOND Software.
All rights reserved.