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

Extend GeneratorBuyEvent to cancellable #137

Open
2 tasks done
rudde0 opened this issue Sep 24, 2024 · 1 comment
Open
2 tasks done

Extend GeneratorBuyEvent to cancellable #137

rudde0 opened this issue Sep 24, 2024 · 1 comment

Comments

@rudde0
Copy link

rudde0 commented Sep 24, 2024

Is your feature request related to a problem?

I want to add my custom requirements to generator buying feature.

Describe the solution you'd like.

I need to listen GeneratorBuyEvent and I have to cancel it in some situations.

Describe alternatives you've considered.

Agreements

  • I have searched for and ensured there isn't already an open issue regarding this.
  • I have ensured the feature I'm requesting isn't already in the latest supported BentoBox build or Addons.

Other

No response

@tastybento
Copy link
Member

The event is called here.

It fires when the generator has already been purchased so there is no meaning to cancelation. If you need to cancel the purchase operation, then another event should be made,= and fired before the purchase is made, maybe called something like GeneratorPreBuyEvent. You could fire it immediately on entering the purchaseGenerator method. Fancy writing it and making a PR?

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

2 participants