Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 55 additions & 13 deletions FileFormats/map_Gamedata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,26 @@
</InternalCompression>
<Converts>
<Convert Path ="//AreaManagerData/None[text()]" Type="Int16" />

<!-- SessionSettings -->
<Convert Path ="//GlobalAmbientName" Type ="String"/>
<Convert Path ="//PlayableArea" Type ="Int32" Structure="List"/>
<Convert Path ="//HasFogOfWarGrid" Type ="Boolean"/>
<Convert Path ="//VegetationPropSetName" Type ="String" Encoding="UTF-8"/>

<Convert Path ="//WorldSize" Type ="Int32" Structure="List"/>

<!-- HeightMap is (mapsize*2+1)^2 times 0000 -->
<Convert Path ="//HeightMap/HeightMap" Type ="Int16" Structure="List"/>
<Convert Path ="//View/*" Type ="Single" Structure="List"/>
<Convert Path ="//val" Type ="Byte" Structure="List"/>
<Convert Path ="//block/mode" Type ="Boolean"/>

<!-- AreaIDs/val is 0100 (little endian 1) repeated for mapsize^2 times -->
<Convert Path ="//AreaIDs/val" Type ="Int16" Structure="List"/>
<!-- EnvironmentGrid is 1 byte per tile, streets is 1 byte mapsize^2 times -->
<Convert Path ="//*[not(self::AreaIDs)]/val" Type ="Byte" Structure="List"/>


<!-- WaterGrid and RiverGrid bits are 1 bit mapsize^2 times -->
<Convert Path ="//bits" Type ="Byte" Structure="List"/>
<Convert Path ="//GameObjectIDCounter" Type ="Int64"/>
<Convert Path ="//NonGameObjectIDCounter" Type ="Int64"/>
Expand All @@ -21,25 +34,52 @@

<Convert Path ="//GameObjectLabelMap/None[position() mod 2 = 1]" Type="String" Encoding="UTF-8"/>
<Convert Path ="//GameObjectLabelMap/None[position() mod 2 = 0]" Type="Int64"/><!-- maybe -->

<!-- SpawnAreaPoints -->
<Convert Path ="//SpawnAreaPoints/None[position() mod 2 = 1]" Type="Byte"/> <!-- maybe -->
<Convert Path ="//SpawnAreaPoints/None[position() mod 2 = 0]/*[self::m_AreaPointGrid or self::m_AreaRect]/None[position() mod 2 = 1]" Type="Int32"/>
<Convert Path ="//SpawnAreaPoints/None[position() mod 2 = 0]/*[self::m_AreaPointGrid or self::m_AreaRect]/None[position() mod 2 = 0]" Type="Int32" Structure="List"/> <!-- maybe -->

<!-- Sparse Grid -->
<Convert Path ="//SparseEnabled" Type ="Boolean" />
<Convert Path ="//StreetMap/VarMapData/block/*[self::x or self::y]" Type ="Int16" />
<Convert Path ="//id" Type ="Int16" />
<Convert Path ="//ID" Type ="Int64" />

<Convert Path ="//SpawnAreaPoints/None[position() mod 2 = 1]" Type="Byte"/>
<!-- maybe -->
<Convert Path ="//block/*[self::x or self::y]" Type ="Int16" />
<Convert Path ="//block/mode" Type ="Byte"/>
<Convert Path ="//block/default" Type="Byte" Structure="List" />
<Convert Path ="//block/values" Type="Byte" Structure="List" />

<!-- Default ID and id fields -->
<Convert Path ="//*[not(self::Asset)]/id" Type ="Int16" />
<Convert Path ="//*[self::ID and not(ancestor::Sequence)]" Type ="Int64" />

<!-- Positons and stuff-->
<Convert Path ="//*[not(self::View)]/Direction" Type ="Single" Structure ="List" />
<Convert Path ="//Position" Type ="Single" Structure ="List" />
<Convert Path ="//Orientation" Type ="Single" Structure ="List" />
<Convert Path ="//BasePosition" Type ="Int32" Structure="List" />

<Convert Path ="//BasePosition" Type ="Single" Structure="List" />

<!-- Camera Sequences and Stuff -->
<Convert Path ="//Sequence/Name" Type="String" Encoding="UTF-8"/>
<Convert Path ="//*[self::ID and ancestor::Sequence]" Type ="Int32" />
<Convert Path ="//Sequence/Asset/id" Type ="Int32" /> <!-- In the Sunken Treasures map, there is one Asset with both ID and id -->
<Convert Path ="//Sequence/Asset/objectlink" Type ="Int64" /> <!-- this is probably an object ID -->
<Convert Path ="//TangentIn" Type ="Single" Structure ="List" />
<Convert Path ="//TangentOut" Type ="Single" Structure ="List" />
<Convert Path ="//Interpolation" Type ="Byte" />
<Convert Path ="//ManualTangentMode" Type ="Byte" />
<Convert Path ="//BreakableFirstLastTangents" Type ="Byte" Structure="List"/>
<Convert Path ="//SameWeightFirstLastTangents" Type ="Byte" Structure="List"/>
<Convert Path ="//KeyframeTypeVisibility/None" Type="Byte"/>

<!-- ObjectGroupCollection -->
<Convert Path ="//ObjectGroups/None[position() mod 2 = 1]" Type="String" Encoding="UTF-8"/> <!-- maybe -->
<Convert Path ="//GameObjects/None" Type="Int64"/> <!-- maybe -->

<!-- Game Object Properties-->
<Convert Path ="//SonarEnd" Type ="Int64"/>
<Convert Path ="//CommandQueue/StateParams/*[self::Object or self::AttachObject]/ObjectID" Type ="Int64" />
<Convert Path ="//CommandQueue/StateParams/EscortedObjectMetaID" Type ="Int64" />
<Convert Path ="//OptimalAttackMovementData/OptimalAngleWS" Type ="Single" />
<Convert Path ="//OptimalAttackMovementData/OptimalDistanceWS" Type ="Single" />
<Convert Path ="//Draggable/Dragger" Type="Int64" />
<Convert Path ="//Mesh/SequenceData/CurrentSequenceStartTime" Type ="Int64" />
<Convert Path ="//FeedbackController/SequenceStartTime" Type ="Int64" />
Expand All @@ -51,9 +91,9 @@
<Convert Path ="//PropertyTradeRouteVehicle/TargetLoadingHarbour" Type ="Int64" />

<Convert Path ="//Walking/Reservation/RectSize" Type ="Int64" Structure="List"/>
<Convert Path ="//Walking/LastPos" Type ="Int32" Structure="List"/>
<Convert Path ="//Walking/LastWaystepPos" Type ="Int32" Structure="List"/>
<Convert Path ="//Walking/LastTickPos" Type ="Int32" Structure="List"/>
<Convert Path ="//Walking/LastPos" Type ="Single" Structure="List"/>
<Convert Path ="//Walking/LastWaystepPos" Type ="Single" Structure="List"/>
<Convert Path ="//Walking/LastTickPos" Type ="Single" Structure="List"/>
<Convert Path ="//Walking/LastDirView" Type ="Single"/>
<Convert Path ="//Walking/LastDirLogic" Type ="Single"/>
<Convert Path ="//Walking/LastDeltaDirDelta" Type ="Single"/>
Expand All @@ -64,5 +104,7 @@
<Convert Path ="//UpgradeList/HasElectricity" Type="Boolean"/>

<Convert Path ="//QuestObject/ObjectWasVisible/None" Type="Boolean" />
<Convert Path ="//AmbientAreaName" Type="String" />

</Converts>
</Converts>