isTrusted: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
No edit summary
(Applied Template:MacroFunction)
Line 1: Line 1:
==Function isTrusted==
{{MacroFunction
 
|name=isTrusted
|description=
Returns 1 if this is running as a [[Macros:TrustedMacros|trusted macro]] or 0 if it is not.
Returns 1 if this is running as a [[Macros:TrustedMacros|trusted macro]] or 0 if it is not.


===Usage===
|usage=
<source lang="mtmacro" line>
<source lang="mtmacro" line>
[h: trusted = isTrusted()]
[h: trusted = isTrusted()]
</source>
</source>


 
|example=
===Example===
[[Map:fog of war|fog of war]].
<source lang="mtmacro" line>
<source lang="mtmacro" line>
[r, if(isTrusted()): "I can run the trusted functions! yay!")]
[r, if(isTrusted()): "I can run the trusted functions! yay!")]
</source>
</source>
}}
[[Category:Metamacro Function]]
[[Category:Permission Function]]

Revision as of 21:06, 8 March 2009

isTrusted() Function

Returns 1 if this is running as a trusted macro or 0 if it is not.

Usage

[h: trusted = isTrusted()]

Example

[r, if(isTrusted()): "I can run the trusted functions! yay!")]