Modding:Save File Format: Difference between revisions

From the Dyson Sphere Program Wiki
imported>76561198054818918
(Added up through CargoTraffic)
imported>76561198045853337
mNo edit summary
 
(35 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{WIP}}
This page defines the Dyson Sphere Program save file format .dsv.  On Windows by default save files are stored in <code>%USERPROFILE%\Documents\Dyson Sphere Program\Save\</code>.


This page defines the Dyson Sphere Program save file format .dsv. On Windows by default save files are stored in %USERPROFILE%\Documents\Dyson Sphere Program\Save\.
Return to [[Modding:Modding|Modding Hub]].
 
A save file parser in C++ written to the specification below is available on GitHub: [https://github.com/GreyHak/dsp-save-parser github.com/GreyHak/dsp-save-parser].
 
<syntaxhighlight lang="csharp">
float oilSpeedMultiplier = 4E-05f


<syntaxhighlight lang="cpp">
GameSave
GameSave
{
{
     "VFSAVE"
     "VFSAVE"
     int64_t fileStreamLength
     int64 fileStreamLength
     int32_t saveFileFormatNumber = 4
     int32 saveFileFormatNumber = 4
     int32_t majorGameVersion
     int32 majorGameVersion
     int32_t minorGameVersion
     int32 minorGameVersion
     int32_t releaseGameVersion
     int32 releaseGameVersion
     int64_t gameTick
     int64 gameTick
     int64_t nowTicks
     int64 nowTicks
     int32_t sizeOfPngFile
     int32 sizeOfPngFile
     uint8_t screenShotPngFile[sizeOfPngFile]
     uint8 screenShotPngFile[sizeOfPngFile]
     GameData
     GameData
}
}
Line 21: Line 25:
GameData
GameData
{
{
     int32_t version = 2
     int32 version = 2
     string gameName
     string gameName
     GameDesc gameDesc
     GameDesc
     int64_t gameTick
     int64 gameTick
     GamePrefsData preferences (version >= 1)
     GamePrefsData preferences (version >= 1)
     GameHistoryData
     GameHistoryData
     uint8_t bool hidePlayerModel (version >= 2)
     uint8_bool hidePlayerModel (version >= 2)
     uint8_t bool disableController (version >= 2)
     uint8_bool disableController (version >= 2)
     GameStatData statistics
     GameStatData statistics
     int32_t planetId
     int32 planetId
     Player mainPlayer
     Player mainPlayer
     int32_t factoryCount
     int32 factoryCount
     GalacticTransport
     GalacticTransport
     PlanetFactory[factoryCount]
     PlanetFactory[factoryCount]
     int32_t galaxyStarCount: Must equal GameDesc::starCount or the game will crash.
     int32 galaxyStarCount: Must equal GameDesc::starCount or the game will crash.
    int32_t numDysonSpheres
     [galaxyStarCount] {
     [numDysonSpheres] {
         int32 dysonSphereDataIsAvailableFlag: Must be 0 or 1 or the game will crash.
         int32_t dysonSphereDataIsAvailableFlag: Must be 0 or 1 or the game will crash.
         DysonSphere (dysonSphereDataIsAvailableFlag == 1)
         DysonSphere (dysonSphereDataIsAvailableFlag == 1)
     }
     }
Line 45: Line 48:
GameDesc
GameDesc
{
{
     int32_t version = 2
     int32 version = 2
     int32_t galaxyAlgo
     int32 galaxyAlgo
     int32_t galaxySeed
     int32 galaxySeed
     int32_t starCount
     int32 starCount
     int32_t playerProto
     int32 playerProto
     float resourceMultiplier (version >= 2)
     float resourceMultiplier (version >= 2)
     int32_t numThemeIds (version >= 1)
     int32 numThemeIds (version >= 1)
     int32_t themeIds[numThemeIds] (version >= 1)
     int32 themeIds[numThemeIds] (version >= 1)
}
}


GamePrefsData
GamePrefsData
{
{
     int32_t version = 2
     int32 version = 2
     double cameraUPosX
     double cameraUPos_x
     double cameraUPosY
     double cameraUPos_y
     double cameraUPosZ
     double cameraUPos_z
     float cameraURotX
     float cameraURot_x
     float cameraURotY
     float cameraURot_y
     float cameraURotZ
     float cameraURot_z
     float cameraURotW
     float cameraURot_w
     int32_t reformCursorSize (version >= 1)
     int32 reformCursorSize (version >= 1)
     int32_t numReplicatorMultipliers (version >= 1)
     int32 numReplicatorMultipliers (version >= 1)
     replicatorMultipliers[numReplicatorMultipliers] (version >= 1) {
     replicatorMultipliers[numReplicatorMultipliers] (version >= 1) {
         int32_t key
         int32 key
         int32_t value
         int32 value
     }
     }
     float bool detailPower
     uint8_bool detailPower
     float bool detailVein
     uint8_bool detailVein
     float bool detailSpaceGuide
     uint8_bool detailSpaceGuide
     float bool detailSign
     uint8_bool detailSign
     float bool detailIcon
     uint8_bool detailIcon
     int32_t numTutorialShowing (version >= 2)
     int32 numTutorialShowing (version >= 2)
     int32_t tutorialShowing[numTutorialShowing] (version >= 2)
     int32 tutorialShowing[numTutorialShowing] (version >= 2)
}
}


GameHistoryData
GameHistoryData
{
{
     int32_t version = 2
     int32 version = 2
     int32_t numRecipeUnlocked
     int32 numRecipeUnlocked
     int32_t recipeUnlocked[numRecipeUnlocked]
     int32 recipeUnlocked[numRecipeUnlocked]
     int32_t numTutorialUnlocked (version >= 2)
     int32 numTutorialUnlocked (version >= 2)
     int32_t tutorialUnlocked[numTutorialUnlocked] (version >= 2)
     int32 tutorialUnlocked[numTutorialUnlocked] (version >= 2)
     int32_t numFeatureKeys
     int32 numFeatureKeys
     int32_t featureKeys[numFeatureKeys]
     int32 featureKeys[numFeatureKeys]
     int32_t numTechState
     int32 numTechState
     [numTechState] {
     TechState[numTechState] {
         int32_t techProtoIndex
         int32 techProtoIndex
         uint8_t bool TechState_unlocked
         uint8_bool TechState_unlocked
         int32_t TechState_curLevel
         int32 TechState_curLevel
         int32_t TechState_maxLevel
         int32 TechState_maxLevel
         int64_t TechState_hashUploaded
         int64 TechState_hashUploaded
         int64_t TechState_hashNeeded
         int64 TechState_hashNeeded
     }
     }
     uint8_t bool autoManageLabItems
     uint8_bool autoManageLabItems
     int32_t currentTech
     int32 currentTech
     int32_t numTechQueue (version >= 1)
     int32 numTechQueue (version >= 1)
     int32_t techQueue_TechStateKey[numTechQueue]
     int32 techQueue[numTechQueue] (version >= 1)
     int32_t universeObserveLevel
     int32 universeObserveLevel
     float solarSailLife
     float solarSailLife
     float solarEnergyLossRate
     float solarEnergyLossRate
     uint8_t bool useIonLayer
     uint8_bool useIonLayer
     int32_t inserterStackCount
     int32 inserterStackCount
     float logisticDroneSpeed
     float logisticDroneSpeed
     float logisticDroneSpeedScale
     float logisticDroneSpeedScale
     int32_t logisticDroneCarries
     int32 logisticDroneCarries
     float logisticShipSailSpeed
     float logisticShipSailSpeed
     float logisticShipWarpSpeed
     float logisticShipWarpSpeed
     float logisticShipSpeedScale
     float logisticShipSpeedScale
     float bool logisticShipWarpDrive
     uint8_bool logisticShipWarpDrive
     int32_t logisticShipCarries
     int32 logisticShipCarries
     float miningCostRate
     float miningCostRate
     float miningSpeedScale
     float miningSpeedScale
     int32_t storageLevel
     int32 storageLevel
     int32_t labLevel
     int32 labLevel
     int32_t techSpeed
     int32 techSpeed
     float dysonNodeLatitude
     float dysonNodeLatitude
     int64_t universeMatrixPointUploaded
     int64 universeMatrixPointUploaded
     float bool missionAccomplished
     uint8_bool missionAccomplished
}
}


GameStatData
GameStatData
{
{
     int32_t version = 0
     int32 version = 0
     int32_t numTechHashedHistory
     int32 numTechHashedHistory
     int32_t techHashedHistory[numTechHashedHistory]
     int32 techHashedHistory[numTechHashedHistory]
     ProductionStatistics
     ProductionStatistics
}
}
Line 135: Line 138:
ProductionStatistics
ProductionStatistics
{
{
     int32_t version = 0
     int32 version = 0
     int32_t numFactoryStatPool
     int32 numFactoryStatPool
     FactoryProductionStat factoryStatPool[numFactoryStatPool]
     FactoryProductionStat factoryStatPool[numFactoryStatPool]
     int32_t numFirstCreateIds
     int32 numFirstCreateIds
     int32_t firstCreateIds[numFirstCreateIds]
     int32 firstCreateIds[numFirstCreateIds]
     int32_t numFavoriteIds
     int32 numFavoriteIds
     int32_t favoriteIds[numFavoriteIds]
     int32 favoriteIds[numFavoriteIds]
}
}


FactoryProductionStat
FactoryProductionStat
{
{
     int32_t version = 1
     int32 version = 1
     int32_t productCapacity
     int32 productCapacity
     int32_t productCursor
     int32 productCursor
     ProductStat productPool[productCursor]
     ProductStat productPool[productCursor - 1]
     int32_t numPowerPool, max 5
     int32 numPowerPool, max 5
     PowerStat powerPool[numPowerPool]
     PowerStat powerPool[numPowerPool]
     int32_t numProductIndices
     int32 numProductIndices
     int32_t productIndices[numProductIndices]
     int32 productIndices[numProductIndices]
     int64_t energyConsumption (version >= 1)
     int64 energyConsumption (version >= 1)
}
}


ProductStat
ProductStat
{
{
     int32_t version = 0
     int32 version = 0
     int32_t numCount:  Saved as 7200.  Reads more or less, but only stores up to 7200, and enforces abs.
     int32 numCount:  Saved as 7200.  Reads more or less, but only stores up to 7200, and enforces abs.
     int32_t count[numCount]
     int32 count[numCount]
     int32_t numCursor:  Saved as 12.  Reads more or less, but only stores up to 12.
     int32 numCursor:  Saved as 12.  Reads more or less, but only stores up to 12.
     int32_t cursor[numCount]
     int32 cursor[numCount]
     int32_t numTotal:  Saved as 14.  Reads more or less, but only stores up to 14, and enforces abs.
     int32 numTotal:  Saved as 14.  Reads more or less, but only stores up to 14, and enforces abs.
     int32_t total[numCount]
     int32 total[numCount]
     int32_t itemId
     int32 itemId
}
}


PowerStat
PowerStat
{
{
     int32_t version = 0
     int32 version = 0
     int32_t numEnergy:  Saved as 3600.  Reads more or less, but only stores up to 3600, and enforces abs.
     int32 numEnergy:  Saved as 3600.  Reads more or less, but only stores up to 3600, and enforces abs.
     int64_t energy[numCount]
     int64 energy[numCount]
     int32_t numCursor:  Saved as 6.  Reads more or less, but only stores up to 6.
     int32 numCursor:  Saved as 6.  Reads more or less, but only stores up to 6.
     int32_t cursor[numCount]
     int32 cursor[numCount]
     int32_t numTotal:  Saved as 7.  Reads more or less, but only stores up to 7, and enforces abs.
     int32 numTotal:  Saved as 7.  Reads more or less, but only stores up to 7, and enforces abs.
     int64_t total[numCount]
     int64 total[numCount]
    int32_t itemId
}
}


Player
Player
{
{
     int32_t version = 1
     int32 version = 1
     int32_t planetId: Ignored on read
     int32 planetId: Ignored on read
     float position_x
     float position_x
     float position_y
     float position_y
     float position_z
     float position_z
     float uPosition_x
     double uPosition_x
     float uPosition_y
     double uPosition_y
     float uPosition_z
     double uPosition_z
     float uRotation_x
     float uRotation_x
     float uRotation_y
     float uRotation_y
     float uRotation_z
     float uRotation_z
     float uRotation_w
     float uRotation_w
     int32_t EMovementState movementState (Walk, Drift, Fly, Sail)
     int32 EMovementState movementState (Walk, Drift, Fly, Sail)
     float warpState
     float warpState
     uint8_t bool warpCommand
     uint8_bool warpCommand
     double uVelocity_x
     double uVelocity_x
     double uVelocity_y
     double uVelocity_y
     double uVelocity_z
     double uVelocity_z
     int32_t inhandItemId
     int32 inhandItemId
     int32_t inhandItemCount
     int32 inhandItemCount
     Mecha
     Mecha
     StorageComponent package[10]
     StorageComponent package
     PlayerNavigation
     PlayerNavigation
     int32_t sandCount
     int32 sandCount
}
}


Mecha
Mecha
{
{
     int32_t version = 0
     int32 version = 0
     double coreEnergyCap
     double coreEnergyCap
     double coreEnergy
     double coreEnergy
Line 217: Line 219:
     double reactorPowerGen
     double reactorPowerGen
     double reactorEnergy
     double reactorEnergy
     int32_t reactorItemId
     int32 reactorItemId
     StorageComponent reactorStorage[4]
     StorageComponent reactorStorage
     StorageComponent warpStorage
     StorageComponent warpStorage
     double walkPower
     double walkPower
Line 230: Line 232:
     double droneEjectEnergy
     double droneEjectEnergy
     double droneEnergyPerMeter
     double droneEnergyPerMeter
     int32_t coreLevel
     int32 coreLevel
     int32_t thrusterLevel
     int32 thrusterLevel
     float miningSpeed
     float miningSpeed
     float replicateSpeed
     float replicateSpeed
Line 241: Line 243:
     MechaForge
     MechaForge
     MechaLab
     MechaLab
     int32_t droneCount
     int32 droneCount
     float droneSpeed
     float droneSpeed
     int32_t droneMovement
     int32 droneMovement
     MechaDrone[droneCount]
     MechaDrone[droneCount]
}
}
Line 249: Line 251:
StorageComponent
StorageComponent
{
{
     int32_t version = 1
     int32 version = 1
     int32_t id
     int32 id
     int32_t entityId
     int32 entityId
     int32_t previous (version >= 1)
     int32 previous (version >= 1)
     int32_t next (version >= 1)
     int32 next (version >= 1)
     int32_t bottom (version >= 1)
     int32 bottom (version >= 1)
     int32_t top (version >= 1)
     int32 top (version >= 1)
     int32_t EStorageType type (0:Default 1:Fuel 9:Filtered)
     int32 EStorageType type (0:Default 1:Fuel 9:Filtered)
     int32_t gridSize
     int32 gridSize
     int32_t bans (version >= 1)
     int32 bans (version >= 1)
     grids[gridSize] {
     grids[gridSize] {
         int32_t itemId
         int32 itemId
         int32_t filter
         int32 filter
         int32_t count
         int32 count
         int32_t stackSize
         int32 stackSize
    }
}
 
MechaForge
{
    int32 version = 0
    int32 numTasks
    ForgeTask tasks[numTasks]
}
 
ForgeTask
{
    int32 version = 0
    int32 recipeId
    int32 count
    int32 tick
    int32 tickSpend
    int32 numItem
    int32 numProduct
    [numItem] {
        int32 itemIds
        int32 itemCounts
        int32 served
     }
     }
    [numProduct] {
        int32 productIds
        int32 productCounts
        int32 produced
    }
    int32 parentTaskIndex
}
MechaLab
{
    int32 version = 0
    int32 numItemPoints
    itemPoints[numItemPoints] {
        int32 key
        int32 value
    }
}
MechaDrone
{
    int32 version = 0
    int32 stage
    float position_x
    float position_y
    float position_z
    float target_x
    float target_y
    float target_z
    float forward_x
    float forward_y
    float forward_z
    float speed
    int32 movement
    int32 targetObject
    float progress
    float initialVector_x
    float initialVector_y
    float initialVector_z
}
}


PlayerNavigation
PlayerNavigation
{
{
     int32_t version = 0
     int32 version = 0
     uint8_t bool navigating
     uint8_bool navigating
     int32_t naviAstroId
     int32 naviAstroId
     double naviTarget_x
     double naviTarget_x
     double naviTarget_y
     double naviTarget_y
     double naviTarget_z
     double naviTarget_z
     uint8_t bool useFly
     uint8_bool useFly
     uint8_t bool useSail
     uint8_bool useSail
     uint8_t bool useWarp
     uint8_bool useWarp
     int32_t ENaviStage stage (None, Departure, OriginOrbit, AccOrbit, Space, DestOrbit, Approaching)
     int32 ENaviStage stage (None, Departure, OriginOrbit, AccOrbit, Space, DestOrbit, Approaching)
     double flyThreshold
     double flyThreshold
     double sailThreshold
     double sailThreshold
Line 287: Line 350:
GalacticTransport
GalacticTransport
{
{
     int32_t version = 0
     int32 version = 0
}
}


PlanetFactory
PlanetFactory
{
{
     int32_t version = 1
     int32 version = 1
     int32_t planetId
     int32 planetId
     PlanetData
     PlanetData
     int32_t entityCapacity
     int32 entityCapacity
     int32_t entityCursor
     int32 entityCursor
     int32_t entityRecycleCursor
     int32 entityRecycleCursor
     EntityData entityPool[entityCursor - 1]
     EntityData entityPool[entityCursor - 1]
     entityAnimPool[entityCursor - 1] {
     entityAnimPool[entityCursor - 1] {
Line 303: Line 366:
         float prepare_length
         float prepare_length
         float working_length
         float working_length
         uint32_t state
         uint32 state
         float power
         float power
     }
     }
     entitySignPool[entityCursor - 1] {
     entitySignPool[entityCursor - 1] {
         uint32_t signType
         uint32 signType
         uint32_t iconType
         uint32 iconType
         uint32_t iconId0
         uint32 iconId0
         uint32_t iconId1
         uint32 iconId1
         uint32_t iconId2
         uint32 iconId2
         uint32_t iconId3
         uint32 iconId3
         float count0
         float count0
         float count1
         float count1
Line 322: Line 385:
         float w
         float w
     }
     }
     int32_t entityConnPool[entityCursor * 16 - 16]
     int32 entityConnPool[entityCursor * 16 - 16]
     int32_t entityRecycle[entityRecycleCursor]
     int32 entityRecycle[entityRecycleCursor]
     int32_t prebuildCapacity
     int32 prebuildCapacity
     int32_t prebuildCursor
     int32 prebuildCursor
     int32_t prebuildRecycleCursor
     int32 prebuildRecycleCursor
     PrebuildData prebuildPool[prebuildCursor - ]
     PrebuildData prebuildPool[prebuildCursor - 1]
     int32_t prebuildConnPool[prebuildCursor * 16 - 16]
     int32 prebuildConnPool[prebuildCursor * 16 - 16]
     int32_t prebuildRecycle[prebuildRecycleCursor]
     int32 prebuildRecycle[prebuildRecycleCursor]
     int32_t vegeCapacity
     int32 vegeCapacity
     int32_t vegeCursor
     int32 vegeCursor
     int32_t vegeRecycleCursor
     int32 vegeRecycleCursor
     VegeData vegePool[vegeCursor - 1]
     VegeData vegePool[vegeCursor - 1]
     int32_t vegeRecycle[vegeRecycleCursor]
     int32 vegeRecycle[vegeRecycleCursor]
     int32_t veinCapacity
     int32 veinCapacity
     int32_t veinCursor
     int32 veinCursor
     int32_t veinRecycleCursor
     int32 veinRecycleCursor
     VeinData veinPool[veinCursor - 1]
     VeinData veinPool[veinCursor - 1]
     int32_t veinRecycle[veinRecycleCursor]
     int32 veinRecycle[veinRecycleCursor]
     veinAnimPool[veinCursor] {
     veinAnimPool[veinCursor - 1] {
         float time
         float time
         float prepare_length
         float prepare_length
         float working_length
         float working_length
         uint32_t state
         uint32 state
         float power
         float power
     }
     }
Line 359: Line 422:
PlanetData
PlanetData
{
{
     int32_t modDataByteCount
     int32 modDataByteCount
     uint8_t modData[modDataByteCount]
     uint8 modData[modDataByteCount]
     int32_t numVeinAmounts
     int32 numVeinAmounts
     int64_t veinAmounts[numVeinAmounts]
     int64 veinAmounts[numVeinAmounts]: The index is the EVeinType.  This contains the total of the veinGroups's amounts which is also the total of the VeinData::amounts.
     int32_t numVeinGroups
     int32 numVeinGroups
     veinGroups[numVeinGroups] {
     veinGroups[numVeinGroups] {
         int32_t EVeinType type ()
         int32 EVeinType type (None, Iron, Copper, Silicium, Titanium, Stone, Coal, Oil, Fireice, Diamond, Fractal, Crysrub, Grat, Bamboo, Mag)
         float pos_x
         float pos_x
         float pos_y
         float pos_y
         float pos_z
         float pos_z
         int32_t count: Read, but then set to zero
         int32 count: Read, but then set to zero
         int64_t amount: Read, but then set to zero
         int64 amount: Read, but then set to zero
     }
     }
}
}
Line 376: Line 439:
EntityData
EntityData
{
{
     uint8_t version = 0
     uint8 version = 0
     int32_t id
     int32 id
     int16_t protoId
     int16 protoId
     int16_t modelIndex
     int16 modelIndex
     float pos_x
     float pos_x
     float pos_y
     float pos_y
Line 387: Line 450:
     float rot_z
     float rot_z
     float rot_w
     float rot_w
     int32_t beltId
     int32 beltId
     int32_t splitterId
     int32 splitterId
     int32_t storageId
     int32 storageId
     int32_t tankId
     int32 tankId
     int32_t minerId
     int32 minerId
     int32_t inserterId
     int32 inserterId
     int32_t assemblerId
     int32 assemblerId
     int32_t fractionateId
     int32 fractionateId
     int32_t ejectorId
     int32 ejectorId
     int32_t siloId
     int32 siloId
     int32_t labId
     int32 labId
     int32_t stationId
     int32 stationId
     int32_t powerNodeId
     int32 powerNodeId
     int32_t powerGenId
     int32 powerGenId
     int32_t powerConId
     int32 powerConId
     int32_t powerAccId
     int32 powerAccId
     int32_t powerExcId
     int32 powerExcId
     int32_t monsterId
     int32 monsterId
}
}


PrebuildData
PrebuildData
{
{
     uint8_t version = 0
     uint8 version = 0
     int32_t id
     int32 id
     int16_t protoId
     int16 protoId
     int16_t modelIndex
     int16 modelIndex
     float pos_x
     float pos_x
     float pos_y
     float pos_y
Line 427: Line 490:
     float rot2_z
     float rot2_z
     float rot2_w
     float rot2_w
     int32_t upEntity
     int32 upEntity
     int16_t pickOffset
     int16 pickOffset
     int16_t insertOffset
     int16 insertOffset
     int32_t recipeId
     int32 recipeId
     int32_t filterId
     int32 filterId
     int32_t refCount
     int32 refCount
     int32_t refArr[refCount]
     int32 refArr[refCount]
}
}


VegeData
VegeData
{
{
     uint8_t version = 0
     uint8 version = 0
     int32_t id
     int32 id
     int16_t protoId
     int16 protoId
     int16_t modelIndex
     int16 modelIndex
     int16_t hp
     int16 hp
     float pos_x
     float pos_x
     float pos_y
     float pos_y
Line 450: Line 513:
     float rot_z
     float rot_z
     float rot_w
     float rot_w
    float scl_x
     float scl_y
     float scl_y
     float scl_z
     float scl_z
    float scl_w
}
}


VeinData
VeinData
{
{
     uint8_t version = 0
     uint8 version = 0
     int32_t id
     int32 id
     int16_t EVeinType (None, Iron, Copper, Silicium, Titanium, Stone, Coal, Oil, Fireice, Diamond, Fractal, Crysrub, Grat, Bamboo, Mag)
     int16 EVeinType (see above)
     int16_t modelIndex
     int16 modelIndex
     int16_t groupIndex
     int16 groupIndex
     int32_t amount
     int32 amount
     int32_t productId
     int32 productId
     float pos_x
     float pos_x
     float pos_y
     float pos_y
     float pos_z
     float pos_z
     int32_t minerCount
     int32 minerCount
     int32_t minerId0
     int32 minerId0
     int32_t minerId1
     int32 minerId1
     int32_t minerId2
     int32 minerId2
     int32_t minerId3
     int32 minerId3
}
}


CargoContainer
CargoContainer
{
{
     int32_t version = 0
     int32 version = 0
     int32_t poolCapacity
     int32 poolCapacity
     int32_t cursor
     int32 cursor
     int32_t recycleBegin
     int32 recycleBegin
     int32_t recycleEnd
     int32 recycleEnd
     cargoPool[cursor] {
     cargoPool[cursor] {
         int32_t item
         int32 item
         float position_x
         float position_x
         float position_y
         float position_y
Line 491: Line 554:
         float rotation_w
         float rotation_w
     }
     }
     int32_t recycleIds[poolCapacity]
     int32 recycleIds[poolCapacity]
}
}


CargoTraffic
CargoTraffic
{
{
     int32_t version = 0
     int32 version = 0
     int32_t beltCursor
     int32 beltCursor
     int32_t beltCapacity
     int32 beltCapacity
     int32_t beltRecycleCursor
     int32 beltRecycleCursor
     int32_t splitterCursor
     int32 splitterCursor
     int32_t splitterCapacity
     int32 splitterCapacity
     int32_t splitterRecycleCursor
     int32 splitterRecycleCursor
     int32_t pathCursor
     int32 pathCursor
     int32_t pathCapacity
     int32 pathCapacity
     int32_t pathRecycleCursor
     int32 pathRecycleCursor
     BeltComponent beltPool[beltCursor - 1]
     BeltComponent beltPool[beltCursor - 1]
     int32_t beltRecycle[beltRecycleCursor]
     int32 beltRecycle[beltRecycleCursor]
     SplitterComponent splitterPool[splitterCursor - 1]
     SplitterComponent splitterPool[splitterCursor - 1]
     int32_t splitterRecycle[splitterRecycleCursor]
     int32 splitterRecycle[splitterRecycleCursor]
     [pathCursor - 1] {
     [pathCursor - 1] {
         int32_t cargoPathIndex
         int32 cargoPathIndex
         CargoPath (cargoPathIndex != 0)
         CargoPath pathPool (cargoPathIndex != 0)
     }
     }
     int32_t pathRecycle[pathRecycleCursor]
     int32 pathRecycle[pathRecycleCursor]
}
}


BeltComponent
BeltComponent
{
{
      
     int32 version = 0
    int32 id
    int32 entityId
    int32 speed
    int32 segPathId
    int32 segIndex
    int32 segPivotOffset
    int32 segLength
    int32 outputId
    int32 backInputId
    int32 leftInputId
    int32 rightInputId
}
}


SplitterComponent
SplitterComponent
{
{
      
     int32 version = 0
    int32 id
    int32 entityId
    int32 beltA
    int32 beltB
    int32 beltC
    int32 beltD
    int32 input0
    int32 input1
    int32 input2
    int32 input3
    int32 output0
    int32 output1
    int32 output2
    int32 output3
    uint8_bool inPriority
    uint8_bool outPriority
    int32 outFilter
}
}


CargoPath
CargoPath
{
{
      
     int32 version = 0
    int32 id
    int32 capacity
    int32 bufferLength
    int32 chunkCapacity
    int32 chunkCount
    int32 updateLen
    uint8_bool closed
    int32 outputPathIdForImport
    int32 outputIndex
    int32 numBelts
    int32 numInputPaths
    uint8 buffer[bufferLength]
    int32 chunks[chunkCount * 3]
    [bufferLength] {
        float pointPos_x
        float pointPos_y
        float pointPos_z
        float pointRot_x
        float pointRot_y
        float pointRot_z
        float pointRot_w
    }
    int32 belts[numBelts]
    int32 inputPaths[numInputPaths]
}
}


FactoryStorage
FactoryStorage
{
{
      
     int32 version = 0
    int32 storageCursor
    int32 storageCapacity
    int32 storageRecycleCursor
    [storageCursor - 1] {
        int32 storagePoolIndex
        int32 size (storagePoolIndex != 0)
        StorageComponent storagePool (storagePoolIndex != 0)
    }
    int32 storageRecycle[storageRecycleCursor]
    int32 tankCapacity
    int32 tankCursor
    int32 tankRecycleCursor
    TankComponent tankPool[tankCursor - 1]
    int32 tankRecycle[tankRecycleCursor]
}
 
TankComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 lastTankId
    int32 nextTankId
    int32 belt0
    int32 belt1
    int32 belt2
    int32 belt3
    uint8_bool isOutput0
    uint8_bool isOutput1
    uint8_bool isOutput2
    uint8_bool isOutput3
    int32 fluidStorageCount
    int32 currentCount
    int32 fluidId
    uint8_bool outputSwitch
    uint8_bool inputSwitch
    uint8_bool isBottom
}
}


PowerSystem
PowerSystem
{
{
      
     int32 version = 0
    int32 generatorCapacity
    int32 genCursor
    int32 genRecycleCursor
    PowerGeneratorComponent genPool[genCursor - 1]
    int32 genRecycle[genRecycleCursor]
    int32 nodeCapacity
    int32 nodeCursor
    int32 nodeRecycleCursor
    PowerNodeComponent nodePool[nodeCursor - 1]
    int32 nodeRecycle[nodeRecycleCursor]
    int32 consumerCapacity
    int32 consumerCursor
    int32 consumerRecycleCursor
    PowerConsumerComponent consumerPool[consumerCursor - 1]
    int32 consumerRecycle[consumerRecycleCursor]
    int32 accumulatorCapacity
    int32 accCursor
    int32 accRecycleCursor
    PowerAccumulatorComponent accPool[accCursor - 1]
    int32 accRecycle[accRecycleCursor]
    int32 exchangerCapacity
    int32 excCursor
    int32 excRecycleCursor
    PowerExchangerComponent excPool[excCursor - 1]
    int32 excRecycle[excRecycleCursor]
    int32 networkCapacity
    int32 netCursor
    int32 netRecycleCursor
    [netCursor] {
        int32 powerNetworkIncludedFlag
        PowerNetwork netPool (powerNetworkIncludedFlag == 1)
    }
    int32 netRecycle[netRecycleCursor]
}
 
PowerGeneratorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    uint8_bool photovoltaic
    uint8_bool wind
    uint8_bool gamma
    int64 genEnergyPerTick
    int64 useFuelPerTick
    int16 fuelMask
    int64 fuelEnergy
    int16 curFuelId
    int16 fuelId
    int16 fuelCount
    int64 fuelHeat
    int32 catalystId
    int32 catalystPoint
    int32 productId
    float productCount
    int64 productHeat
    float warmup
    float ionEnhance
    float x
    float y
    float z
}
 
PowerNodeComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    uint8_bool isCharger
    int32 workEnergyPerTick
    int32 idleEnergyPerTick
    int32 requiredEnergy
    float powerPoint_x
    float powerPoint_y
    float powerPoint_z
    float connectDistance
    float coverRadius
}
 
PowerConsumerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    float plugPos_x
    float plugPos_y
    float plugPos_z
    int64 requiredEnergy
    int64 servedEnergy
    int64 workEnergyPerTick
    int64 idleEnergyPerTick
}
 
PowerAccumulatorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    int64 inputEnergyPerTick
    int64 outputEnergyPerTick
    int64 curEnergy
    int64 maxEnergy
}
 
PowerExchangerComponent
{
    int32 version = 1
    int32 id
    int32 entityId
    int32 networkId
    int16 emptyCount
    int16 fullCount
    float targetState
    float state
    int64 energyPerTick
    int64 curPoolEnergy
    int64 poolMaxEnergy
    int32 emptyId
    int32 fullId
    int32 belt0 (version >= 1)
    int32 belt1 (version >= 1)
    int32 belt2 (version >= 1)
    int32 belt3 (version >= 1)
    uint8_bool isOutput0 (version >= 1)
    uint8_bool isOutput1 (version >= 1)
    uint8_bool isOutput2 (version >= 1)
    uint8_bool isOutput3 (version >= 1)
    int32 outputSlot (version >= 1)
    int32 inputSlot (version >= 1)
    int32 outputRectify (version >= 1)
    int32 inputRectify (version >= 1)
}
 
PowerNetwork
{
    int32 version = 0
    int32 id
    int32 numNodes
    int32 numConsumers
    int32 numGenerators
    int32 numAccumulators
    int32 numExchangers
    PowerNetworkStructures::Node[numNodes]
    int32 consumers[numConsumers]
    int32 generators[numGenerators]
    int32 accumulators[numAccumulators]
    int32 exchangers[numExchangers]
}
 
PowerNetworkStructures::Node
{
    int32 version = 0
    int32 id
    float x
    float y
    float z
    float connDistance2
    float coverRadius2
    int32 genId
    int32 accId
    int32 excId
    int32 numConnIdsForLoad
    int32 numLineIdsForLoad
    int32 numConsumers
    int32 connIdsForLoad[numConnIdsForLoad]
    int32 lineIdsForLoad[numLineIdsForLoad]
    int32 consumers[numConsumers]
}
}


FactorySystem
FactorySystem
{
{
      
     int32 version = 0
    int32 minerCapacity
    int32 minerCursor
    int32 minerRecycleCursor
    MinerComponent minerPool[minerCursor - 1]
    int32 minerRecycle[minerRecycleCursor]
    int32 inserterCapacity
    int32 inserterCursor
    int32 inserterRecycleCursor
    InserterComponent inserterPool[inserterCursor - 1]
    int32 inserterRecycle[inserterRecycleCursor]
    int32 assemblerCapacity
    int32 assemblerCursor
    int32 assemblerRecycleCursor
    AssemblerComponent assemblerPool[assemblerCursor - 1]
    int32 assemblerRecycle[assemblerRecycleCursor]
    int32 fractionateCapacity
    int32 fractionateCursor
    int32 fractionateRecycleCursor
    FractionateComponent fractionatePool[fractionateCursor - 1]
    int32 fractionateRecycle[fractionateRecycleCursor]
    int32 ejectorCapacity
    int32 ejectorCursor
    int32 ejectorRecycleCursor
    EjectorComponent ejectorPool[ejectorCursor - 1]
    int32 ejectorRecycle[ejectorRecycleCursor]
    int32 siloCapacity
    int32 siloCursor
    int32 siloRecycleCursor
    SiloComponent siloPool[siloCursor - 1]
    int32 siloRecycle[siloRecycleCursor]
    int32 labCapacity
    int32 labCursor
    int32 labRecycleCursor
    LabComponent labPool[labCursor - 1]
    int32 labRecycle[labRecycleCursor]
}
 
MinerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 EMinerType type (None, Water, Vein, Oil)
    int32 speed
    int32 time
    int32 period
    int32 insertTarget
    int32 EWorkState workstate (Idle, Running, Outputing, Lack, Full)
    int32 veinCount
    int32 veins[veinCount]
    int32 currentVeinIndex
    int32 minimumVeinAmount
    int32 productId
    int32 productCount
    uint32 seed
}
 
InserterComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 EInserterStage stage (Picking, Sending, Inserting, Returning)
    int32 speed
    int32 time
    int32 stt
    int32 delay
    int32 pickTarget
    int32 insertTarget
    uint8_bool careNeeds
    uint8_bool canStack
    int16 pickOffset
    int16 insertOffset
    int32 filter
    int32 itemId
    int32 stackCount
    int32 stackSize
    float pos2_x
    float pos2_y
    float pos2_z
    float rot2_x
    float rot2_y
    float rot2_z
    float rot2_w
    int16 t1
    int16 t2
}
 
AssemblerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    uint8_bool replicating
    uint8_bool outputing
    int32 speed
    int32 time
    int32 recipeId
    (recipeId > 0) {
        int32 ERecipeType recipeType (0:None 1:Smelt 2:Chemical 3:Refine 4:Assemble 5:Particle 6:Exchange 7:PhotonStore 8:Fractionate 15:Research)
        int32 timeSpend
        int32 numRequires
        int32 requires[numRequires]
        int32 numRequireCounts
        int32 requireCounts[numRequireCounts]
        int32 numServed
        int32 served[numServed]
        int32 numNeeds
        int32 needs[numNeeds]
        int32 numProducts
        int32 products[numProducts]
        int32 numProductCounts
        int32 productCounts[numProductCounts]
        int32 numProduced
        int32 produced[numProduced]
    }
}
 
FractionateComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 belt0
    int32 belt1
    int32 belt2
    uint8_bool isOutput0
    uint8_bool isOutput1
    uint8_bool isOutput2
    uint8_bool isWorking
    float produceProb
    int32 need
    int32 product
    int32 needCurrCount
    int32 productCurrCount
    int32 oriProductCurrCount
    int32 progress
    uint8_bool isRand
    uint8_bool fractionateSuccess
    int32 needMaxCount
    int32 productMaxCount
    int32 oriProductMaxCount
    uint32 seed
}
 
EjectorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 planetId
    int32 pcId
    int32 direction
    int32 time
    uint8_bool fired
    int32 chargeSpend
    int32 coldSpend
    int32 bulletId
    int32 bulletCount
    int32 orbitId
    float pivotY
    float muzzleY
    float localPosN_x
    float localPosN_y
    float localPosN_z
    float localAlt
    float localRot_x
    float localRot_y
    float localRot_z
    float localRot_w
    float localDir_x
    float localDir_y
    float localDir_z
}
 
SiloComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 planetId
    int32 pcId
    int32 direction
    int32 time
    uint8_bool fired
    int32 chargeSpend
    int32 coldSpend
    int32 bulletId
    int32 bulletCount
    int32 autoIndex
    uint8_bool hasNode
    float localPos_x
    float localPos_y
    float localPos_z
    float localRot_x
    float localRot_y
    float localRot_z
    float localRot_w
}
 
LabComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 nextLabId
    uint8_bool replicating
    uint8_bool outputing
    int32 time
    int32 hashBytes
    uint8_bool researchMode
    int32 recipeId
    int32 techId
    (not researchMode and recipeId > 0) {
        int32 timeSpend
        int32 numRequires
        int32 requires[numRequires]
        int32 numRequireCounts
        int32 requireCounts[numRequireCounts]
        int32 numServed
        int32 served[numServed]
        int32 numNeeds
        int32 needs[numNeeds]
        int32 numProducts
        int32 products[numProducts]
        int32 numProductCounts
        int32 productCounts[numProductCounts]
        int32 numProduced
        int32 produced[numProduced]
    }
    (researchMode) {
        int32 numMatrixPoints
        int32 matrixPoints[numMatrixPoints]
        int32 numMatrixServed
        int32 matrixServed[numMatrixServed]
        int32 numNeeds
        int32 needs[numNeeds]
    }
}
}


PlanetTransport
PlanetTransport
{
{
      
     int32 version = 0
    int32 stationCursor
    int32 stationCapacity
    int32 stationRecycleCursor
    [stationCursor - 1] {
        int32 stationIndex
        StationComponent stationPool (stationIndex != 0)
    }
    int32 stationRecycle[stationRecycleCursor]
}
 
StationComponent
{
    int32 version = 2
    int32 id
    int32 gid
    int32 entityId
    int32 planetId
    int32 pcId
    int32 gene
    float droneDock_x
    float droneDock_y
    float droneDock_z
    float shipDockPos_x
    float shipDockPos_y
    float shipDockPos_z
    float shipDockRot_x
    float shipDockRot_y
    float shipDockRot_z
    float shipDockRot_w
    uint8_bool isStellar
    int32 nameIsIncludedFlag (0 or 1)
    string name (nameIsIncludedFlag > 0)
    int64 energy
    int64 energyPerTick
    int64 energyMax
    int32 warperCount
    int32 warperMaxCount
    int32 idleDroneCount
    int32 workDroneCount
    int32: Used for allocating array sizes for workDroneDatas and workDroneOrders, and not uses for read in the arrays.
    DroneData workDroneDatas[workDroneCount]
    LocalLogisticOrder workDroneOrders[workDroneCount]
    int32 idleShipCount
    int32 workShipCount
    uint64 idleShipIndices
    uint64 workShipIndices
    int32: Used for allocating array sizes for workShipDatas, shipRenderers, shipUIRenderers, workShipOrders, and not uses for read in the arrays.
    ShipData workShipDatas[workShipCount]
    RemoteLogisticOrder workShipOrders[workShipCount]
    int32 numStorage
    StationStore[numStorage]
    (version >= 1) {
        int32 numSlots
        slots[numSlots] {
            int32 dir
            int32 beltId
            int32 storageIdx
            int32 counter
        }
    }
    int32 localPairProcess
    int32 remotePairProcess
    int32 nextShipIndex
    uint8_bool isCollector
    int32 numCollectionIds
    int32 collectionIds[numCollectionIds]
    int32 numCollectionPerTick
    float collectionPerTick[numCollectionPerTick]
    int32 numCurrentCollections
    float currentCollections[numCurrentCollections]
    int32 collectSpeed
    double tripRangeDrones (version >= 2)
    double tripRangeShips (version >= 2)
    uint8_bool includeOrbitCollector (version >= 2)
    double warpEnableDist (version >= 2)
    uint8_bool warperNecessary (version >= 2)
    int32 deliveryDrones (version >= 2)
    int32 deliveryShips (version >= 2)
}
 
DroneData
{
    int32 version = 0
    float begin_x
    float begin_y
    float begin_z
    float end_x
    float end_y
    float end_z
    int32 endId
    float direction
    float maxt
    float t
    int32 itemId
    int32 itemCount
    int32 gene
}
 
LocalLogisticOrder
{
    int32 version = 0
    int32 otherStationId
    int32 thisIndex
    int32 otherIndex
    int32 itemId
    int32 thisOrdered
    int32 otherOrdered
}
 
ShipData
{
    int32 version = 0
    int32 stage
    int32 planetA
    int32 planetB
    double uPos_x
    double uPos_y
    double uPos_z
    float uVel_x
    float uVel_y
    float uVel_z
    float uSpeed
    float warpState
    float uRot_x
    float uRot_y
    float uRot_z
    float uRot_w
    float uAngularVel_x
    float uAngularVel_y
    float uAngularVel_z
    float uAngularSpeed
    double pPosTemp_x
    double pPosTemp_y
    double pPosTemp_z
    float pRotTemp_x
    float pRotTemp_y
    float pRotTemp_z
    float pRotTemp_w
    int32 otherGId
    int32 direction
    float t
    int32 itemId
    int32 itemCount
    int32 gene
    int32 shipIndex
    int32 warperCnt
}
 
RemoteLogisticOrder
{
    int32 version = 0
    int32 otherStationGId
    int32 thisIndex
    int32 otherIndex
    int32 itemId
    int32 thisOrdered
    int32 otherOrdered
}
 
StationStore
{
    int32 version = 0
    int32 itemId
    int32 count
    int32 localOrder
    int32 remoteOrder
    int32 max
    int32 ELogisticStorage localLogic (None, Supply, Demand)
    int32 ELogisticStorage remoteLogic
}
}


