Add some patches, fix compile

This commit is contained in:
Spottedleaf
2023-09-22 15:33:14 -07:00
parent 9bf842c13e
commit 1efbbb3ef9
35 changed files with 308 additions and 235 deletions

View File

@@ -825,32 +825,22 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ // Paper start
+ @Override
+ public int getStewEffectDuration() {
+ return this.getHandle().effectDuration;
+ throw new UnsupportedOperationException(); // TODO https://github.com/PaperMC/Paper/issues/9742
+ }
+
+ @Override
+ public void setStewEffectDuration(int duration) {
+ this.getHandle().effectDuration = duration;
+ throw new UnsupportedOperationException(); // TODO https://github.com/PaperMC/Paper/issues/9742
+ }
+
+ @Override
+ public org.bukkit.potion.PotionEffectType getStewEffectType() {
+ net.minecraft.world.effect.MobEffect effect = this.getHandle().effect;
+ if (effect == null) {
+ return null;
+ }
+
+ return org.bukkit.potion.PotionEffectType.getById(net.minecraft.world.effect.MobEffect.getId(effect));
+ throw new UnsupportedOperationException(); // TODO https://github.com/PaperMC/Paper/issues/9742
+ }
+
+ @Override
+ public void setStewEffect(org.bukkit.potion.PotionEffectType type) {
+ net.minecraft.world.effect.MobEffect effect = null;
+ if (type != null) {
+ effect = net.minecraft.world.effect.MobEffect.byId(type.getId());
+ }
+
+ this.getHandle().effect = effect;
+ throw new UnsupportedOperationException(); // TODO https://github.com/PaperMC/Paper/issues/9742
+ }
+ // Paper end
+