Post by teritha on Oct 5, 2023 8:57:53 GMT -5
I have encountered an issue with Sims 4 Studio when saving a package that contains a deformer map / slider.
An existing/downloaded slider package can be opened in Sims 4 Studio and all of its details can be read, including the Data tab for the Deformer Map entries.
However, if the package is saved (even with no changes made) and re-opened in Sims 4 Studio, the Data tab for the Deformer Map entries produces one of the below 2 errors.
This only appears to happen for a Deformer Map entry that has items listed in ScanLines, even if there is only 1 item. If there are no items in ScanLines then it will not produce an error in the new package.
Error 1:
System.IndexOutOfRangeException: Index was outside the bounds of the array.
at S4Studio.Data.IO.Images.DeformerMapResource.DecompressPixelData()
at S4Studio.Data.IO.Images.DeformerMapResource.Read(Stream stream, IReferenceList resources)
at S4Studio.Data.IO.Package.DBPFPackage.FetchResource(Type t, IDBPFResourcePointer index, Boolean nocache)
at S4Studio.ViewModels.Warehouse.WarehouseResourceViewModelBase.GetWrappedResource()
Error 2:
System.IO.EndOfStreamException: Attempted to read past the end of the stream.
at S4Studio.Data.IO.Util.BinaryStreamWrapper.GetBytes(Int32 count, ByteOrder order)
at S4Studio.Data.IO.Images.DeformerMapResource.Read(Stream stream, IReferenceList resources)
at S4Studio.Data.IO.Package.DBPFPackage.FetchResource(Type t, IDBPFResourcePointer index, Boolean nocache)
at S4Studio.ViewModels.Warehouse.WarehouseResourceViewModelBase.GetWrappedResource()
Tested in:
Sims 4 Studio 3.1.6.1 (Wishes)
Sims 4 Studio 3.1.6.3 (Wishes)
Sims 4 Studio 3.2.1.2 (Star)
Tested against:
Sims 4 Studio 3.1.6.1 (Wishes)
Sims 4 Studio 3.1.6.3 (Wishes)
Sims 4 Studio 3.2.1.2 (Star)
Tested against:
The Sims 4 with all DLC
The Sims 4 with no DLC (fresh install and never started)
Screenshot showing error 1:
Screenshot showing error 2:
Screenshot showing ScanLines (as an example):