Function to create a copy of the specified event. For example, if you want to transpose the events of a MIDI sequence, and you do not want to modify the original data, you can clone the events before transposing them.
Clone does not copy the ID of the event. The ID of the copied event will be -1, because the event has not been played yet. To retrieve an ID, use postEvent or playNote.
Available in: Processor.
Returns a copy of the specified event.
-- create a copy of the event and transpose it
eventCopy = clone(event)
eventCopy.note = event.note + 12
local id = postEvent(eventCopy)