MonsterSystem
MonsterSystem
{
{
      
     int32 version = 0
    int32 monsterCapacity
    int32 monsterCursor
    int32 monsterRecycleCursor
    MonsterComponent monsterPool[monsterCursor - 1]
    int32 monsterRecycle[monsterRecycleCursor]
}
 
MonsterComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    float walkSpeed
    float point0_x
    float point0_y
    float point0_z
    float point1_x
    float point1_y
    float point1_z
    float point2_x
    float point2_y
    float point2_z
    int32 direction
    float stopTime
    float t
    float stopCurrentTime
    int32 EMonsterState monsterState (Null, Stopped, Wandering)
    float stepDistance
}
}


PlatformSystem
PlatformSystem
{
{
      
     int32 version = 0
    int32 reformDataByteCount
    uint8 reformData[reformDataByteCount]: If count exceeds a limit, count is read, but only the limit is used.
    int32 reformOffsetsByteCount
    uint32 reformOffsets[reformOffsetsByteCount]: If count exceeds a limit, count is read, but only the limit is used.
}
}


DysonSphere
DysonSphere
{
{
      
     int32 version = 2
    (version >= 1) {
        int32 randSeed
        DysonSwarm
        int32 = 1212: File will be rejected if the value is not 1212
        int32 layerCount
        int32 numDysonSphereLayer
        [numDysonSphereLayer - 1] {
            int32 dysonSphereLayerIndex
            DysonSphereLayer (dysonSphereLayerIndex != 0)
        }
        int32 rocketCapacity
        int32 rocketCursor
        int32 rocketRecycleCursor
        DysonRocket rocketPool[rocketCursor - 1]
        int32 rocketRecycle[rocketRecycleCursor]
        int32 autoNodeCount
        int32 numAutoNodes
        [numAutoNodes] {
            int32 autoNodeIncludedFlag
            int32 layerId (autoNodeIncludedFlag > 0)
            int32 nodeId (autoNodeIncludedFlag > 0)
        }
    }
    (version >= 2) {
        int32 nrdCapacity
        int32 nrdCursor
        int32 nrdRecycleCursor
        DysonNodeRData nrdPool[nrdCursor - 1]
        int32 nrdRecycle[nrdRecycleCursor]
    }
}
 
DysonSwarm
{
    int32 version = 4
    (version >= 1) {
        int32 randSeed
        int32 sailCapacity
        int32 sailCursor
        int32 sailRecycleCursor
        sailPoolForSave[sailCursor] {
            float st
            float px
            float py
            float pz
            float vx
            float vy
            float vz
            float gs
        }
        sailInfos[sailCursor] {
            uint32 orbit
            uint32 node (version >= 3)
            uint32 kill (version >= 3)
            float posr_x (version >= 4)
            float posr_y (version >= 4)
            float posr_z (version >= 4)
        }
        int32 sailRecycle[sailRecycleCursor]
        int32 orbitCapacity
        int32 orbitCursor
        SailOrbit orbits[orbitCursor - 1]
        int32 numExpiryOrder: Must match sailCapacity or the game will crash.
        int32 expiryCursor
        int32 expiryEnding
        [numExpiryOrder] {
            int64 time
            int32 index
        }
        (version >= 2) {
            int32 numAbsorbOrder: Must match sailCapacity or the game will crash.
            int32 absorbCursor
            int32 absorbEnding
            absorbOrder[numAbsorbOrder] {
                int64 time
                int32 index
                int32 layer
                int32 node
            }
        }
        int32 bulletCapacity
        int32 bulletCursor
        int32 bulletRecycleCursor
        SailBullet bulletPool[bulletCursor - 1]
        int32 bulletRecycle[bulletRecycleCursor]
    }
}
 
SailOrbit
{
    int32 version = 0
    int32 id
    float radius
    float rotation_x
    float rotation_y
    float rotation_z
    float rotation_w
    float up_x
    float up_y
    float up_z
    int32 count
    uint8_bool enabled
}
 
SailBullet
{
    int32 version = 0
    int32 id
    float t
    float maxt
    int32 state
    float rBegin_x
    float rBegin_y
    float rBegin_z
    float rEnd_x
    float rEnd_y
    float rEnd_z
    float lBegin_x
    float lBegin_y
    float lBegin_z
    float uEndVel_x
    float uEndVel_y
    float uEndVel_z
    double uBegin_x
    double uBegin_y
    double uBegin_z
    double uEnd_x
    double uEnd_y
    double uEnd_z
}
 
DysonSphereLayer
{
    int32 version = 0
    int32 id
    float orbitRadius
    float orbitRotation_x
    float orbitRotation_y
    float orbitRotation_z
    float orbitRotation_w
    float orbitAngularSpeed
    float currentAngle
    float currentRotation_x
    float currentRotation_y
    float currentRotation_z
    float currentRotation_w
    float nextRotation_x
    float nextRotation_y
    float nextRotation_z
    float nextRotation_w
    int32 gridMode
    int32 nodeCapacity
    int32 nodeCursor
    int32 nodeRecycleCursor
    [nodeCursor - 1] {
        int32 dysonNodeIndex
        DysonNode (dysonNodeIndex != 0)
    }
    int32 nodeRecycle[nodeRecycleCursor]
    int32 frameCapacity
    int32 frameCursor
    int32 frameRecycleCursor
    [frameCursor - 1] {
        int32 dysonFrameIndex
        DysonFrame (dysonFrameIndex != 0)
    }
    int32 frameRecycle[frameRecycleCursor]
    int32 shellCapacity
    int32 shellCursor
    int32 shellRecycleCursor
    [shellCursor - 1] {
        int32 dysonShellIndex
        DysonShell (dysonShellIndex != 0)
    }
    int32 shellRecycle[shellRecycleCursor]
}
 
DysonNode
{
    int32 version = 4
    int32 id
    int32 protoId
    int32 layerId
    uint8_bool use
    uint8_bool reserved
    float pos_x
    float pos_y
    float pos_z
    int32 sp
    int32 spMax
    int32 spOrdered
    int32 cpOrdered (version >= 3)
    int32 rid (version >= 2)
    int32 frameTurn
    int32 shellTurn (version >= 1)
    int32 _spReq
    int32 _cpReq (version >= 4)
}
 
DysonFrame
{
    int32 version = 0
    int32 id
    int32 protoId
    int32 layerId
    uint8_bool reserved
    int32 nodeId
    int32 nodeId2
    uint8_bool euler
    int32 spA
    int32 spB
    int32 spMax
}
 
DysonShell
{
    int32 version = 0
    int32 id
    int32 protoId
    int32 layerId
    int32 randSeed
    int32 numPolygon
    polygon[numPolygon] {
        float item_x
        float item_y
        float item_z
    }
    int32 numDysonNode
    int32 nodeId[numDysonNode]: Must be an existing ID or the game will crash.
    int32 vertexCount
    int32 triangleCount
    int32 numVerts
    verts[numVerts] {
        float x
        float y
        float z
    }
    int32 numPqArr
    pqArr[numPqArr] {
        int32 x
        int32 y
    }
    int32 numTris
    int32 tris[numTris]
    int32 numVAdjs
    int32 vAdjs[numVAdjs]
    int32 numVertAttr
    int32 vertAttr[numVertAttr]
    int32 numVertsq
    int32 vertsq[numVertsq]
    int32 numVertsqOffset
    int32 vertsqOffset[numVertsqOffset]
    int32 numNodecps
    int32 nodecps[numNodecps]
    int32 numVertcps
    int32 vertcps[numVertcps]
    int32 vertRecycleArraySize
    int32 vertRecycleCursor
    int32 vertRecycle[vertRecycleCursor]
}
 
DysonRocket
{
    int32 version = 0
    int32 id
    int32 nodeLayerId
    int32 nodeId
    int32 planetId
    float t
    float uSpeed
    double uPos_x
    double uPos_y
    double uPos_z
    float uRot_x
    float uRot_y
    float uRot_z
    float uRot_w
    float uVel_x
    float uVel_y
    float uVel_z
    float launch_x
    float launch_y
    float launch_z
}
 
DysonNodeRData
{
    int32 version = 0
    int32 id
    int32 layerId
    float pos_x
    float pos_y
    float pos_z
    float angularVel
    float layerRot_x
    float layerRot_y
    float layerRot_z
    float layerRot_w
}
}


