2.0 - replacetool is iffy on rightclick
Zarius opened this issue ยท 2 comments
This config gets a bit buggy:
COW:
- action: RIGHT_CLICK
tool: BUCKET
replacetool: WATER_BUCKET
message: Water from a cow!
Often the water will spill out to the ground (seems the rightclick event occurs after the bucket has been replaced) and if we add an event cancellation on the second line of onPlayerInteract we still sometimes get buckets of milk?
The PlayerInteractEvent has a method that's something like setUseItem(Result.DENY). Maybe that would fix the issue? We could rig up a fake Cancellable (much like what I did with EntityDeathEvent) which does that instead of setCancelled(true). I'm not certain that that wouldn't break something else, though.