Plugin category: Administration Suggested name: PluginWorlds A bit about me: I would like to start developing plugins What I want: I think a great plugin to make is one where you can control plugins so they only work in certain worlds! I am sorry if there is already a plugin that does this and I dont know about it just please tell me then. EXAMPLE: I was looking forward to having Multiverse installed then 1 world that is a RPG and other worlds normal, but the rpg plugins only work in the RPG world. Thanks for reading and if you make one or know of an existing plugin that does this please tell me, Thank You! Ideas for commands: Ideas for permissions: When I'd like it by: idk, soon would be cool
This is up to each plugin developer as they would have to add extensive Multi-World support to their own plugin. There is no way to do it from an external plugin unless the original author supports it
this is quite a moloch task to do really... I will explain in detail, but first let me say that it would be MUCH easier to set up 2 servers and connect them with a plugin that allows teleportation from one server to another, so you can have those worlds separated this way it's not much of a problem to check PlayerCommandPreprocessEvent and cancel all commands in worlds where they should not be enabled (like cancelling /jobs command in worlds where no jobs should be allowed) however, for the second part - there are event listeners involved that are registered by a plugin for all worlds, unless the plugin itself is dividing their usage per world what this means is that if the plugin Jobs registers even listener that listens on each block break and updates player experience, it does so for ALL worlds and the only way to cancel this would be to create your own block break listener and do a setCancelled(true) on it the latter will ONLY work if Jobs plugin is aware of cancelled events (by doing isCancelled() check in its own listener) and follow this architecture, this omitting experience raise for the player also, you would need to listen on Lowest priority with your own plugin, so you can cancel the break event as the first one, before any other plugin gets its hands on it... not to mention calling event listening functions of all plugins that SHOULD work in that world manually somehow after you cancel them listening to this event as you can see, it's almost impossible to create such a plugin unless the plugin you're controlling is commands-only plugin
There is another issue: Plugin A and Plugin B use BlockBreakEvent, but Plugin A needs to work on World 1 and Plugin B needs to work on World 2 (and A is disabled on 2, and B is disabled on 1). If you cancel the break event then neither A or B get the event (assuming proper care is taken)... but both need to work in different worlds.
thank you! very interesting and informative! i actually wanted the plugin to only be commands and even though it would be hard to make i am glad its possible! zathrus the 2 server idea is also good, what plugin would you recommend for server-to-server teleporting? EDIT by Moderator: merged posts, please use the edit button instead of double posting.
interesting stuff, never heard about per-world permission... gotta study, thx for the tip! unfortunately I never tried any of them, so I cannot... but you might be able to use per-world permissions as other stated here as well EDIT by Moderator: merged posts, please use the edit button instead of double posting.
yeah really... I use PermissionsEX but there was never a need to implement this for me... now that I read their docs, it clearly described the feature... it's really nice to know
i knew about the per-world permission feature for PermissionsEX i use for my creative world on my server so they can use mods and fly are you talking about per-world permissions or plugins that can be configured to work only in one world?
You can do both with the world: part... just use the negative permissions in the worlds you dont want it in. like Code: default: default: true permissions: - essentials.sethome - essentials.home - essentials.warp - darkbrotherhood.use.shuriken - essentials.list - essentials.help - essentials.spawn - multiverse.portal.access.* - chairs.* - essentials.signs.use.* - iconomy.payment - iconomy.access - allowlockpicking.canpick worlds: Survival: permissions: - -factions.claim - -factions.autoclaim - -factions.sethome Creative: permissions: - -factions.claim - -factions.autoclaim - -factions.sethome
thank you but i was asking for example, i installed the plugin factions but i only want it to work in my pvp world, no other worlds
Code: worlds: PvPWorld: permissions: - factions.claim - factions.autoclaim - factions.sethome Normalworld: permissions: - -factions.* That should work and disable the factions stuff on "Normalworld"
hmm that would work, but what about plugins that keep the sun in one spot the whole day, like plugins that change mechanics or physics how could they work in only 1 world