Difference between revisions of "DropAllItems"

268 bytes removed ,  03:47, 4 July 2007
Added warning about using OBSE's loops
imported>Scruggs
(looping version)
imported>Haama
(Added warning about using OBSE's loops)
Line 37: Line 37:
  end
  end


Using OBSE's looping functions, you can speed things up a bit:
Note that using OBSE's loop functions may result in a crash. See [[:Category:OBSE_Flow_Control_Functions|this link]] for more information.
<pre>ref item
short quant
short numItems
 
begin gameMode
  if ( timeToDropItems )
    set numItems to getNumItems
    Label 10; start of loop
    if ( numItems )
      set numItems to numItems - 1
      set item to getInventoryObject numItems
      set quant to getItemCount item
      drop item quant
      GoTo 10
    endif
  endif
end</pre>
Anonymous user