setHasSight: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 2: Line 2:
|name=setHasSight
|name=setHasSight
|version=1.3b48
|version=1.3b48
|trusted=false
|description=
|description=
Sets if the [[Current Token]] has [[Token:Sight|Sight]] or not. If the argument is 0 the [[Current Token]] does not have [[Token:Sight|Sight]] if it is non zero then it does.
Enables/disables sight for the [[Current Token]]. If the argument is 0 (false) sight will be disabled on the [[Current Token]]. If it is non-zero (true) sight is enabled.


You can not set the [[Token:Sight|Sight]] of a [[NPC Token]].
|usage=
<source lang="mtmacro" line>
setHasSight(state)
</source>
 
'''Parameters'''
{{param|state|Boolean - true to enable sight, false to disable }}


|usage=
|example=
Enables sight for [[Current Token]]
<source lang="mtmacro" line>
<source lang="mtmacro" line>
setHasSight(val)
[h: setHasSight(1)]
</source>
</source>
Returns: Empty String.
}}
}}
[[Category:Sight Function]]
[[Category:Sight Function]]

Revision as of 13:39, 6 July 2019

setHasSight() Function

Introduced in version 1.3b48
Enables/disables sight for the Current Token. If the argument is 0 (false) sight will be disabled on the Current Token. If it is non-zero (true) sight is enabled.

Usage

setHasSight(state)

Parameters

  • state - Boolean - true to enable sight, false to disable

Example

Enables sight for Current Token
[h: setHasSight(1)]
Returns: Empty String.