React(iidxhook4-cn): Use sdk-hook and support new config api

Summary:

Test Plan:
Summary:

Test Plan:
This commit is contained in:
icex2
2024-08-17 12:49:18 +02:00
parent 617550b6e6
commit 4f97282d97
9 changed files with 371 additions and 283 deletions

View File

@@ -57,8 +57,5 @@ if not exist dev\nvram mkdir dev\nvram
if not exist dev\raw mkdir dev\raw
%BEMANITOOLS_DIR%\inject.exe^
%BEMANITOOLS_DIR%\iidxhook4-cn.dll^
%REVISION_DIR%\bm2dx.exe^
-D^
--config %BEMANITOOLS_DIR%\iidxhook-18-cn.conf^
%BEMANITOOLS_DIR%\inject-18-cn.xml^
%*

View File

@@ -1,50 +0,0 @@
# PCBID
eamuse.pcbid=0101020304050607086F
# Run the game in a framed window (requires windowed option)
gfx.framed=false
# Software limit the frame rate of the rendering loop in hz, e.g. 60 or 59.95 (0.0 = no software limit)
gfx.frame_rate_limit=0.0
# Enable/disable software monitor check/auto timebase or set a pre-determined refresh value. -1 disables this feature. 0 enables auto detecting the current refresh rate on startup. Setting any positive value > 0 allows you to set a pre-determined refresh rate (e.g. retrieved from the monitor check on newer IIDX games). Either the auto detected value or pre-determined value is used to patch any chart files in-memory to fix song synchronization issues. Requires constant refresh rate!!!
gfx.monitor_check=-1.000000
# Patch the GPU device ID detection (leave empty to disable), format XXXX:YYYY, two 4 digit hex numbers (vid:pid). Examples: 1002:7146 (RV515, Radeon X1300), 1002:95C5 (RV620 LE, Radeon HD3450)
gfx.pci_id=1002:7146
# Run the game windowed
gfx.windowed=false
# Windowed width, 0 for default size
gfx.window_width=0
# Windowed height, 0 for default size
gfx.window_height=0
# Up-/downscale the back buffer's width. This does not change the game's rendering resolution but scales the final frame. Use this to target the native resolution of your monitor/TV, e.g. to avoid over-/underscan, bad image quality or latency caused by the monitors internal upscaler. 0 to disable this feature. Must be set in combination with the corresponding height parameter.
gfx.scale_back_buffer_width=0
# Up-/downscale the back buffer's height. This does not change the game's rendering resolution but scales the final frame. Use this to target the native resolution of your monitor/TV, e.g. to avoid over-/underscan, bad image quality or latency caused by the monitors internal upscaler. 0 to disable this feature. Must be set in combination with the corresponding width parameter.
gfx.scale_back_buffer_height=0
# Filter type to use for up-/downscaling the back buffer. Only used if scaling feature was enabled by setting the scaling width and height parameters. Available types: none, linear, point (refer to D3DTEXTUREFILTERTYPE for explanation).
gfx.scale_back_buffer_filter=none
# Forced refresh rate, -1 to not force any (try 59 or 60 if monitor check fails to lock on high refresh rate monitors)
gfx.forced_refresh_rate=-1
# D3D9 device adapter (monitor), -1 to use default, 0, 1, 2 etc. to use specified adapter
gfx.device_adapter=-1
# Fix diagonal tearing with video cards other than Radeon X1300 and HD3450
gfx.diagonal_tearing_fix=false
# Disable ezusb IO emulation and enable usage of real ezusb1/2 IO hardware
io.disable_io_emu=false
# Path to store the settings, e.g. bookkeeping, operator settings. d:, e: and f: drive configuration/settings data
misc.settings_path=.\
# Security black plug mcode id string (e.g. GQC02JAA).
sec.black_plug_mcode=GKJDZCAA

97
dist/iidx/inject-18-cn.xml vendored Normal file
View File

