benilla-re systems structs docs

GetSpellEffectPointsInt

function · spell · primitive

Address
0x6e3760 · 156 bytes, up to 0x6e37fb
Signature
void __fastcall (const void *spell, uint32_t effect, int32_t *min, int32_t *max, uint32_t level, uint32_t pet, uint32_t unmodified)
Meaning
Converts the bounds 0x6e3800 returns to integers through fistp and a halving shift
Confidence
verified, proof one
Finding
spell/records#effect-amount-as-integers
Test
spell::spell_minmax_radius_difftest

Finding: Effect amount as integers in spell: records

0x6e3760 calls GetEffectPoints with its own arguments and converts each bound x to rint(2x − 0.5) >> 1 when x ≥ 0 and rint(2x + 0.5) >> 1 otherwise, an arithmetic shift, at round-to-nearest-even. That is the floor for x ≥ 0, and nearest with ties toward zero for x < 0. A NaN takes the second form and gives 0xc0000000; so does a value past the int32_t range.

The derivation is in the doc.

Callers 9

Callees 1

Calls and jumps by a bare address, from tables/calls.tsv.