Multiverse-Core icon indicating copy to clipboard operation
Multiverse-Core copied to clipboard

Unable to delete world with multiverse API

Open wellnesscookie opened this issue 5 years ago • 4 comments

Greetings,

I'm trying to delete a world by using MV API from my plugin with #deleteWorld method from the Multiverse's WorldManager.

The issue is that I want Multiverse to delete a world of mine in onEnable() of my plugin. My plugin.yml has dependecy set on MV and it successfully deleted the world given after the method, yet after my plugin is enabled and server started, the previously named world folder generates again with "region" folder inside him, making me unable to recreate the world with the same name.

The world does not exists, but I have no idea what is generating that "region" folder afterwards. I even tried deleting a world onDisable() too, but after it's really deleted, it generates again with that region folder and a few .mcb files inside.

What am I missing and what is the proper way of deleting a world on server start/stop? Thanks in advance.

EDIT: I've tested it again, it happens with /mv delete too

wellnesscookie avatar Apr 15 '20 15:04 wellnesscookie

(very late reply but) I think its due to the world being the default, defined by level-name in server.properties

benwoo1110 avatar Oct 06 '20 14:10 benwoo1110

It occurs from time to time, but I believe it has something to do with the deletion being done async? Because the threads are not synchronised, the one might still be editing the world, while the older may be deleting it.

wellnesscookie avatar Oct 11 '20 14:10 wellnesscookie

Deleting worlds shouldn't be done async, unless you set your plugin to do so?

benwoo1110 avatar Oct 11 '20 15:10 benwoo1110

I have not, I thought it was done async in MV itself. Nevermind, I'm still clueless about it.

wellnesscookie avatar Oct 14 '20 18:10 wellnesscookie