</syntaxhighlight>
</syntaxhighlight>
{{Modding Navbox}}
[[Category:Modding]]

Latest revision as of 13:04, 15 June 2021

This page defines the Dyson Sphere Program save file format .dsv. On Windows by default save files are stored in %USERPROFILE%\Documents\Dyson Sphere Program\Save\.

Return to Modding Hub.

A save file parser in C++ written to the specification below is available on GitHub: github.com/GreyHak/dsp-save-parser.

float oilSpeedMultiplier = 4E-05f

GameSave
{
    "VFSAVE"
    int64 fileStreamLength
    int32 saveFileFormatNumber = 4
    int32 majorGameVersion
    int32 minorGameVersion
    int32 releaseGameVersion
    int64 gameTick
    int64 nowTicks
    int32 sizeOfPngFile
    uint8 screenShotPngFile[sizeOfPngFile]
    GameData
}

GameData
{
    int32 version = 2
    string gameName
    GameDesc
    int64 gameTick
    GamePrefsData preferences (version >= 1)
    GameHistoryData
    uint8_bool hidePlayerModel (version >= 2)
    uint8_bool disableController (version >= 2)
    GameStatData statistics
    int32 planetId
    Player mainPlayer
    int32 factoryCount
    GalacticTransport
    PlanetFactory[factoryCount]
    int32 galaxyStarCount: Must equal GameDesc::starCount or the game will crash.
    [galaxyStarCount] {
        int32 dysonSphereDataIsAvailableFlag: Must be 0 or 1 or the game will crash.
        DysonSphere (dysonSphereDataIsAvailableFlag == 1)
    }
}

GameDesc
{
    int32 version = 2
    int32 galaxyAlgo
    int32 galaxySeed
    int32 starCount
    int32 playerProto
    float resourceMultiplier (version >= 2)
    int32 numThemeIds (version >= 1)
    int32 themeIds[numThemeIds] (version >= 1)
}

GamePrefsData
{
    int32 version = 2
    double cameraUPos_x
    double cameraUPos_y
    double cameraUPos_z
    float cameraURot_x
    float cameraURot_y
    float cameraURot_z
    float cameraURot_w
    int32 reformCursorSize (version >= 1)
    int32 numReplicatorMultipliers (version >= 1)
    replicatorMultipliers[numReplicatorMultipliers] (version >= 1) {
        int32 key
        int32 value
    }
    uint8_bool detailPower
    uint8_bool detailVein
    uint8_bool detailSpaceGuide
    uint8_bool detailSign
    uint8_bool detailIcon
    int32 numTutorialShowing (version >= 2)
    int32 tutorialShowing[numTutorialShowing] (version >= 2)
}

GameHistoryData
{
    int32 version = 2
    int32 numRecipeUnlocked
    int32 recipeUnlocked[numRecipeUnlocked]
    int32 numTutorialUnlocked (version >= 2)
    int32 tutorialUnlocked[numTutorialUnlocked] (version >= 2)
    int32 numFeatureKeys
    int32 featureKeys[numFeatureKeys]
    int32 numTechState
    TechState[numTechState] {
        int32 techProtoIndex
        uint8_bool TechState_unlocked
        int32 TechState_curLevel
        int32 TechState_maxLevel
        int64 TechState_hashUploaded
        int64 TechState_hashNeeded
    }
    uint8_bool autoManageLabItems
    int32 currentTech
    int32 numTechQueue (version >= 1)
    int32 techQueue[numTechQueue] (version >= 1)
    int32 universeObserveLevel
    float solarSailLife
    float solarEnergyLossRate
    uint8_bool useIonLayer
    int32 inserterStackCount
    float logisticDroneSpeed
    float logisticDroneSpeedScale
    int32 logisticDroneCarries
    float logisticShipSailSpeed
    float logisticShipWarpSpeed
    float logisticShipSpeedScale
    uint8_bool logisticShipWarpDrive
    int32 logisticShipCarries
    float miningCostRate
    float miningSpeedScale
    int32 storageLevel
    int32 labLevel
    int32 techSpeed
    float dysonNodeLatitude
    int64 universeMatrixPointUploaded
    uint8_bool missionAccomplished
}

GameStatData
{
    int32 version = 0
    int32 numTechHashedHistory
    int32 techHashedHistory[numTechHashedHistory]
    ProductionStatistics
}

ProductionStatistics
{
    int32 version = 0
    int32 numFactoryStatPool
    FactoryProductionStat factoryStatPool[numFactoryStatPool]
    int32 numFirstCreateIds
    int32 firstCreateIds[numFirstCreateIds]
    int32 numFavoriteIds
    int32 favoriteIds[numFavoriteIds]
}

FactoryProductionStat
{
    int32 version = 1
    int32 productCapacity
    int32 productCursor
    ProductStat productPool[productCursor - 1]
    int32 numPowerPool, max 5
    PowerStat powerPool[numPowerPool]
    int32 numProductIndices
    int32 productIndices[numProductIndices]
    int64 energyConsumption (version >= 1)
}

