From 1b082de8dea753d167cc6df349a6c942c2577f55 Mon Sep 17 00:00:00 2001 From: BlackDragon-B Date: Sun, 25 Feb 2024 20:49:19 +0100 Subject: [PATCH] fdfdgsdfsdf fixed checksum --- src/wacca.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wacca.rs b/src/wacca.rs index 7826f77..9544200 100644 --- a/src/wacca.rs +++ b/src/wacca.rs @@ -16,8 +16,8 @@ impl UnitBoardVersionPacket<'_> { for v in &self.unit_board_version { s.append(&mut v.as_bytes().to_vec()); } - //s.push(calc_checksum(&s)); - if self.side {s.push(104)} else {s.push(118)}; + s.push(calc_checksum(&[s.as_slice(),vec![0x80].as_slice()].concat())); + //if self.side {s.push(104)} else {s.push(118)}; s } }