PickOneOf
Revision as of 16:06, 1 July 2014 by imported>Odessa (Created page with "{{Function |origin = NVSE |summary = Called on a reference, returns one random item from the intersection subset of items that are contained both in their inventory and the...")
< [[::Category:Functions|Category:Functions]]
A function added by the New Vegas Script Extender.
Description
Called on a reference, returns one random item from the intersection subset of items that are contained both in their inventory and the specified form list. Returns 0 if no items are common to both.
Syntax
(form) actor.PickOneOf Intersection:formlist
Example
; SunnyREF inventory contains: Beer, Jet, Knife ; MyFormList contains: Beer, Jet, GeckoSteak SunnyREF.PickOneOf MyFormList ; returns either Beer or Jet, at random