Skip to content

Commit bfde275

Browse files
committed
add PotionEffectType Registry for paper
1 parent e1ef647 commit bfde275

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

modules/library/src/main/java/top/mrxiaom/pluginbase/utils/RegistryConverter.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,14 @@ protected static void init() {
6767
add(DamageType.class, Registry.DAMAGE_TYPE);
6868
} catch (Throwable ignored) {}
6969
try {
70-
add(PotionEffectType.class, Registry.EFFECT);
71-
} catch (Throwable ignored) {}
70+
// Paper
71+
add("org.bukkit.potion.PotionEffectType", "POTION_EFFECT_TYPE");
72+
} catch (Throwable t) {
73+
try {
74+
add(PotionEffectType.class, Registry.EFFECT);
75+
} catch (Throwable ignored) {
76+
}
77+
}
7278
try {
7379
add(Enchantment.class, Registry.ENCHANTMENT);
7480
} catch (Throwable ignored) {}

0 commit comments

Comments
 (0)