From 530bb7875c0654aa13f91d22580aa09408bb3626 Mon Sep 17 00:00:00 2001 From: andy Date: Wed, 6 Jul 2022 22:39:06 +0000 Subject: [PATCH] veryimportantnull probably --- src/packet/ship.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/packet/ship.rs b/src/packet/ship.rs index 0995449..0db8c55 100644 --- a/src/packet/ship.rs +++ b/src/packet/ship.rs @@ -292,7 +292,10 @@ pub struct SmallLeftDialog { } impl SmallLeftDialog { - pub fn new(msg: String) -> SmallLeftDialog { + pub fn new(mut msg: String) -> SmallLeftDialog { + if !msg.ends_with('\0') { + msg.push('\0'); + } SmallLeftDialog { padding: [0x00004500, 0x45004500], msg: msg, -- 2.36.0