Discuss this page on this page's [[scrSetListFilter Talk Page|Talk Page]] === scrSetListFilter === See [[http://xelerus.de/index.php?s=functions&function=165|scrSetListFilter at Xelerus]] ^ Syntax | (scrSetListFilter screen expression) | ^ Arguments | screen: The screen you want to filter the items on. | ^ | expression: This can be one of three things. a) A string containing the criteria you want to filter the item list with. | ^ | b) A number giving the margin on sales. 100 = normal price, 0 = free, etc. | ^ | c) A function returning True or Nil. It is evaluated for each item with True = include in list, Nil = exclude from list. | ^ Returns | condition: True is successful. | ^ Category | [[screen functions|screen]] | ^ Description | Sets the list filter from the given screen. Will only display the items that fit the criteria. | Very helpful in filtering item selection screens like loot screens. === Example === (scrSetListFilter gScreen "*U") The current screen lists all the non equipped items. (switch (not gMargin) (scrSetListFilter gScreen intComputeSellPrice) ; Price is calculated individually by item. (isfunction gMargin) (scrSetListFilter gScreen gMargin) ; expression is function (scrSetListFilter gScreen "*") ; expression is criteria string ) Here we see scrSetListFilter used within the ListOptions element in the dockscreen dsExchangeBuy from Transcendence.xml Return to [[:Functions]] list