fix: only look at non-null bytes

This commit is contained in:
Anna Clemens 2021-03-03 21:10:46 -05:00
parent 66b4d19603
commit 5dde360e02
No known key found for this signature in database
GPG key ID: 0B391D8F06FCD9E0

View file

@ -256,8 +256,8 @@ namespace Dalamud.Game.Internal.Gui.Structs {
this.jobsPresent = listing.jobsPresent;
Id = listing.id;
Name = seStringManager.Parse(listing.name);
Description = seStringManager.Parse(listing.description);
Name = seStringManager.Parse(listing.name.TakeWhile(b => b != 0).ToArray());
Description = seStringManager.Parse(listing.description.TakeWhile(b => b != 0).ToArray());
World = new Lazy<World>(() => dataManager.GetExcelSheet<World>().GetRow(listing.world));
HomeWorld = new Lazy<World>(() => dataManager.GetExcelSheet<World>().GetRow(listing.homeWorld));
CurrentWorld = new Lazy<World>(() => dataManager.GetExcelSheet<World>().GetRow(listing.currentWorld));