Skip to content

.range()

Alex edited this page Aug 20, 2020 · 4 revisions

Ballistics.range(): u8

  • Public
  • Calculate the maximum range that a ballistic projectile can be fired on given speed and gravity.
  • Returns 1 if range is larger than 0, otherwise returns 0

Input Buffer

Index Value
0 projectile speed
1 force of gravity, positive is down
2 distance above flat terrain

Output Buffer

Index Value
0 maximum range