Vault API event for gaining money

Discussion in 'Plugin Development' started by ItsJonathan, May 22, 2023.

Thread Status:
Not open for further replies.
  1. Offline

    ItsJonathan

    Hi! I am working with VaultAPI and I am wondering if there is an event for when a player gains money. I have a system where when a user has a setting enabled they should lose 25% of the money they gain. So I'm wondering if there is an event for when a user gains money. And what would be the best way to remove 25%?
     
  2. Online

    timtower Administrator Administrator Moderator

    There is no event.
    Usually those tax things are handled in the plugin supplying the server with an economy system
     
  3. Offline

    OMGitzFROST

    If your adding money using your own methods, you could just trigger a custom event after money is added.

    If other plugins are handling your economy, a possible solution could be to store their current balance and check it once in a while and if different than what was stored, te tigger an event, keep in mind this is super inefficient but could be a solution
     
Thread Status:
Not open for further replies.

Share This Page