diff options
author | metamuffin <metamuffin@disroot.org> | 2025-01-12 00:57:58 +0100 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2025-01-12 00:57:58 +0100 |
commit | c810b040f875333fb9b1fe5d2269ba08d0c878f2 (patch) | |
tree | f8b93771cab1d736d04156a6a82ea961bd6c3d7b /shared/src/helper.rs | |
parent | e4500d6bbd512d2744916c8288a8c423af21416f (diff) | |
download | weareserver-c810b040f875333fb9b1fe5d2269ba08d0c878f2.tar weareserver-c810b040f875333fb9b1fe5d2269ba08d0c878f2.tar.bz2 weareserver-c810b040f875333fb9b1fe5d2269ba08d0c878f2.tar.zst |
switch to 32-bit index format
Diffstat (limited to 'shared/src/helper.rs')
-rw-r--r-- | shared/src/helper.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/shared/src/helper.rs b/shared/src/helper.rs index 61e149f..4702aef 100644 --- a/shared/src/helper.rs +++ b/shared/src/helper.rs @@ -104,7 +104,7 @@ impl ReadWrite for Vec<Vec2> { .collect()) } } -impl ReadWrite for Vec<[u16; 3]> { +impl ReadWrite for Vec<[u32; 3]> { fn write(&self, w: &mut dyn Write) -> Result<()> { for e in self { w.write_all(&e[0].to_be_bytes())?; @@ -118,8 +118,8 @@ impl ReadWrite for Vec<[u16; 3]> { r.read_to_end(&mut buf)?; Ok(buf .into_iter() - .array_chunks::<2>() - .map(u16::from_be_bytes) + .array_chunks::<4>() + .map(u32::from_be_bytes) .array_chunks::<3>() .collect()) } |