Ajneb97 / ConditionalEvents

MIT License
22 stars 12 forks source link

Checking Block Location in block_interact Event vs Player's Location #75

Open Reeferx7 opened 1 month ago

Reeferx7 commented 1 month ago

Is it possible to check the location of the block_interact event rather than the player's body? For example, if the player is on their plot (using the Towny plugin) with the condition %townyadvanced_player_plot_is_trusted% == true, and they move to the edge of their plot, they can interact with blocks from another plot.

here my event

Events: paint_wool: type: block_interact enabled: true conditions:

Ajneb97 commented 1 month ago

The location of the block interact is provided by the %block_% variables. If you need to check if the block clicked is on a townyadvanced plot, that plugin must provide a variable to check that from a location.

Reeferx7 commented 1 month ago

Thanks for your answer. I don't think the Towny plugin has those placeholders; I'll try to find another solution.

I was thinking if it could be done using ConditionalEvents .