setTableEntry: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 8: Line 8:
<source lang="mtmacro" line>
<source lang="mtmacro" line>
setTableEntry(tableName, roll, result)
setTableEntry(tableName, roll, result)
setTableEntry(tableName, roll, result, imageId)
</source>
</source>
'''Parameters'''
'''Parameters'''
Line 13: Line 14:
{{param|roll|Whether or not the table can be seen by players in the Table Window, {{true}} or {{false}}.}}
{{param|roll|Whether or not the table can be seen by players in the Table Window, {{true}} or {{false}}.}}
{{param|result|A string containing the result returned by the '''table()''' function.}}
{{param|result|A string containing the result returned by the '''table()''' function.}}
{{param|imageId|Optional and is the asset id of an image that will be returned by the '''tableImage()''' function.}}
|also=
|also=
[[table (function)|table()]]
[[table (function)|table()]]
}}
}}
[[Category:Table Function]]
[[Category:Table Function]]

Revision as of 09:49, 4 March 2019

setTableEntry() Function

 Note: This function can only be used in a Trusted Macro

Introduced in version 1.4.0.1
Sets the result for a specified roll value. Returns true(1) if update successful and false(0) if not.

Usage

setTableEntry(tableName, roll, result)
setTableEntry(tableName, roll, result, imageId)

Parameters

  • tableName - A string containing the name of the Table.
  • roll - Whether or not the table can be seen by players in the Table Window, true(1) or false(0).
  • result - A string containing the result returned by the table() function.
  • imageId - Optional and is the asset id of an image that will be returned by the tableImage() function.


See Also