CheckKeys
Jump to navigation
Jump to search
Note: This feature is for ZScript only. |
clearscope bool 'CheckKeys(int locknum, bool remote, bool quiet = false)
Usage
Checks to see if the Actor has the appropriate key. This is normally called when trying to interact with a locked door or switch.
Parameters
- int locknum
- The id of the key to check for. For example, it can be obtained from a Line pointer through its
locknumber
field.
- bool remote
- If the check fails and this is true, display the message when hitting a remote switch and not the door message.
- bool quiet
- Default is false. If true, don't play any sound or display any message if the check fails.
Return value
Returns true if the Actor had the key.
Examples
![]() |
Note: This article lists no examples. If you make use of this feature in your own project(s) or know of any basic examples that could be shared, please add them. This will make it easier to understand for future authors seeking assistance. Your contributions are greatly appreciated. |