Skip to content

Commit

Permalink
docs(SaveGame): update SAVEDAT.SAV structure
Browse files Browse the repository at this point in the history
  • Loading branch information
lmichaelis committed Feb 11, 2024
1 parent 9daf7dc commit e239bfa
Showing 1 changed file with 38 additions and 30 deletions.
68 changes: 38 additions & 30 deletions docs/engine/formats/savegame.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,82 +57,90 @@ originally only used to generate the save-game list preview when browsing saved
Contains most of the script and world state information of the save-game. It uses the [ZenGin Archive](archive.md)
format and structured as follows:

<ul class="sp-list">
<li class="sp-int"><a href="#day">day</a> = 0</li>
<li class="sp-int"><a href="#hour">hour</a> = 0</li>
<li class="sp-int"><a href="#min">min</a> = 0</li>
<li class="sp-type"><a href="../../objects/oCInfoManager/">(inline) oCInfoManager</a><sup>1</sup></li>
<li class="sp-type"><a href="../../objects/oCMissionManager/">(inline) oCMissionManager</a><sup>1</sup></li>
<li class="sp-type"><a href="../../objects/oCLogManager/">(inline) oCLogManager</a><sup>1</sup></li>
<li class="sp-type"><a href="../../objects/oCCSManager/">oCCSManager</a></li>
<li class="sp-int"><a href="#numSymbols">numSymbols</a> = 0</li>
<li class="sp-folder">
<span>[Symbol]</span>
<ul class="sp-list">
<li class="sp-string"><a href="#symName">symName0</a> = ""</li>
<li class="sp-int"><a href="#symValue">symValue0</a> = 0</li>
<li class="sp-int"><a href="#symNameCnt">symName0cnt</a> = 0</li>
<li class="sp-int"><a href="#symValue_">symValue0_0</a> = 0</li>
</ul>
</li>
<li class="sp-misc"><a href="#guildTable">guildTable</a> = #</li>
</ul>

<a name="day" class="t-int"></a> `day`
- [day](#day) = 0
{: .sp-int}
- [hour](#hour) = 0
{: .sp-int}
- [min](#min) = 0
{: .sp-int}
- (inline)[^1] [oCInfoManager](../objects/oCInfoManager.md)
{: .sp-type}
- (inline)[^1] [oCMissionManager](../objects/oCMissionManager.md)
{: .sp-type}
- (inline)[^1] [oCLogManager](../objects/oCLogManager.md)
{: .sp-type}
- (inline)[^1] [oCCSManager](../objects/oCCSManager.md)
{: .sp-type}
- [numSymbols](#numsymbols) = 0
{: .sp-int}
- (Symbol) ...
{: .sp-folder}
- [symName0](#symname) = ""
{: .sp-string}
- [symValue0](#symvalue) = 0
{: .sp-int}
- [symName0cnt](#symnamecnt) = 0
{: .sp-int}
- [symValue0_0](#symvalue_) = 0
{: .sp-int}
- [guildTable](#guildtable) = 0 ...
{: .sp-misc}

#### `day` {: .t-int}

: The number of in-game days played in the save-game.

!!! info
This value is the true time to be set when loading the save. The value stored in [`SAVEINFO.SAV`](saveinfosav)
is discarded and only used in the save-game preview.

<a name="hour" class="t-int"></a> `hour`
#### `hour` {: .t-int}

: The hour of the in-game [day](#day) when the save-game was created (values from `0` to `24`).

!!! info
This value is the true time to be set when loading the save. The value stored in [`SAVEINFO.SAV`](saveinfosav)
is discarded and only used in the save-game preview.

<a name="min" class="t-int"></a> `min`
#### `min` {: .t-int}

: The minute of the in-game [hour](#hour) when the save-game was created (values from `0` to `59`).

!!! info
This value is the true time to be set when loading the save. The value stored in [`SAVEINFO.SAV`](saveinfosav)
is discarded and only used in the save-game preview.

<a name="numSymbols" class="t-int"></a> `numSymbols`
#### `numSymbols` {: .t-int}

: The number of script symbol values that are stored in the archive.

<a name="symName" class="t-string"></a> `symName0`
#### `symName0` {: .t-string}

: The name of the symbol the next value is stored for. Appears for every stored symbol value and is suffixed with the
index in the saved symbol list.

<a name="symValue" class="t-int"></a> `symValue0`
#### `symValue0` {: .t-int}

: The single value saved for the symbol.

!!! warning
Only available in *Gothic I*-saves. *Gothic II* allows for storing multiple values per symbol; see [symName0cnt](#symNameCnt).

<a name="symNameCnt" class="t-int"></a> `symName0cnt`
#### `symName0cnt` {: .t-int}

: The number of values stored for the symbol. Appears for every stored symbol value.

!!! warning
Only available in *Gothic II*-saves.

<a name="symValue_" class="t-int"></a> `symValue0_0`
#### `symValue0_0` {: .t-int}

: The value of the symbol at the index given by the suffix. Stored sequentially.

!!! warning
Only available in *Gothic II*-saves.

<a name="guildTable" class="t-misc"></a> `guildTable`
#### `guildTable` {: .t-misc}

: The attitude values for each in-game guild towards each other. Stored as a 42x42 matrix in the `raw` format.

Expand Down

0 comments on commit e239bfa

Please sign in to comment.