Island owner inventory deletion on /is team kick
See original GitHub issueDescription Island owners inventory gets resetted when member is kicked out of the team.
Steps to reproduce the behavior:
- Bskyblock config:
on-join:
money: false
inventory: true
ender-chest: false
on-leave:
money: false
inventory: true
ender-chest: true
- Player ‘dcAnt’ joins player 'acBee’s island.
- See http://prntscr.com/mgzcgm , acBee has some items.
- Players ‘acBee’ kicks ‘dcAnt’ from island using /is team kick
- acBee’s inventory is cleared, see: http://prntscr.com/mgzgci
Expected behavior Only the members that join/leave/get kicked shall be affected with the configuration above, and not owners.
Server Information:
-
Database being used: MySQL
-
OS: Debian GNU/Linux 9
-
Java Version: Java™ SE Runtime Environment 18.3 (build 10.0.1+10) Java HotSpot™ 64-Bit Server VM 18.3 (build 10.0.1+10, mixed mode)
-
BentoBox version: [19:37:21] [main/INFO]: [CHAT] Bentobox version: 1.3.0-SNAPSHOT
-
Addons: [19:37:21] [main/INFO]: [CHAT] BSkyBlock 1.2.1-SNAPSHOT [19:37:21] [main/INFO]: [CHAT] WelcomeWarps 1.2-SNAPSHOT [19:37:21] [main/INFO]: [CHAT] ASBwarp 1.0 [19:37:21] [main/INFO]: [CHAT] Challenges 0.3.1-SNAPSHOT [19:37:21] [main/INFO]: [CHAT] Level 1.2.1-SNAPSHOT [19:37:21] [main/INFO]: [CHAT] Biomes 0.5.0-SNAPSHOT
-
Other plugins?
-
[06:32:17 INFO]: Plugins (50): AnimatedNames*, AreaShop, ArmorStandTools, BentoBox, BungeeTabListPlus*, ChatControl, ChestCommands, ChestShop*, ClearLag*, CrateReloaded, EditableSign, Essentials, EssentialsChat*, EssentialsSpawn*, ExecuteEverywhere*, FastAsyncWorldEdit*, FeatherBoard*, HeadDatabase*, HolographicDisplays, HungerKeeperPlus*, IPWhitelist*, IslandBorder, LeaderHeads*, LibsDisguises, LuckPerms, MobManager*, Multiverse-Core*, MVdWPlaceholderAPI*, NickRemover*, NoSleepCMDs*, OpenInv*, PlayerHeads, PlayerPoints*, ProtocolLib*, PvPManager*, PvPManagerBossBar*, RedstoneClockDetector*, RPGHealthIndicator*, SilkSpawners, SkinsRestorer, Spartan, TradeMe, TrophyHeads*, UnbreakingAnvils*, Vault*, VoidGenerator, WorldEdit, WorldGuard, WorldGuardPistonFix*, Yamler*
Localhost:
- Plugins: [16:38:36 INFO]: Plugins (1): BentoBox
- Addons: [16:38:56 INFO]: BentoBox version: 1.3.0-SNAPSHOT [16:38:56 INFO]: Loaded Game Worlds: [16:38:56 INFO]: BSkyBlock_world (BSkyBlock) [16:38:56 INFO]: Loaded Addons: [16:38:56 INFO]: BSkyBlock 1.1 [16:38:56 INFO]: Challenges 0.5.0-SNAPSHOT [16:38:56 INFO]: Level 0.2.0
Additional context
- acBee(s) inventory did not reset if dcAnt used /is team leave. Happened only when the member was kicked out from the team.
- Last test of this was done on localhost on my PC (The above one)
- First time when we noticed this on our server, we immediately turned off these features, because players had already started losing their items. We didn’t want to test again on a live server and in the meantime this was forgotten. Now when I remembered I decided to start it on my PC to test and report, and it’s still a bug.
- Tested it only with 2 players on island, not sure what happens if more are present.
- Since the configuration file for these settings is found in BSkyBlocks addon folder, I thought that this issue shall be placed in the BSB section.
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (6 by maintainers)
Top GitHub Comments
I just fixed the bug - at least the island owner’s no longer losing his stuff. However, the member that gets kicked does not get his inventory/enderchest resetted if he’s offline at that moment. @tastybento Could you please have a look at that? I’ve also
@Ignore
’d the unit test responsible for checking this. That’s pointless to rewrite it as long as we do not have the final solution to this problem.I’ll keep this issue opened so we can monitor it. I’m also assigning you to it if you don’t mind, tasty.
Okay, I can confirm it’s occuring - no need to test it on a fresh install: https://github.com/BentoBoxWorld/BentoBox/blob/f71ca4f0847593dad1cc751a96a3c2b6a298d267/src/main/java/world/bentobox/bentobox/api/commands/island/team/IslandTeamKickCommand.java#L74-L80
The user shouldn’t be used there - it should be the target.