Skip to content

Make object destroy events cancelable #4

Description

@Foxbud

Currently all events except for the destroy event can be "canceled" by not calling event->handle and returning false. This includes create events.

When it comes to destroy events, if a mod listener cancels the event, the instance will still be destroyed, but none of it's destroy listeners (vanilla or mod) will be called. That means that canceling a destroy event effectively makes it such that the instance was deleted. The expected behavior is the instance not being destroyed or deleted.

As it stands, I'm not actually sure if this is possible. Further analysis is required.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions