Because some people really wanted to disable this,

mostly due to clientside lag.
This commit is contained in:
TfT_02 2013-04-01 16:38:22 +02:00
parent 0ebc555136
commit 6c3820c747
3 changed files with 9 additions and 1 deletions

View File

@ -115,6 +115,7 @@ public class Config extends AutoUpdateConfigLoader {
public boolean getDodgeEffectEnabled() { return config.getBoolean("Particles.Dodge", true); } public boolean getDodgeEffectEnabled() { return config.getBoolean("Particles.Dodge", true); }
public boolean getBleedEffectEnabled() { return config.getBoolean("Particles.Bleed", true); } public boolean getBleedEffectEnabled() { return config.getBoolean("Particles.Bleed", true); }
public boolean getGreaterImpactEffectEnabled() { return config.getBoolean("Particles.Greater_Impact", true); } public boolean getGreaterImpactEffectEnabled() { return config.getBoolean("Particles.Greater_Impact", true); }
public boolean getLevelUpEffectsEnabled() { return config.getBoolean("Particles.LevelUp", true); }
/* PARTY SETTINGS */ /* PARTY SETTINGS */
public int getAutoPartyKickInterval() { return config.getInt("Party.AutoKick_Interval", 12); } public int getAutoPartyKickInterval() { return config.getInt("Party.AutoKick_Interval", 12); }

View File

@ -6,12 +6,17 @@ import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority; import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener; import org.bukkit.event.Listener;
import com.gmail.nossr50.config.Config;
import com.gmail.nossr50.events.experience.McMMOPlayerLevelUpEvent; import com.gmail.nossr50.events.experience.McMMOPlayerLevelUpEvent;
import com.gmail.nossr50.util.skills.ParticleEffectUtils; import com.gmail.nossr50.util.skills.ParticleEffectUtils;
public class SelfListener implements Listener { public class SelfListener implements Listener {
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true) @EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onPlayerLevelUp(McMMOPlayerLevelUpEvent event) { public void onPlayerLevelUp(McMMOPlayerLevelUpEvent event) {
if (!Config.getInstance().getLevelUpEffectsEnabled()) {
return;
}
Calendar today = Calendar.getInstance(); Calendar today = Calendar.getInstance();
if (today.get(Calendar.MONTH) == Calendar.APRIL && today.get(Calendar.DAY_OF_MONTH) == 1) { if (today.get(Calendar.MONTH) == Calendar.APRIL && today.get(Calendar.DAY_OF_MONTH) == 1) {
ParticleEffectUtils.runescapeModeCelebration(event.getPlayer(), event.getSkill()); ParticleEffectUtils.runescapeModeCelebration(event.getPlayer(), event.getSkill());

View File

@ -373,3 +373,5 @@ Particles:
Dodge: true Dodge: true
Bleed: true Bleed: true
Greater_Impact: true Greater_Impact: true
LevelUp: true