ProductStat
{
    int32 version = 0
    int32 numCount:  Saved as 7200.  Reads more or less, but only stores up to 7200, and enforces abs.
    int32 count[numCount]
    int32 numCursor:  Saved as 12.  Reads more or less, but only stores up to 12.
    int32 cursor[numCount]
    int32 numTotal:  Saved as 14.  Reads more or less, but only stores up to 14, and enforces abs.
    int32 total[numCount]
    int32 itemId
}

PowerStat
{
    int32 version = 0
    int32 numEnergy:  Saved as 3600.  Reads more or less, but only stores up to 3600, and enforces abs.
    int64 energy[numCount]
    int32 numCursor:  Saved as 6.  Reads more or less, but only stores up to 6.
    int32 cursor[numCount]
    int32 numTotal:  Saved as 7.  Reads more or less, but only stores up to 7, and enforces abs.
    int64 total[numCount]
}

Player
{
    int32 version = 1
    int32 planetId: Ignored on read
    float position_x
    float position_y
    float position_z
    double uPosition_x
    double uPosition_y
    double uPosition_z
    float uRotation_x
    float uRotation_y
    float uRotation_z
    float uRotation_w
    int32 EMovementState movementState (Walk, Drift, Fly, Sail)
    float warpState
    uint8_bool warpCommand
    double uVelocity_x
    double uVelocity_y
    double uVelocity_z
    int32 inhandItemId
    int32 inhandItemCount
    Mecha
    StorageComponent package
    PlayerNavigation
    int32 sandCount
}

Mecha
{
    int32 version = 0
    double coreEnergyCap
    double coreEnergy
    double corePowerGen
    double reactorPowerGen
    double reactorEnergy
    int32 reactorItemId
    StorageComponent reactorStorage
    StorageComponent warpStorage
    double walkPower
    double jumpEnergy
    double thrustPowerPerAcc
    double warpKeepingPowerPerSpeed
    double warpStartPowerPerSpeed
    double miningPower
    double replicatePower
    double researchPower
    double droneEjectEnergy
    double droneEnergyPerMeter
    int32 coreLevel
    int32 thrusterLevel
    float miningSpeed
    float replicateSpeed
    float walkSpeed
    float jumpSpeed
    float maxSailSpeed
    float maxWarpSpeed
    float buildArea
    MechaForge
    MechaLab
    int32 droneCount
    float droneSpeed
    int32 droneMovement
    MechaDrone[droneCount]
}

StorageComponent
{
    int32 version = 1
    int32 id
    int32 entityId
    int32 previous (version >= 1)
    int32 next (version >= 1)
    int32 bottom (version >= 1)
    int32 top (version >= 1)
    int32 EStorageType type (0:Default 1:Fuel 9:Filtered)
    int32 gridSize
    int32 bans (version >= 1)
    grids[gridSize] {
        int32 itemId
        int32 filter
        int32 count
        int32 stackSize
    }
}

MechaForge
{
    int32 version = 0
    int32 numTasks
    ForgeTask tasks[numTasks]
}

ForgeTask
{
    int32 version = 0
    int32 recipeId
    int32 count
    int32 tick
    int32 tickSpend
    int32 numItem
    int32 numProduct
    [numItem] {
        int32 itemIds
        int32 itemCounts
        int32 served
    }
    [numProduct] {
        int32 productIds
        int32 productCounts
        int32 produced
    }
    int32 parentTaskIndex
}

MechaLab
{
    int32 version = 0
    int32 numItemPoints
    itemPoints[numItemPoints] {
        int32 key
        int32 value
    }
}

MechaDrone
{
    int32 version = 0
    int32 stage
    float position_x
    float position_y
    float position_z
    float target_x
    float target_y
    float target_z
    float forward_x
    float forward_y
    float forward_z
    float speed
    int32 movement
    int32 targetObject
    float progress
    float initialVector_x
    float initialVector_y
    float initialVector_z
}

PlayerNavigation
{
    int32 version = 0
    uint8_bool navigating
    int32 naviAstroId
    double naviTarget_x
    double naviTarget_y
    double naviTarget_z
    uint8_bool useFly
    uint8_bool useSail
    uint8_bool useWarp
    int32 ENaviStage stage (None, Departure, OriginOrbit, AccOrbit, Space, DestOrbit, Approaching)
    double flyThreshold
    double sailThreshold
    double warpThreshold
    double maxSailSpeed
}

GalacticTransport
{
    int32 version = 0
}

PlanetFactory
{
    int32 version = 1
    int32 planetId
    PlanetData
    int32 entityCapacity
    int32 entityCursor
    int32 entityRecycleCursor
    EntityData entityPool[entityCursor - 1]
    entityAnimPool[entityCursor - 1] {
        float time
        float prepare_length
        float working_length
        uint32 state
        float power
    }
    entitySignPool[entityCursor - 1] {
        uint32 signType
        uint32 iconType
        uint32 iconId0
        uint32 iconId1
        uint32 iconId2
        uint32 iconId3
        float count0
        float count1
        float count2
        float count3
        float x
        float y
        float z
        float w
    }
    int32 entityConnPool[entityCursor * 16 - 16]
    int32 entityRecycle[entityRecycleCursor]
    int32 prebuildCapacity
    int32 prebuildCursor
    int32 prebuildRecycleCursor
    PrebuildData prebuildPool[prebuildCursor - 1]
    int32 prebuildConnPool[prebuildCursor * 16 - 16]
    int32 prebuildRecycle[prebuildRecycleCursor]
    int32 vegeCapacity
    int32 vegeCursor
    int32 vegeRecycleCursor
    VegeData vegePool[vegeCursor - 1]
    int32 vegeRecycle[vegeRecycleCursor]
    int32 veinCapacity
    int32 veinCursor
    int32 veinRecycleCursor
    VeinData veinPool[veinCursor - 1]
    int32 veinRecycle[veinRecycleCursor]
    veinAnimPool[veinCursor - 1] {
        float time
        float prepare_length
        float working_length
        uint32 state
        float power
    }
    CargoContainer
    CargoTraffic
    FactoryStorage
    PowerSystem
    FactorySystem
    PlanetTransport
    MonsterSystem
    PlatformSystem (version >= 1)
}

PlanetData
{
    int32 modDataByteCount
    uint8 modData[modDataByteCount]
    int32 numVeinAmounts
    int64 veinAmounts[numVeinAmounts]: The index is the EVeinType.  This contains the total of the veinGroups's amounts which is also the total of the VeinData::amounts.
    int32 numVeinGroups
    veinGroups[numVeinGroups] {
        int32 EVeinType type (None, Iron, Copper, Silicium, Titanium, Stone, Coal, Oil, Fireice, Diamond, Fractal, Crysrub, Grat, Bamboo, Mag)
        float pos_x
        float pos_y
        float pos_z
        int32 count: Read, but then set to zero
        int64 amount: Read, but then set to zero
    }
}

EntityData
{
    uint8 version = 0
    int32 id
    int16 protoId
    int16 modelIndex
    float pos_x
    float pos_y
    float pos_z
    float rot_x
    float rot_y
    float rot_z
    float rot_w
    int32 beltId
    int32 splitterId
    int32 storageId
    int32 tankId
    int32 minerId
    int32 inserterId
    int32 assemblerId
    int32 fractionateId
    int32 ejectorId
    int32 siloId
    int32 labId
    int32 stationId
    int32 powerNodeId
    int32 powerGenId
    int32 powerConId
    int32 powerAccId
    int32 powerExcId
    int32 monsterId
}

PrebuildData
{
    uint8 version = 0
    int32 id
    int16 protoId
    int16 modelIndex
    float pos_x
    float pos_y
    float pos_z
    float rot_x
    float rot_y
    float rot_z
    float rot_w
    float pos2_x
    float pos2_y
    float pos2_z
    float rot2_x
    float rot2_y
    float rot2_z
    float rot2_w
    int32 upEntity
    int16 pickOffset
    int16 insertOffset
    int32 recipeId
    int32 filterId
    int32 refCount
    int32 refArr[refCount]
}

VegeData
{
    uint8 version = 0
    int32 id
    int16 protoId
    int16 modelIndex
    int16 hp
    float pos_x
    float pos_y
    float pos_z
    float rot_x
    float rot_y
    float rot_z
    float rot_w
    float scl_x
    float scl_y
    float scl_z
}

VeinData
{
    uint8 version = 0
    int32 id
    int16 EVeinType (see above)
    int16 modelIndex
    int16 groupIndex
    int32 amount
    int32 productId
    float pos_x
    float pos_y
    float pos_z
    int32 minerCount
    int32 minerId0
    int32 minerId1
    int32 minerId2
    int32 minerId3
}

CargoContainer
{
    int32 version = 0
    int32 poolCapacity
    int32 cursor
    int32 recycleBegin
    int32 recycleEnd
    cargoPool[cursor] {
        int32 item
        float position_x
        float position_y
        float position_z
        float rotation_x
        float rotation_y
        float rotation_z
        float rotation_w
    }
    int32 recycleIds[poolCapacity]
}

CargoTraffic
{
    int32 version = 0
    int32 beltCursor
    int32 beltCapacity
    int32 beltRecycleCursor
    int32 splitterCursor
    int32 splitterCapacity
    int32 splitterRecycleCursor
    int32 pathCursor
    int32 pathCapacity
    int32 pathRecycleCursor
    BeltComponent beltPool[beltCursor - 1]
    int32 beltRecycle[beltRecycleCursor]
    SplitterComponent splitterPool[splitterCursor - 1]
    int32 splitterRecycle[splitterRecycleCursor]
    [pathCursor - 1] {
        int32 cargoPathIndex
        CargoPath pathPool (cargoPathIndex != 0)
    }
    int32 pathRecycle[pathRecycleCursor]
}

BeltComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 speed
    int32 segPathId
    int32 segIndex
    int32 segPivotOffset
    int32 segLength
    int32 outputId
    int32 backInputId
    int32 leftInputId
    int32 rightInputId
}

SplitterComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 beltA
    int32 beltB
    int32 beltC
    int32 beltD
    int32 input0
    int32 input1
    int32 input2
    int32 input3
    int32 output0
    int32 output1
    int32 output2
    int32 output3
    uint8_bool inPriority
    uint8_bool outPriority
    int32 outFilter
}

CargoPath
{
    int32 version = 0
    int32 id
    int32 capacity
    int32 bufferLength
    int32 chunkCapacity
    int32 chunkCount
    int32 updateLen
    uint8_bool closed
    int32 outputPathIdForImport
    int32 outputIndex
    int32 numBelts
    int32 numInputPaths
    uint8 buffer[bufferLength]
    int32 chunks[chunkCount * 3]
    [bufferLength] {
        float pointPos_x
        float pointPos_y
        float pointPos_z
        float pointRot_x
        float pointRot_y
        float pointRot_z
        float pointRot_w
    }
    int32 belts[numBelts]
    int32 inputPaths[numInputPaths]
}

FactoryStorage
{
    int32 version = 0
    int32 storageCursor
    int32 storageCapacity
    int32 storageRecycleCursor
    [storageCursor - 1] {
        int32 storagePoolIndex
        int32 size (storagePoolIndex != 0)
        StorageComponent storagePool (storagePoolIndex != 0)
    }
    int32 storageRecycle[storageRecycleCursor]
    int32 tankCapacity
    int32 tankCursor
    int32 tankRecycleCursor
    TankComponent tankPool[tankCursor - 1]
    int32 tankRecycle[tankRecycleCursor]
}

TankComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 lastTankId
    int32 nextTankId
    int32 belt0
    int32 belt1
    int32 belt2
    int32 belt3
    uint8_bool isOutput0
    uint8_bool isOutput1
    uint8_bool isOutput2
    uint8_bool isOutput3
    int32 fluidStorageCount
    int32 currentCount
    int32 fluidId
    uint8_bool outputSwitch
    uint8_bool inputSwitch
    uint8_bool isBottom
}

PowerSystem
{
    int32 version = 0
    int32 generatorCapacity
    int32 genCursor
    int32 genRecycleCursor
    PowerGeneratorComponent genPool[genCursor - 1]
    int32 genRecycle[genRecycleCursor]
    int32 nodeCapacity
    int32 nodeCursor
    int32 nodeRecycleCursor
    PowerNodeComponent nodePool[nodeCursor - 1]
    int32 nodeRecycle[nodeRecycleCursor]
    int32 consumerCapacity
    int32 consumerCursor
    int32 consumerRecycleCursor
    PowerConsumerComponent consumerPool[consumerCursor - 1]
    int32 consumerRecycle[consumerRecycleCursor]
    int32 accumulatorCapacity
    int32 accCursor
    int32 accRecycleCursor
    PowerAccumulatorComponent accPool[accCursor - 1]
    int32 accRecycle[accRecycleCursor]
    int32 exchangerCapacity
    int32 excCursor
    int32 excRecycleCursor
    PowerExchangerComponent excPool[excCursor - 1]
    int32 excRecycle[excRecycleCursor]
    int32 networkCapacity
    int32 netCursor
    int32 netRecycleCursor
    [netCursor] {
        int32 powerNetworkIncludedFlag
        PowerNetwork netPool (powerNetworkIncludedFlag == 1)
    }
    int32 netRecycle[netRecycleCursor]
}

PowerGeneratorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    uint8_bool photovoltaic
    uint8_bool wind
    uint8_bool gamma
    int64 genEnergyPerTick
    int64 useFuelPerTick
    int16 fuelMask
    int64 fuelEnergy
    int16 curFuelId
    int16 fuelId
    int16 fuelCount
    int64 fuelHeat
    int32 catalystId
    int32 catalystPoint
    int32 productId
    float productCount
    int64 productHeat
    float warmup
    float ionEnhance
    float x
    float y
    float z
}

PowerNodeComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    uint8_bool isCharger
    int32 workEnergyPerTick
    int32 idleEnergyPerTick
    int32 requiredEnergy
    float powerPoint_x
    float powerPoint_y
    float powerPoint_z
    float connectDistance
    float coverRadius
}

PowerConsumerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    float plugPos_x
    float plugPos_y
    float plugPos_z
    int64 requiredEnergy
    int64 servedEnergy
    int64 workEnergyPerTick
    int64 idleEnergyPerTick
}

PowerAccumulatorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 networkId
    int64 inputEnergyPerTick
    int64 outputEnergyPerTick
    int64 curEnergy
    int64 maxEnergy
}

PowerExchangerComponent
{
    int32 version = 1
    int32 id
    int32 entityId
    int32 networkId
    int16 emptyCount
    int16 fullCount
    float targetState
    float state
    int64 energyPerTick
    int64 curPoolEnergy
    int64 poolMaxEnergy
    int32 emptyId
    int32 fullId
    int32 belt0 (version >= 1)
    int32 belt1 (version >= 1)
    int32 belt2 (version >= 1)
    int32 belt3 (version >= 1)
    uint8_bool isOutput0 (version >= 1)
    uint8_bool isOutput1 (version >= 1)
    uint8_bool isOutput2 (version >= 1)
    uint8_bool isOutput3 (version >= 1)
    int32 outputSlot (version >= 1)
    int32 inputSlot (version >= 1)
    int32 outputRectify (version >= 1)
    int32 inputRectify (version >= 1)
}

PowerNetwork
{
    int32 version = 0
    int32 id
    int32 numNodes
    int32 numConsumers
    int32 numGenerators
    int32 numAccumulators
    int32 numExchangers
    PowerNetworkStructures::Node[numNodes]
    int32 consumers[numConsumers]
    int32 generators[numGenerators]
    int32 accumulators[numAccumulators]
    int32 exchangers[numExchangers]
}

PowerNetworkStructures::Node
{
    int32 version = 0
    int32 id
    float x
    float y
    float z
    float connDistance2
    float coverRadius2
    int32 genId
    int32 accId
    int32 excId
    int32 numConnIdsForLoad
    int32 numLineIdsForLoad
    int32 numConsumers
    int32 connIdsForLoad[numConnIdsForLoad]
    int32 lineIdsForLoad[numLineIdsForLoad]
    int32 consumers[numConsumers]
}

FactorySystem
{
    int32 version = 0
    int32 minerCapacity
    int32 minerCursor
    int32 minerRecycleCursor
    MinerComponent minerPool[minerCursor - 1]
    int32 minerRecycle[minerRecycleCursor]
    int32 inserterCapacity
    int32 inserterCursor
    int32 inserterRecycleCursor
    InserterComponent inserterPool[inserterCursor - 1]
    int32 inserterRecycle[inserterRecycleCursor]
    int32 assemblerCapacity
    int32 assemblerCursor
    int32 assemblerRecycleCursor
    AssemblerComponent assemblerPool[assemblerCursor - 1]
    int32 assemblerRecycle[assemblerRecycleCursor]
    int32 fractionateCapacity
    int32 fractionateCursor
    int32 fractionateRecycleCursor
    FractionateComponent fractionatePool[fractionateCursor - 1]
    int32 fractionateRecycle[fractionateRecycleCursor]
    int32 ejectorCapacity
    int32 ejectorCursor
    int32 ejectorRecycleCursor
    EjectorComponent ejectorPool[ejectorCursor - 1]
    int32 ejectorRecycle[ejectorRecycleCursor]
    int32 siloCapacity
    int32 siloCursor
    int32 siloRecycleCursor
    SiloComponent siloPool[siloCursor - 1]
    int32 siloRecycle[siloRecycleCursor]
    int32 labCapacity
    int32 labCursor
    int32 labRecycleCursor
    LabComponent labPool[labCursor - 1]
    int32 labRecycle[labRecycleCursor]
}

MinerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 EMinerType type (None, Water, Vein, Oil)
    int32 speed
    int32 time
    int32 period
    int32 insertTarget
    int32 EWorkState workstate (Idle, Running, Outputing, Lack, Full)
    int32 veinCount
    int32 veins[veinCount]
    int32 currentVeinIndex
    int32 minimumVeinAmount
    int32 productId
    int32 productCount
    uint32 seed
}

InserterComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 EInserterStage stage (Picking, Sending, Inserting, Returning)
    int32 speed
    int32 time
    int32 stt
    int32 delay
    int32 pickTarget
    int32 insertTarget
    uint8_bool careNeeds
    uint8_bool canStack
    int16 pickOffset
    int16 insertOffset
    int32 filter
    int32 itemId
    int32 stackCount
    int32 stackSize
    float pos2_x
    float pos2_y
    float pos2_z
    float rot2_x
    float rot2_y
    float rot2_z
    float rot2_w
    int16 t1
    int16 t2
}

AssemblerComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    uint8_bool replicating
    uint8_bool outputing
    int32 speed
    int32 time
    int32 recipeId
    (recipeId > 0) {
        int32 ERecipeType recipeType (0:None 1:Smelt 2:Chemical 3:Refine 4:Assemble 5:Particle 6:Exchange 7:PhotonStore 8:Fractionate 15:Research)
        int32 timeSpend
        int32 numRequires
        int32 requires[numRequires]
        int32 numRequireCounts
        int32 requireCounts[numRequireCounts]
        int32 numServed
        int32 served[numServed]
        int32 numNeeds
        int32 needs[numNeeds]
        int32 numProducts
        int32 products[numProducts]
        int32 numProductCounts
        int32 productCounts[numProductCounts]
        int32 numProduced
        int32 produced[numProduced]
    }
}

FractionateComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 belt0
    int32 belt1
    int32 belt2
    uint8_bool isOutput0
    uint8_bool isOutput1
    uint8_bool isOutput2
    uint8_bool isWorking
    float produceProb
    int32 need
    int32 product
    int32 needCurrCount
    int32 productCurrCount
    int32 oriProductCurrCount
    int32 progress
    uint8_bool isRand
    uint8_bool fractionateSuccess
    int32 needMaxCount
    int32 productMaxCount
    int32 oriProductMaxCount
    uint32 seed
}

EjectorComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 planetId
    int32 pcId
    int32 direction
    int32 time
    uint8_bool fired
    int32 chargeSpend
    int32 coldSpend
    int32 bulletId
    int32 bulletCount
    int32 orbitId
    float pivotY
    float muzzleY
    float localPosN_x
    float localPosN_y
    float localPosN_z
    float localAlt
    float localRot_x
    float localRot_y
    float localRot_z
    float localRot_w
    float localDir_x
    float localDir_y
    float localDir_z
}

SiloComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 planetId
    int32 pcId
    int32 direction
    int32 time
    uint8_bool fired
    int32 chargeSpend
    int32 coldSpend
    int32 bulletId
    int32 bulletCount
    int32 autoIndex
    uint8_bool hasNode
    float localPos_x
    float localPos_y
    float localPos_z
    float localRot_x
    float localRot_y
    float localRot_z
    float localRot_w
}

LabComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    int32 pcId
    int32 nextLabId
    uint8_bool replicating
    uint8_bool outputing
    int32 time
    int32 hashBytes
    uint8_bool researchMode
    int32 recipeId
    int32 techId
    (not researchMode and recipeId > 0) {
        int32 timeSpend
        int32 numRequires
        int32 requires[numRequires]
        int32 numRequireCounts
        int32 requireCounts[numRequireCounts]
        int32 numServed
        int32 served[numServed]
        int32 numNeeds
        int32 needs[numNeeds]
        int32 numProducts
        int32 products[numProducts]
        int32 numProductCounts
        int32 productCounts[numProductCounts]
        int32 numProduced
        int32 produced[numProduced]
    }
    (researchMode) {
        int32 numMatrixPoints
        int32 matrixPoints[numMatrixPoints]
        int32 numMatrixServed
        int32 matrixServed[numMatrixServed]
        int32 numNeeds
        int32 needs[numNeeds]
    }
}

PlanetTransport
{
    int32 version = 0
    int32 stationCursor
    int32 stationCapacity
    int32 stationRecycleCursor
    [stationCursor - 1] {
        int32 stationIndex
        StationComponent stationPool (stationIndex != 0)
    }
    int32 stationRecycle[stationRecycleCursor]
}

