IsWorldPositionInRange
function · unassigned
- Address
0x404d10· 170 bytes, up to0x404db9- Signature
uint32_t __stdcall (float x, float y, float z, float margin)- Meaning
- Returns whether x, y and z are finite and x and y lie within the map square less a margin
- Confidence
- verified, proof one
- Finding
- console/commands#position-range-test
Finding: Position range test in console: commands
0x404d10(x, y, z, margin) returns 1 when x, y and z are finite and, with H = 17066.666
(0x46855555) and S = 34133.332, margin ≤ H − x < S − margin and margin ≤ H − y < S − margin;
otherwise 0. z is only tested for being finite. Both callers pass z and margin as 0, so x and
y must each lie in (−17066.666, 17066.666]. H − x is rounded to a float before its tests; H − y
is not.
The derivation is in the doc.
Callers 2
- PortCommand unassigned
- SetRawPosCommand unassigned
Callees 1
- _finite crt
Calls and jumps by a bare address, from tables/calls.tsv.