Skip to content

Commit

Permalink
Fixed ignore cancelled.
Browse files Browse the repository at this point in the history
  • Loading branch information
tastybento committed Jan 21, 2017
1 parent 34e33b1 commit 5f62a4b
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions src/com/wasteofplastic/askyblock/listeners/PlayerEvents.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
import org.bukkit.event.player.PlayerRespawnEvent;
import org.bukkit.event.player.PlayerTeleportEvent;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
import org.bukkit.util.Vector;

import com.wasteofplastic.askyblock.ASkyBlock;
import com.wasteofplastic.askyblock.InventorySave;
Expand Down Expand Up @@ -93,7 +92,7 @@ public void onHungerChange(final FoodLevelChangeEvent e) {
* Places player back on their island if the setting is true
* @param e
*/
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = false)
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onPlayerRespawn(final PlayerRespawnEvent e) {
if (DEBUG) {
plugin.getLogger().info(e.getEventName());
Expand All @@ -116,7 +115,7 @@ public void onPlayerRespawn(final PlayerRespawnEvent e) {
* Places the player on the island respawn list if set
* @param e
*/
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = false)
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
public void onPlayerDeath(final PlayerDeathEvent e) {
if (DEBUG) {
plugin.getLogger().info(e.getEventName());
Expand Down Expand Up @@ -148,7 +147,7 @@ public void onPlayerDeath(final PlayerDeathEvent e) {
* This option helps reduce the down side of dying due to traps, etc.
* Also handles muting of death messages
*/
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = false)
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
public void onVistorDeath(final PlayerDeathEvent e) {
if (DEBUG) {
plugin.getLogger().info(e.getEventName());
Expand Down Expand Up @@ -277,7 +276,7 @@ public void onPlayerFall(final PlayerMoveEvent e) {
*
* @param e
*/
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = false)
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onPlayerTeleport(final PlayerCommandPreprocessEvent e) {
if (DEBUG) {
plugin.getLogger().info(e.getEventName());
Expand All @@ -303,7 +302,7 @@ public void onPlayerTeleport(final PlayerCommandPreprocessEvent e) {
*
* @param e
*/
@EventHandler(priority = EventPriority.HIGH, ignoreCancelled = false)
@EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true)
public void onPlayerTeleport(final PlayerTeleportEvent e) {
if (DEBUG) {
plugin.getLogger().info(e.getEventName());
Expand Down Expand Up @@ -595,7 +594,7 @@ public static void unsetFalling(UUID uniqueId) {
* Prevents visitors from using commands on islands, like /spawner
* @param e
*/
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = false)
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onVisitorCommand(final PlayerCommandPreprocessEvent e) {
if (DEBUG) {
plugin.getLogger().info("Visitor command " + e.getEventName() + ": " + e.getMessage());
Expand All @@ -619,7 +618,7 @@ public void onVisitorCommand(final PlayerCommandPreprocessEvent e) {
* Prevents visitors from getting damage if invinciblevisitors option is set to TRUE
* @param e
*/
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = false)
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onVisitorGetDamage(EntityDamageEvent e){
if(!Settings.invincibleVisitors) return;
if(!(e.getEntity() instanceof Player)) return;
Expand Down

0 comments on commit 5f62a4b

Please sign in to comment.