Saved game data: Difference between revisions

    From Gallowpedia, the MediEvil Wiki. You'll be dying to read!
    (17 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.
    ===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 Flag'''
    | '''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.
    |-
    |-
    | '''Block Number'''
    | '''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 Colour Palette'''
    | '''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 47: Line 54:
    ! 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 Games'''
    |'''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 550 bytes long.
    The file can hold a maximum of three saved games. Each saved game is 1360 bytes long.
    =====Saved game=====
    =====Saved game=====
    {| class="wikitable"
    {| class="wikitable"
    ! colspan="5" | General
    |-
    ! Name
    ! Name
    ! Offset
    ! Offset
    ! Length
    ! Value
    ! Value
    ! Meaning
    ! Meaning
    Line 71: Line 85:
    |'''Checksum'''
    |'''Checksum'''
    | 0x0
    | 0x0
    | 4
    | Number
    | Number
    | Used to verify save game integrity. Uses the Checksum-16 algorithm.
    | Used to verify save game integrity. Uses the Checksum-16 algorithm.
    |-
    |-
    |'''Save game number'''
    |'''Save game count'''
    |0x6
    |0x6
    |1
    |Number
    |Number
    |Number of times the game has been saved.
    |Number of times the game has been saved.
    Line 81: Line 97:
    |'''Time played'''
    |'''Time played'''
    |0x1C
    |0x1C
    |4
    |Number
    |Number
    |Time the player has played the game for. Displayed on the tombstones in the main menu.
    |Time the player has played the game for. Displayed on the tombstones in the main menu and on the save game screen.
    |-
    |'''Current weapon'''
    |0x38
    |1
    |{{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'''
    |0x3C
    |1
    |{{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.
    |-
    ! colspan="5" | Inventory
    |-
    ! Name
    ! Offset
    ! Length
    ! Value
    ! Meaning
    |-
    |'''Small Sword'''
    |0xAC
    |4
    |0xFFFF
    |The default value is 0xFFFF, which means Dan doesn't have the Small Sword in his inventory. It is set to 0x0000 when Dan obtains it.
    |-
    |'''Copper Shield'''
    |0x134
    |4
    |0xFFFF
    |The default value is 0xFFFF, which means Dan doesn't have the Copper Shield in his inventory. It is set to 0x96 (150) when Dan obtains it, which is the durability of the shield.
    |}
    |}


    ===Frames 35 to 63===
    ===Frames 35 to 63===
    These are unused.
    These are unused.
    ==Navigation==
    ==Navigation==
    {{Empty section|Navigation}}
    {{Empty section|Navigation}}
    [[Category:Files in MediEvil]]
    [[Category:Files in MediEvil]]

    Revision as of 10:22, 21 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.

    Frame 0

    This frame is the header for a block of PS1 saved data.

    Name Offset Length Value Meaning
    Magic 0x0 2 SC Signature for all PS1 saved game data.
    Icon flag 0x2 1 11 This means the icon for the saved game consists of a single image.
    Number of blocks 0x3 1 1 How many blocks the save will take up on a memory card.
    Title 0x4 64 MediEvil      Name of the saved game in Shift JIS format.
    Icon colour palette 0x96 32 MediEvil1998-MemoryCardIconPalette.png Saved game icon colour palette.

    Frame 1

    This frame is used to store a PS1 saved game icon: MediEvil-Memory-Card.png

    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.

    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.

    Saved game
    General
    Name Offset Length Value Meaning
    Checksum 0x0 4 Number Used to verify save game integrity. Uses the Checksum-16 algorithm.
    Save game count 0x6 1 Number Number of times the game has been saved.
    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 weapon 0x38 1
    00 - Small Sword

    01 - Broad Sword
    02 - Magic Sword
    03 - Throwing Daggers
    04 - Axe
    05 - Club
    06 - Crossbow
    07 - Chicken Drumsticks
    08 - Arm
    09 - Lightning
    0A - Longbow
    0B - Spear
    0C - Hammer
    0D Flaming Longbow
    0E - Magic Longbow
    0F - Good Lightning
    10 - Dragon Armour
    11 - Chaos Rune
    12 - None

    The weapon Dan is currently wielding.
    Current shield 0x3C 1
    00 - None

    01 - Copper Shield
    02 - Silver Shield
    03 - Gold Shield

    The shield Dan is currently wielding. If set without having set its durability in the inventory, it will immediately break.
    Inventory
    Name Offset Length Value Meaning
    Small Sword 0xAC 4 0xFFFF The default value is 0xFFFF, which means Dan doesn't have the Small Sword in his inventory. It is set to 0x0000 when Dan obtains it.
    Copper Shield 0x134 4 0xFFFF The default value is 0xFFFF, which means Dan doesn't have the Copper Shield in his inventory. It is set to 0x96 (150) when Dan obtains it, which is the durability of the shield.

    Frames 35 to 63

    These are unused.

    Navigation