Editing Walking Through Inventory Items

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 21: Line 21:


==From the Beginning to the End==
==From the Beginning to the End==
<pre>short invPos
<pre>short InvPos
short invCount
ref pInvObj
ref pInvObj
ref pCont
ref pCont
...
...
set pCont to YourDesiredContainer
set pCont to YourDesiredContainer
set invPos to 0
set InvPos to 0
set invCount to pCont.GetNumItems
Label
While invPos < invCount
set pInvObj to (pCont.GetInventoryObject InvPos)
   set pInvObj to (pCont.GetInventoryObject invPos)
if pInvObj
   set InvPos to (InvPos + 1)
   ;Do whatever you want to do
   ;Do whatever you want to do
   set invPos to invPos + 1
   Goto
Loop</pre>
endif</pre>


==Notes==
==Notes==

Please note that all contributions to the Oblivion ConstructionSet Wiki are considered to be released under the Creative Commons Attribution-ShareAlike (see CSwiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)

Template used on this page: