mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-23 05:36:46 +01:00
We don't need this any more.
This commit is contained in:
parent
b55ce30b2d
commit
78eb7787e9
@ -161,7 +161,6 @@ public class mcMMO extends JavaPlugin {
|
|||||||
@Override
|
@Override
|
||||||
public void onDisable() {
|
public void onDisable() {
|
||||||
try {
|
try {
|
||||||
reloadDisableHelper(); // Prevent Berserk from getting "stuck"
|
|
||||||
UserManager.saveAll(); // Make sure to save player information if the server shuts down
|
UserManager.saveAll(); // Make sure to save player information if the server shuts down
|
||||||
PartyManager.saveParties(); // Save our parties
|
PartyManager.saveParties(); // Save our parties
|
||||||
placeStore.saveAll(); // Save our metadata
|
placeStore.saveAll(); // Save our metadata
|
||||||
@ -381,17 +380,4 @@ public class mcMMO extends JavaPlugin {
|
|||||||
partyAutoKickTask.runTaskTimer(this, kickIntervalTicks, kickIntervalTicks);
|
partyAutoKickTask.runTaskTimer(this, kickIntervalTicks, kickIntervalTicks);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Because /reload is the biggest piece of garbage in existence,
|
|
||||||
* we have to do some special checks to keep it from breaking everything.
|
|
||||||
*/
|
|
||||||
private void reloadDisableHelper() {
|
|
||||||
for (McMMOPlayer mcMMOPlayer : UserManager.getPlayers().values()) {
|
|
||||||
if (mcMMOPlayer.getAbilityMode(AbilityType.BERSERK)) {
|
|
||||||
mcMMOPlayer.setAbilityMode(AbilityType.BERSERK, false);
|
|
||||||
mcMMOPlayer.getPlayer().setCanPickupItems(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user