feat(parser): deep-parse v1.2 ArrayProperty<StructProperty>#8
Merged
Merged
Conversation
The v1.2 RawProperty path already deep-parses ArrayProperty<ObjectProperty> (see PropertySerializer.cs:240) but falls through to the binary-size fence for ArrayProperty<StructProperty>, leaving callers with unparseable bytes. That's the gap blocking ERP.Satisfactory #138: pipe actors carry `mSplineData` as Array<Struct<FSplinePointData>>, and the app can't render pipe polylines without those inner property lists. Wire format at v1.2 (inferred from the existing Array<Object> branch and Unreal property conventions): the inner-tag header that v1.1 carried before the element loop is gone — the struct subtype name lives in TypeNode.Children[0] (e.g. "SplinePointData"). Value bytes are int32 count, then `count` element bodies, each a v1.2 property-list terminated by "None". No per-element serializationControl byte (those only prefix the outer object body). Changes - RawProperty: new `ArrayStructValues` slot exposing `StructElementValue` entries (each carries the inner Property list). - PropertySerializer: new `IsStructChild` predicate + Array<Struct> branch in TryParseKnownValue. Reads count, drains v1.2 property-lists per element, respects the outer binarySize fence to recover if the format guess is off (ArrayStructValues stays null on misread). - Threaded `Header` into TryParseKnownValue so the inner DeserializeProperty loop can resolve struct sub-property reads that need header context. Tests - PropertySerializerV12Tests: ArrayOfStruct_ParsesElementsAsInnerPropertyLists — two elements, each one IntProperty + "None" terminator; verifies inner values and that the outer fence aligns to the post-value sentinel. - ArrayOfStruct_EmptyArray_ProducesEmptyValuesList — count=0 fast path. - All 137 existing tests continue to pass. Downstream: unblocks ERP.Satisfactory #138 (pipe polylines via Pipeline.Polyline) and lands the app on 0.4.0.
4 tasks
ChrisonSimtian
added a commit
to erp-for-factory-games/ErpForFactoryGames
that referenced
this pull request
May 17, 2026
The vendored fork now deep-parses `ArrayProperty<StructProperty>` at v1.2 (ChrisonSimtian/SatisfactorySaveNet#8 → 4.1.3) — pipe actors expose their `mSplineData` (`Array<Struct<FSplinePointData>>`) via the new `RawProperty.ArrayStructValues` slot. Wiring - Bump SatisfactorySaveNet + .Abstracts PackageReference 4.1.2 → 4.1.3. - New `TryGetArrayStructValues` helper on `ComponentObject`. - `SaveFileReader.ExtractPipePolyline` walks each spline element's inner property list, pulls the `Location` StructProperty's vector value, and builds the polyline. Pipes without spline data (legacy saves, isolated actors) keep `Polyline = null` and fall back to point-only rendering. - Updated `Pipeline.cs` xmldoc to reflect that the slot is now populated. Tests - `dotnet build` clean. - Full ERP test suite passes (Application 24, Catalog 18, Infrastructure 17, Save 33, Persistence 9, Web.UiTests 9). - Fork-side coverage: PropertySerializerV12Tests adds ArrayOfStruct_ParsesElementsAsInnerPropertyLists and ArrayOfStruct_EmptyArray_ProducesEmptyValuesList (137 fork tests pass). This is the 0.4.0 milestone feature — pipes now render as LineStrings in the GeoJSON map alongside conveyor belts. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ArrayProperty<StructProperty>(e.g.Array<Struct<FSplinePointData>>on pipe actors).RawProperty.ArrayStructValuesslot (IReadOnlyList<StructElementValue>), each carrying the inner v1.2 property list.ArrayStructValuesstays null).Wire format (inferred from the existing
Array<Object>branch)At v1.2, the inner-tag header that v1.1 carried before the element loop is gone — the struct subtype name lives in
TypeNode.Children[0](e.g."SplinePointData"). Value bytes areint32 count, thencountelement bodies, each a v1.2 property-list terminated by"None". No per-elementserializationControlbyte.Test plan
dotnet build -c Releasegreen (Abstracts + main + tests projects)ArrayOfStruct_ParsesElementsAsInnerPropertyLists— two elements, IntProperty inner +"None"; verifies inner values and outer fenceArrayOfStruct_EmptyArray_ProducesEmptyValuesList— count=0 fast pathDownstream
Unblocks ERP.Satisfactory #138 (pipe polylines via
Pipeline.Polyline) and lands the app on 0.4.0.