@@ -0,0 +1,97 @@
<?xml version="1.0" encoding="Shift-JIS"?>
<inject>
<version __type="u32">1</version>
<debugger>
<app>
<path __type="str">bm2dx.exe</path>
<args __type="str"></args>
</app>
<attach_type __type="str">inject</attach_type>
</debugger>
<hooks>
<hook>
<enable __type="bool">1</enable>
<path __type="str">iidxhook4-cn.dll</path>
<config kind="inline">
<hook>
<eamuse>
<pcbid __type="bin">0101020304050607086F</pcbid>
</eamuse>
<gfx>
<device>
<!-- D3D9 device adapter (monitor), -1 to use default, 0, 1, 2 etc. to use specified adapter -->
<adapter __type="s8">-1</adapter>
<!-- Forced refresh rate, -1 to not force any (try 59 or 60 if monitor check fails to lock on high refresh rate monitors) -->
<forced_refresh_rate __type="s16">-1</forced_refresh_rate>
<!-- Software limit the frame rate of the rendering loop in hz, e.g. 60 or 59.95 (0.0 = no software limit) -->
<frame_rate_limit __type="float">0.0</frame_rate_limit>
<!-- Patch the GPU device ID detection (leave empty to disable), format XXXX:YYYY, two 4 digit hex numbers (vid:pid). Examples: 1002:7146 (RV515, Radeon X1300), 1002:95C5 (RV620 LE, Radeon HD3450) -->
<pci_id_vid __type="str">1002</pci_id_vid>
<pci_id_pid __type="str">7146</pci_id_pid>
</device>
<window>
<windowed __type="bool">1</windowed>
<framed __type="bool">1</framed>
<!-- Windowed height, 0 for default size -->
<width __type="u16">0</width>
<height __type="u16">0</height>
</window>
<back_buffer_scale>
<!-- Up-/downscale the back buffer's height. This does not change the game's rendering resolution but scales the final frame. Use this to target the native resolution of your monitor/TV, e.g. to avoid over-/underscan, bad image quality or latency caused by the monitors internal upscaler. 0 to disable this feature. Must be set in combination with the corresponding width parameter. -->
<width __type="u16">0</width>
<height __type="u16">0</height>
<!-- Filter type to use for up-/downscaling the back buffer. Only used if scaling feature was enabled by setting the scaling width and height parameters. Available types: none, linear, point (refer to D3DTEXTUREFILTERTYPE for explanation). -->
<filter __type="str">none</filter>
</back_buffer_scale>
<game>
<!-- Enable/disable software monitor check/auto timebase or set a pre-determined refresh value. -1 disables this feature. 0 enables auto detecting the current refresh rate on startup. Setting any positive value > 0 allows you to set a pre-determined refresh rate (e.g. retrieved from the monitor check on newer IIDX games). Either the auto detected value or pre-determined value is used to patch any chart files in-memory to fix song synchronization issues. Requires constant refresh rate!!! -->
<monitor_check __type="float">-1.000000</monitor_check>
<!-- Fix diagonal tearing with video cards other than Radeon X1300 and HD3450 -->
<diagonal_tearing_fix __type="bool">0</diagonal_tearing_fix>
</game>
</gfx>
<ezusb>
<security>
<plug_black_mcode __type="str">GKJDZCAA</plug_black_mcode>
</security>
</ezusb>
<io>
<disable_io_emu __type="bool">0</disable_io_emu>
</io>
<misc>
<!-- Path to store the settings, e.g. bookkeeping, operator settings. d:, e: and f: drive configuration/settings data -->
<settings_path __type="str">.\</settings_path>
<disable_clock_set __type="bool">1</disable_clock_set>
</misc>
</hook>
</config>
</hook>
</hooks>
<logger>
<enable __type="bool">1</enable>
<level __type="str">misc</level>
<msg_buffer_size_bytes __type="u32">8192</msg_buffer_size_bytes>
<sinks>
<async>
<enable __type="bool">0</enable>
<queue_length __type="u8">64</queue_length>
<overflow_policy __type="str">discard_new</overflow_policy>
</async>
<console>
<enable __type="bool">1</enable>
<color __type="bool">1</color>
</console>
<file>
<enable __type="bool">1</enable>
<path __type="str">inject.log</path>
<append __type="bool">0</append>
<rotate __type="bool">0</rotate>
<max_rotations __type="u8">1</max_rotations>
</file>
</sinks>
</logger>
<debug>
<property_configs_log __type="bool">1</property_configs_log>
<property_api_trace_log __type="bool">0</property_api_trace_log>
</debug>
</inject>