[Constants] ; Intentionally not making this persistent to ensure it doesn't get forgotten ; about leading to users asking why their game is pink and hazy. Feel free to ; add the persist keyword here if you promise not to do that ;-) global $mode global persist $var = 1 [KeyDemist] key = Ctrl Shift Alt M type = cycle run = CommandListAuto, CommandListOn, CommandListOff [KeyDemist2] key = no_modifiers F2 type = cycle $var = 0,1 [CommandListAuto] Resource\ShaderFixes\help.ini\Notification = ref ResourceAuto run = CustomShader\ShaderFixes\help.ini\FormatText $\ShaderFixes\help.ini\notification_timeout = time + 2.0 $mode = 0 run = CommandListDemistOff ; Ensure the preset will re-trigger next frame if applicable: exclude_preset = Gacha [CommandListOn] Resource\ShaderFixes\help.ini\Notification = ref ResourceOn run = CustomShader\ShaderFixes\help.ini\FormatText $\ShaderFixes\help.ini\notification_timeout = time + 2.0 $mode = 1 run = CommandListDemistOn [CommandListOff] Resource\ShaderFixes\help.ini\Notification = ref ResourceOff run = CustomShader\ShaderFixes\help.ini\FormatText $\ShaderFixes\help.ini\notification_timeout = time + 2.0 $mode = 2 run = CommandListDemistOff [ResourceAuto] type = Buffer data = "Gacha Demist: Autodetect" [ResourceOn] type = Buffer data = "Gacha Demist: On (NOTE: Will add fog to all other scenes)" [ResourceOff] type = Buffer data = "Gacha Demist: Off" [PresetGacha] unique_triggers_required = 4 run = CommandListPresetGacha [CommandListPresetGacha] ; Switch constant buffers used by certain shaders. Alternative approach to ; editing the shaders as I want to avoid taking up any more IniParams given ; that it might lead to mod conflicts, and this keeps this mod entirely self ; contained outside of ShaderFixes so it can be dragged and dropped and won't ; conflict with anyone else's shader edits. ; ; Downside is this overrides all params in the constant buffer, so probably ; will only work for this camera angle. if $mode == 0 if $costume_mods pre run = CommandListDemistOn endif post run = CommandListDemistOff endif [CommandListDemistOn] ResourceFrostedGlassOverrideParams = ref ResourceFrostedGlassGachaParams ResourceFogOverride = ref ResourceFogGacha ResourceGlassOverride = ref ResourceGlassGacha ; Messes up post-Gacha scene, which is why the preset has multiple conditions ; to make sure it is only used in the pre-gacha scene: ResourceDOFOverride = ref ResourceDOFGacha [CommandListDemistOff] ResourceFrostedGlassOverrideParams = null ResourceFogOverride = null ResourceGlassOverride = null ResourceDOFOverride = null [ResourceFrostedGlassOverrideParams] [ResourceFrostedGlassGachaParams] type = Buffer format = R32G32B32A32_FLOAT ;data = 960 540 0 0 5 1.6 0.005 0 data = 960 540 0 0 0 0 0 0 [ResourceFogOverride] [ResourceFogGacha] type = Buffer format = R32G32B32A32_FLOAT ;data = 0.649999976 0.349999994 0.340000004 1 -0.369999975 -0.169999987 -0.170000002 0 3.79999995 5.30000019 0.666666567 0.285714298 0.159999996 0.840000033 0 0 0 0 0 1 0 0 0 0 4194301 4194302 1 1 0.5 0.5 0 0 0 0 0 1 0.0691632405 -0.20441021 0.97643894 0 0 0 0 0 0 0 0 1 0 0 0 -0 data = 0.649999976 0.349999994 0.340000004 1 -0.369999975 -0.169999987 -0.170000002 0 3.79999995 5.30000019 0.666666567 0.285714298 0 0 0 0 0 0 0 1 0 0 0 0 4194301 4194302 1 1 0.5 0.5 0 0 0 0 0 1 0.0691632405 -0.20441021 0.97643894 0 0 0 0 0 0 0 0 1 0 0 0 -0 [ResourceDOFOverride] [ResourceDOFGacha] type = Buffer format = R32G32B32A32_FLOAT ;data = -7.32475528e-05 0.300021976 0.227738589 0.128102958 2 -2 -1 1.5 2.25580406 0.285714298 -0.285714298 2 data = -7.32475528e-05 0.300021976 0.227738589 0.128102958 2 -2 -1 1.5 2.25580406 0 -0.285714298 2 ;data = -7.32475528e-05 0.300021976 0.227738589 0.128102958 2 -2 -1 1.5 2.25580406 0.175 -0.285714298 2 [ResourceGlassOverride] [ResourceGlassGacha] filename = glass.png [ShaderOverrideFrostedGlassDistort] ; Bytecode hash: 5305f759 hash = b5df69331d7ac559 preset = Gacha ps-cb0 = ResourceFrostedGlassOverrideParams unless_null [ShaderOverrideFrostedGlassDistort-20220524] ; Bytecode hash: 5305f759 hash = 353e84ce75c3e809 preset = Gacha ps-cb0 = ResourceFrostedGlassOverrideParams unless_null [ShaderRegexLightingCSGacha] shader_model = cs_5_0 ;dump = deferred_ctx_accurate cs-cb1 cs-cb1 = ResourceFogOverride unless_null [ShaderRegexLightingCSGacha.Pattern] (?x) ^ \/\/ \s+ gSceneFogParam \s+ cbuffer \s+ NA \s+ NA \s+ (CB)? (?# d3dcompiler_47 compatibility) 1 \s+ 1 $ [ShaderRegexPSFog] shader_model = ps_5_0 ps-cb4 = ResourceFogOverride unless_null [ShaderRegexPSFog.Pattern] (?x) (?P ^ \/\/ \s+ ps_scene_fog_cb \s+ cbuffer \s+ NA \s+ NA \s+ (CB)? (?# d3dcompiler_47 compatibility) (?P4) \s+ 1 $ (.|\n)* ) cb(?P=cb)\[3\]\.[xyzw]{4} ;[ShaderRegexPSFog.Pattern.Replace] ;${before}l(0.1,0.1,0.1,0.1) [ShaderOverrideDOF] ; Bytecode hash: 6b4d3ab8 hash = 0d12591e764f8e92 ;dump = deferred_ctx_accurate ps-cb0 ps-cb0 = ResourceDOFOverride unless_null [ShaderOverrideFrostedGlassFog] ; Bytecode hash: fbcb9e96 - not found in 2018-12-06 update ; Bytecode hash: 3da2a1ac - 2018-12-06 added gMaterialParam2 check hash = 1e372bfddbafcfc9 checktextureoverride = ps-t0 [TextureOverrideGachaGlassTX] hash = c2b7db06 this = ResourceGlassOverride unless_null preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [ShaderOverrideShowerWaterOld] ; Bytecode hash: 9fc47c30 hash = 939a1a797dcaa3ec checktextureoverride = ps-t0 ;dump = deferred_ctx_accurate ps-t0 ;[ShaderOverrideShowerWater201910] ; Bytecode hash: 040873f2 ;hash = 5b8db602c9419047 ;checktextureoverride = ps-t0 ;dump = deferred_ctx_accurate ps-t0 [TextureOverrideWaterDropsLarge] hash = a5e65945 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideShutterBehindBath] ; Ensures we only activate when the camera is facing the right direction ; Eliminates flickering in 2nd bath photo location hash = 45c60e2c preset = Gacha [TextureOverrideAngleCheck2] hash = 02f661f5 preset = Gacha [TextureOverrideAngleCheck3] hash = 52a386e4 preset = Gacha [TextureOverrideAngleCheck4] hash = f4eca7e2 preset = Gacha [TextureOverrideAngleCheck5] hash = dcd745d8 preset = Gacha [TextureOverrideAngleCheck6] hash = 27bad880 preset = Gacha [TextureOverrideAngleCheck7] hash = 3e719307 preset = Gacha [TextureOverrideAngleCheck8] hash = eb512b7e preset = Gacha [TextureOverrideAngleCheck9] hash = a1d3bb77 preset = Gacha [ShaderOverrideTest] hash = 2bb472d1779a98f1 handling = skip [ShaderOverrideTest2] hash = a55e615c70a2aaee handling = skip [ShaderOverrideFog1] hash = 3ab004e8ce8d685f handling = skip [TextureOverrideGlassPatternRight] hash = e0431ef1 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideGlassPatternLeft] hash = 8bae579e preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideShowerDoor] hash = b0762976 match_first_index = 0 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideShowerDoor2] hash = 0fbcc660 match_first_index = 0 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideShowerDoor3] hash = b7e2352b match_first_index = 0 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [TextureOverrideShowerDoor4] hash = 0fbcc660 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif [ShaderOverrideGlassPatternNEW] hash = 4c1977cd038af5fe checktextureoverride = ib [ShaderOverrideGlassPatternNEW2] hash = bb5864a9b440d709 checktextureoverride = ib [TextureOverrideShowerDoorNEW] hash = 17e5e5f8 preset = Gacha if $var == 1 && $mode != 2 handling = skip endif