Jump to content

[Template] Equip item to player, wait for OStim end, unequip item


hextun

Recommended Posts

Posted
; change this to something other than $system.player (e.g. $system.ostim.partner) to target a different actor for some reason
set $target_actor $system.player

; if we are not in a scene, exit
ostim_isin $target_actor
if $$ == false
  return
endif

; change these two values appropriately to the formid and armor slot of the item to add/equip/unequip/remove
set $item_to_equip "modfile.esp:0xDEADBEEF"
set $item_slot 32

; add and equip
item_addex $target_actor $item_to_equip 1 true
item_equipex $target_actor $item_to_equip $item_slot false false

; wait til done
ostim_waitforend $target_actor

; unequip and remove
item_unequipex $target_actor $item_to_equip $item_slot
item_remove $target_actor $item_to_equip 1 true

 

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...