findDrawings: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{MacroFunction |name=findDrawings |version=1.4.1.9 |trusted=true |description= Returns the id or ids of any drawing on the specified map that match the name parameter. |usage...") |
No edit summary |
||
Line 17: | Line 17: | ||
<source lang="mtmacro" line> | <source lang="mtmacro" line> | ||
[h:id=findDrawings("Grasslands", "block")] | [h:id=findDrawings("Grasslands", "block")] | ||
[h:setFillColor("Grasslands", id," | [h:setFillColor("Grasslands", id,"#000000")] | ||
[h:refreshDrawing("Grasslands", id)] | [h:refreshDrawing("Grasslands", id)] | ||
</source> | </source> |
Revision as of 21:10, 5 February 2018
findDrawings() Function
Note: This function can only be used in a Trusted Macro
• Introduced in version 1.4.1.9
Returns the id or ids of any drawing on the specified map that match the name parameter.
Usage
findDrawings(mapName, name)
findDrawings(mapName, name, delim)
Parameters
mapName
- A string containing the name of the map.name
- A string containing name of the searched for drawings. The only way to name a drawing is via the Draw Explorer interface.delim
- Optional separator. If not specified the default value","
is used.
Example
[h:id=findDrawings("Grasslands", "block")]
[h:setFillColor("Grasslands", id,"#000000")]
[h:refreshDrawing("Grasslands", id)]