getImpersonated: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(New page: ==Function getImpersonated== {{ProposedChange}} Returns the id of the impersonated token. ===Usage=== <source lang="mtmacro" line> [h: tokenId = getImpersonated()] </source>)
 
m (Text replacement - "<source" to "<syntaxhighlight")
 
(13 intermediate revisions by 6 users not shown)
Line 1: Line 1:
==Function getImpersonated==
{{MacroFunction
{{ProposedChange}}
|name=getImpersonated
|version=1.3b48
|description=Returns the id of the [[impersonated token]].


Returns the id of the [[impersonated token]].
|usage=
===Usage===
<syntaxhighlight lang="mtmacro" line>
<source lang="mtmacro" line>
getImpersonated()
[h: tokenId = getImpersonated()]
getImpersonated(global)
</source>
</syntaxhighlight>
 
'''Parameter'''
{{param|global|If set to {{false}}, returns the id of the token impersonated in the current macro context. If set to {{true}}, returns the token impersonated globally through the UI. Defaults to {{false}} (macro context).}}
 
|changes=
{{change|1.3b51|No longer a trusted function.}}
{{change|1.7.0|Added parameter "global".}}
 
|also=
[[getImpersonatedName|getImpersonatedName()]]
 
}}
[[Category:Token Function]]
[[Category:Impersonation Function]]

Latest revision as of 23:59, 14 March 2023

getImpersonated() Function

Introduced in version 1.3b48
Returns the id of the impersonated token.

Usage

getImpersonated()
getImpersonated(global)

Parameter

  • global - If set to false(0), returns the id of the token impersonated in the current macro context. If set to true(1), returns the token impersonated globally through the UI. Defaults to false(0) (macro context).


See Also

Version Changes

  • 1.3b51 - No longer a trusted function.
  • 1.7.0 - Added parameter "global".