eirikh1996 / Movecraft

The original movement plugin for Bukkit. Reloaded. Again.
GNU General Public License v3.0
33 stars 7 forks source link

Fix direct control #98

Closed galacticwarrior9 closed 3 years ago

galacticwarrior9 commented 3 years ago

Describe in detail what your pull request accomplishes

Misplaced braces introduced in the last commit were causing the event.getAction() == Action.LEFT_CLICK_AIR || event.getAction() == Action.LEFT_CLICK_BLOCK check to only occur if event.getAction() == Action.RIGHT_CLICK_AIR || event.getAction() == Action.RIGHT_CLICK_BLOCK evaluated to true, so the check always returned false and direct control could never be activated.

I moved them so this no longer occurs.

I also removed a redundant null craft check.

Checklist