this is my code
Main
package dzcore;
import cn.nukkit.plugin.PluginBase;
import cn.nukkit.registry.EntityRegistry;
import cn.nukkit.registry.RegisterException;
import cn.nukkit.registry.Registries;
import dzcore.items.menu_book;
import dzcore.entities.map_table;
public class Main extends PluginBase {
private static Main instance;
private static Main getInstance() {
return instance;
}
@Override
public void onEnable() {
getLogger().info("DzCore has been enabled!");
Main.instance = this;
}
@Override
public void onDisable() {
getLogger().info("DzCore has been disabled!");
}
@Override
public void onLoad() {
instance = this;
getLogger().info("DzCore has been loaded!");
try {
Registries.ITEM.registerCustomItem(this, menu_book.class);
Registries.ENTITY.registerCustomEntity
(this, new EntityRegistry.CustomEntityDefinition("dz:map_table","",false, true), map_table.class);
} catch (RegisterException e) {
throw new RuntimeException(e);
}
}
}