SpongeAPI icon indicating copy to clipboard operation
SpongeAPI copied to clipboard

World Config

Open boformer opened this issue 11 years ago • 10 comments

Many plugins need a configuration per world (e.g. plot plugin: plot size per world). Sponge should provide a configuration file (or a config section) per dimension and per world for plugins.

Why?

  • all world-related config data stored in one place
  • make it easy to rename a world
  • make it possible to bundle world-related plugin configs with a world (e.g. for adventure maps)
  • resolves the problem that the unique identifier of a world is a UUID (not-human-readable)

This commit (https://github.com/SpongePowered/Sponge/commit/be08be04b06b413686c7f6c574bf89e918e1d6d3) adds these files for Sponge configuration data. It would be easy to add a subsection for plugin config data.

boformer avatar Feb 06 '15 18:02 boformer

@bloodmc

Thoughts on this?

Zidane avatar Feb 13 '15 18:02 Zidane

@boformer @Zidane Yes, I have already thought about allowing plugins to tap into the configs. I have it on my TODO list.

bloodmc avatar Feb 14 '15 05:02 bloodmc

As the developer of PlotMe I would just like to say that this would really help make the process easier to setup worlds.

MattBDev avatar Mar 12 '15 21:03 MattBDev

@bloodmc, @Zidane, I'm not familiar enough with the world configs, but seeing as this hasn't been replied to in many months, is this currently possible?

gabizou avatar Nov 16 '15 00:11 gabizou

It would be nice to have this added soon. For a private server, I need to clone worlds, and plugins' configuration for those worlds would need to be copied as well.

JBYoshi avatar Dec 22 '15 02:12 JBYoshi

@boformer @gabizou @JBYoshi @MattBDev This is now a top priority before our beta release. We are working on it now.

bloodmc avatar Dec 22 '15 03:12 bloodmc

Thanks!

JBYoshi avatar Dec 22 '15 03:12 JBYoshi

@Zidane Thoughts on this getting finished?

gabizou avatar Feb 27 '16 15:02 gabizou

I don't believe we'll be able to get to rewriting our configuration system this soon to make an API 7 release. Perhaps on API 8?

gabizou avatar May 19 '18 02:05 gabizou

Copying what I posted in the Sponge discord earlier today as it's somewhat relevant to this discussion:

Here's an idea for API 8. Give APIs for dedicated data and cache folders. It's really annoying having plugins store active data in their config directory or their config file. If I want to restart the server from scratch ideally I'd like to just delete the world folder and a global data folder and have that be the end of it. Like how you have /etc and /var separate on Linux. If you mount /etc as readonly then you don't have any problems at all until you actually want to go change some configuration somewhere. Of course some plugins let you modify their configs with commands (which is fine), but it's really annoying having to hunt through all the config files for old persistence data if I want to keep everything else the same. It also would be nice if plugins stored world-specific data in the world folders. Like Nations has its own set of directories for each world instead of just adding the world config in the world data dir.

treyzania avatar May 19 '18 15:05 treyzania