GetWornItemMods - Actor

From Creation Kit
Revision as of 2018-01-20T23:59:40 by Scrivener07 (Talk | contribs) (added required f4se version)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

F4SE Member of: Actor Script
Requires F4SE version 0.2.0 or higher.

Obtains all the Object Mods for an item at a particular Biped Slot.

Syntax

ObjectMod[] Function GetWornItemMods(int slotIndex) Native

Parameters

Return Value

An array of all Object Mods obtained from the given Biped Slot index, returns none if there is no item.

Examples

; Get the players left hand object mods.
ObjectMod[] objectMods = Game.GetPlayer().GetWornItemMods(4)


{For each object mod}
int LeftHand = 4 const
ObjectMod[] objectMods = Game.GetPlayer().GetWornItemMods(LeftHand)
If (objectMods)
    int index = 0
    While (index < objectMods.Length)
        Debug.Trace("Found the object mod '" + objectMods[index] + "' on slot index " + LeftHand)
        index += 1
    EndWhile
Else
    Debug.Trace("Slot index " + LeftHand + " had no object mods.")
EndIf

Notes

None

See Also