A
Admincraft•2y ago
EarthCow

Multiverse Core not found

Can someone take a look at this and tell me why it might not be confirming the multiverse plugin as an instance of multiverse. I can't figure it out
private void loadMultiverseCore() {
Plugin multiversePlugin = getServer().getPluginManager().getPlugin("Multiverse-Core");
if (multiversePlugin instanceof MultiverseCore) {
MVWorldManager = ((MultiverseCore) multiversePlugin).getMVWorldManager();
} else {
throw new RuntimeException("Multiverse-Core not found!");
}
}
private void loadMultiverseCore() {
Plugin multiversePlugin = getServer().getPluginManager().getPlugin("Multiverse-Core");
if (multiversePlugin instanceof MultiverseCore) {
MVWorldManager = ((MultiverseCore) multiversePlugin).getMVWorldManager();
} else {
throw new RuntimeException("Multiverse-Core not found!");
}
}
I have the 4.3.1 API and MultiverseCore-4.3.1 installed and running on my server yet it still tells me it's not found. Not sure what it is
80 Replies
Admincraft Meta
Admincraft Meta•2y ago
Thanks for asking your question!
Once you have finished, please close your thread. Make sure to provide as much helpful information as possible such as logs/what you tried and what your exact issue is
command to close
/close !close !solved
Requested by .earth69#0
ProGamingDk
ProGamingDk•2y ago
GitHub
Developer API Starter
The original Bukkit Multi-World Plugin! . Contribute to Multiverse/Multiverse-Core development by creating an account on GitHub.
ProGamingDk
ProGamingDk•2y ago
did u follow this?
EarthCow
EarthCowOP•2y ago
Yup
QarthO
QarthO•2y ago
make sure multiverse is being loaded before your plugin
Lunaiskey
Lunaiskey•2y ago
you are depending on the plugin right?
QarthO
QarthO•2y ago
No description
EarthCow
EarthCowOP•2y ago
yeah it's under my depend list in plugin.yml
Lunaiskey
Lunaiskey•2y ago
have you made sure its actually loaded? multiverse i mean
EarthCow
EarthCowOP•2y ago
yea it loads on the server I use a bunch of the multiverse add-ons too none of them fail
QarthO
QarthO•2y ago
send the logs i wanna see the errosrs
EarthCow
EarthCowOP•2y ago
ignore [15:21:43] [Server thread/WARN]: [MultiverseHardcore] Multiverse-Core I was just trying to see if it was null or not
Admincraft Meta
Admincraft Meta•2y ago
Please use a paste service instead!
Paste services are more mobile friendly and easier to read than just posting a log file
Requested by .earth69#0
EarthCow
EarthCowOP•2y ago
mb
Lunaiskey
Lunaiskey•2y ago
well it doesnt throw the not found exception so it must be instanceof
EarthCow
EarthCowOP•2y ago
yeah but I have the latest API
Lunaiskey
Lunaiskey•2y ago
well i dont see what the issue is? its running as normal
EarthCow
EarthCowOP•2y ago
yeah fr dumb error to get stuck on
QarthO
QarthO•2y ago
no like what error i dont see an error
EarthCow
EarthCowOP•2y ago
[15:21:43] [Server thread/ERROR]: Error occurred while enabling MultiverseHardcore v2.0.0 (Is it up to date?)
java.lang.RuntimeException: Multiverse-Core not found!
at me.lluiscamino.multiversehardcore.MultiverseHardcore.loadMultiverseCore(MultiverseHardcore.java:69) ~[MultiverseHardcore-2.0.0.jar:?]
at me.lluiscamino.multiversehardcore.MultiverseHardcore.onEnable(MultiverseHardcore.java:54) ~[MultiverseHardcore-2.0.0.jar:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:281) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:189) ~[paper-1.20.1.jar:git-Paper-45]
at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:104) ~[paper-1.20.1.jar:git-Paper-45]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:507) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugin(CraftServer.java:636) ~[paper-1.20.1.jar:git-Paper-45]
at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugins(CraftServer.java:547) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:636) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:435) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:308) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1101) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:318) ~[paper-1.20.1.jar:git-Paper-45]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[15:21:43] [Server thread/ERROR]: Error occurred while enabling MultiverseHardcore v2.0.0 (Is it up to date?)
java.lang.RuntimeException: Multiverse-Core not found!
at me.lluiscamino.multiversehardcore.MultiverseHardcore.loadMultiverseCore(MultiverseHardcore.java:69) ~[MultiverseHardcore-2.0.0.jar:?]
at me.lluiscamino.multiversehardcore.MultiverseHardcore.onEnable(MultiverseHardcore.java:54) ~[MultiverseHardcore-2.0.0.jar:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:281) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:189) ~[paper-1.20.1.jar:git-Paper-45]
at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:104) ~[paper-1.20.1.jar:git-Paper-45]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:507) ~[paper-api-1.20.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugin(CraftServer.java:636) ~[paper-1.20.1.jar:git-Paper-45]
at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugins(CraftServer.java:547) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:636) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:435) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:308) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1101) ~[paper-1.20.1.jar:git-Paper-45]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:318) ~[paper-1.20.1.jar:git-Paper-45]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
QarthO
QarthO•2y ago
yes so show the logs with that error pls the full logs
EarthCow
EarthCowOP•2y ago
I did
QarthO
QarthO•2y ago
the log u sent doesnt have it
EarthCow
EarthCowOP•2y ago
yea it does I just copied it from that
QarthO
QarthO•2y ago
upload to mclogs pls the bot only pulled the first 100lines hard to see the txt file on mobile
EarthCow
EarthCowOP•2y ago
mb
EarthCow
EarthCowOP•2y ago
mclo.gs
Paper 1.20.1 Server Log [#DjUM1jX]
332 lines | 2 errors | 1 problem automatically detected
EarthCow
EarthCowOP•2y ago
Just for reference I'm trying to upgrade this plugin: https://github.com/lluiscamino/MultiverseHardcore
GitHub
GitHub - lluiscamino/MultiverseHardcore: Spigot plugin that extends...
Spigot plugin that extends the Multiverse plugin by adding a Hardcore gamemode - GitHub - lluiscamino/MultiverseHardcore: Spigot plugin that extends the Multiverse plugin by adding a Hardcore gamemode
EarthCow
EarthCowOP•2y ago
I forked it The jar on the spigot page loads multiverse fine but there's errors when using the plugin so I thought I would just update it but I can't get multiverse as an instance of the class
Lunaiskey
Lunaiskey•2y ago
well thats just weird
EarthCow
EarthCowOP•2y ago
bro it's so annoying thanks for you guys trying to help though I appreciate it
Lunaiskey
Lunaiskey•2y ago
doesnt multiverse have a discord? ask there if they do
QarthO
QarthO•2y ago
whats ur plugin.yml look like?
Lunaiskey
Lunaiskey•2y ago
id assume exactly like the github
EarthCow
EarthCowOP•2y ago
yes except I added Multiverse-Core as a depend
depend:
- Multiverse-Core
depend:
- Multiverse-Core
QarthO
QarthO•2y ago
so this is how they're doing it now not using instanceof
mvCore = (MultiverseCore) this.getServer().getPluginManager().getPlugin("Multiverse-Core");
// Test if the Core was found, if not we'll disable this plugin.
if (mvCore == null) {
Logging.severe("Multiverse-Core not found, disabling...");
this.getServer().getPluginManager().disablePlugin(this);
return;
mvCore = (MultiverseCore) this.getServer().getPluginManager().getPlugin("Multiverse-Core");
// Test if the Core was found, if not we'll disable this plugin.
if (mvCore == null) {
Logging.severe("Multiverse-Core not found, disabling...");
this.getServer().getPluginManager().disablePlugin(this);
return;
EarthCow
EarthCowOP•2y ago
I can try it but doesn't casting require it to be of that type?
QarthO
QarthO•2y ago
thats why ur checking it with the if im looking at other addons and this is how they're doing it
Lunaiskey
Lunaiskey•2y ago
well if that returns null then itll try and cast null
EarthCow
EarthCowOP•2y ago
who are you referring to btw
QarthO
QarthO•2y ago
multiverse inventories
QarthO
QarthO•2y ago
No description
QarthO
QarthO•2y ago
they also cast in their documetnation
QarthO
QarthO•2y ago
No description
QarthO
QarthO•2y ago
GitHub
Developer API Starter
The original Bukkit Multi-World Plugin! . Contribute to Multiverse/Multiverse-Core development by creating an account on GitHub.
EarthCow
EarthCowOP•2y ago
Failed to cast one sec I'll post the log this error seems more helpful though
EarthCow
EarthCowOP•2y ago
mclo.gs
Paper 1.20.1 Server Log [#rFLG0ku]
444 lines | 2 errors | 1 problem automatically detected
EarthCow
EarthCowOP•2y ago
so it's trying to cast Multiverse-Core as MultiverseHardcore but why
QarthO
QarthO•2y ago
oh no dont do that can i see ur code?
EarthCow
EarthCowOP•2y ago
I'm not trying bro
private void loadMultiverseCore() {
MultiverseCore mvCore = (MultiverseCore) this.getServer().getPluginManager().getPlugin("Multiverse-Core");
// Test if the Core was found, if not we'll disable this plugin.
if (mvCore == null) {
throw new RuntimeException("Multiverse-Core not found!");
} else {
MVWorldManager = mvCore.getMVWorldManager();
}
}
private void loadMultiverseCore() {
MultiverseCore mvCore = (MultiverseCore) this.getServer().getPluginManager().getPlugin("Multiverse-Core");
// Test if the Core was found, if not we'll disable this plugin.
if (mvCore == null) {
throw new RuntimeException("Multiverse-Core not found!");
} else {
MVWorldManager = mvCore.getMVWorldManager();
}
}
QarthO
QarthO•2y ago
whats your import looking like for MultiverseCore
EarthCow
EarthCowOP•2y ago
I'll send the pom
EarthCow
EarthCowOP•2y ago
Pastebin
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
Admincraft Meta
Admincraft Meta•2y ago
Pastebin is blocked in some countries
Requested by .earth69#0
EarthCow
EarthCowOP•2y ago
bruh
QarthO
QarthO•2y ago
its fine hmm idk tbh
EarthCow
EarthCowOP•2y ago
same I'm stump
QarthO
QarthO•2y ago
maybe try importing the multiverse plugin directly instead of using pom adding it as a resource
EarthCow
EarthCowOP•2y ago
I can try that but idk how that'll change anything
QarthO
QarthO•2y ago
yeah i dont think it will either.. LMAO im stumped too
EarthCow
EarthCowOP•2y ago
java.lang.ClassCastException: class com.onarandombox.MultiverseCore.MultiverseCore cannot be cast to class com.onarandombox.MultiverseCore.MultiverseCore (com.onarandombox.MultiverseCore.MultiverseCore is in unnamed module of loader 'Multiverse-Core-4.3.1.jar' @6c663e50; com.onarandombox.MultiverseCore.MultiverseCore is in unnamed module of loader 'MultiverseHardcore-2.0.0.jar' @5a6b6814)
this error confuses me Conflicting classes?
Lunaiskey
Lunaiskey•2y ago
thats like its trying to create a new instance or smth join the mv discord
QarthO
QarthO•2y ago
i found this exact issue in the mv discord
QarthO
QarthO•2y ago
No description
Lunaiskey
Lunaiskey•2y ago
ohhhh they didnt shade mv core
EarthCow
EarthCowOP•2y ago
mines already set as provided 😭
Lunaiskey
Lunaiskey•2y ago
open the jar with recaf or jdgui or smth and check if it hasnt included it
EarthCow
EarthCowOP•2y ago
No description
EarthCow
EarthCowOP•2y ago
nah tf I thought the provided was going to be it I tried reloading maven and shit and fresh building but it still fails also if there was a class conflict wouldn't I be able to see a duplicate in the jar?
Lunaiskey
Lunaiskey•2y ago
uhh that means you have implemented it it shouldnt be there post your pom.xml
EarthCow
EarthCowOP•2y ago
it was originally implemented and then I changed it to provided is there something I have to do additionally? pom.xml I FOUND IT lemme make sure it works first thank you I wouldn't have known
Lunaiskey
Lunaiskey•2y ago
you found what?
EarthCow
EarthCowOP•2y ago
No description
Lunaiskey
Lunaiskey•2y ago
ha
EarthCow
EarthCowOP•2y ago
the multiverse core jar file was listed where I circled after I removed it It wasn't in the jar anymore like you said and it worked
Lunaiskey
Lunaiskey•2y ago
that would do it
EarthCow
EarthCowOP•2y ago
alr but I didn't put it there
Lunaiskey
Lunaiskey•2y ago
its why you never touch the project structure
EarthCow
EarthCowOP•2y ago
it must've happened when maven was set to implement and then when I changed it to provided it never removed the jar I never fuck with that dw thanks for all your help guys !solved

Did you find this page helpful?