mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-26 07:06:45 +01:00
Revert "Added basic functionality of Hardcore Mode, needs testing..."
This reverts commit 1fa4fccbcc
.
This commit is contained in:
parent
1fa4fccbcc
commit
ff1326a44f
32
src/main/java/com/gmail/nossr50/listeners/SelfListener.java
Normal file
32
src/main/java/com/gmail/nossr50/listeners/SelfListener.java
Normal file
@ -0,0 +1,32 @@
|
||||
package com.gmail.nossr50.listeners;
|
||||
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.Listener;
|
||||
|
||||
import com.gmail.nossr50.events.experience.McMMOPlayerXpGainEvent;
|
||||
|
||||
/**
|
||||
* Listener for listening to our own events, only really useful for catching errors
|
||||
*/
|
||||
public class SelfListener implements Listener {
|
||||
|
||||
/**
|
||||
* Monitor internal XP gain events.
|
||||
*
|
||||
* @param event The event to watch
|
||||
*/
|
||||
@EventHandler
|
||||
public void onPlayerXpGain(McMMOPlayerXpGainEvent event) {
|
||||
int xp = event.getXpGained();
|
||||
|
||||
if(xp < 0) {
|
||||
try {
|
||||
throw new Exception("Gained negative XP!");
|
||||
}
|
||||
catch (Exception e) {
|
||||
System.out.println(e.getMessage());
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -32,9 +32,6 @@ public class Permissions {
|
||||
/*
|
||||
* MCMMO.BYPASS.*
|
||||
*/
|
||||
public boolean hardcoremodeBypass(Player player) {
|
||||
return player.hasPermission("mcmmo.bypass.hardcoremode");
|
||||
}
|
||||
public boolean arcaneBypass(Player player) {
|
||||
return player.hasPermission("mcmmo.bypass.arcanebypass");
|
||||
}
|
||||
|
@ -142,12 +142,9 @@ permissions:
|
||||
mcmmo.bypass.*:
|
||||
description: Implies all bypass permissions.
|
||||
children:
|
||||
mcmmo.bypass.hardcoremode: true
|
||||
mcmmo.bypass.arcanebypass: true
|
||||
mcmmo.bypass.inspect.distance: true
|
||||
mcmmo.bypass.inspect.offline: true
|
||||
mcmmo.bypass.hardcoremode:
|
||||
description: Allows user to bypass the negative effects of death from Hardcore mode
|
||||
mcmmo.bypass.arcanebypass:
|
||||
description: Allows user to bypass Arcane Repair so he will never lose enchantments
|
||||
mcmmo.bypass.inspect.distance:
|
||||
|
Loading…
Reference in New Issue
Block a user