Update to 1.3.4.0

This commit is contained in:
Zontreck 2022-10-13 00:28:58 -07:00
parent 6a4feca615
commit 2ed19b6e0c
36 changed files with 60 additions and 321 deletions

View file

@ -118,6 +118,11 @@ repositories {
name = "CurseMaven" name = "CurseMaven"
url = "https://cursemaven.com" url = "https://cursemaven.com"
} }
maven {
name = "ZNI Creations"
url = "https://maven.zontreck.dev"
}
} }
dependencies { dependencies {
@ -129,6 +134,9 @@ dependencies {
compileOnly fg.deobf("mezz.jei:jei-${mc_version}-common-api:${jei_version}") compileOnly fg.deobf("mezz.jei:jei-${mc_version}-common-api:${jei_version}")
compileOnly fg.deobf("mezz.jei:jei-${mc_version}-forge-api:${jei_version}") compileOnly fg.deobf("mezz.jei:jei-${mc_version}-forge-api:${jei_version}")
runtimeOnly fg.deobf("mezz.jei:jei-${mc_version}-forge:${jei_version}") runtimeOnly fg.deobf("mezz.jei:jei-${mc_version}-forge:${jei_version}")
compileOnly fg.deobf("dev.zontreck:libzontreck:1.0.0.1:dev")
runtimeOnly fg.deobf("dev.zontreck:libzontreck:1.0.0.1")
// compile against the JEI API but do not include it at runtime // compile against the JEI API but do not include it at runtime
//compileOnly fg.deobf("mezz.jei:jei-${mc_version}-forge-api:${jei_version}") //compileOnly fg.deobf("mezz.jei:jei-${mc_version}-forge-api:${jei_version}")
// at runtime, use the full JEI jar // at runtime, use the full JEI jar
@ -154,7 +162,7 @@ dependencies {
jar { jar {
manifest { manifest {
attributes([ attributes([
"Specification-Title" : "otemod", "Specification-Title" : project.name,
"Specification-Vendor" : "Zontreck", "Specification-Vendor" : "Zontreck",
"Specification-Version" : "${my_version}", // We are version 1 of ourselves "Specification-Version" : "${my_version}", // We are version 1 of ourselves
"Implementation-Title" : project.name, "Implementation-Title" : project.name,

View file

@ -3,7 +3,7 @@
org.gradle.jvmargs=-Xmx8G org.gradle.jvmargs=-Xmx8G
org.gradle.daemon=false org.gradle.daemon=false
my_version=1.3.3.7 my_version=1.3.4.0
mc_version=1.19.2 mc_version=1.19.2
forge_version=43.1.32 forge_version=43.1.32

View file

@ -48,9 +48,8 @@ import net.minecraftforge.registries.ForgeRegistries;
import org.slf4j.Logger; import org.slf4j.Logger;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.blocks.ModBlocks; import dev.zontreck.otemod.blocks.ModBlocks;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.commands.CommandRegistry; import dev.zontreck.otemod.commands.CommandRegistry;
import dev.zontreck.otemod.commands.teleport.TeleportContainer; import dev.zontreck.otemod.commands.teleport.TeleportContainer;

View file

@ -1,6 +1,5 @@
package dev.zontreck.otemod.blocks; package dev.zontreck.otemod.blocks;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.DoorBlock; import net.minecraft.world.level.block.DoorBlock;
public class AuroraDoorBlock extends DoorBlock public class AuroraDoorBlock extends DoorBlock

View file

@ -1,13 +1,9 @@
package dev.zontreck.otemod.blocks; package dev.zontreck.otemod.blocks;
import java.util.function.Supplier;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.items.ModItems;
import net.minecraft.world.item.BlockItem; import net.minecraft.world.item.BlockItem;
import net.minecraft.world.item.CreativeModeTab; import net.minecraft.world.item.CreativeModeTab;
import net.minecraft.world.item.Item; import net.minecraft.world.item.Item;
import net.minecraft.world.item.Item.Properties;
import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.Blocks;
import net.minecraft.world.level.block.DoorBlock; import net.minecraft.world.level.block.DoorBlock;

View file

@ -1,161 +0,0 @@
package dev.zontreck.otemod.chat;
public class ChatColor {
public enum ColorOptions{
Black,
Dark_Blue,
Dark_Green,
Dark_Aqua,
Dark_Red,
Dark_Purple,
Gold,
Gray,
Dark_Gray,
Blue,
Green,
Aqua,
Red,
Light_Purple,
Yellow,
White,
MinecoinGold,
Underline,
Bold,
Italic,
Strikethrough,
Crazy
}
public static char CODE = '§';
public static String BLACK = build("0");
public static String DARK_BLUE = build("1");
public static String DARK_GREEN = build("2");
public static String DARK_AQUA = build("3");
public static String DARK_RED = build("4");
public static String DARK_PURPLE = build("5");
public static String GOLD = build("6");
public static String GRAY = build("7");
public static String DARK_GRAY = build("8");
public static String BLUE = build("9");
public static String GREEN = build("a");
public static String AQUA = build("b");
public static String RED = build("c");
public static String LIGHT_PURPLE = build("d");
public static String YELLOW = build("e");
public static String WHITE = build("f");
public static String MINECOIN_GOLD = build("g");
public static String UNDERLINE = build("u");
public static String BOLD = build("l");
public static String ITALIC = build("o");
public static String STRIKETHROUGH = build("m");
public static String CRAZY = build("k");
public static String RESET = build("r");
public static String build(String c)
{
return CODE+c;
}
public static String resetChat()
{
return RESET+WHITE;
}
public static String from(ColorOptions nick){
switch(nick){
case Black:
{
return BLACK;
}
case Dark_Blue:
{
return DARK_BLUE;
}
case Dark_Green:
{
return DARK_GREEN;
}
case Dark_Aqua:
{
return DARK_AQUA;
}
case Dark_Red:
{
return DARK_RED;
}
case Dark_Purple:
{
return DARK_PURPLE;
}
case Gold:
{
return GOLD;
}
case Gray:
{
return GRAY;
}
case Dark_Gray:
{
return DARK_GRAY;
}
case Blue:
{
return BLUE;
}
case Green:
{
return GREEN;
}
case Aqua:
{
return AQUA;
}
case Red:
{
return RED;
}
case Light_Purple:
{
return LIGHT_PURPLE;
}
case Yellow:
{
return YELLOW;
}
case White:
{
return WHITE;
}
case MinecoinGold:
{
return MINECOIN_GOLD;
}
case Underline:
{
return UNDERLINE;
}
case Bold:
{
return BOLD;
}
case Italic:
{
return ITALIC;
}
case Strikethrough:
{
return STRIKETHROUGH;
}
case Crazy:
{
return CRAZY;
}
default:
{
return RESET+CRAZY;
}
}
}
}

View file

@ -6,22 +6,19 @@ import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
import java.util.UUID; import java.util.UUID;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.HoverTip;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.configs.PlayerFlyCache; import dev.zontreck.otemod.configs.PlayerFlyCache;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import dev.zontreck.otemod.database.Database;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.Style; import net.minecraft.network.chat.Style;
import net.minecraft.server.MinecraftServer; import net.minecraft.server.MinecraftServer;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.server.network.ServerPlayerConnection;
import net.minecraft.world.entity.player.Player; import net.minecraft.world.entity.player.Player;
import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn; import net.minecraftforge.api.distmarker.OnlyIn;
import net.minecraftforge.event.ForgeEventFactory;
import net.minecraftforge.event.ServerChatEvent; import net.minecraftforge.event.ServerChatEvent;
import net.minecraftforge.event.entity.EntityJoinLevelEvent;
import net.minecraftforge.event.entity.player.PlayerEvent; import net.minecraftforge.event.entity.player.PlayerEvent;
import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.Mod;
@ -118,7 +115,7 @@ public class ChatServerOverride {
} }
String msg = ev.getMessage().getString(); String msg = ev.getMessage().getString();
msg=doColors(msg); msg= ChatColor.doColors(msg);
String nameStr = ChatColor.resetChat() + "< "+ XD.name_color + XD.nickname + ChatColor.resetChat() + " >"; String nameStr = ChatColor.resetChat() + "< "+ XD.name_color + XD.nickname + ChatColor.resetChat() + " >";
String message = ": "+XD.chat_color + msg; String message = ": "+XD.chat_color + msg;
@ -129,13 +126,6 @@ public class ChatServerOverride {
ChatServerOverride.broadcast(Component.literal(prefixStr+nameStr+message).setStyle(hover), ev.getPlayer().server); ChatServerOverride.broadcast(Component.literal(prefixStr+nameStr+message).setStyle(hover), ev.getPlayer().server);
} }
public static String doColors(String msg)
{
for(ChatColor.ColorOptions color : ChatColor.ColorOptions.values()){
msg = msg.replace("!"+color.toString()+"!", ChatColor.from(color));
}
return msg;
}
public static void broadcastAbove(Component message, MinecraftServer s) public static void broadcastAbove(Component message, MinecraftServer s)
{ {

View file

@ -1,16 +0,0 @@
package dev.zontreck.otemod.chat;
import net.minecraft.network.chat.ClickEvent;
import net.minecraft.network.chat.ClickEvent.Action;
/*
* Because of some weird behavior with java not liking that both HoverEvent and ClickEvent have an Action implementation, these must both be in a custom factory here where Action can be imported by itself in both files
*/
public class Clickable {
public static ClickEvent command(String text)
{
return new ClickEvent(Action.RUN_COMMAND, text);
}
}

View file

@ -1,17 +0,0 @@
package dev.zontreck.otemod.chat;
import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.HoverEvent;
import net.minecraft.network.chat.HoverEvent.Action;
/*
* Because of some weird behavior with java not liking that both HoverEvent and ClickEvent have an Action implementation, these must both be in a custom factory here where Action can be imported by itself in both files
*/
public class HoverTip {
public static HoverEvent get(String text)
{
return new HoverEvent(Action.SHOW_TEXT, Component.literal(text));
}
}

View file

@ -3,7 +3,7 @@ package dev.zontreck.otemod.commands;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.context.CommandContext; import com.mojang.brigadier.context.CommandContext;
import dev.zontreck.otemod.chat.ChatColor; import dev.zontreck.libzontreck.chat.ChatColor;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.contents.TranslatableContents; import net.minecraft.network.chat.contents.TranslatableContents;

View file

@ -1,33 +1,23 @@
package dev.zontreck.otemod.commands.homes; package dev.zontreck.otemod.commands.homes;
import java.sql.Array;
import java.sql.Connection; import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
import java.sql.Statement;
import java.util.ArrayList;
import java.util.List;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.context.CommandContext;
import com.mojang.math.Vector3d;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.contents.TranslatableContents; import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.entity.player.Player;
import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3;
import net.minecraftforge.server.command.TextComponentHelper;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent; import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.Style;
import net.minecraft.network.chat.TextColor;
public class DelHomeCommand { public class DelHomeCommand {
public static void register(CommandDispatcher<CommandSourceStack> dispatcher) public static void register(CommandDispatcher<CommandSourceStack> dispatcher)
@ -50,8 +40,10 @@ public class DelHomeCommand {
if(! ctx.isPlayer()) if(! ctx.isPlayer())
{ {
Style s = Style.EMPTY.withColor(TextColor.parseColor(ChatColor.DARK_RED)).withFont(Style.DEFAULT_FONT);
ChatServerOverride.broadcastTo(ctx.getPlayer().getUUID(), Component.literal(ChatColor.DARK_RED).append(Component.translatable("dev.zontreck.otemod.msgs.only_player")), ctx.getServer());
ChatServerOverride.broadcastTo(ctx.getPlayer().getUUID(), Component.translatable("dev.zontreck.otemod.msgs.only_player").withStyle(s), ctx.getServer());
return 1; return 1;
} }
ServerPlayer p = ctx.getPlayer(); ServerPlayer p = ctx.getPlayer();

View file

@ -10,8 +10,8 @@ import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.exceptions.CommandSyntaxException; import com.mojang.brigadier.exceptions.CommandSyntaxException;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.commands.teleport.TeleportActioner; import dev.zontreck.otemod.commands.teleport.TeleportActioner;
import dev.zontreck.otemod.commands.teleport.TeleportContainer; import dev.zontreck.otemod.commands.teleport.TeleportContainer;
@ -20,14 +20,14 @@ import dev.zontreck.otemod.exceptions.InvalidDeserialization;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.nbt.NbtUtils; import net.minecraft.nbt.NbtUtils;
import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.resources.ResourceLocation; import net.minecraft.resources.ResourceLocation;
import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerLevel;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent; import net.minecraft.network.chat.Style;
import net.minecraft.network.chat.TextColor;
public class HomeCommand { public class HomeCommand {
public static void register(CommandDispatcher<CommandSourceStack> dispatcher) public static void register(CommandDispatcher<CommandSourceStack> dispatcher)
@ -122,7 +122,9 @@ public class HomeCommand {
if(!has_home)throw new SQLException("NO HOME"); if(!has_home)throw new SQLException("NO HOME");
ctx.sendSuccess(MutableComponent.create(new TranslatableContents("dev.zontreck.otemod.msgs.homes.goto.success")), true); Style sxx = Style.EMPTY.withColor(TextColor.parseColor(ChatColor.DARK_GREEN)).withFont(Style.DEFAULT_FONT);
ctx.sendSuccess(Component.translatable("dev.zontreck.otemod.msgs.homes.goto.success").withStyle(sxx), true);
con.endRequest(); con.endRequest();
} catch (SQLException e) { } catch (SQLException e) {
// TODO Auto-generated catch block // TODO Auto-generated catch block

View file

@ -1,6 +1,5 @@
package dev.zontreck.otemod.commands.homes; package dev.zontreck.otemod.commands.homes;
import java.sql.Array;
import java.sql.Connection; import java.sql.Connection;
import java.sql.ResultSet; import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
@ -11,26 +10,18 @@ import java.util.List;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.context.CommandContext; import com.mojang.brigadier.context.CommandContext;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.Clickable;
import dev.zontreck.libzontreck.chat.HoverTip;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.Clickable;
import dev.zontreck.otemod.chat.HoverTip;
import net.minecraft.ChatFormatting;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.contents.TranslatableContents; import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.entity.player.Player;
import net.minecraft.world.item.WrittenBookItem;
import net.minecraft.world.item.Item.Properties;
import net.minecraftforge.server.command.TextComponentHelper;
import net.minecraft.network.chat.ClickEvent;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.HoverEvent;
import net.minecraft.network.chat.MutableComponent; import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.Style; import net.minecraft.network.chat.Style;
import net.minecraft.network.chat.TextColor;
public class HomesCommand { public class HomesCommand {
public static void register(CommandDispatcher<CommandSourceStack> dispatcher) public static void register(CommandDispatcher<CommandSourceStack> dispatcher)

View file

@ -1,36 +1,24 @@
package dev.zontreck.otemod.commands.homes; package dev.zontreck.otemod.commands.homes;
import java.sql.Array;
import java.sql.Connection; import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
import java.sql.Statement;
import java.util.ArrayList;
import java.util.List;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.context.CommandContext;
import com.mojang.math.Vector3d;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.containers.Vector2; import dev.zontreck.otemod.containers.Vector2;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;
import dev.zontreck.otemod.database.TeleportDestination; import dev.zontreck.otemod.database.TeleportDestination;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.entity.player.Player;
import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;
import net.minecraftforge.server.command.TextComponentHelper;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent;
public class SetHomeCommand { public class SetHomeCommand {
public static void register(CommandDispatcher<CommandSourceStack> dispatcher) public static void register(CommandDispatcher<CommandSourceStack> dispatcher)

View file

@ -2,10 +2,10 @@ package dev.zontreck.otemod.commands.profilecmds;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -2,9 +2,9 @@ package dev.zontreck.otemod.commands.profilecmds;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -3,9 +3,8 @@ package dev.zontreck.otemod.commands.profilecmds;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -2,9 +2,9 @@ package dev.zontreck.otemod.commands.profilecmds;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -3,14 +3,12 @@ package dev.zontreck.otemod.commands.profilecmds;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatColor.ColorOptions;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraftforge.server.command.EnumArgument;
public class PrefixCommand { public class PrefixCommand {

View file

@ -8,12 +8,10 @@ import java.util.UUID;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.BoolArgumentType; import com.mojang.brigadier.arguments.BoolArgumentType;
import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.commands.CommandRegistry;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
@ -23,7 +21,6 @@ import net.minecraft.server.level.ServerLevel;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.Blocks;
import net.minecraft.world.level.block.DoubleBlockCombiner.BlockType;
import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;

View file

@ -1,14 +1,12 @@
package dev.zontreck.otemod.commands.teleport; package dev.zontreck.otemod.commands.teleport;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.ArgumentType;
import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.Clickable;
import dev.zontreck.libzontreck.chat.HoverTip;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.Clickable;
import dev.zontreck.otemod.chat.HoverTip;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -1,14 +1,12 @@
package dev.zontreck.otemod.commands.teleport; package dev.zontreck.otemod.commands.teleport;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.ArgumentType;
import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.Clickable;
import dev.zontreck.libzontreck.chat.HoverTip;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.Clickable;
import dev.zontreck.otemod.chat.HoverTip;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -5,8 +5,8 @@ import java.util.UUID;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -5,8 +5,8 @@ import java.util.UUID;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -5,8 +5,8 @@ import java.util.UUID;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;

View file

@ -1,11 +1,6 @@
package dev.zontreck.otemod.commands.vaults; package dev.zontreck.otemod.commands.vaults;
import java.util.UUID;
import javax.annotation.Nullable;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.IntegerArgumentType;
import dev.zontreck.otemod.implementation.VaultContainer; import dev.zontreck.otemod.implementation.VaultContainer;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;

View file

@ -1,9 +1,5 @@
package dev.zontreck.otemod.commands.vaults; package dev.zontreck.otemod.commands.vaults;
import java.util.UUID;
import javax.annotation.Nullable;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.IntegerArgumentType; import com.mojang.brigadier.arguments.IntegerArgumentType;

View file

@ -3,13 +3,12 @@ package dev.zontreck.otemod.commands.warps;
import java.sql.Connection; import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.SQLException; import java.sql.SQLException;
import java.sql.Statement;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.containers.Vector2; import dev.zontreck.otemod.containers.Vector2;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;
@ -17,8 +16,6 @@ import dev.zontreck.otemod.database.TeleportDestination;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;

View file

@ -3,13 +3,12 @@ package dev.zontreck.otemod.commands.warps;
import java.sql.Connection; import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.SQLException; import java.sql.SQLException;
import java.sql.Statement;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.containers.Vector2; import dev.zontreck.otemod.containers.Vector2;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;
@ -17,8 +16,6 @@ import dev.zontreck.otemod.database.TeleportDestination;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;

View file

@ -3,13 +3,12 @@ package dev.zontreck.otemod.commands.warps;
import java.sql.Connection; import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.SQLException; import java.sql.SQLException;
import java.sql.Statement;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.containers.Vector2; import dev.zontreck.otemod.containers.Vector2;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;
@ -17,8 +16,6 @@ import dev.zontreck.otemod.database.TeleportDestination;
import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands; import net.minecraft.commands.Commands;
import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.MutableComponent;
import net.minecraft.network.chat.contents.TranslatableContents;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.phys.Vec2; import net.minecraft.world.phys.Vec2;
import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.Vec3;

View file

@ -7,10 +7,10 @@ import java.sql.ResultSet;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType; import com.mojang.brigadier.arguments.StringArgumentType;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.Clickable;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.Clickable;
import dev.zontreck.otemod.commands.teleport.RTPCommand; import dev.zontreck.otemod.commands.teleport.RTPCommand;
import dev.zontreck.otemod.commands.teleport.TeleportActioner; import dev.zontreck.otemod.commands.teleport.TeleportActioner;
import dev.zontreck.otemod.commands.teleport.TeleportContainer; import dev.zontreck.otemod.commands.teleport.TeleportContainer;

View file

@ -7,11 +7,11 @@ import java.sql.SQLException;
import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.CommandDispatcher;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.libzontreck.chat.Clickable;
import dev.zontreck.libzontreck.chat.HoverTip;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import dev.zontreck.otemod.chat.Clickable;
import dev.zontreck.otemod.chat.HoverTip;
import dev.zontreck.otemod.configs.Profile; import dev.zontreck.otemod.configs.Profile;
import dev.zontreck.otemod.containers.Vector2; import dev.zontreck.otemod.containers.Vector2;
import dev.zontreck.otemod.containers.Vector3; import dev.zontreck.otemod.containers.Vector3;

View file

@ -4,8 +4,8 @@ import java.sql.Connection;
import java.sql.PreparedStatement; import java.sql.PreparedStatement;
import java.sql.SQLException; import java.sql.SQLException;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import net.minecraft.server.level.ServerPlayer; import net.minecraft.server.level.ServerPlayer;
public class Profile { public class Profile {

View file

@ -12,8 +12,8 @@ import org.mariadb.jdbc.export.Prepare;
import com.mojang.brigadier.exceptions.CommandSyntaxException; import com.mojang.brigadier.exceptions.CommandSyntaxException;
import dev.zontreck.libzontreck.chat.ChatColor;
import dev.zontreck.otemod.OTEMod; import dev.zontreck.otemod.OTEMod;
import dev.zontreck.otemod.chat.ChatColor;
import dev.zontreck.otemod.chat.ChatServerOverride; import dev.zontreck.otemod.chat.ChatServerOverride;
import net.minecraft.core.BlockPos; import net.minecraft.core.BlockPos;
import net.minecraft.nbt.CompoundTag; import net.minecraft.nbt.CompoundTag;

View file

@ -3,15 +3,11 @@ package dev.zontreck.otemod.implementation;
import java.util.Map; import java.util.Map;
import java.util.UUID; import java.util.UUID;
import dev.zontreck.otemod.chat.HoverTip;
import dev.zontreck.otemod.implementation.inits.MenuInitializer; import dev.zontreck.otemod.implementation.inits.MenuInitializer;
import net.minecraft.core.BlockPos; import net.minecraft.core.BlockPos;
import net.minecraft.world.Container;
import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.entity.player.Inventory;
import net.minecraft.world.entity.player.Player; import net.minecraft.world.entity.player.Player;
import net.minecraft.world.inventory.AbstractContainerMenu; import net.minecraft.world.inventory.AbstractContainerMenu;
import net.minecraft.world.inventory.ClickType;
import net.minecraft.world.inventory.ContainerLevelAccess;
import net.minecraft.world.inventory.MenuConstructor; import net.minecraft.world.inventory.MenuConstructor;
import net.minecraft.world.inventory.Slot; import net.minecraft.world.inventory.Slot;
import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.ItemStack;

View file

@ -19,7 +19,7 @@ modId="otemod" #mandatory
# The version number of the mod - there's a few well known ${} variables useable here or just hardcode it # The version number of the mod - there's a few well known ${} variables useable here or just hardcode it
# ${file.jarVersion} will substitute the value of the Implementation-Version as read from the mod's JAR file metadata # ${file.jarVersion} will substitute the value of the Implementation-Version as read from the mod's JAR file metadata
# see the associated build.gradle script for how to populate this completely automatically during a build # see the associated build.gradle script for how to populate this completely automatically during a build
version="1.3.3.7" #mandatory version="1.3.4.0" #mandatory
# A display name for the mod # A display name for the mod
displayName="OTEMod Resources" #mandatory displayName="OTEMod Resources" #mandatory
# A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/ # A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/