Table of Contents


Inherits: Object

Supported platforms:

Available since version: Gideros 2011.6


The objects of Event class contains information about an event that has occurred. Event objects
are passed to event listeners when an event occurs.
Usually event objects contains specific additional information about the event that has occured. For example,
when an Event.MOUSE_DOWN event occurs, x and y fields contain the coordinates.
Users can create their own events and dispatch through the event mechanism.

Common uses and examples:

Mouse down event example

function onMouseDown(event)
	print(event.x, event.y)
mysprite:addEventListener(Event.MOUSE_DOWN, onMouseDown)

User created event

local event ="myevent")
event.data1 = "12345"
event.data2 = "abcde"

Methods, events and properties: