Remove deprecation and removal warnings
This commit is contained in:
parent
0bf2697c25
commit
a0f15d5252
@ -20,3 +20,10 @@ java {
|
|||||||
languageVersion = JavaLanguageVersion.of(21)
|
languageVersion = JavaLanguageVersion.of(21)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.withType<JavaCompile> {
|
||||||
|
options.compilerArgs.addAll(listOf(
|
||||||
|
"-Xlint:-removal",
|
||||||
|
"-Xlint:-deprecation"
|
||||||
|
))
|
||||||
|
}
|
||||||
|
|||||||
@ -33,7 +33,6 @@ import org.bukkit.util.BoundingBox;
|
|||||||
import org.bukkit.util.Vector;
|
import org.bukkit.util.Vector;
|
||||||
import org.jetbrains.annotations.NotNull;
|
import org.jetbrains.annotations.NotNull;
|
||||||
import org.jetbrains.annotations.Nullable;
|
import org.jetbrains.annotations.Nullable;
|
||||||
import org.patchbukkit.PatchBukkitServer;
|
|
||||||
|
|
||||||
import io.papermc.paper.datacomponent.DataComponentType;
|
import io.papermc.paper.datacomponent.DataComponentType;
|
||||||
import io.papermc.paper.datacomponent.DataComponentType.Valued;
|
import io.papermc.paper.datacomponent.DataComponentType.Valued;
|
||||||
@ -49,7 +48,7 @@ public class PatchBukkitEntity implements Entity {
|
|||||||
private final String name;
|
private final String name;
|
||||||
|
|
||||||
public PatchBukkitEntity(
|
public PatchBukkitEntity(
|
||||||
UUID uuid,
|
UUID uuid,
|
||||||
String name
|
String name
|
||||||
) {
|
) {
|
||||||
this.uuid = uuid;
|
this.uuid = uuid;
|
||||||
|
|||||||
@ -48,7 +48,6 @@ import org.checkerframework.checker.index.qual.NonNegative;
|
|||||||
import org.jetbrains.annotations.NotNull;
|
import org.jetbrains.annotations.NotNull;
|
||||||
import org.jetbrains.annotations.Nullable;
|
import org.jetbrains.annotations.Nullable;
|
||||||
import org.jetbrains.annotations.Range;
|
import org.jetbrains.annotations.Range;
|
||||||
import org.patchbukkit.PatchBukkitServer;
|
|
||||||
|
|
||||||
import com.destroystokyo.paper.block.TargetBlockInfo;
|
import com.destroystokyo.paper.block.TargetBlockInfo;
|
||||||
import com.destroystokyo.paper.block.TargetBlockInfo.FluidMode;
|
import com.destroystokyo.paper.block.TargetBlockInfo.FluidMode;
|
||||||
@ -58,11 +57,12 @@ import io.papermc.paper.world.damagesource.CombatTracker;
|
|||||||
import net.kyori.adventure.key.Key;
|
import net.kyori.adventure.key.Key;
|
||||||
import net.kyori.adventure.util.TriState;
|
import net.kyori.adventure.util.TriState;
|
||||||
|
|
||||||
|
@SuppressWarnings({ "deprecation", "removal" })
|
||||||
public class PatchBukkitHumanEntity
|
public class PatchBukkitHumanEntity
|
||||||
extends PatchBukkitLivingEntity
|
extends PatchBukkitLivingEntity
|
||||||
implements HumanEntity {
|
implements HumanEntity {
|
||||||
|
|
||||||
public PatchBukkitHumanEntity(UUID uuid,
|
public PatchBukkitHumanEntity(UUID uuid,
|
||||||
String name) {
|
String name) {
|
||||||
super(uuid, name);
|
super(uuid, name);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -45,11 +45,12 @@ import io.papermc.paper.world.damagesource.CombatTracker;
|
|||||||
import net.kyori.adventure.key.Key;
|
import net.kyori.adventure.key.Key;
|
||||||
import net.kyori.adventure.util.TriState;
|
import net.kyori.adventure.util.TriState;
|
||||||
|
|
||||||
|
@SuppressWarnings({ "deprecation", "removal" })
|
||||||
public class PatchBukkitLivingEntity
|
public class PatchBukkitLivingEntity
|
||||||
extends PatchBukkitEntity
|
extends PatchBukkitEntity
|
||||||
implements LivingEntity {
|
implements LivingEntity {
|
||||||
|
|
||||||
public PatchBukkitLivingEntity(UUID uuid,
|
public PatchBukkitLivingEntity(UUID uuid,
|
||||||
String name) {
|
String name) {
|
||||||
super(uuid, name);
|
super(uuid, name);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -75,19 +75,20 @@ import net.kyori.adventure.text.Component;
|
|||||||
import net.kyori.adventure.util.TriState;
|
import net.kyori.adventure.util.TriState;
|
||||||
import net.md_5.bungee.api.chat.BaseComponent;
|
import net.md_5.bungee.api.chat.BaseComponent;
|
||||||
|
|
||||||
|
@SuppressWarnings({ "deprecation", "removal" })
|
||||||
public class PatchBukkitPlayer
|
public class PatchBukkitPlayer
|
||||||
extends PatchBukkitHumanEntity
|
extends PatchBukkitHumanEntity
|
||||||
implements Player {
|
implements Player {
|
||||||
|
|
||||||
public PatchBukkitPlayer(UUID uuid, String name) {
|
public PatchBukkitPlayer(UUID uuid, String name) {
|
||||||
super(uuid, name);
|
super(uuid, name);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Player.Spigot spigot() {
|
public Player.Spigot spigot() {
|
||||||
throw new UnsupportedOperationException("Unimplemented method 'spigot'");
|
throw new UnsupportedOperationException("Unimplemented method 'spigot'");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isConversing() {
|
public boolean isConversing() {
|
||||||
// TODO Auto-generated method stub
|
// TODO Auto-generated method stub
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user