Skip to content

Commit

Permalink
updated dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
NonSwag committed Dec 19, 2023
1 parent f4e47c4 commit 8f0a476
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
5 changes: 3 additions & 2 deletions src/main/java/net/thenextlvl/tweaks/TweaksPlugin.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
package net.thenextlvl.tweaks;

import core.annotation.FieldsAreNotNullByDefault;
import core.api.file.format.GsonFile;
import core.file.format.GsonFile;
import core.i18n.file.ComponentBundle;
import core.io.IO;
import core.paper.messenger.PluginMessenger;
import lombok.Getter;
import lombok.experimental.Accessors;
Expand Down Expand Up @@ -40,7 +41,7 @@ public class TweaksPlugin extends JavaPlugin {
private final Metrics metrics = new Metrics(this, 19651);

private final TweaksConfig config = new GsonFile<>(
new File(getDataFolder(), "config.json"),
IO.of(getDataFolder(), "config.json"),
new TweaksConfig(
new GeneralConfig(5, (byte) -1, false, false, false, true),
new InventoryConfig(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package net.thenextlvl.tweaks.command.player;

import com.google.gson.annotations.SerializedName;
import core.io.IO;
import core.nbt.file.NBTFile;
import core.nbt.snbt.SNBT;
import core.nbt.snbt.SNBTBuilder;
Expand Down Expand Up @@ -37,7 +38,6 @@
public class OfflineTeleportCommand implements TabExecutor {
private final TweaksPlugin plugin;
private final SNBT snbt = new SNBTBuilder()
.enableComplexMapKeySerialization()
.create();

@Override
Expand Down Expand Up @@ -130,8 +130,8 @@ public static LocationData of(Location location) {

private @Nullable NBTFile<CompoundTag> getNBTFile(OfflinePlayer player) {
var worldFolder = Bukkit.getWorlds().get(0).getWorldFolder();
var file = new File(new File(worldFolder, "playerdata"), player.getUniqueId() + ".dat");
return file.exists() ? new NBTFile<>(file, new CompoundTag()) : null;
var io = IO.of(new File(worldFolder, "playerdata"), player.getUniqueId() + ".dat");
return io.exists() ? new NBTFile<>(io, new CompoundTag()) : null;
}

@Override
Expand Down

0 comments on commit 8f0a476

Please sign in to comment.