IsOpen (script event)
Game class
This event operates on an instance of the game class type {{{gameclass}}}
Description
Returns true if the door is open.
Usage
float isOpen( )
Parameters
- tba
Examples
// Opens or closes a door depending on it's current state ...
void doorToggle(ent door)
{
if (door.isOpen())
{
door.close();
} else {
door.open();
}
}
Notes
This script event does not report the correct status for doors with the “start_open” key/value pair set to 1. Instead it reports true when the door is closed and vice versa.