Skip to content

Commit

Permalink
docs: Automatic Documentation Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Panakotta00 committed Nov 5, 2024
1 parent e8e6e8e commit 1cf51fb
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions docs/modules/ROOT/pages/lua/api/Event.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@



[cols="1,5a",separator="!"]
!===
!Dependencies
! xref:/lua/api/ReflectionSystemStructModule.adoc[ReflectionSystemStructModule]
!===

== Globals

=== **event**
Expand Down Expand Up @@ -76,3 +82,26 @@ Returns directly if there is already a signal in the queue (the tick doesn¬タ
!===
====

=== __event.__**registerListener** (xref:/reflection/structs/EventFilter.adoc[EventFilter], function(event, sender, ...)) -> integer
Registers the given function as a listener.
When `event.pull()` pulls a signal from the queue, that matches the given Event-Filter,
a Task will be created using the function and the signals parameters will be passed into the function.

=== __event.__**waitFor** (xref:/reflection/structs/EventFilter.adoc[EventFilter]) -> xref:/reflection/structs/Future.adoc[Future]
Returns a Future that resolves when a signal got polled that matches the given Event Filter.

=== __event.__**queue** (xref:/reflection/structs/EventFilter.adoc[EventFilter]) -> xref:/lua/api/Event.adoc#_eventqueue[EventQueue]
Creates a new event queue.
When this variable closes or gets garbage collected, it will stop receiving signals.

== Types

=== **EventQueue**


=== __EventQueue.__**pull** ()


=== __EventQueue.__**waitFor** ()
Returns a Future that resolves when a signal got added to the queue that matches the given Event Filter.

0 comments on commit 1cf51fb

Please sign in to comment.