From fd1630185e23a1d1cc7a035dc661fdb3ebad8fbd Mon Sep 17 00:00:00 2001 From: FryingPan Date: Thu, 4 Aug 2022 23:42:59 -0400 Subject: [PATCH] added some useful comments removed unused imports --- build.hxml | 1 + src/Connection.hx | 1 - src/UnitTest.hx | 6 +++++- src/entity/Player.hx | 2 -- src/packet/clientbound/LoginSuccessPacket.hx | 2 -- src/packet/clientbound/StatusResponsePacket.hx | 1 - src/packet/serverbound/HandshakePacket.hx | 1 - src/packet/serverbound/LoginStartPacket.hx | 1 - src/packet/serverbound/PingRequestPacket.hx | 1 - 9 files changed, 6 insertions(+), 10 deletions(-) diff --git a/build.hxml b/build.hxml index 65c7011..5d25f29 100644 --- a/build.hxml +++ b/build.hxml @@ -1,5 +1,6 @@ -p src -m Main -L uuid +# i might remove `uuid` as a dependancy at some point --cpp ./build/ --cmd ./test.sh \ No newline at end of file diff --git a/src/Connection.hx b/src/Connection.hx index 6336c8b..fedd388 100644 --- a/src/Connection.hx +++ b/src/Connection.hx @@ -15,7 +15,6 @@ import packet.serverbound.HandshakePacket; import haxe.io.Output; import haxe.io.Input; import packet.serverbound.ServerboundPacket; -import cpp.vm.Debugger.ThreadInfo; import sys.thread.Thread; import sys.net.Socket; diff --git a/src/UnitTest.hx b/src/UnitTest.hx index e63510b..49fe755 100644 --- a/src/UnitTest.hx +++ b/src/UnitTest.hx @@ -2,11 +2,15 @@ package; import haxe.io.BytesOutput; import haxe.io.BytesInput; -import haxe.io.Bytes; using StringTools; using VarIntLong; + +/** + i made this to sanity check my parsing of var ints. it worked fine. + but this testing code sucks and should probably be improved at some point +**/ class UnitTest { public static function main() { testVarInt(0); diff --git a/src/entity/Player.hx b/src/entity/Player.hx index faab0ed..1b0ad06 100644 --- a/src/entity/Player.hx +++ b/src/entity/Player.hx @@ -1,7 +1,5 @@ package entity; -import uuid.Uuid; - class Player extends Entity { public var uuid:String; public var name:String; diff --git a/src/packet/clientbound/LoginSuccessPacket.hx b/src/packet/clientbound/LoginSuccessPacket.hx index 1e0a52d..d2aa0b9 100644 --- a/src/packet/clientbound/LoginSuccessPacket.hx +++ b/src/packet/clientbound/LoginSuccessPacket.hx @@ -1,7 +1,5 @@ package packet.clientbound; -import haxe.io.BytesOutput; - using VarIntLong; class LoginSuccessPacket extends ClientboundPacket { diff --git a/src/packet/clientbound/StatusResponsePacket.hx b/src/packet/clientbound/StatusResponsePacket.hx index 078b30c..2083aad 100644 --- a/src/packet/clientbound/StatusResponsePacket.hx +++ b/src/packet/clientbound/StatusResponsePacket.hx @@ -2,7 +2,6 @@ package packet.clientbound; import haxe.io.BytesOutput; import haxe.Json; -import haxe.io.Output; using VarIntLong; diff --git a/src/packet/serverbound/HandshakePacket.hx b/src/packet/serverbound/HandshakePacket.hx index e746965..ca31a02 100644 --- a/src/packet/serverbound/HandshakePacket.hx +++ b/src/packet/serverbound/HandshakePacket.hx @@ -1,6 +1,5 @@ package packet.serverbound; -import packet.clientbound.StatusResponsePacket; import haxe.io.Input; using VarIntLong; diff --git a/src/packet/serverbound/LoginStartPacket.hx b/src/packet/serverbound/LoginStartPacket.hx index 75c022a..d234357 100644 --- a/src/packet/serverbound/LoginStartPacket.hx +++ b/src/packet/serverbound/LoginStartPacket.hx @@ -2,7 +2,6 @@ package packet.serverbound; import haxe.Int64; import haxe.io.Bytes; -import haxe.io.Input; using VarIntLong; diff --git a/src/packet/serverbound/PingRequestPacket.hx b/src/packet/serverbound/PingRequestPacket.hx index c237478..9fb518e 100644 --- a/src/packet/serverbound/PingRequestPacket.hx +++ b/src/packet/serverbound/PingRequestPacket.hx @@ -1,7 +1,6 @@ package packet.serverbound; import haxe.io.Bytes; -import haxe.Int64; import haxe.io.Input; class PingRequestPacket extends ServerboundPacket {