Items: Difference between revisions

From VisionaireWiki
Jump to navigation Jump to search
m (Bot (Edward's framework))
 
Line 1: Line 1:
==General==
==items==
In this section you can create all items which might be put into a bag. These items have only one image.
Adds one or more items to a control.


==Actions==
Lua Syntax:
Action parts which belong to the item are listed here.
<pre>items({flags=1,
    image = image,
    name = text,
    action = script,
    select = selectitem})</pre>
===Arguments===
===Flags===
====i/image====


For example a possible action for an item "map" might be: "Look at 'map'".
:Associates an image with an item
:'''image''' - Filename of an image-file.
====n/name====


Read more about [[Action System]].
:Associates a text with an item
:'''text''' - Text to use for the list-entry.
====a/action====


==Conditions==
:Associates a Lua-script with an item
Conditions belonging to the item are listed here. Read more about [[conditions]].
:'''script''' - Script to execute when item is selected/activcated.
====s/select====


==Values==
:Selects an item in the control
Values belonging to the item are listed here. Read more about [[values]].
:'''selectitem''' - Specifies the item (first item starts at 0) which will be selected.If -1 is passed no item is selected. If the flag is ommited the first item is selected by default.
===Return Values===
None.

Latest revision as of 11:57, 16 August 2009

items

Adds one or more items to a control.

Lua Syntax:

items({flags=1, 
    image = image, 
    name = text, 
    action = script, 
    select = selectitem})

Arguments

Flags

i/image

Associates an image with an item
image - Filename of an image-file.

n/name

Associates a text with an item
text - Text to use for the list-entry.

a/action

Associates a Lua-script with an item
script - Script to execute when item is selected/activcated.

s/select

Selects an item in the control
selectitem - Specifies the item (first item starts at 0) which will be selected.If -1 is passed no item is selected. If the flag is ommited the first item is selected by default.

Return Values

None.