diff --git a/Cargo.lock b/Cargo.lock index fb89d51..60ed38a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -569,6 +569,7 @@ checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "reliquary" version = "5.0.0" +source = "git+https://github.com/IceDynamix/reliquary?tag=v5.0.0#6eb51e0310bfefdcb9124221ceb9e0f7c058110b" dependencies = [ "base64", "etherparse", @@ -601,6 +602,7 @@ dependencies = [ [[package]] name = "reliquary-proc-macro" version = "0.1.0" +source = "git+https://github.com/IceDynamix/reliquary?tag=v5.0.0#6eb51e0310bfefdcb9124221ceb9e0f7c058110b" dependencies = [ "quote", "syn", diff --git a/src/main.rs b/src/main.rs index 4c04cef..6dbafbb 100644 --- a/src/main.rs +++ b/src/main.rs @@ -204,7 +204,7 @@ where if commands.is_empty() { invalid += 1; - if invalid >= 50 && !warning_sent { + if invalid >= 100 && !warning_sent { error!( "received a large number of packets that could not be parsed" ); @@ -215,7 +215,7 @@ where warning_sent = true; } } else { - invalid -= 10; + invalid = 0.max(invalid - 1); for command in commands { if command.command_id == PlayerLoginScRsp {