title_name = "Saints Row 2 (TU3)"
title_id = "545107FC" # TQ-2044
hash = "9B9E734BA6BDCCD9" # default.xex
#media_id = [
#    "43400270",
#    "4E854E4B", Disc (USA, Europe): http://redump.org/disc/14038
#]

[[patch]]
    name = "PS3 Button Prompts"
    desc = "Swaps out the platform strings to load the PS3 localization (has hardcoded button prompts) and to fool Lua to display PS3 buttons (has hardcoded buttons too)."
    author = "Tervel"
    is_enabled = false

    [[patch.string]]
        address = 0x82097240
        value = "PS3"
    [[patch.be8]]
        address = 0x82097243
        value = 0x00
    [[patch.string]]
        address = 0x820984b8
        value = "PS3"
    [[patch.be8]]
        address = 0x820984bb
        value = 0x00

[[patch]]
    name = "Motion Blur Strength Fix"
    desc = "Corrects the motion blur strength so that it is consistent regardless of your framerate."
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x821d4f9c
        value = 0x4886804c
    [[patch.be32]]
        address = 0x82a3cfe8
        value = 0x3ec082b6
    [[patch.be32]]
        address = 0x82a3cfec
        value = 0xc0362370
    [[patch.be32]]
        address = 0x82a3cff0
        value = 0x4b797fb0

[[patch]]
    name = "Force 720p"
    desc = "Makes the game run at 720p instead of the default 640p."
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x8221ce3c
        value = 0x38e00500
    [[patch.be32]]
        address = 0x8221cdc0
        value = 0x3be002d0

[[patch]]
    name = "Disable HDR"
    desc = "Turns HDR off and edits the brightness, saturation and contrast to make up for that."
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x8205393c
        value = 0x60000000
    [[patch.be32]]
        address = 0x8221ac4c
        value = 0x60000000
    [[patch.be32]]
        address = 0x823df920
        value = 0x60000000
    [[patch.be32]]
        address = 0x8221abf4
        value = 0x60000000
    [[patch.be32]]
        address = 0x823df928
        value = 0x60000000
    [[patch.be32]]
        address = 0x8221ac54
        value = 0x60000000
    [[patch.be32]]
        address = 0x823df92c
        value = 0x60000000
    [[patch.be32]]
        address = 0x821e28c0
        value = 0x60000000
    [[patch.be32]]
        address = 0x82053f74
        value = 0x60000000
    [[patch.f32]]
        address = 0x837dac74 # Brightness
        value = 0.3
    [[patch.f32]]
        address = 0x82b76c7c # Contrast
        value = 1.62
    [[patch.f32]]
        address = 0x82b76c80 # Saturation
        value = 0.8

[[patch]]
    name = "Disable Sky Reflections"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x82230790
        value = 0x4e800020

[[patch]]
    name = "Disable Bleach Filter"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x820539a8
        value = 0x60000000

[[patch]]
    name = "Disable Cutscene Letterbox"
    author = "Tervel, jason098"
    is_enabled = false

    [[patch.be32]]
        address = 0x82461c90
        value = 0x4e800020

[[patch]]
    name = "Disable Vignette"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x8208027c
        value = 0x60000000

[[patch]]
    name = "Disable Sharpening"
    author = "Tervel"
    is_enabled = false

    [[patch.f32]]
        address = 0x82b77070
        value = 0.0

[[patch]]
    name = "Disable Motion Blur"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x821d4b10
        value = 0x4e800020
    [[patch.be32]]
        address = 0x821d4d00
        value = 0x4e800020

[[patch]]
    name = "60 FPS"
    author = "illusion"
    is_enabled = false

    [[patch.be32]]
        address = 0x829384d0
        value = 0x48104aa0
    [[patch.be32]]
        address = 0x82a3cf70
        # value = 0x39403c88 # to Unlock FPS
        value = 0x3d403c88
    [[patch.be32]]
        address = 0x82a3cf74
        value = 0x614a8889
    [[patch.be32]]
        address = 0x82a3cf78
        value = 0x91580004
    [[patch.be32]]
        address = 0x82a3cf7c
        value = 0xc1b80004
    [[patch.be32]]
        address = 0x82a3cf80
        value = 0x4befb554

