setMapName: Difference between revisions
Jump to navigation
Jump to search
m (Conversion script moved page SetMapName to setMapName: Converting page titles to lowercase) |
No edit summary |
||
Line 6: | Line 6: | ||
Changes the name of a specified map. | Changes the name of a specified map. | ||
|usage= | |usage= | ||
< | <syntaxhighlight lang="mtmacro" line> | ||
setMapName(oldMapName, newMapName) | setMapName(oldMapName, newMapName) | ||
</ | </syntaxhighlight> | ||
'''Parameters''' | '''Parameters''' | ||
{{param|oldMapName|String specifying the current name of the map you wish to rename.}} | {{param|oldMapName|String specifying the current name of the map you wish to rename.}} | ||
{{param|newMapName|A string containing the name to which you want it changed.}} | {{param|newMapName|A string containing the name to which you want it changed.}} | ||
|examples= | |examples= | ||
< | <syntaxhighlight lang="mtmacro" line> | ||
[r:setMapName("Grasslands","Map1")] | [r:setMapName("Grasslands","Map1")] | ||
</ | </syntaxhighlight> | ||
}} | }} | ||
[[Category:Map Function]] | [[Category:Map Function]] |
Latest revision as of 20:50, 14 March 2023
setMapName() Function
Note: This function can only be used in a Trusted Macro
• Introduced in version 1.4.0.1
Changes the name of a specified map.
Usage
setMapName(oldMapName, newMapName)
Parameters
oldMapName
- String specifying the current name of the map you wish to rename.newMapName
- A string containing the name to which you want it changed.
Examples
[r:setMapName("Grasslands","Map1")]