Saved game data: Difference between revisions
DansFriend (talk | contribs) |
DansFriend (talk | contribs) |
||
(52 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
{{Original research|author=[[User:DansFriend|Dan's Friend]] and [[User:Lazlo52|Lazlo52]]}} | |||
This page documents ''[[MediEvil]]'' '''saved game data''' formats. | This page documents ''[[MediEvil]]'' '''saved game data''' formats. | ||
==''MediEvil'' (1998 original)== | ==''MediEvil'' (1998 original)== | ||
A PlayStation Memory Card data block consists of 64 frames. | A PlayStation Memory Card data block consists of 64 frames. Each frame is 128 bytes long.<ref>{{Cite web|url=https://www.psdevwiki.com/ps3/PS1_Savedata#Memory_card_PS1_(original)|site=PS3 Developer wiki|title=PS1 Savedata|retrieved=November 22, 2024}}</ref> | ||
===Frame 0=== | ===Frame 0=== | ||
This frame is the header for a block of PS1 saved data. | This frame is the header for a block of PS1 saved data. | ||
Line 7: | Line 8: | ||
! Name | ! Name | ||
! Offset | ! Offset | ||
! Length | |||
! Value | ! Value | ||
! Meaning | ! Meaning | ||
Line 12: | Line 14: | ||
| '''Magic''' | | '''Magic''' | ||
| 0x0 | | 0x0 | ||
| 2 | |||
| SC | | SC | ||
| Signature for all PS1 saved game data. | | Signature for all PS1 saved game data. | ||
|- | |- | ||
| '''Icon | | '''Icon flag''' | ||
| 0x2 | | 0x2 | ||
| 1 | |||
| 11 | | 11 | ||
| This means the icon for the saved game consists of a single image. | | This means the icon for the saved game consists of a single image. | ||
|- | |- | ||
| ''' | | '''Number of blocks''' | ||
|0x3 | | 0x3 | ||
| 1 | |||
| 1 | | 1 | ||
| How many blocks the save will take up on a memory card. | | How many blocks the save will take up on a memory card. | ||
Line 27: | Line 32: | ||
| '''Title''' | | '''Title''' | ||
| 0x4 | | 0x4 | ||
| 64 | |||
| MediEvil | | MediEvil | ||
| Name of the saved game in Shift JIS format. | | Name of the saved game in Shift JIS format. | ||
|- | |- | ||
| '''Icon | | '''Icon colour palette''' | ||
| 0x96 | | 0x96 | ||
| 32 | |||
| [[File:MediEvil1998-MemoryCardIconPalette.png]] | | [[File:MediEvil1998-MemoryCardIconPalette.png]] | ||
| Saved game icon colour palette. | | Saved game icon colour palette. | ||
Line 43: | Line 50: | ||
These frames contain the actual ''MediEvil'' saved game data. | These frames contain the actual ''MediEvil'' saved game data. | ||
====File header==== | ====File header==== | ||
The header is 12 bytes long. | The header is 12 bytes long. The offsets in the table below are relative to the beginning of Frame 4. | ||
{| class="wikitable" | {| class="wikitable" | ||
! Name | ! Name | ||
! Offset | ! Offset | ||
! Length | |||
! Value | ! Value | ||
! Meaning | ! Meaning | ||
Line 52: | Line 60: | ||
|'''Magic''' | |'''Magic''' | ||
|0x0 | |0x0 | ||
|4 | |||
|60SM | |60SM | ||
|Signature for ''MediEvil'' saved game data. | |Signature for ''MediEvil'' saved game data. | ||
|- | |- | ||
|'''Saved | |'''Saved games''' | ||
|0x4 | |0x4 | ||
|1 | |||
|0-2 | |0-2 | ||
|The number of saved games. | |The number of saved games. | ||
|} | |} | ||
====Saved games==== | ====Saved games==== | ||
The file can hold a maximum of three saved games. Each saved game is | The file can hold a maximum of three saved games. Each saved game is 1360 bytes long. The offsets for the saved games relative to the beginning of the Memory Card data block are 0x20C, 0x75C, and 0xCAC. | ||
=====Saved game===== | =====Saved game===== | ||
The offsets in the table below are relative to the beginning of a saved game. | |||
{| class="wikitable" | {| class="wikitable" | ||
! colspan="5" | General | |||
|- | |||
! Name | ! Name | ||
! Offset | ! Offset | ||
! Length | |||
! Value | ! Value | ||
! Meaning | ! Meaning | ||
Line 71: | Line 86: | ||
|'''Checksum''' | |'''Checksum''' | ||
| 0x0 | | 0x0 | ||
| 4 | |||
| Number | | Number | ||
| Used to verify | | Used to verify saved game integrity. Uses the Checksum-32 algorithm. | ||
|- | |- | ||
|'''Save | |'''Level index''' | ||
|0x4 | |||
|2 | |||
|{{CollapsibleContent|show=see more|hide=see less|width=14em|01 - The Graveyard|02 - Return to the Graveyard<br>03 - Cemetery Hill<br>04 - The Hilltop Mausoleum<br>05 - Scarecrow Fields<br>06 - Dan's Crypt<br>07 - The Ant Caves<br>08 - The Crystal Caves<br>09 - Pumpkin Gorge<br>0A - The Pumpkin Serpent<br>0B - The Sleeping Village<br>0C - Pools Of The Ancient Dead<br>0D - The Asylum Grounds<br>0E - Inside The Asylum<br>0F - The Enchanted Earth<br>10 - The Gallows Gauntlet<br>11 - The Haunted Ruins<br>12 - Hall of Heroes<br>13 - The Ghost Ship<br>14 - The Entrance Hall<br>15 - The Time Device<br>16 - The Lake<br>17 - Zarok's Lair<br>18 - *Programmers's Playground}} | |||
|The index of the level the name of which will be displayed on the saved game tombstone and in the save game menu. Although 00 should be "<nowiki>*</nowiki>Title Level", setting the value to this will make the saved game unselectable. | |||
|- | |||
|'''Save game count''' | |||
|0x6 | |0x6 | ||
|2 | |||
|Number | |Number | ||
|Number of times the game has been saved. | |Number of times the game has been saved. | ||
|- | |||
! colspan="5" | Pause Menu Options | |||
|- | |||
! Name | |||
! Offset | |||
! Length | |||
! Value | |||
! Meaning | |||
|- | |||
|'''Options flags''' | |||
|0x8 | |||
|4 | |||
|<code>00000100</code> (NTSC-U default) | |||
|Various flags from the Pause Menu. From right to left:<br>Flag 0: Vibration (0 for on, 1 for off)<br>Flag 1: Audio Mode (0 for stereo, 1 for mono)<br>Flag 2: Walk/Run toggle (0 for on, 1 for off) | |||
|- | |||
|'''FX volume''' | |||
|0xC | |||
|2 | |||
|0-127 (80 default) | |||
|FX volume. Can be set through the Pause Menu. | |||
|- | |||
|'''Speech volume''' | |||
|0xE | |||
|2 | |||
|0-127 (110 default) | |||
|Speech volume. Can be set through the Pause Menu. | |||
|- | |||
|'''Music volume''' | |||
|0x10 | |||
|2 | |||
|0-127 (64 default) | |||
|Music volume. Can be set through the Pause Menu. | |||
|- | |||
|'''Lighting''' | |||
|0x12 | |||
|2 | |||
| (-192)-128 (32 default) | |||
|Lighting. Can be set through the Pause Menu. | |||
|- | |||
|'''Screen adjust (horizontal)''' | |||
|0x16 | |||
|2 | |||
| 0 (default) | |||
|Horizontal screen adjustment. Can be set through the Pause Menu. | |||
|- | |||
|'''Screen adjust (vertical)''' | |||
|0x18 | |||
|2 | |||
| 0 (default) | |||
|Vertical screen adjustment. Can be set through the Pause Menu. | |||
|- | |||
|'''Button layout''' | |||
|0x1A | |||
|2 | |||
|0-2 (0 default) | |||
|Button layout. Can be set through the Pause Menu. | |||
|- | |||
! colspan="5" | Player Stats | |||
|- | |||
! Name | |||
! Offset | |||
! Length | |||
! Value | |||
! Meaning | |||
|- | |||
|'''Time played''' | |||
|0x1C | |||
|4 | |||
|Number | |||
|Time the player has played the game for. Displayed on the tombstones in the main menu and on the save game screen. | |||
|- | |||
|'''Current energy''' | |||
|0x20 | |||
|4 | |||
|300 (default) | |||
|Dan's current energy (as seen in the Life Bar). Starts at 300. Changes when enemies attack Dan or when he heals. | |||
|- | |||
|'''Current stored energy''' | |||
|0x24 | |||
|4 | |||
|0 (default) | |||
|Current stored energy. Starts at 0, set to 300 once first Life Bottle is picked up. | |||
|- | |||
|'''Maximum stored energy''' | |||
|0x28 | |||
|4 | |||
|0 (default) | |||
|Maximum stored energy. Starts at 0, set to 300 once first Life Bottle is picked up. Only changes when Life Bottles are picked up. | |||
|- | |||
|'''Current weapon''' | |||
|0x2C | |||
|4 | |||
|{{CollapsibleContent|show=see more|hide=see less|width=12.75em|00 - Small Sword|01 - Broad Sword<br>02 - Magic Sword<br>03 - Throwing Daggers<br>04 - Axe<br>05 - Club<br>06 - Crossbow<br>07 - Chicken Drumsticks<br>08 - Arm<br>09 - Lightning<br>0A - Longbow<br>0B - Spear<br>0C - Hammer<br>0D Flaming Longbow<br>0E - Magic Longbow<br>0F - Good Lightning<br>10 - Dragon Armour<br>11 - Chaos Rune<br>12 - None}} | |||
|The weapon Dan is currently wielding. | |||
|- | |||
|'''Current shield''' | |||
|0x30 | |||
|4 | |||
|{{CollapsibleContent|show=see more|hide=see less|width=12.75em|00 - None|01 - Copper Shield<br>02 - Silver Shield<br>03 - Gold Shield}} | |||
|The shield Dan is currently wielding. If set without having set its durability in the inventory, it will immediately break. | |||
|- | |||
|'''Current map position''' | |||
|0x4C | |||
|4 | |||
|{{CollapsibleContent|show=see more|hide=see less|width=12.75em|00 - Dan's Crypt|01 - The Graveyard<br>02 - Return to the Graveyard<br>03 - Cemetery Hill<br>04 - The Hilltop Mausoleum<br>05 - Scarecrow Fields<br>06 - The Enchanted Earth<br>07 - Pumpkin Gorge<br>08 - The Pumpkin Serpent<br>09 - The Sleeping Village<br>0A - The Asylum Grounds<br>0B - Inside The Asylum<br>0C - Pools Of The Ancient Dead<br>0D - The Lake<br>0E - The Crystal Caves<br>0F - The Gallows Gauntlet<br>10 - The Haunted Ruins<br>11 - The Ghost Ship<br>12 - The Entrance Hall<br>13 - The Time Device<br>14 - Zarok's Lair}} | |||
|Dan's current position on the map. Setting this to a level that is locked will allow Dan to enter that level, but may create a softlocked saved game if previous levels are not unlocked on the map. | |||
|- | |||
! colspan="5" | Inventory | |||
|- | |||
! Name | |||
! Offset | |||
! Length | |||
! Value | |||
! Meaning | |||
|- | |||
|'''Small Sword''' | |||
|0xA0 | |||
|2 | |||
| -1 | |||
|The default value is -1 (<code>FF FF</code>), which means Dan doesn't have the Small Sword in his inventory. It is set to 0 when Dan obtains it. | |||
|- | |||
|'''Throwing Daggers''' | |||
|0xB4 | |||
|2 | |||
| -1 | |||
|The default value is -1 (<code>FF FF</code>), which means Dan doesn't have the Throwing Daggers in his inventory. Set to 100 when Dan obtains them, which is the amount of daggers. | |||
|- | |||
|'''Copper Shield''' | |||
|0x128 | |||
|2 | |||
| -1 | |||
|The default value is -1 (<code>FF FF</code>), which means Dan doesn't have the Copper Shield in his inventory. It is set to 150 (0x96) when Dan obtains it, which is the durability of the shield. | |||
|- | |||
|'''Gold Pieces''' | |||
|0x138 | |||
|2 | |||
| 0-32767 | |||
|The default value is 0. Updated when Dan picks up treasure. Because the value is a signed short, the maximum size is 32,767. If more gold should be collected, the value will break. It will no longer be displayed in the HUD and Dan won't be able to use it to buy anything from Merchant Gargoyles. | |||
|- | |||
! colspan="5" | Level Changes | |||
|- | |||
! Name | |||
! Offset | |||
! Length | |||
! Value | |||
! Meaning | |||
|- | |||
| '''Length of array''' | |||
| 0x14C | |||
| 4 | |||
| 0-256 | |||
| Length of the "level changes" array. The array grows each time something happens that should change a level permanently on replays. | |||
|- | |||
| '''Start of array''' | |||
| 0x150 | |||
| Length of array * 4 | |||
| <code>00 00 00 00</code> | |||
|This is where the "level changes" array begins. The maximum amount of members in the array is 256 (1024 bytes). | |||
|- | |||
| '''CR - don't play starting cutscene''' | |||
| N/A | |||
| 4 | |||
| <code>06 00 21 B6</code> | |||
|Makes it so that the cutscene at the beginning of Dan's Crypt with the Information Gargoyles is skipped. | |||
|- | |||
| '''CR - Small Sword to moneybag''' | |||
| N/A | |||
| 4 | |||
| <code>06 01 36 B3</code> | |||
|Changes the Small Sword pickup from Dan's Crypt into a moneybag. | |||
|- | |||
| '''CR - Life Bottle on dirt mound to moneybag''' | |||
| N/A | |||
| 4 | |||
| <code>06 01 E4 B5</code> | |||
|Changes the Life Bottle on the dirt mound in Dan's Crypt into a moneybag. | |||
|- | |||
| '''CR - secret Life Bottle to moneybag''' | |||
| N/A | |||
| 4 | |||
| <code>06 01 C6 B6</code> | |||
|Changes the Life Bottle behind the breakable wall in Dan's Crypt into a moneybag. | |||
|} | |} | ||
===Frames 35 to 63=== | ===Frames 35 to 63=== | ||
These are unused. | These are unused. | ||
==References== | |||
{{Reflist}} | |||
==Navigation== | ==Navigation== | ||
{{Empty section|Navigation}} | {{Empty section|Navigation}} | ||
[[Category:Files in MediEvil]] | [[Category:Files in MediEvil]] |
Latest revision as of 13:55, 22 November 2024
- The following article contains original research by Dan's Friend and Lazlo52.
This page documents MediEvil saved game data formats.
MediEvil (1998 original)
A PlayStation Memory Card data block consists of 64 frames. Each frame is 128 bytes long.[1]
Frame 0
This frame is the header for a block of PS1 saved data.
Frame 1
This frame is used to store a PS1 saved game icon:
Frames 2-3
These frames are reserved for additional images in case the icon is meant to be animated, but are unused by MediEvil.
Frames 4-34
These frames contain the actual MediEvil saved game data.
File header
The header is 12 bytes long. The offsets in the table below are relative to the beginning of Frame 4.
Name | Offset | Length | Value | Meaning |
---|---|---|---|---|
Magic | 0x0 | 4 | 60SM | Signature for MediEvil saved game data. |
Saved games | 0x4 | 1 | 0-2 | The number of saved games. |
Saved games
The file can hold a maximum of three saved games. Each saved game is 1360 bytes long. The offsets for the saved games relative to the beginning of the Memory Card data block are 0x20C, 0x75C, and 0xCAC.
Saved game
The offsets in the table below are relative to the beginning of a saved game.
General | ||||
---|---|---|---|---|
Name | Offset | Length | Value | Meaning |
Checksum | 0x0 | 4 | Number | Used to verify saved game integrity. Uses the Checksum-32 algorithm. |
Level index | 0x4 | 2 | 01 - The Graveyard
02 - Return to the Graveyard |
The index of the level the name of which will be displayed on the saved game tombstone and in the save game menu. Although 00 should be "*Title Level", setting the value to this will make the saved game unselectable. |
Save game count | 0x6 | 2 | Number | Number of times the game has been saved. |
Pause Menu Options | ||||
Name | Offset | Length | Value | Meaning |
Options flags | 0x8 | 4 | 00000100 (NTSC-U default)
|
Various flags from the Pause Menu. From right to left: Flag 0: Vibration (0 for on, 1 for off) Flag 1: Audio Mode (0 for stereo, 1 for mono) Flag 2: Walk/Run toggle (0 for on, 1 for off) |
FX volume | 0xC | 2 | 0-127 (80 default) | FX volume. Can be set through the Pause Menu. |
Speech volume | 0xE | 2 | 0-127 (110 default) | Speech volume. Can be set through the Pause Menu. |
Music volume | 0x10 | 2 | 0-127 (64 default) | Music volume. Can be set through the Pause Menu. |
Lighting | 0x12 | 2 | (-192)-128 (32 default) | Lighting. Can be set through the Pause Menu. |
Screen adjust (horizontal) | 0x16 | 2 | 0 (default) | Horizontal screen adjustment. Can be set through the Pause Menu. |
Screen adjust (vertical) | 0x18 | 2 | 0 (default) | Vertical screen adjustment. Can be set through the Pause Menu. |
Button layout | 0x1A | 2 | 0-2 (0 default) | Button layout. Can be set through the Pause Menu. |
Player Stats | ||||
Name | Offset | Length | Value | Meaning |
Time played | 0x1C | 4 | Number | Time the player has played the game for. Displayed on the tombstones in the main menu and on the save game screen. |
Current energy | 0x20 | 4 | 300 (default) | Dan's current energy (as seen in the Life Bar). Starts at 300. Changes when enemies attack Dan or when he heals. |
Current stored energy | 0x24 | 4 | 0 (default) | Current stored energy. Starts at 0, set to 300 once first Life Bottle is picked up. |
Maximum stored energy | 0x28 | 4 | 0 (default) | Maximum stored energy. Starts at 0, set to 300 once first Life Bottle is picked up. Only changes when Life Bottles are picked up. |
Current weapon | 0x2C | 4 | 00 - Small Sword
01 - Broad Sword |
The weapon Dan is currently wielding. |
Current shield | 0x30 | 4 | 00 - None
01 - Copper Shield |
The shield Dan is currently wielding. If set without having set its durability in the inventory, it will immediately break. |
Current map position | 0x4C | 4 | 00 - Dan's Crypt
01 - The Graveyard |
Dan's current position on the map. Setting this to a level that is locked will allow Dan to enter that level, but may create a softlocked saved game if previous levels are not unlocked on the map. |
Inventory | ||||
Name | Offset | Length | Value | Meaning |
Small Sword | 0xA0 | 2 | -1 | The default value is -1 (FF FF ), which means Dan doesn't have the Small Sword in his inventory. It is set to 0 when Dan obtains it.
|
Throwing Daggers | 0xB4 | 2 | -1 | The default value is -1 (FF FF ), which means Dan doesn't have the Throwing Daggers in his inventory. Set to 100 when Dan obtains them, which is the amount of daggers.
|
Copper Shield | 0x128 | 2 | -1 | The default value is -1 (FF FF ), which means Dan doesn't have the Copper Shield in his inventory. It is set to 150 (0x96) when Dan obtains it, which is the durability of the shield.
|
Gold Pieces | 0x138 | 2 | 0-32767 | The default value is 0. Updated when Dan picks up treasure. Because the value is a signed short, the maximum size is 32,767. If more gold should be collected, the value will break. It will no longer be displayed in the HUD and Dan won't be able to use it to buy anything from Merchant Gargoyles. |
Level Changes | ||||
Name | Offset | Length | Value | Meaning |
Length of array | 0x14C | 4 | 0-256 | Length of the "level changes" array. The array grows each time something happens that should change a level permanently on replays. |
Start of array | 0x150 | Length of array * 4 | 00 00 00 00
|
This is where the "level changes" array begins. The maximum amount of members in the array is 256 (1024 bytes). |
CR - don't play starting cutscene | N/A | 4 | 06 00 21 B6
|
Makes it so that the cutscene at the beginning of Dan's Crypt with the Information Gargoyles is skipped. |
CR - Small Sword to moneybag | N/A | 4 | 06 01 36 B3
|
Changes the Small Sword pickup from Dan's Crypt into a moneybag. |
CR - Life Bottle on dirt mound to moneybag | N/A | 4 | 06 01 E4 B5
|
Changes the Life Bottle on the dirt mound in Dan's Crypt into a moneybag. |
CR - secret Life Bottle to moneybag | N/A | 4 | 06 01 C6 B6
|
Changes the Life Bottle behind the breakable wall in Dan's Crypt into a moneybag. |
Frames 35 to 63
These are unused.
References
- ↑ PS1 Savedata on PS3 Developer wiki. Retrieved November 22, 2024.
|