The OpenD Programming Language

InputEvent

RealTimeConsoleInput.nextEvent returns one of these. Check the type, then use the get method to get the more detailed information about the event.

Constructors

this
this(CustomEvent c, Terminal* p)

custom event is public because otherwise there's no point at all

Members

Enums

Type
enum Type

.

Functions

isDeprecated
bool isDeprecated()

If this event is deprecated, you should filter it out in new programs

Properties

get
auto get [@property getter]

Gets the specific event instance. First, check the type (such as in a switch statement), then extract the correct one from here. Note that the template argument is a value type of the enum above, not a type argument. So to use it, do event.get!(InputEvent.Type.KeyboardEvent), for example.

terminal
Terminal* terminal [@property getter]

Returns a pointer to the terminal associated with this event. (You can usually just ignore this as there's only one terminal typically.)

type
Type type [@property getter]

.

Meta