createTable: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(Created page with "{{MacroFunction |name=createTable |version=1.4.0.1 |description= Creates an empty table, specifying its access levels and optional image. May only be used by GM or a trusted m...")
 
No edit summary
Line 8: Line 8:
createTable(tableName, visible, accessible)
createTable(tableName, visible, accessible)
createTable(tableName, visible, accessible, imageId)
createTable(tableName, visible, accessible, imageId)
</source>
'''Parameters'''
{{param|tableName|A string containing the name of the Table.}}
{{param|visible|Whether or not the table can be seen by players in the Table Window, {{true}} or {{false}}.}}
{{param|accessible|Whether or not the table can be used by players to lookup values, {{true}} or {{false}}.}}
{{param|imageId|Optional and is the asset id of an image that will be used for the table in the Table Window. If an invalid or missing asset id is used, the table will display a red "X".}}
|examples=
<source lang="mtmacro" line>
[r:createTable("tableX",1,1)]
[r:createTable("tableY",1,1,getTableImage("tableZ"))]
</source>
</source>
|also=
|also=

Revision as of 20:35, 2 May 2016

createTable() Function

Introduced in version 1.4.0.1
Creates an empty table, specifying its access levels and optional image. May only be used by GM or a trusted macro.

Usage

createTable(tableName, visible, accessible)
createTable(tableName, visible, accessible, imageId)

Parameters

  • tableName - A string containing the name of the Table.
  • visible - Whether or not the table can be seen by players in the Table Window, true(1) or false(0).
  • accessible - Whether or not the table can be used by players to lookup values, true(1) or false(0).
  • imageId - Optional and is the asset id of an image that will be used for the table in the Table Window. If an invalid or missing asset id is used, the table will display a red "X".

Examples

[r:createTable("tableX",1,1)]
[r:createTable("tableY",1,1,getTableImage("tableZ"))]

See Also