WorldBorder

WorldBorder

1M Downloads

API: GetWorldBorder don't work with new worlds

systemNEO opened this issue ยท 2 comments

commented

Hello!

If I create a new world while the server is running and try to get the BorderData of that new world with the method GetWorldBorder(worldName) then the result is null.

Suggested result: If a world is not registered in the WorldBorder config and I execute the method GetWorldBorder then it will create the needed entries (if the world exists) so I can set borders on new worlds without reload the whole server via bukkit.

Best Regards,
neo

commented

The result is of course null for a reason, to indicate there is no border set.

If you want to create a new border, load the Config class instead and run Config.setBorder() or Config.setBorderCorners(). The methods are overloaded with a few variants available depending on how you want to pass the data in.

commented

Thanks, works fine.

Best Regards,
neo