[[patch]]
    name = "Havok physics FPS fix"
    desc = "Fixes Cutscene Objects desyncing and doors teleporting on high fps, at the cost of framerates and worse bike physics."
    author = "Clippy95" # Initially found by uzis for SR2 PC, SR2 X360 address provided by Tervel.
    is_enabled = false

    [[patch.be32]]
        address = 0x8221ceac
        value = 0x60000000
    [[patch.be32]]
        address = 0x82938568
        value = 0x48104a1c
    [[patch.be32]]
        address = 0x82a3cf84
        value = 0xd017236c
    [[patch.be32]]
        address = 0x82a3cf88
        value = 0x3c608200
    [[patch.be32]]
        address = 0x82a3cf8c
        value = 0xc0c32388
    [[patch.be32]]
        address = 0x82a3cf90
        value = 0xece03024
    [[patch.be32]]
        address = 0x82a3cf94
        value = 0x3c60837e
    [[patch.be32]]
        address = 0x82a3cf98
        value = 0x3b83c2e1
    [[patch.be32]]
        address = 0x82a3cf9c
        value = 0xd0fcf33f
    [[patch.be32]]
        address = 0x82a3cfa0
        value = 0x4befb5cc

[[patch]]
    name = "Aspect Ratio"
    desc = "To get proper Aspect Ratio FOV = Default * (Width/Height) / (16/9)"
    author = "Tervel"
    is_enabled = false

    [[patch.be8]]
        address = 0x82b7a01c
        value = 0x01
    [[patch.f32]]
        address = 0x820b80d0
        value = 2.38888888889
    [[patch.f32]]
        address = 0x82b68a4c # General FOV Multiplier
        value = 1.777741190 # Default: 1.3333334
    [[patch.f32]]
        address = 0x820b80b4 # Cutscene FOV Multiplier.
        value = 75.200706 # Default # 57.295776

[[patch]]
    name = "FOV Multiplier"
    desc = "Multiplies FOV. Default is 1.33333, crosshair will be misaligned unless changed manually."
    author = "Clippy95, Tervel"
    is_enabled = false

    [[patch.f32]]
        address = 0x82b68a4c # General FOV Multiplier
        value = 1.777741190 # Default: 1.3333334
    [[patch.f32]]
        address = 0x820b80b4 # Cutscene FOV Multiplier.
        value = 75.200706 # Default # 57.295776

[[patch]]
    name = "Skip Intros"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x8244b7e0
        value = 0x3bc00003
    [[patch.be32]]
        address = 0x82397ea0
        value = 0x82398010

[[patch]]
    name = "16x Anisotropic Filtering"
    author = "Tervel, Clippy95"
    is_enabled = false

    [[patch.be32]]
        address = 0x8290cfe0
        value = 0x38a00010

[[patch]]
    name = "Better Drive By Cam"
    author = "Clippy95"
    is_enabled = false

    [[patch.be32]]
        address = 0x821a1f74
        value = 0x60000000

[[patch]]
    name = "Better Movement Behaviour"
    desc = "Stops several animation events from running, closer to SR1's movement."
    author = "Uzis, Clippy95"
    is_enabled = false

    [[patch.be32]]
        address = 0x82086590 # jog 180
        value = 0x60000000
    [[patch.be32]]
        address = 0x820865bc # stand 180
        value = 0x60000000
    [[patch.be32]]
        address = 0x820865c8 # walk stop
        value = 0x60000000
    [[patch.be32]]
        address = 0x82086270 # run to stop
        value = 0x60000000
    [[patch.be32]]
        address = 0x8208627c # walk to stop
        value = 0x60000000
    [[patch.be32]]
        address = 0x82086240 # walk to stand
        value = 0x60000000
    [[patch.be32]]
        address = 0x82086260 # stand to run
        value = 0x60000000
    [[patch.be32]]
        address = 0x82086250 # stand to walk
        value = 0x60000000

[[patch]]
    name = "Ugly Mode"
    desc = "Huge performance boost at the cost of worse visuals."
    author = "Tervel"
    is_enabled = false

    [[patch.be8]]
        address = 0x837dac89
        value = 0x01
    [[patch.be32]]
        address = 0x82229a00
        value = 0x60000000
    [[patch.be8]]
        address = 0x82b62e3f # MSAA
        value = 0x00
    [[patch.f32]]
        address = 0x82b76ca0
        value = 400.0

[[patch]]
    name = "Disable Weapon Glow"
    author = "Tervel"
    is_enabled = false

    [[patch.be32]]
        address = 0x820a41c0
        value = 0x60000000
