GetScale - ObjectReference

Revision as of 12:19, 14 August 2018 by imported>DavidJCobb (verified via disassembly: scale is stored as a percentage)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Member of: ObjectReference Script

Returns the current scale of this reference.

SyntaxEdit

float Function GetScale() native

ParametersEdit

None.

Return ValueEdit

The current scale of the reference.

ExamplesEdit

Debug.Trace("The box has a scale of: " + box.GetScale())

NotesEdit

  • Internally, a reference's scale is stored as an integer percentage (i.e. 100 for normal size; 200 for double-sized). This function returns that scale value divided by 100 (with additional multipliers for actors). This means that a reference's scale cannot be gotten or set to a precision of more than 0.01.

See AlsoEdit