StationComponent
{
    int32 version = 2
    int32 id
    int32 gid
    int32 entityId
    int32 planetId
    int32 pcId
    int32 gene
    float droneDock_x
    float droneDock_y
    float droneDock_z
    float shipDockPos_x
    float shipDockPos_y
    float shipDockPos_z
    float shipDockRot_x
    float shipDockRot_y
    float shipDockRot_z
    float shipDockRot_w
    uint8_bool isStellar
    int32 nameIsIncludedFlag (0 or 1)
    string name (nameIsIncludedFlag > 0)
    int64 energy
    int64 energyPerTick
    int64 energyMax
    int32 warperCount
    int32 warperMaxCount
    int32 idleDroneCount
    int32 workDroneCount
    int32: Used for allocating array sizes for workDroneDatas and workDroneOrders, and not uses for read in the arrays.
    DroneData workDroneDatas[workDroneCount]
    LocalLogisticOrder workDroneOrders[workDroneCount]
    int32 idleShipCount
    int32 workShipCount
    uint64 idleShipIndices
    uint64 workShipIndices
    int32: Used for allocating array sizes for workShipDatas, shipRenderers, shipUIRenderers, workShipOrders, and not uses for read in the arrays.
    ShipData workShipDatas[workShipCount]
    RemoteLogisticOrder workShipOrders[workShipCount]
    int32 numStorage
    StationStore[numStorage]
    (version >= 1) {
        int32 numSlots
        slots[numSlots] {
            int32 dir
            int32 beltId
            int32 storageIdx
            int32 counter
        }
    }
    int32 localPairProcess
    int32 remotePairProcess
    int32 nextShipIndex
    uint8_bool isCollector
    int32 numCollectionIds
    int32 collectionIds[numCollectionIds]
    int32 numCollectionPerTick
    float collectionPerTick[numCollectionPerTick]
    int32 numCurrentCollections
    float currentCollections[numCurrentCollections]
    int32 collectSpeed
    double tripRangeDrones (version >= 2)
    double tripRangeShips (version >= 2)
    uint8_bool includeOrbitCollector (version >= 2)
    double warpEnableDist (version >= 2)
    uint8_bool warperNecessary (version >= 2)
    int32 deliveryDrones (version >= 2)
    int32 deliveryShips (version >= 2)
}

DroneData
{
    int32 version = 0
    float begin_x
    float begin_y
    float begin_z
    float end_x
    float end_y
    float end_z
    int32 endId
    float direction
    float maxt
    float t
    int32 itemId
    int32 itemCount
    int32 gene
}

LocalLogisticOrder
{
    int32 version = 0
    int32 otherStationId
    int32 thisIndex
    int32 otherIndex
    int32 itemId
    int32 thisOrdered
    int32 otherOrdered
}

ShipData 
{
    int32 version = 0
    int32 stage
    int32 planetA
    int32 planetB
    double uPos_x
    double uPos_y
    double uPos_z
    float uVel_x
    float uVel_y
    float uVel_z
    float uSpeed
    float warpState
    float uRot_x
    float uRot_y
    float uRot_z
    float uRot_w
    float uAngularVel_x
    float uAngularVel_y
    float uAngularVel_z
    float uAngularSpeed
    double pPosTemp_x
    double pPosTemp_y
    double pPosTemp_z
    float pRotTemp_x
    float pRotTemp_y
    float pRotTemp_z
    float pRotTemp_w
    int32 otherGId
    int32 direction
    float t
    int32 itemId
    int32 itemCount
    int32 gene
    int32 shipIndex
    int32 warperCnt
}

RemoteLogisticOrder 
{
    int32 version = 0
    int32 otherStationGId
    int32 thisIndex
    int32 otherIndex
    int32 itemId
    int32 thisOrdered
    int32 otherOrdered
}

StationStore 
{
    int32 version = 0
    int32 itemId
    int32 count
    int32 localOrder
    int32 remoteOrder
    int32 max
    int32 ELogisticStorage localLogic (None, Supply, Demand)
    int32 ELogisticStorage remoteLogic
}

MonsterSystem
{
    int32 version = 0
    int32 monsterCapacity
    int32 monsterCursor
    int32 monsterRecycleCursor
    MonsterComponent monsterPool[monsterCursor - 1]
    int32 monsterRecycle[monsterRecycleCursor]
}

MonsterComponent
{
    int32 version = 0
    int32 id
    int32 entityId
    float walkSpeed
    float point0_x
    float point0_y
    float point0_z
    float point1_x
    float point1_y
    float point1_z
    float point2_x
    float point2_y
    float point2_z
    int32 direction
    float stopTime
    float t
    float stopCurrentTime
    int32 EMonsterState monsterState (Null, Stopped, Wandering)
    float stepDistance
}

PlatformSystem
{
    int32 version = 0
    int32 reformDataByteCount
    uint8 reformData[reformDataByteCount]: If count exceeds a limit, count is read, but only the limit is used.
    int32 reformOffsetsByteCount
    uint32 reformOffsets[reformOffsetsByteCount]: If count exceeds a limit, count is read, but only the limit is used.
}

DysonSphere
{
    int32 version = 2
    (version >= 1) {
        int32 randSeed
        DysonSwarm
        int32 = 1212: File will be rejected if the value is not 1212
        int32 layerCount
        int32 numDysonSphereLayer
        [numDysonSphereLayer - 1] {
            int32 dysonSphereLayerIndex
            DysonSphereLayer (dysonSphereLayerIndex != 0)
        }
        int32 rocketCapacity
        int32 rocketCursor
        int32 rocketRecycleCursor
        DysonRocket rocketPool[rocketCursor - 1]
        int32 rocketRecycle[rocketRecycleCursor]
        int32 autoNodeCount
        int32 numAutoNodes
        [numAutoNodes] {
            int32 autoNodeIncludedFlag
            int32 layerId (autoNodeIncludedFlag > 0)
            int32 nodeId (autoNodeIncludedFlag > 0)
        }
    }
    (version >= 2) {
        int32 nrdCapacity
        int32 nrdCursor
        int32 nrdRecycleCursor
        DysonNodeRData nrdPool[nrdCursor - 1]
        int32 nrdRecycle[nrdRecycleCursor]
    }
}

DysonSwarm
{
    int32 version = 4
    (version >= 1) {
        int32 randSeed
        int32 sailCapacity
        int32 sailCursor
        int32 sailRecycleCursor
        sailPoolForSave[sailCursor] {
            float st
            float px
            float py
            float pz
            float vx
            float vy
            float vz
            float gs
        }
        sailInfos[sailCursor] {
            uint32 orbit
            uint32 node (version >= 3)
            uint32 kill (version >= 3)
            float posr_x (version >= 4)
            float posr_y (version >= 4)
            float posr_z (version >= 4)
        }
        int32 sailRecycle[sailRecycleCursor]
        int32 orbitCapacity
        int32 orbitCursor
        SailOrbit orbits[orbitCursor - 1]
        int32 numExpiryOrder: Must match sailCapacity or the game will crash.
        int32 expiryCursor
        int32 expiryEnding
        [numExpiryOrder] {
            int64 time
            int32 index
        }
        (version >= 2) {
            int32 numAbsorbOrder: Must match sailCapacity or the game will crash.
            int32 absorbCursor
            int32 absorbEnding
            absorbOrder[numAbsorbOrder] {
                int64 time
                int32 index
                int32 layer
                int32 node
            }
        }
        int32 bulletCapacity
        int32 bulletCursor
        int32 bulletRecycleCursor
        SailBullet bulletPool[bulletCursor - 1]
        int32 bulletRecycle[bulletRecycleCursor]
    }
}

SailOrbit
{
    int32 version = 0
    int32 id
    float radius
    float rotation_x
    float rotation_y
    float rotation_z
    float rotation_w
    float up_x
    float up_y
    float up_z
    int32 count
    uint8_bool enabled
}

SailBullet
{
    int32 version = 0
    int32 id
    float t
    float maxt
    int32 state
    float rBegin_x
    float rBegin_y
    float rBegin_z
    float rEnd_x
    float rEnd_y
    float rEnd_z
    float lBegin_x
    float lBegin_y
    float lBegin_z
    float uEndVel_x
    float uEndVel_y
    float uEndVel_z
    double uBegin_x
    double uBegin_y
    double uBegin_z
    double uEnd_x
    double uEnd_y
    double uEnd_z
}

DysonSphereLayer
{
    int32 version = 0
    int32 id
    float orbitRadius
    float orbitRotation_x
    float orbitRotation_y
    float orbitRotation_z
    float orbitRotation_w
    float orbitAngularSpeed
    float currentAngle
    float currentRotation_x
    float currentRotation_y
    float currentRotation_z
    float currentRotation_w
    float nextRotation_x
    float nextRotation_y
    float nextRotation_z
    float nextRotation_w
    int32 gridMode
    int32 nodeCapacity
    int32 nodeCursor
    int32 nodeRecycleCursor
    [nodeCursor - 1] {
        int32 dysonNodeIndex
        DysonNode (dysonNodeIndex != 0)
    }
    int32 nodeRecycle[nodeRecycleCursor]
    int32 frameCapacity
    int32 frameCursor
    int32 frameRecycleCursor
    [frameCursor - 1] {
        int32 dysonFrameIndex
        DysonFrame (dysonFrameIndex != 0)
    }
    int32 frameRecycle[frameRecycleCursor]
    int32 shellCapacity
    int32 shellCursor
    int32 shellRecycleCursor
    [shellCursor - 1] {
        int32 dysonShellIndex
        DysonShell (dysonShellIndex != 0)
    }
    int32 shellRecycle[shellRecycleCursor]
}

DysonNode
{
    int32 version = 4
    int32 id
    int32 protoId
    int32 layerId
    uint8_bool use
    uint8_bool reserved
    float pos_x
    float pos_y
    float pos_z
    int32 sp
    int32 spMax
    int32 spOrdered
    int32 cpOrdered (version >= 3)
    int32 rid (version >= 2)
    int32 frameTurn
    int32 shellTurn (version >= 1)
    int32 _spReq
    int32 _cpReq (version >= 4)
}

DysonFrame
{
    int32 version = 0
    int32 id
    int32 protoId
    int32 layerId
    uint8_bool reserved
    int32 nodeId
    int32 nodeId2
    uint8_bool euler
    int32 spA
    int32 spB
    int32 spMax
}

DysonShell
{
    int32 version = 0
    int32 id
    int32 protoId
    int32 layerId
    int32 randSeed
    int32 numPolygon
    polygon[numPolygon] {
        float item_x
        float item_y
        float item_z
    }
    int32 numDysonNode
    int32 nodeId[numDysonNode]: Must be an existing ID or the game will crash.
    int32 vertexCount
    int32 triangleCount
    int32 numVerts
    verts[numVerts] {
        float x
        float y
        float z
    }
    int32 numPqArr
    pqArr[numPqArr] {
        int32 x
        int32 y
    }
    int32 numTris
    int32 tris[numTris]
    int32 numVAdjs
    int32 vAdjs[numVAdjs]
    int32 numVertAttr
    int32 vertAttr[numVertAttr]
    int32 numVertsq
    int32 vertsq[numVertsq]
    int32 numVertsqOffset
    int32 vertsqOffset[numVertsqOffset]
    int32 numNodecps
    int32 nodecps[numNodecps]
    int32 numVertcps
    int32 vertcps[numVertcps]
    int32 vertRecycleArraySize
    int32 vertRecycleCursor
    int32 vertRecycle[vertRecycleCursor]
}

DysonRocket
{
    int32 version = 0
    int32 id
    int32 nodeLayerId
    int32 nodeId
    int32 planetId
    float t
    float uSpeed
    double uPos_x
    double uPos_y
    double uPos_z
    float uRot_x
    float uRot_y
    float uRot_z
    float uRot_w
    float uVel_x
    float uVel_y
    float uVel_z
    float launch_x
    float launch_y
    float launch_z
}

DysonNodeRData
{
    int32 version = 0
    int32 id
    int32 layerId
    float pos_x
    float pos_y
    float pos_z
    float angularVel
    float layerRot_x
    float layerRot_y
    float layerRot_z
    float layerRot_w
}


🍪 We use cookies to keep session information to provide you a better experience.