getOwnerOnlyVisible: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(New page: {{stub|Examples of usage.}} {{MacroFunction |name=getOwnerOnlyVisible |version=1.3b74 |description= Returns {{true}} if the visible to owners only flag is ...)
 
No edit summary
 
(10 intermediate revisions by 3 users not shown)
Line 4: Line 4:
|version=1.3b74
|version=1.3b74
|description=
|description=
Returns {{true}} if the [[Token:visible to owners only|visible to owners only]] flag is set on a [[Token]] otherwise returns {{false}}.  
Returns {{true}} if the [[Introduction to Tokens|Visible to Owners Only]] flag is set on a [[Token]] otherwise returns {{false}}.  


|usage=
|usage=
<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
getOwnerOnlyVisible()
getOwnerOnlyVisible()
</source>
</syntaxhighlight>
<source lang="mtmacro" line>
<syntaxhighlight lang="mtmacro" line>
getOwnerOnlyVisible(id)
getOwnerOnlyVisible(tokenRef)
</source>
</syntaxhighlight>
'''Parameter'''
'''Parameter'''
{{param|id|The token {{code|id}} of token that has its player visibility checked, defaults to the [[Current Token]]. {{TrustedParameter}} }}
{{param|tokenRef|Either the token [[getSelected|{{code|id}}]] or [[getTokenName|Token Name]] of the token that has its player visibility checked, defaults to the [[Current Token]]. {{TrustedParameter}} }}
{{Note|Token IDs are unique, but Token Names can be duplicated. Using Token Name when more than one token has the same name can produce unexpected results.}}


|also=
|also=
[[getVisible|getVisible()]]
[[getVisible|getVisible()]], [[setOwnerOnlyVisible|setOwnerOnlyVisible()]]


}}
}}
[[Category:Token Function]]
[[Category:Token Function]]

Latest revision as of 23:59, 13 May 2024

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

getOwnerOnlyVisible() Function

Introduced in version 1.3b74
Returns true(1) if the Visible to Owners Only flag is set on a Token otherwise returns false(0).

Usage

getOwnerOnlyVisible()
getOwnerOnlyVisible(tokenRef)

Parameter

  • tokenRef - Either the token id or Token Name of the token that has its player visibility checked, defaults to the Current Token.

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

Token IDs are unique, but Token Names can be duplicated. Using Token Name when more than one token has the same name can produce unexpected results.


See Also