Event(type) Constructor to create a new Event object of the specified type. Available in: Processor. Returns a new Event object of the specified type. The fields of the Event object must be set after its creation.
Description
Arguments
type The type of event. See Event Types for details. enum or number Return Values
Example
-- create new note-on event
function onNote(event)
local newEvent = Event(EventType.noteOn)
newEvent.note = event.note + 12
newEvent.velocity = event.velocity
local id = postEvent(newEvent)
waitForRelease()
releaseVoice(id)
end
See Also: Event, Event Types
1 Comment
Sabine Pfeifer
proofread done