Commit Graph

3193 Commits

Author SHA1 Message Date
BONNe
56c9f5c28e
Fixes a bug with on-join commands not working when players join the team. #1925 (#1926) 2022-01-23 15:25:27 -08:00
tastybento
2f0869fd6e More voiding of event listeners
https://github.com/BentoBoxWorld/BentoBox/issues/1918
2022-01-22 18:04:00 -08:00
tastybento
d14ad977ab Clean up imports. 2022-01-22 13:14:57 -08:00
tastybento
9062aab34b Change behavior of teleporting to default nether
If create-and-link-portals is true, then teleporting to the nether will
not go to a central portal point and instead create a portal in the
nether at the same coordinates as the portal in the overworld.
Teleporting back will not be affected.

https://github.com/BentoBoxWorld/BSkyBlock/issues/464
2022-01-22 13:14:34 -08:00
tastybento
94b982f644 Fix tests
Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1918
2022-01-22 12:16:27 -08:00
tastybento
5573e9f329 Fix TNTListener tests 2022-01-22 11:57:11 -08:00
tastybento
823bc5ceed Fix Fire tests 2022-01-22 11:54:00 -08:00
tastybento
f25e54f3c8 Return void for event listeners
https://github.com/BentoBoxWorld/BentoBox/issues/1918
2022-01-21 18:47:31 -08:00
tastybento
5ab89ac63d Fix tests 2022-01-15 16:20:12 -08:00
tastybento
046c4fff35 Fix for double chest protection.
Double chests could be viewed but not accessed even if chest access or
trapped chest access was allowed.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1912
2022-01-09 20:53:47 -08:00
tastybento
bea9f0e394 List must be mutable. Remove debug. 2022-01-09 20:41:20 -08:00
tastybento
721f0271aa Dynamically grab flags
https://github.com/BentoBoxWorld/BentoBox/issues/1915
2022-01-09 19:44:44 -08:00
tastybento
b63df41082 Remove |+ block chunking marker
https://github.com/BentoBoxWorld/BentoBox/issues/1914
2022-01-09 14:14:04 -08:00
tastybento
d06688ad45 Remove the |+ block code because it adds linefeeds
At least with the latest server it does.

