Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Event Types #1

Open
adriantandara opened this issue Dec 1, 2024 · 0 comments
Open

Event Types #1

adriantandara opened this issue Dec 1, 2024 · 0 comments

Comments

@adriantandara
Copy link

It would be interesting to have a type that includes all the events defined in the IOMP interface and is exported, so that we can benefit from autocomplete for the event names easily when creating our functions, decorators, or others.

Example:

export type ServerEvents = 'resourceStart' | 'playerGiveDamageActor'...
function Decorator(eventName: ServerEvents) {
 omp.on(eventName, target);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant