Fixed FakeEvent noClassDefFoundException on mcmmo classic
This commit is contained in:
@@ -2,6 +2,7 @@ package com.willfp.ecoenchants.integrations.mcmmo.plugins;
|
||||
|
||||
import com.gmail.nossr50.events.fake.FakeEvent;
|
||||
import com.willfp.ecoenchants.integrations.mcmmo.McmmoIntegration;
|
||||
import com.willfp.ecoenchants.util.ClassUtils;
|
||||
import org.bukkit.event.Event;
|
||||
|
||||
/**
|
||||
@@ -10,6 +11,8 @@ import org.bukkit.event.Event;
|
||||
public class McmmoIntegrationImpl implements McmmoIntegration {
|
||||
@Override
|
||||
public boolean isFake(Event event) {
|
||||
if(!ClassUtils.exists("com.gmail.nossr50.events.fake.FakeEvent"))
|
||||
return false;
|
||||
return event instanceof FakeEvent;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user