ScreamingSandals / BedWars

Simple BedWars minigame plugin for Spigot version 1.8.8 - 1.21.3
https://www.spigotmc.org/resources/bedwars.63714/
GNU Lesser General Public License v3.0
268 stars 95 forks source link

Joining (or leaving) to (from) the arena with potion effects leads to "Can't unwrap object" error. #461

Closed ghost closed 1 year ago

ghost commented 1 year ago

Describe the bug

Joining (or leaving) to (from) the arena with potion effects leads to "Can't unwrap object" error.

Recreation steps

In order to recreate this bug, you need at least one saved arena.

  1. Launch a server with Screaming BedWars plugin installed;
  2. Join the server;
  3. Give yourself any effect via /effect;
  4. Enter the arena using /bw join <ArenaName>;
  5. Bug recreated.

Expected behavior

Player joins or leaves the arena without any errors. Potion effects will return if player decides to leave or game is finished.

Observed behavior

Plugin fails with java.lang.UnsupportedOperationException: Can't unwrap object to org.bukkit.potion.PotionEffectType error.

Server and plugin version

Spigot version: Paper version git-Paper-794 (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT) BedWars version: 0.3.0-SNAPSHOT - SNAPSHOT VERSION (962)

Installed plugins on server (can be obtained by /pl)

Plugins (3): Multiverse-Core, ScreamingBedWars, SkinsRestorer

Console log

2023-02-25-2.log

Configuration (of config.yml and shop.yml)

config.yml: https://pastebin.com/Qjfv6pi6 shop/shop.yml: https://pastebin.com/jYez7964

Extra notes

This bug only exists in 0.3.x version. 0.2.x is unaffected.

Video

https://user-images.githubusercontent.com/93866416/221377754-477900bc-4e25-41d3-bed3-38e6044cee6d.mp4

Misat11 commented 1 year ago

There was an issue in the underlying library, please try this snapshot: https://github.com/ScreamingSandals/BedWars/actions/runs/4271913981 (yes, it is newer than the one I linked you in your another issue)

ghost commented 1 year ago

There was an issue in the underlying library, please try this snapshot: https://github.com/ScreamingSandals/BedWars/actions/runs/4271913981 (yes, it is newer than the one I linked you in your another issue)

This fixed the issue. Closing.