https://github.com/BentoBoxWorld/BentoBox/issues/1914
2022-01-08 15:16:01 -08:00
tastybento
00e174258e Hook into Vault after other plugins have loaded.
https://github.com/BentoBoxWorld/BentoBox/issues/1913
2022-01-07 19:08:15 -08:00
BONNe
eaf2236f7f
Fixes a bug that increased all button count by 1 (#1911)
This will fix an issue when the next button was not displayed when it was necessary.
2022-01-07 18:48:25 -08:00
gitlocalize-app[bot]
ff4a7c9d61
Translate vi.yml via GitLocalize (#1910)
Co-authored-by: HSGamer <huynhqtienvtag@gmail.com>
2022-01-07 18:47:58 -08:00
gitlocalize-app[bot]
318d399a5b
Translate zh-CN.yml via GitLocalize (#1908)
Co-authored-by: DuckSoft <realducksoft@gmail.com>
2022-01-07 18:47:46 -08:00
tastybento
5c94f97e71 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2022-01-02 12:27:09 -08:00
tastybento
bfbeb7964b Fix tests 2022-01-02 12:25:35 -08:00
tastybento
5c8af0c1df Fix tests 2022-01-02 12:21:28 -08:00
tastybento
728c60d472 Fix failing tests. 2022-01-02 12:19:43 -08:00
gitlocalize-app[bot]
2d08e28a01
Translate zh-CN.yml via GitLocalize (#1907)
Co-authored-by: tastybento <tastybento@wasteofplastic.com>
2022-01-01 18:20:24 -08:00
gitlocalize-app[bot]
c1f33ad1d4
Dutch translation (#1906)
* Translate nl.yml via GitLocalize

* Translate nl.yml via GitLocalize

* Translate nl.yml via GitLocalize

Co-authored-by: mt-gitlocalize <mt@gitlocalize.com>
Co-authored-by: tastybento <tastybento@wasteofplastic.com>
Co-authored-by: Dark_Ville <darkville13@gmail.com>
2022-01-01 18:16:50 -08:00
gitlocalize-app[bot]
a5f093758c
Translate tr.yml via GitLocalize (#1905)
Co-authored-by: tastybento <tastybento@wasteofplastic.com>
2022-01-01 18:13:29 -08:00
tastybento
20a6846523 Remove deprecated methods 2022-01-01 18:05:40 -08:00
tastybento
796114eeef Fix tests 2022-01-01 18:01:50 -08:00
BONNe
d1eb175e88
Change AbsolutePath to CanonicalPath (#1901)
I am not 100% sure if this would fix https://github.com/BentoBoxWorld/BSkyBlock/issues/451

However, searching google I found that others had a similar issue with the absolute path and they changed it to canonical. 

As I was not able to reproduce the main reported issue, I do not know if this fixes it.
2022-01-01 17:45:05 -08:00
Huynh Tien
7088a2736f
Flags for Block Explode (#1899)
* add Block Explosion support for TNT_DAMAGE flag

* prevent block explosion from damaging entities

* seperated flags for block explode

* invert and cancel

* pattern instanceof
2022-01-01 17:42:46 -08:00
Huynh Tien
dffe8a811e
fix an exception when cleaning an offline player (#1898) 2022-01-01 17:39:25 -08:00
Huynh Tien
ce1d8e5117
Rework the chunk deletion (#1897)
* delete island one by one

* register before IslandDeletionManager

* optimize imports

* setting

* just some indents

* config

* run synchronously

* a bit reformat before recoding

* proper delete chunks

* comment

* combine the task call

* expose the NMS Handler

* don't have to try-catch this

* we know that this is final

* expose copy chunk data so that it can be overridden

* Don't have to use Vector

* set block from minimum height

* remove NMS and use fallback if not set

* only get the height once

* fix test
2022-01-01 17:38:27 -08:00
Huynh Tien
c9c9ea0389
Fix Biome compatibility on 1.17 (#1895)
* Fix Biome compatibility on 1.17

* check if it's not 1.17.1
2022-01-01 17:34:51 -08:00
gitlocalize-app[bot]
b6a739db00
German Translation (#1904)
* Translate de.yml via GitLocalize

* Translate de.yml via GitLocalize

Co-authored-by: tastybento <tastybento@wasteofplastic.com>
Co-authored-by: Rikamo045 <rik.amos.krajinovic@gmail.com>
2022-01-01 17:33:11 -08:00
tastybento
17ac4f688a Add an admin delete homes command
https://github.com/BentoBoxWorld/BentoBox/issues/1900

This admin command removes all homes from a specified island.
2021-12-31 10:51:16 -08:00
tastybento
acba363523 Added why to VisitorKeepInventory and test class
why reports can now be made by subclasses of FlagListener
2021-12-21 10:12:20 -08:00
tastybento
7fbae58bb2 Make check an NPE check and failure 2021-12-20 15:30:29 -08:00
tastybento
3ece0d049a Added test for SafeSpotTeleport and removed old test 2021-12-20 09:50:45 -08:00
tastybento
f049fc6941 Added SafeSpotTepeortTest 2021-12-20 09:46:04 -08:00
Huynh Tien
e3b99195ca
Optimize safe location searching with configurable range limit (#1892)
* better safe spot finder

* this should be better

* limit how far the y-coordinate will be expanded

* load chunks passively
2021-12-20 09:44:34 -08:00
Huynh Tien
333c9a8272 load chunks passively 2021-12-20 19:37:50 +07:00
BONNe
ed50765b98
Addres Biome's changes in Minecraft 1.18. (#1893)
Since Minecraft 1.18 renamed and removed a lot of biomes, some addons that stored them in the database may require migration.

This Adapter will fix that as now BentoBox itself will do migration for all Biome.class objects.
2021-12-19 08:49:29 -08:00
Huynh Tien
168de622ea limit how far the y-coordinate will be expanded 2021-12-19 20:40:01 +07:00
Huynh Tien
f91ed4705a this should be better 2021-12-16 17:18:09 +07:00
Huynh Tien
6f01310f92 better safe spot finder 2021-12-16 08:58:41 +07:00
tastybento
2e6ef59040 Update dates in BentoBox console banner 2021-12-13 21:59:30 -08:00
tastybento
60cde5334d
Release 1.19.0 (#1890)
* Update to Minecraft 1.18 (#1887)

* Make BlockEndDragon support custom max world height (#1888)

Use max world height instead of magic 255 value.

* Send PVP toggle messages only to on-island players.

https://github.com/BentoBoxWorld/BentoBox/issues/1885

* Add 1.18.1

Co-authored-by: BONNe <bonne@bonne.id.lv>
2021-12-12 20:26:48 -08:00
tastybento
6567104f94 Add 1.18.1 2021-12-11 10:50:09 -08:00
tastybento
524cb46e27 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-12-07 19:35:08 -08:00
tastybento
8a6cc39214 Send PVP toggle messages only to on-island players.
https://github.com/BentoBoxWorld/BentoBox/issues/1885
2021-12-07 19:34:58 -08:00
BONNe
3b64973c2b
Make BlockEndDragon support custom max world height (#1888)
Use max world height instead of magic 255 value.
2021-12-06 11:49:22 +01:00
tastybento
59de6a8efb
Update to Minecraft 1.18 (#1887) 2021-12-05 21:03:21 -08:00
tastybento
11a3bf9227
Release 1.18.1 (#1886)
* Version 1.18.1

* Added snapshot repo to Maven info.

* Fixes console teleporting.

https://github.com/BentoBoxWorld/BentoBox/issues/1877

* Address potential NPE's

* Preveent NPEs and other items.

* Remove dead paper forks (#1884)

Tuinity has since merged with Paper, and is now not a valid fork

Airplane is shutting down / not updating to 1.18.x

* Added toString to resolve issue with arrays

* Fix minor JavaDoc mistake

Co-authored-by: Fredthedoggy <45927799+Fredthedoggy@users.noreply.github.com>
2021-12-05 13:46:54 -08:00
tastybento
79abf965f3 Fix minor JavaDoc mistake 2021-12-05 12:01:27 -08:00
tastybento
de951b6c4b Added toString to resolve issue with arrays 2021-12-05 11:58:20 -08:00
Fredthedoggy
2d032523c7
Remove dead paper forks (#1884)
Tuinity has since merged with Paper, and is now not a valid fork

Airplane is shutting down / not updating to 1.18.x
2021-12-05 11:33:42 -08:00
tastybento
7277432c41 Preveent NPEs and other items. 2021-11-12 15:39:52 -08:00
tastybento
7616f6aa2a Address potential NPE's 2021-11-12 13:19:19 -08:00
tastybento
6b6ab711e5 Fixes console teleporting.
https://github.com/BentoBoxWorld/BentoBox/issues/1877
2021-11-11 15:36:49 -08:00
tastybento
22c62c91b4 Merge branch 'master' into develop
Conflicts:
	src/main/java/world/bentobox/bentobox/api/events/team/TeamEvent.java
	src/main/java/world/bentobox/bentobox/api/panels/reader/TemplateReader.java
	src/main/java/world/bentobox/bentobox/blueprints/worldedit/BlueprintClipboardFormat.java
	src/main/java/world/bentobox/bentobox/blueprints/worldedit/BlueprintClipboardReader.java
	src/main/java/world/bentobox/bentobox/blueprints/worldedit/BlueprintClipboardWriter.java
	src/main/java/world/bentobox/bentobox/blueprints/worldedit/BlueprintSchematicConverter.java
	src/main/java/world/bentobox/bentobox/listeners/flags/settings/PVPListener.java
2021-11-11 10:40:17 -08:00
tastybento
df2b445002
Release 1.18.0 (#1876)
## Change Log 

* Island range perms could be 2x island distance

This could allow protection ranges to be much greater than the island
range and therefore overflow into adjacent islands.

https://github.com/BentoBoxWorld/BentoBox/issues/1851

* Ensure maxEverProtectionRange is less than range.

https://github.com/BentoBoxWorld/BentoBox/issues/1851

* Added test class for Island.

* Added access to private fields for JUnit tests

* Added Sonar Properties to POM

* Changes to analyze using sonar.

* Remove zip reference

* Avoid zipSlip vulnerability.

* Removed the unused WorldEdit hook. (#1853)

If someone wants to add it back later they can, but this code does
nothing right now.

* Requires nonNull parameters for User.instanceOf (#1852)

* Requires nonNull parameters for User.instanceOf

The only reason why User.instanceOf was returning a potential null was
if the parameter was null. Further absolutely no null checking was being
done, so the assumption was that User.instanceOf should never return a
null. This corrects the annotations and requires non-Null parameters.

* Remove null player test

* Fix JavaDoc for GameModeAddon inWorld method

* Fix max-range bug

* Remove illegal tag as it's not needed

* Code smell reduction

* Add missing packages so tests can pass.

* Non null user methods (#1856)

* This makes some User methods non-null.

Instead of returning null, some methods will throw an error if they are
called on non-Players. This means code does not have to do null checks.

* Perform null check in method.

* Null check

* Fix test

* Fix test.

* Npe squashing (#1857)

* Fix hanging [uuid] in info.

* NPE checking

* Make getProtectionCenter nonNull

* More NPE fixes.

* Fix test

* Make getPlayer() and getOfflinePlayer() nonNull returns

This requires addons to not use null checks and instead us the isPlayer
or isOfflinePlayer methods.

* NPE blockers

* Deprecate CompositeCommand isPlayer method.

* Fix test

* Use isPlayer instead of null check.

Refactor code to be easier to understand.

* Fix

* Fix some code smells.

* Prevent NPE possibility.

* Fix "ugly" enchant name. (#1858)

Enchant names did not have a touch of Util#prettifyText code.

* Remove deprecated events.

* Fix IslandSethomeCommand test

* Fix tests - just counts of events.

* Added API to get a translation without color conversion

It may be necessary to read the translation without converting colors to
Bukkit colors.

* Fix tests.

* Fix test.

* Version NPE protections.

* 1.18.0 (#1860)

* Mark all home-related methods in PlayersManager as deprecated.

* Fix bug where maxHomes was shown as null

* Version 1.18.0

API changes may break compatibility with Addons.

* Remove usage of deprecated methods except for migration code.

* Prevent NPE. Check isPlayer instead of getWorld() == null

* Fix nullability issue and added to @Deprecated annotations

* Added deprecation notices to home methods in Players

* Fix missing color conversion for translations.

* Fix mis-statement of island protection coordinates in info command.

* Fix tests

* Fix missing edge deletion of island.

The bounding box was erroneously being made smaller when it was not
required because the inBounds check does that already.

https://github.com/BentoBoxWorld/BentoBox/issues/1863

* Prevent rare NPE

* Ensure oldIsland is never null.

* Refactored setowner command and added test class

* API: Require getWorldSettings to be a game mode world

* Fix tests and refactor code

* Fix test

IWM inWworld needs to return true

* Fix test

IWM inWorld must return true

* Put default getHandlers back in for backwards compatibility

Without them, too many older addons break. They need updating to have
their own handlers. Once that is done, the default ones can be removed
maybe.

* Refactor code for clarity.

* NPE protections

* Prevent NPE

@Poslovich - you were right!

* Throw an error if player is null

* Prevent NPE

* Prevent NPE

* Do a null check

* World should never be null.

* Require non-null world

* Require owner to be non-null. It should never be null

* Prevent NPEs

* Clear the going home flag for edge cases

There were a few potential times when the flag may not have been
cleared. These were mostly teleport failure scenarios. Hopefully, this
is all of them.

https://github.com/BentoBoxWorld/BentoBox/issues/1864

* Shift priority of EntityPortalEnterEvent to HIGH

https://github.com/BentoBoxWorld/BentoBox/issues/1866

This will allow other plugins running at NORMAL to cancel the event
before BentoBox does something.

* Increase priority of EntityPortalEvent listener

https://github.com/BentoBoxWorld/BentoBox/issues/1866

* Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1868

* Code refactoring around User.getInstance(player)

Co-authored-by: BONNe <bonne@bonne.id.lv>
Co-authored-by: Fredthedoggy <45927799+Fredthedoggy@users.noreply.github.com>
Co-authored-by: Justin <jstnf@users.noreply.github.com>
Co-authored-by: gecko10000 <60494179+levtey@users.noreply.github.com>
2021-11-08 21:28:12 -08:00
tastybento
5e3cffbe11 Code refactoring around User.getInstance(player) 2021-10-30 14:02:30 -07:00
tastybento
1953caa7c5 Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1868 2021-10-30 13:44:34 -07:00
tastybento
8752e19e5d Increase priority of EntityPortalEvent listener
https://github.com/BentoBoxWorld/BentoBox/issues/1866
2021-10-26 20:49:38 -07:00
tastybento
6aa7869b17 Shift priority of EntityPortalEnterEvent to HIGH
https://github.com/BentoBoxWorld/BentoBox/issues/1866

This will allow other plugins running at NORMAL to cancel the event
before BentoBox does something.
2021-10-23 16:39:36 -07:00
tastybento
930433b64b Clear the going home flag for edge cases
There were a few potential times when the flag may not have been
cleared. These were mostly teleport failure scenarios. Hopefully, this
is all of them.

https://github.com/BentoBoxWorld/BentoBox/issues/1864
2021-10-16 20:44:18 -07:00
tastybento
731d902d98 Prevent NPEs 2021-10-11 18:02:23 -07:00
tastybento
1a802a7510 Require owner to be non-null. It should never be null 2021-10-11 17:56:06 -07:00
tastybento
37e7846908 Require non-null world 2021-10-11 17:55:04 -07:00
tastybento
28a2ecfcfa World should never be null. 2021-10-11 17:52:38 -07:00
tastybento
081f74544b Do a null check 2021-10-11 17:48:41 -07:00
tastybento
2ffa4c9874 Prevent NPE 2021-10-11 17:43:04 -07:00
tastybento
907c6b3534 Prevent NPE 2021-10-11 17:27:24 -07:00
tastybento
8852b9d660 Throw an error if player is null 2021-10-11 17:21:07 -07:00
tastybento
765f774652 Prevent NPE
@Poslovich - you were right!
2021-10-11 17:15:51 -07:00
tastybento
db464d5c04 NPE protections 2021-10-09 11:40:15 -07:00
tastybento
f37226b115 Refactor code for clarity. 2021-10-09 11:20:48 -07:00
tastybento
536d7ef1c3 Put default getHandlers back in for backwards compatibility
Without them, too many older addons break. They need updating to have
their own handlers. Once that is done, the default ones can be removed
maybe.
2021-10-09 09:29:52 -07:00
tastybento
d3e7b55be5 Fix test
IWM inWorld must return true
2021-10-08 17:27:52 -07:00
tastybento
665724e825 Fix test
IWM inWworld needs to return true
2021-10-08 17:25:20 -07:00
tastybento
fe2e9e1a9e Fix tests and refactor code 2021-10-08 17:15:41 -07:00
tastybento
b5d9d2e52e API: Require getWorldSettings to be a game mode world 2021-10-03 20:33:50 -07:00
tastybento
cfad9879a5 Refactored setowner command and added test class 2021-10-03 19:20:45 -07:00
tastybento
3a43c40634 Ensure oldIsland is never null. 2021-10-03 16:16:58 -07:00
tastybento
60c62a5967 Prevent rare NPE 2021-10-03 16:08:49 -07:00
tastybento
3c65194dfb Fix missing edge deletion of island.
The bounding box was erroneously being made smaller when it was not
required because the inBounds check does that already.

https://github.com/BentoBoxWorld/BentoBox/issues/1863
2021-10-03 15:50:18 -07:00
tastybento
a1c3f78293 Fix tests 2021-10-03 15:46:11 -07:00
tastybento
b5fd992fa7 Fix mis-statement of island protection coordinates in info command. 2021-10-03 15:29:57 -07:00
tastybento
bc6ec36f87 Fix missing color conversion for translations. 2021-10-03 15:04:14 -07:00
tastybento
d780bbd4c0
1.18.0 (#1860)
* Mark all home-related methods in PlayersManager as deprecated.

* Fix bug where maxHomes was shown as null

* Version 1.18.0

API changes may break compatibility with Addons.

* Remove usage of deprecated methods except for migration code.

* Prevent NPE. Check isPlayer instead of getWorld() == null

* Fix nullability issue and added to @Deprecated annotations

* Added deprecation notices to home methods in Players
2021-09-26 13:35:18 -07:00
tastybento
f66eeed4a1 Version NPE protections. 2021-09-25 16:42:54 -07:00
tastybento
3236c68e5c Fix test. 2021-09-25 09:42:51 -07:00
tastybento
500f7292c6 Fix tests. 2021-09-25 09:34:02 -07:00
tastybento
af3c0a874c Added API to get a translation without color conversion
It may be necessary to read the translation without converting colors to
Bukkit colors.
2021-09-25 08:47:14 -07:00
tastybento
0a4fc83218 Fix tests - just counts of events. 2021-09-25 08:33:07 -07:00
tastybento
8b474833e1 Fix IslandSethomeCommand test 2021-09-25 08:07:15 -07:00
tastybento
bc737d4d66 Remove deprecated events. 2021-09-25 08:00:04 -07:00
tastybento
3d2a99c036 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-09-25 07:51:13 -07:00
BONNe
16d5775c84
Fix "ugly" enchant name. (#1858)
Enchant names did not have a touch of Util#prettifyText code.
2021-09-22 19:35:22 -07:00
tastybento
690ea2f99e Prevent NPE possibility. 2021-09-19 18:36:37 -07:00
tastybento
29fa03976c Fix some code smells. 2021-09-19 18:29:19 -07:00
tastybento
f6f5b63110 Fix 2021-09-19 08:45:19 -07:00
tastybento
110a282deb Use isPlayer instead of null check.
Refactor code to be easier to understand.
2021-09-19 08:42:37 -07:00
tastybento
53f02ae686
Npe squashing (#1857)
* Fix hanging [uuid] in info.

* NPE checking

* Make getProtectionCenter nonNull

* More NPE fixes.

* Fix test

* Make getPlayer() and getOfflinePlayer() nonNull returns

This requires addons to not use null checks and instead us the isPlayer
or isOfflinePlayer methods.

* NPE blockers

* Deprecate CompositeCommand isPlayer method.

* Fix test
2021-09-18 17:59:32 -07:00
tastybento
b247b360bf Fix test. 2021-09-18 12:25:25 -07:00
tastybento
68890eba00 Fix test 2021-09-18 12:25:14 -07:00
tastybento
8eac5070f0 Null check 2021-09-18 11:37:33 -07:00
tastybento
25fe86d812
Non null user methods (#1856)
* This makes some User methods non-null.

Instead of returning null, some methods will throw an error if they are
called on non-Players. This means code does not have to do null checks.

* Perform null check in method.
2021-09-18 11:22:28 -07:00
tastybento
8eb45e817c Code smell reduction 2021-09-18 08:15:15 -07:00
tastybento
3282b1bd12 Fix max-range bug 2021-09-18 08:14:43 -07:00
tastybento
d92632341d Fix JavaDoc for GameModeAddon inWorld method 2021-09-16 16:47:42 -07:00
tastybento
02a14cab6e
Requires nonNull parameters for User.instanceOf (#1852)
* Requires nonNull parameters for User.instanceOf

The only reason why User.instanceOf was returning a potential null was
if the parameter was null. Further absolutely no null checking was being
done, so the assumption was that User.instanceOf should never return a
null. This corrects the annotations and requires non-Null parameters.

* Remove null player test
2021-09-16 16:41:27 -07:00
tastybento
063fa97cf3
Removed the unused WorldEdit hook. (#1853)
If someone wants to add it back later they can, but this code does
nothing right now.
2021-09-13 19:46:10 -07:00
tastybento
bb7f124066 Avoid zipSlip vulnerability. 2021-09-12 21:53:26 -07:00
tastybento
0e744cae81 Added test class for Island. 2021-09-12 17:35:52 -07:00
tastybento
7271096ace Ensure maxEverProtectionRange is less than range.
https://github.com/BentoBoxWorld/BentoBox/issues/1851
2021-09-11 16:53:27 -07:00
tastybento
3dd9e973fb Island range perms could be 2x island distance
This could allow protection ranges to be much greater than the island
range and therefore overflow into adjacent islands.

https://github.com/BentoBoxWorld/BentoBox/issues/1851
2021-09-11 16:50:43 -07:00
tastybento
a6d70d6e90
Release 1.17.3 (#1827)
* Version 1.17.1

* Add homes command to default player options.

* Implements better online player counter. (#1791)

Current one is based on online player count when bStats sends data to the server.
This one will send data about amount of players who logged in the server.

* Add Boxed Gamemode to the list. (#1793)

* Add Bank addon (#1792)

* Add Holographic Displays as SoftDepend for AOneBlock (#1794)

* Custom date time format support for /<admin> info <player> (#1783)

Fixes #1720

* Parent/sub-flag support, split up and designate CONTAINER flag as parent flag (#1784)

* Split CONTAINER flag into multiple flags

CONTAINER split into
- CONTAINER (Chest/Minecart Chest)
- BARREL (Barrel)
- COMPOSTER (Composter)
- FLOWER_POT (Flower Pot)
- SHULKER_BOX (Shulker Box)
- TRAPPED_CHEST (Trapped Chest)

Fixes #1777

* Add subflag support

* Create container parent flag, chest subflag

* Remove extra string from when CHEST was CONTAINER

* Fix incorrect flag specified on fired event in IslandToggleClick

* Add missing world subflag event firing

* Remove extra import

* Add world setting flag for island visitors keep inventory (#1785)

* Implement 3 bar charts: addons, gamemodes, hooks (#1790)

BStats supports sending Bar chart data, however, it does not display it via their site directly.
It can be called manually, to view.

PieChart does not work very well for addons and hooks. BarChart however allows viewing each addon separately. 

This change allows sending data to the server about bar charts.

* Update action versions

* Declare distribution - adopt

* Cache Java Maven files differently.

* Try dependency for shade snapshot

* Add support for Minecraft 1.17.1

* Fix test by incrementing listener value check

There is a new listener now.

* Spigot 1.17.1

* Fix test for InventoryListener

* Re-order repos.

* Downgrading to 1.17 Spigot for now to enable building.

* Try pluginRespositories tag in POM to enable Github actions

* Version 1.17.2

* Add alternative Addon#getIslandManager method (#1797)

We have already done this to the main BentoBox class. But add-ons missed it, and it still has this weird structure: Addon#getIslands().getIslands().

This will just add the same method as it is already in BentoBox class.

* Fix bucket dupe (#1806)

Fix https://discord.com/channels/272499714048524288/310623455462686720/867790395442462760

* Removes unneeded exploit protection code for skulls (#1810)

This no longer seems to be required with 1.17.1

https://github.com/BentoBoxWorld/BSkyBlock/issues/430

* Quote filename of addon that cannot be loaded.

Provides a better understanding of which addon failed.

* Remove update when pasting chest.

* Version 1.17.3

* Java upgrade (#1814)

* Version 1.17.3

* Use Map.of and List.of instead of Immutable collections

* Replace explicit type argument.

* Replace lamba with method reference

* Replace condition with Objects.requireNonNullElseGet

* Use String.repeat

* Use new switch expressions

* Use instanceof patten variables which are more compact

* Fuse toUnmodifiableList into stream and return it.

* Remove unnecessary toString() calls.

* Remove unnecessary public

* Extracted common part from if

* Simplify conditional expressions

* Remove unused IOExceptions

* Cast to long

* Use Map.putAll

* Use primitives

* Clarify what is null or not

* Addedd @Serial annotation introduced with Java 14.

* Use Optional.isEmpty instead of !isPresent

* Use flatMap then ifPresent

* Just use Arrays.stream

* Swap map and filter for null with Objects::nonNull

* Use expression lambda

* Update JavaDoc version to 16

* Make spawn protection area square instead of circle.

https://github.com/BentoBoxWorld/BentoBox/issues/1819

* Improve ItemParser code. (#1821)

* Improve ItemParser code.

Add ability to parse text if Material is just a single string.
Add ability to parse player heads.

Add comments to the code.

* Fixes failing test.

* Added deprecation suppression.

* Added Pladdon to loadbefore.

* Prevent bucket duping when scooping obsidian Part 35

https://github.com/BentoBoxWorld/BentoBox/issues/1825

* Warns visitors that PVP is active if they teleport to an island

https://github.com/BentoBoxWorld/BentoBox/issues/1780

* Prevents repeated portaling when nether is disabled. (#1826)

* Prevents repeated portaling when nether is disabled.

https://github.com/BentoBoxWorld/BentoBox/issues/1782

* Fix test

* Hex pr 1820 (#1822)

* Fix @since for subflags. (#1831)

* Add Citizens to Softdepend list for NPC support (#1834)

* Fix color test.

* Set the default game mode when player makes island.

* Corrects JavaDocs link

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1838

* Update to 3.3.1-SNAPSHOT for shade plugin.

* Package info files for better JavaDocs (#1839)

* Added package info files for better JavaDocs

* Implement Flag icon changing via Locales file. (#1829)

This commit contains 2 changes:
- An option for Flag to use icon that is defined in locales after "icon" string.
- An option for ItemParser to parse icon or return given value, if parsing was not successful.

The flag option is not ideal, but it is simpler and easier to maintain then adding new config section where icons can be changed, as the locales file already contains a lot of info about each flag.

* Support glowing ink in blueprints (#1842)

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1837

* Panel template (#1841)

* Implement basic functionality to read data from template panels.

Create TemplateReader class that has static method which generates a PanelTemplateRecord. This record contains every necessary information from user created template file so everyone could use it to generate a functional panel.
These classes are just for reading templates and do not create actual panel.

* Add template clearing via bentobox reload command.

* Fix version command to show addon state.

* Fix German flag banner description.

Added more debug around error reporting.

* Make variables final if they can be. (#1843)

* Make variables final if they can be.

* Do not use final so that test can pass.

For testing, we use a trick to set this variable, but it won't work if
it is final. Right now, I'd like to keep the test.

* Static code analysis (#1844)

* StringBuffer (Java 5) may be declared as StringBuilder

* Replace map with flatMap

* Use instanceof naming

* No need to specify paramter types.

* Remove verbose code

* Fix JavaDoc issues

* Make internal class a record.

* Remove unused import.

* Make internal class a record.

* Made internal class a record.

* Removed unused import

* Fix typos

* Fix typo in test.

* Prevent home teleport when already home teleporting

Home teleporting is async so it's possible to issue the command multiple
times. This puts a flag in so that if a playeer is mid-teleport, then
issuing the go command will just repeat the text that the player is
teleporting home.

https://github.com/BentoBoxWorld/BentoBox/issues/1637

* Extracted island info from the Island object.

This is in preparation to have a different info for players than admins.

https://github.com/BentoBoxWorld/BentoBox/issues/1501

* Slimmer trimmer island info for players.

https://github.com/BentoBoxWorld/BentoBox/issues/1501

* Fixes coop and trust invites when team invites are not allowed

If a member or sub-owner has coop or trust invite capability and not
team invite rank, and confirm invites is on, then the invites were not
working.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1452

* Remove invulnerable visitor protection if island is in PVP mode

We now have alerts if a player teleports to a PVP island.

https://github.com/BentoBoxWorld/BentoBox/issues/668

* Fixes NPE in admin tp if nether or end worlds don't exist.

* Adds arrow sound when teleporting into a PVP island.

* Fix PVPListenerTest

Visitors are no longer invincible when on a PVP island.

* Fix test failure in InvincibleVisitorsListenerTest

* Minor JavaDoc correction.

* Go command was not working second time.

* Prevents console errors for missing icons in locale files.

* Fixes PlAddon disabling issue. (#1847)

There was a bug that did not unload PlAddon classes from JVM.
This change should fix it, as it will unload PlAddons via pluginLoader.

* Clear code - set worlds once on construction.

* Fixes a bug when Potion metadata was not applied (#1849)

There was missing potion meta data applying after creating an item. 
This affects both: Potions and Tipped arrows.

* Adds force-shown lines to the template. (#1850)

* Adds force-shown lines to the template.
Fixes a bug when template type was not selected correctly.
Changes "name" to "title" for border and background icons.

* Create TemplatedPanel and TemplatedPanelBuilder.

TemplatedPanel uses PanelTemplateRecord to create a functional panel.
Builder contains button builder callbacks that are used to create buttons with custom data.

* Use final vars for lambdas to avoid them changing async

The processes could run async, especially when chunk loading took a
while, so using fields that could change would result in blocks being
missed, especially in the nether or end. Switching to final vars avoids
this.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1840

* Remove travis.

Co-authored-by: BONNe <bonne@bonne.id.lv>
Co-authored-by: Fredthedoggy <45927799+Fredthedoggy@users.noreply.github.com>
Co-authored-by: Justin <jstnf@users.noreply.github.com>
Co-authored-by: gecko10000 <60494179+levtey@users.noreply.github.com>
2021-09-10 18:39:16 -07:00
tastybento
b24c1fdc86 Use final vars for lambdas to avoid them changing async
The processes could run async, especially when chunk loading took a
while, so using fields that could change would result in blocks being
missed, especially in the nether or end. Switching to final vars avoids
this.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1840
2021-09-08 21:08:15 -07:00
tastybento
6bff4c8132 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-09-08 20:26:56 -07:00
BONNe
9da329356a
Adds force-shown lines to the template. (#1850)
* Adds force-shown lines to the template.
Fixes a bug when template type was not selected correctly.
Changes "name" to "title" for border and background icons.

* Create TemplatedPanel and TemplatedPanelBuilder.

TemplatedPanel uses PanelTemplateRecord to create a functional panel.
Builder contains button builder callbacks that are used to create buttons with custom data.
2021-09-08 19:58:26 -07:00
BONNe
6bf3264ab5
Fixes a bug when Potion metadata was not applied (#1849)
There was missing potion meta data applying after creating an item. 
This affects both: Potions and Tipped arrows.
2021-09-08 19:57:27 -07:00
tastybento
3650863fa1 Clear code - set worlds once on construction. 2021-09-08 19:50:23 -07:00
BONNe
23e3554c4d
Fixes PlAddon disabling issue. (#1847)
There was a bug that did not unload PlAddon classes from JVM.
This change should fix it, as it will unload PlAddons via pluginLoader.
2021-09-05 17:28:49 -07:00
tastybento
938940199d Prevents console errors for missing icons in locale files. 2021-09-04 17:21:45 -07:00
tastybento
184c86bafe Go command was not working second time. 2021-09-04 17:21:25 -07:00
tastybento
0844e97530 Minor JavaDoc correction. 2021-09-04 15:43:51 -07:00
tastybento
28cecc2658 Fix test failure in InvincibleVisitorsListenerTest 2021-09-04 15:43:41 -07:00
tastybento
e77a40f0cb Fix PVPListenerTest
Visitors are no longer invincible when on a PVP island.
2021-09-04 15:12:26 -07:00
tastybento
7d7882c309 Adds arrow sound when teleporting into a PVP island. 2021-09-04 14:46:41 -07:00
tastybento
74ded5a187 Fixes NPE in admin tp if nether or end worlds don't exist. 2021-09-04 14:46:26 -07:00
tastybento
7621677c93 Remove invulnerable visitor protection if island is in PVP mode
We now have alerts if a player teleports to a PVP island.

https://github.com/BentoBoxWorld/BentoBox/issues/668
2021-09-04 14:36:47 -07:00
tastybento
23522a297f Fixes coop and trust invites when team invites are not allowed
If a member or sub-owner has coop or trust invite capability and not
team invite rank, and confirm invites is on, then the invites were not
working.

Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1452
2021-09-04 13:47:44 -07:00
tastybento
0f7ca6ac60 Slimmer trimmer island info for players.
https://github.com/BentoBoxWorld/BentoBox/issues/1501
2021-09-04 10:02:37 -07:00
tastybento
547c266975 Extracted island info from the Island object.
This is in preparation to have a different info for players than admins.

https://github.com/BentoBoxWorld/BentoBox/issues/1501
2021-09-04 09:46:28 -07:00
tastybento
5bb12d53bd Prevent home teleport when already home teleporting
Home teleporting is async so it's possible to issue the command multiple
times. This puts a flag in so that if a playeer is mid-teleport, then
issuing the go command will just repeat the text that the player is
teleporting home.

https://github.com/BentoBoxWorld/BentoBox/issues/1637
2021-09-03 15:39:08 -07:00
tastybento
23857501f5
Static code analysis (#1844)
* StringBuffer (Java 5) may be declared as StringBuilder

* Replace map with flatMap

* Use instanceof naming

* No need to specify paramter types.

* Remove verbose code

* Fix JavaDoc issues

* Make internal class a record.

* Remove unused import.

* Make internal class a record.

* Made internal class a record.

* Removed unused import

* Fix typos

* Fix typo in test.
2021-08-29 18:17:38 -07:00
tastybento
9dc4ebc2d1
Make variables final if they can be. (#1843)
* Make variables final if they can be.

* Do not use final so that test can pass.

For testing, we use a trick to set this variable, but it won't work if
it is final. Right now, I'd like to keep the test.
2021-08-29 18:17:21 -07:00
tastybento
a9a7673ce8 Fix German flag banner description.
Added more debug around error reporting.
2021-08-29 15:04:20 -07:00
tastybento
44f06f2911 Fix version command to show addon state. 2021-08-29 14:56:54 -07:00
BONNe
2607256c06
Panel template (#1841)
* Implement basic functionality to read data from template panels.

Create TemplateReader class that has static method which generates a PanelTemplateRecord. This record contains every necessary information from user created template file so everyone could use it to generate a functional panel.
These classes are just for reading templates and do not create actual panel.

* Add template clearing via bentobox reload command.
2021-08-29 14:34:05 -07:00
tastybento
faf351fd59
Support glowing ink in blueprints (#1842)
Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1837
2021-08-29 14:17:42 -07:00
BONNe
fa41abc062
Implement Flag icon changing via Locales file. (#1829)
This commit contains 2 changes:
- An option for Flag to use icon that is defined in locales after "icon" string.
- An option for ItemParser to parse icon or return given value, if parsing was not successful.

The flag option is not ideal, but it is simpler and easier to maintain then adding new config section where icons can be changed, as the locales file already contains a lot of info about each flag.
2021-08-29 13:30:45 -07:00
tastybento
0341515fc8
Package info files for better JavaDocs (#1839)
* Added package info files for better JavaDocs
2021-08-29 13:28:16 -07:00
tastybento
876ba91837 Set the default game mode when player makes island. 2021-08-23 19:40:46 -07:00
tastybento
6c75733417 Fix color test. 2021-08-21 09:23:18 -07:00
Fredthedoggy
705693f904
Add Citizens to Softdepend list for NPC support (#1834) 2021-08-21 11:43:42 +02:00
BONNe
c635647f85
Fix @since for subflags. (#1831) 2021-08-19 12:10:44 -07:00
tastybento
b906f5561a
Hex pr 1820 (#1822) 2021-08-19 12:09:23 -07:00
tastybento
e0d6e4df30
Merge branch 'master' into develop 2021-08-15 17:08:52 -07:00
tastybento
32638e7a87
Prevents repeated portaling when nether is disabled. (#1826)
* Prevents repeated portaling when nether is disabled.

https://github.com/BentoBoxWorld/BentoBox/issues/1782

* Fix test
2021-08-15 17:05:20 -07:00
tastybento
233c058bfe Warns visitors that PVP is active if they teleport to an island
https://github.com/BentoBoxWorld/BentoBox/issues/1780
2021-08-14 21:02:53 -07:00
tastybento
6b839d9c69 Prevent bucket duping when scooping obsidian Part 35
https://github.com/BentoBoxWorld/BentoBox/issues/1825
2021-08-14 16:23:13 -07:00
tastybento
7cadebc792 Added Pladdon to loadbefore. 2021-08-12 18:23:00 -07:00
tastybento
cc974c795f Added deprecation suppression. 2021-08-08 18:41:43 -07:00
BONNe
56a1fdb55a
Improve ItemParser code. (#1821)
* Improve ItemParser code.

Add ability to parse text if Material is just a single string.
Add ability to parse player heads.

Add comments to the code.

* Fixes failing test.
2021-08-08 10:05:14 -07:00
tastybento
cf8df9c2a8 Make spawn protection area square instead of circle.
https://github.com/BentoBoxWorld/BentoBox/issues/1819
2021-08-07 20:14:40 -07:00
tastybento
acfc001cd6
Java upgrade (#1814)
* Version 1.17.3

* Use Map.of and List.of instead of Immutable collections

* Replace explicit type argument.

* Replace lamba with method reference

* Replace condition with Objects.requireNonNullElseGet

* Use String.repeat

* Use new switch expressions

* Use instanceof patten variables which are more compact

* Fuse toUnmodifiableList into stream and return it.

* Remove unnecessary toString() calls.

* Remove unnecessary public

* Extracted common part from if

* Simplify conditional expressions

* Remove unused IOExceptions

* Cast to long

* Use Map.putAll

* Use primitives

* Clarify what is null or not

* Addedd @Serial annotation introduced with Java 14.

* Use Optional.isEmpty instead of !isPresent

* Use flatMap then ifPresent

* Just use Arrays.stream

* Swap map and filter for null with Objects::nonNull

* Use expression lambda
2021-07-31 08:48:26 -07:00
tastybento
1a7b7cdeb7
1.17.2 Release (#1812)
* Version 1.17.2

* Add alternative Addon#getIslandManager method (#1797)

We have already done this to the main BentoBox class. But add-ons missed it, and it still has this weird structure: Addon#getIslands().getIslands().

This will just add the same method as it is already in BentoBox class.

* Fix bucket dupe (#1806)

Fix https://discord.com/channels/272499714048524288/310623455462686720/867790395442462760

* Removes unneeded exploit protection code for skulls (#1810)

This no longer seems to be required with 1.17.1

https://github.com/BentoBoxWorld/BSkyBlock/issues/430

* Quote filename of addon that cannot be loaded.

Provides a better understanding of which addon failed.

* Remove update when pasting chest.

Co-authored-by: BONNe <bonne@bonne.id.lv>
Co-authored-by: Fredthedoggy <45927799+Fredthedoggy@users.noreply.github.com>
Co-authored-by: Justin <jstnf@users.noreply.github.com>
Co-authored-by: gecko10000 <60494179+levtey@users.noreply.github.com>
2021-07-25 10:52:03 -07:00
tastybento
b5725e7107 Remove update when pasting chest. 2021-07-25 10:23:03 -07:00
tastybento
6bac200ac0 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-07-25 09:32:05 -07:00
tastybento
3b136f0d68 Quote filename of addon that cannot be loaded.
Provides a better understanding of which addon failed.
2021-07-25 09:31:53 -07:00
tastybento
9b1d61659b
Removes unneeded exploit protection code for skulls (#1810)
This no longer seems to be required with 1.17.1

https://github.com/BentoBoxWorld/BSkyBlock/issues/430
2021-07-24 12:27:35 -07:00
gecko10000
21fed6ebfe
Fix bucket dupe (#1806)
Fix https://discord.com/channels/272499714048524288/310623455462686720/867790395442462760
2021-07-23 21:01:40 -07:00
BONNe
2044c73f05
Add alternative Addon#getIslandManager method (#1797)
We have already done this to the main BentoBox class. But add-ons missed it, and it still has this weird structure: Addon#getIslands().getIslands().

This will just add the same method as it is already in BentoBox class.
2021-07-23 19:32:00 -07:00
tastybento
376ac167e8
Version 1.17.1 (#1796)
* Version 1.17.1

* Add homes command to default player options.

* Implements better online player counter. (#1791)

Current one is based on online player count when bStats sends data to the server.
This one will send data about amount of players who logged in the server.

* Add Boxed Gamemode to the list. (#1793)

* Add Bank addon (#1792)

* Add Holographic Displays as SoftDepend for AOneBlock (#1794)

* Custom date time format support for /<admin> info <player> (#1783)

Fixes #1720

* Parent/sub-flag support, split up and designate CONTAINER flag as parent flag (#1784)

* Split CONTAINER flag into multiple flags

CONTAINER split into
- CONTAINER (Chest/Minecart Chest)
- BARREL (Barrel)
- COMPOSTER (Composter)
- FLOWER_POT (Flower Pot)
- SHULKER_BOX (Shulker Box)
- TRAPPED_CHEST (Trapped Chest)

Fixes #1777

* Add subflag support

* Create container parent flag, chest subflag

* Remove extra string from when CHEST was CONTAINER

* Fix incorrect flag specified on fired event in IslandToggleClick

* Add missing world subflag event firing

* Remove extra import

* Add world setting flag for island visitors keep inventory (#1785)

* Implement 3 bar charts: addons, gamemodes, hooks (#1790)

BStats supports sending Bar chart data, however, it does not display it via their site directly.
It can be called manually, to view.

PieChart does not work very well for addons and hooks. BarChart however allows viewing each addon separately. 

This change allows sending data to the server about bar charts.

* Update action versions

* Declare distribution - adopt

* Cache Java Maven files differently.

* Try dependency for shade snapshot

* Add support for Minecraft 1.17.1

* Fix test by incrementing listener value check

There is a new listener now.

* Spigot 1.17.1

* Fix test for InventoryListener

* Re-order repos.

* Downgrading to 1.17 Spigot for now to enable building.

* Try pluginRespositories tag in POM to enable Github actions

Co-authored-by: BONNe <bonne@bonne.id.lv>
Co-authored-by: Fredthedoggy <45927799+Fredthedoggy@users.noreply.github.com>
Co-authored-by: Justin <jstnf@users.noreply.github.com>
2021-07-10 18:27:57 -07:00
tastybento
3d1481fec5 Fix test for InventoryListener 2021-07-06 15:15:35 -07:00
tastybento
9e3a57248a Fix test by incrementing listener value check
There is a new listener now.
2021-07-06 14:55:19 -07:00
tastybento
0845722150 Add support for Minecraft 1.17.1 2021-07-06 14:54:43 -07:00
BONNe
69f7b49469
Implement 3 bar charts: addons, gamemodes, hooks (#1790)
BStats supports sending Bar chart data, however, it does not display it via their site directly.
It can be called manually, to view.

PieChart does not work very well for addons and hooks. BarChart however allows viewing each addon separately. 

This change allows sending data to the server about bar charts.
2021-07-06 13:50:58 -07:00
Justin
759ba522f4
Add world setting flag for island visitors keep inventory (#1785) 2021-07-06 13:47:35 -07:00
Justin
0f7866a00b
Parent/sub-flag support, split up and designate CONTAINER flag as parent flag (#1784)
* Split CONTAINER flag into multiple flags

CONTAINER split into
- CONTAINER (Chest/Minecart Chest)
- BARREL (Barrel)
- COMPOSTER (Composter)
- FLOWER_POT (Flower Pot)
- SHULKER_BOX (Shulker Box)
- TRAPPED_CHEST (Trapped Chest)

Fixes #1777

* Add subflag support

* Create container parent flag, chest subflag

* Remove extra string from when CHEST was CONTAINER

* Fix incorrect flag specified on fired event in IslandToggleClick

* Add missing world subflag event firing

* Remove extra import
2021-07-06 13:41:23 -07:00
Justin
f88b8d4d6d
Custom date time format support for /<admin> info <player> (#1783)
Fixes #1720
2021-07-06 13:33:10 -07:00
Fredthedoggy
7de6563ece
Add Holographic Displays as SoftDepend for AOneBlock (#1794) 2021-07-06 13:30:54 -07:00
BONNe
3a1ec0a570
Implements better online player counter. (#1791)
Current one is based on online player count when bStats sends data to the server.
This one will send data about amount of players who logged in the server.
2021-07-06 15:22:44 +02:00
tastybento
19ddd73204 Add homes command to default player options. 2021-07-05 18:31:06 -07:00
tastybento
85a9e44c4d Revert "Revert "Revert "WIP prevent repeated teleports in portals"""
This reverts commit 17d9271369.
2021-06-27 16:55:14 -07:00
tastybento
17d9271369 Revert "Revert "WIP prevent repeated teleports in portals""
This reverts commit e0e1f2878c.
2021-06-27 16:53:08 -07:00
tastybento
e0e1f2878c Revert "WIP prevent repeated teleports in portals"
This reverts commit 2a5d8c14e3.
2021-06-20 16:29:24 -07:00
tastybento
c89fd03833 Fixed tests 2021-06-20 16:24:36 -07:00
tastybento
a0f2f11499 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-06-20 12:19:09 -07:00
tastybento
c2e832095a
Minecraft 1.17 support (#1781)
* Java 16 preliminary branch.

This compiles, but junit tests fail all over because there is a lack of
Java 16 support right now.

* Use Java 16

* 1.17 WIP

* Require 1.17

* Fixes tests.

* WIP fixing tests

* Exclude maven from shading

* Try update snapshots to build action

* Try repo on command line

* Remove reference to shade plugin in dependencies
2021-06-20 12:18:10 -07:00
tastybento
2a5d8c14e3 WIP prevent repeated teleports in portals 2021-06-19 09:59:20 -07:00
tastybento
cc43dbfabe Fix slime split test as it is allowed. 2021-06-12 09:25:29 -07:00
gecko10000
7768cc69cc
Remove SLIME_SPLIT spawn reason from natural mob spawning flag (#1774) 2021-06-08 10:40:20 -07:00
Korinocho
a91203d439
Update es.yml (#1775)
* Update es.yml

Many syntax and semantic fixes

* Update es.yml
2021-06-08 10:39:34 -07:00
tastybento
044a0c5c0d Fix JavaDoc 2021-05-31 16:01:21 -07:00
tastybento
c3b25c92b5 Added JavaDoc 2021-05-31 16:01:12 -07:00
tastybento
6e9513f2ea
Enable plugins to register Addons (#1768)
* Enable plugins to register Addons

* Pladdon approach. Loads addons as plugins.

* Added auto-move for pladdons.
2021-05-31 12:42:54 -07:00
tastybento
9fc22aa8e7 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-05-28 17:25:03 -07:00
tastybento
bedeb7c168 Addd GSON enum type adapter for compatibility with Mohist
https://github.com/BentoBoxWorld/BentoBox/issues/1766
2021-05-28 17:24:51 -07:00
gitlocalize-app[bot]
7f8297475d
Total translation rate that appears to be incorrect in the system (#1765)
* Translate tr.yml via GitLocalize
Co-authored-by: gitlocalize-app[bot] <55277160+gitlocalize-app[bot]@users.noreply.github.com>
Co-authored-by: tastybento <tastybento@wasteofplastic.com>
Co-authored-by: ZyXpe <thechefsmaster@gmail.com>
Co-authored-by: Over_Brave <soncesurlar@gmail.com>
Co-authored-by: trafoziya <omerziyaakay@gmail.com>
2021-05-28 16:32:30 -07:00
tastybento
e472e07c34 Fixes Invincible Visitor settings panel
https://github.com/BentoBoxWorld/BentoBox/issues/1762
2021-05-22 17:41:47 -07:00
gitlocalize-app[bot]
03417a78f7
Translate tr.yml via GitLocalize (#1761)
Co-authored-by: trafoziya <omerziyaakay@gmail.com>
2021-05-22 16:29:33 -07:00
Fredthedoggy
ca39e05fc7
Allow Non-Bentobox commands as default player (commands) (#1760)
* Update ServerCompatibility.java

* Update Default Player Command to support non-bentobox commands
2021-05-15 13:20:09 -07:00
tastybento
64c83f809c Adjusted default command for backwards compatibility 2021-05-13 08:01:22 -07:00
tastybento
36d0a07e35 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-05-13 07:37:52 -07:00
tastybento
2bc35c8936 Runs player go and create commands as direct calls.
Avoids performCommand because it can be trapped as a cheat because it
executes too fast. Allows use of non-subcommands.
2021-05-13 07:37:41 -07:00
Fredthedoggy
022d343295
Update Plugin.yml for new Permissions Addon (#1758) 2021-05-11 21:36:59 -07:00
tastybento
982dc2fd52 Require non null getCenter
This will throw a big runtime error if range is adjusted without a
center location being defined. Should only affect addons like the
Converter.
2021-05-11 21:29:44 -07:00
tastybento
17af44e67a Fix GameModePlaceholderTest 2021-05-09 13:10:37 -07:00
tastybento
839f05de71 Fix maxteamsize placeholders
The placeholders were not using the correct API call and so were
reporting based on the player's permission and not the actual island's
maxteam size.

https://github.com/BentoBoxWorld/BentoBox/issues/1753
2021-05-07 12:36:12 -07:00
Fredthedoggy
9ed0620bb0
Update ServerCompatibility.java (#1751) 2021-05-01 09:37:11 -07:00
tastybento
09bac48b5e Adjusted portal search radius to 64. 2021-04-25 09:35:45 -07:00
tastybento
352c6dec84 Use home names instead of numbers in locale 2021-04-24 10:50:23 -07:00
gitlocalize-app[bot]
3242a497db
NL Translation (#1748)
* Translate nl.yml via GitLocalize

* Translate nl.yml via GitLocalize

* Update nl.yml

* Update nl.yml

Co-authored-by: tastybento <tastybento@wasteofplastic.com>
Co-authored-by: mt-gitlocalize <mt@gitlocalize.com>
Co-authored-by: tastybento <tastybento@users.noreply.github.com>
2021-04-24 10:45:25 -07:00
tastybento
b1ab2ecece Corrected since reference, removed debug. 2021-04-24 09:02:47 -07:00
tastybento
33b49a2349 Set minimum portal search radius to 8. Added config option.
https://github.com/BentoBoxWorld/BentoBox/issues/1747
2021-04-24 08:45:05 -07:00
fredthedoggy
2a1d9fcc61
Add WildStacker as SoftDepend to plugin.yml (#1742) 2021-04-18 13:47:07 -07:00
tastybento
ac8458fd3c Add IslandHomesCommand
https://github.com/BentoBoxWorld/BentoBox/issues/1737
2021-04-07 21:36:49 -07:00
tastybento
2098fd636a Fix home listing on error.
https://github.com/BentoBoxWorld/BentoBox/issues/1737
2021-04-07 21:20:48 -07:00
tastybento
3e068e4283 Fix missing fields in copy constructor for Island class. 2021-04-03 16:33:55 -07:00
tastybento
fb2c9c0553 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-03-27 18:21:45 -07:00
tastybento
c85f3b9af2 Fix test 2021-03-27 18:21:32 -07:00
BONNe
dc829786d3
Fixes a bug with Commands not being able to find subcommand if defined label contains capital letter. (#1724) 2021-03-27 18:19:44 -07:00
tastybento
9220f9652b Fix broken tests. 2021-03-27 17:20:43 -07:00
tastybento
609322d582 Remove debug. 2021-03-27 17:05:13 -07:00
tastybento
4b9b6774ea Teleport based on protection center and world height. 2021-03-27 16:57:15 -07:00
tastybento
c6e2a9bd66 Admin teleport now goes to island spawn locations if they exist 2021-03-27 09:23:24 -07:00
Qumoo
9db7721016
Updated german language file (#1727)
* Updated german language file

Fixed typo, fixed consistency (beacon = english, Leuchtfeuer = german)

* Updated german language filede.yml

fixed typos, translated messages that were still in English
2021-03-24 22:18:16 -07:00
tastybento
ed46695546 Added teleport method test to DelayedTeleportCommandTest. 2021-03-21 15:58:10 -07:00
tastybento
3c4b7deb75 Treat teleporting as moving for delayed commands.
Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1722
2021-03-21 15:50:47 -07:00
Florian CUNY
8ecfee4359
Added since javadoc to getIslandsManager and getPlayersManager()
Completes 2bef0fe57c
2021-03-21 22:08:21 +01:00
tastybento
9e0fdbd210 Add Util method to enable multi-lingual broadcasts. 2021-03-21 09:04:30 -07:00
tastybento
99e6e11a4a Disable LangUtilsHook for now until @Poslovitch can review. 2021-03-19 15:18:44 -07:00
tastybento
8f767d5e44 Fix tests - event is canceled now.
Change done here: 592b4e3d1f
2021-03-18 18:45:05 -07:00
tastybento
87bdee0946 Return island protection center instead of island logical center
IslandsManager.getIslandLocation(world, uuid) is used to find the
starting point for the island home if a safe home for players cannot be
found. It returns the island center location but should return the
center of the island protection because that can now be in a different
location.
2021-03-17 15:18:55 -07:00
apachezy
b8d9b73103
Added DamageCause into zh-CN.yml and zh-HK.yml. (#1721)
* Added getMusicDiskDesc into LangUtilsHook.

* Added DamageCause into zh-CN.yml and zh-HK.yml.

Co-authored-by: zhangYi <apachezy@hotmail.com>
2021-03-16 19:08:16 -07:00
BONNe
592b4e3d1f
Fixes player teleportation in void. (#1716)
The issue happens mostly with the end portals. Apparently, teleportation to the end is processed before the Bukkit task that runs SafeSpotTeleport. The first check if a player is in the starting world fails, and SafeSpotTeleport is not called. 

I set the event to be cancelled in all situations when we do not create portals, so it always triggers SafeSpotTeleport. This should fix the bug with players appearing in the void.
2021-03-16 19:07:36 -07:00
BONNe
8ce30a7cb5
Fixes spawn platform position in the end. (#1713)
In the vanilla end, the highest block in the End can be above 63. Check for just 0, 63, 0 may be incorrect for most of the end vanilla worlds.
2021-03-16 19:07:05 -07:00
apachezy
4582b23522
Added getMusicDiskDesc into LangUtilsHook. (#1715)
Co-authored-by: zhangYi <apachezy@hotmail.com>
2021-03-15 14:27:28 +01:00
BONNe
cf5483e49d
Fixed end platform generation (#1717)
If a player has end portal at Y=0 or Y=1, then they were spawned in the void, if makePortals option was enabled.
It happens because end portals are generated with 2 air layers above the obsidian platform. So minimal location is necessary to be at least 2 (2 for air and obsidian at 0).
2021-03-15 14:23:25 +01:00
apachezy
17d5b7392b
Additional improvements to zh-CN (#1714)
Co-authored-by: zhangYi <apachezy@hotmail.com>
2021-03-15 14:20:54 +01:00
tastybento
69b059f423 Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop 2021-03-14 18:20:52 -07:00
tastybento
d70b07c273 Date formatting was choking sometimes. This is simpler. 2021-03-14 18:20:36 -07:00
tastybento
6c775329d0 Fix InvincibleVisitorsListenerTest. 2021-03-14 13:48:31 -07:00
tastybento
74023914a7 Fixed enum locale for English and Japanese.
Sort based on translated name in InvincibleVisitors.
2021-03-14 11:57:55 -07:00
gitlocalize-app[bot]
487fa6af8e
Translate ja.yml via GitLocalize (#1711)
Co-authored-by: tastybento <tastybento@wasteofplastic.com>
2021-03-14 11:24:49 -07:00
tastybento
0769af0c65 Remove debug lines. 2021-03-14 10:29:02 -07:00
tastybento
d97d15d47a Added locale strings for the DamageCause enum. Used in InvincibleVistors
Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1705
2021-03-14 10:18:33 -07:00
tastybento
1feaddf704 Avoid loading or enabling disabled addons. 2021-03-13 15:00:49 -08:00
tastybento
45bcf64da5 Added IslandNewIslandEvent
Gets fired when a player is teleported to their new island for the first
time.
2021-03-13 10:47:02 -08:00
apachezy
4544cada3a
Improved zh-CN (#1710)
* Improved zh-CN.yml

* Delete an error.

* days-one-or-more #1707

* Patch NO.1

Co-authored-by: zhangYi <apachezy@hotmail.com>
2021-03-13 18:49:57 +01:00
apachezy
e36dc68ccd
Improved zh-CN.yml (#1708)
* Improved zh-CN.yml

* Delete an error.

* days-one-or-more #1707

Co-authored-by: zhangYi <apachezy@hotmail.com>
2021-03-13 08:44:19 -08:00
apachezy
0f0d8b9ebc
Added LangUtils support. (#1693) 2021-03-12 20:04:34 -08:00
poslovitch
40d1c318d5 Fixed purge command "one day or more" message
Fixes https://github.com/BentoBoxWorld/BentoBox/issues/1707
2021-03-12 22:02:16 +01:00
tastybento
031d789896 Enable to use command line to set spawn island settings.
https://github.com/BentoBoxWorld/BentoBox/issues/1703
2021-03-09 22:18:48 -08:00
tastybento
6849c2a8bd Delete backup database during tests. 2021-03-07 11:34:30 -08:00
tastybento
7d6cce6563 Minor Java doc addition to clarify getAddon() 2021-03-07 10:09:18 -08:00
Huynh Tien
5142894127
rework on Vietnamese translation (#1671)
* rework on Vietnamese translation
2021-03-07 09:29:58 -08:00
tastybento
9c1a239501 Fixed bug where AllLoaded method was not being called on BentoBox reload 2021-03-06 15:08:54 -08:00