transferMBL: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
m (Conversion script moved page TransferMBL to transferMBL: Converting page titles to lowercase)
m (Added description; fleshed out the rest of the page)
Line 2: Line 2:
{{MacroFunction
{{MacroFunction
|name=transferMBL
|name=transferMBL
|proposed=false
|trusted=true
|version=1.12
|version=1.12
|description=
|description=Directly transfers MBL to/from a token and the MBL layer.


|usage=
|usage=
<syntaxhighlight lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
transferMBL(direction)
transferMBL(direction)
</syntaxhighlight>
<syntaxhighlight lang="mtmacro" line>
transferMBL(direction, id)
transferMBL(direction, id)
transferMBL(direction, delete, id)
</syntaxhighlight>
</syntaxhighlight>


<syntaxhighlight lang="mtmacro" line>
See the description of {{func|drawMBL}} for details on the data format.
transferMBL(direction, delete, id)
</syntaxhighlight>


'''Parameters'''
'''Parameters'''
{{param|direction|}}
{{param|direction|The direction of the data transfer:
{{param|delete|}}
** {{code|0}} transfer normal (blue) VBL to token (yellow) VBL}}
{{param|id|}}
** {{code|1}} transfer token (yellow) VBL to normal (blue) VBL
 
{{param|delete|Defines if the transferred VBL is deleted from the source.}}
{{param|id|OPTIONAL: The token {{code|id}} of the token which data will be transferred to or from. Defaults to the [[Current Token]].}}
|also=
[[AI Pathfinding]], {{func|eraseMBL}}, {{func|drawMBL}}, {{func|setTokenMBL}}
}}
}}
[[Category:MBL Function]]
[[Category:MBL Function]]

Revision as of 05:20, 5 June 2023

 This article is a stub, you can help the RPTools Wiki project by contributing content to expand this article.

transferMBL() Function

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

Introduced in version 1.12
Directly transfers MBL to/from a token and the MBL layer.

Usage

transferMBL(direction)
transferMBL(direction, id)
transferMBL(direction, delete, id)

See the description of drawMBL() for details on the data format.

Parameters

  • direction - The direction of the data transfer:
    • 0 transfer normal (blue) VBL to token (yellow) VBL
    • 1 transfer token (yellow) VBL to normal (blue) VBL
  • delete - Defines if the transferred VBL is deleted from the source.
  • id - OPTIONAL: The token id of the token which data will be transferred to or from. Defaults to the Current Token.


See Also