Skip to content

Commit

Permalink
autoplay toggle
Browse files Browse the repository at this point in the history
saving is still disabled while the autoplay plugin is on, but now you can play without turning the plugin off
  • Loading branch information
LlysiX committed May 20, 2024
1 parent 3fbfa0a commit 468e9d5
Show file tree
Hide file tree
Showing 4 changed files with 80 additions and 61 deletions.
18 changes: 14 additions & 4 deletions _ark/ps4/dx/overshell/dx_states.dta
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
}
{$this setup_confirm_actions a
(
{if_else $autoplayenabled "Autoplay: ON" "Autoplay: OFF"}
{if_else $autoplayexists {if_else $autoplayenabled "Autoplay: ON" "Autoplay: OFF"} "Autoplay: DISABLED"}
{if_else $nomiss "No Miss Sounds: ON" "No Miss Sounds: OFF"}
{if_else $nood "No OD: ON" "No OD: OFF"}
{if_else $practiceod "OD in Practice: ON" "OD in Practice: OFF"}
Expand All @@ -171,12 +171,22 @@
{
($objId UIListCom)get_data_in_column token }}
{switch $list_data
("Autoplay: OFF"
("Autoplay: DISABLED"
{$this show_state kState_RB4DXAutoplayHowTo}
{$this trigger_select_effects }
)
("Autoplay: ON"
{$this show_state kState_RB4DXAutoplayOff}
(("Autoplay: OFF" "Autoplay: ON")
{set $autoplayenabled {! $autoplayenabled}}
{if_else $autoplayenabled
{do
{write_file "data:/GoldHEN/RB4DX/autoplay.ini" $dx_write_nul}
{$this show_state kState_RB4DXAutoplayOn}
}
{do
{file_delete "data:/GoldHEN/RB4DX/autoplay.ini"}
{$this show_state kState_RB4DXAutoplayOff}
}
}
{$this trigger_select_effects }
)
(("Track Muting: Partial" "Track Muting: Off" "Track Muting: On")
Expand Down
17 changes: 16 additions & 1 deletion _ark/ps4/dx/overshell/dx_warn_states.dta
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,25 @@
{$this trigger_cancel_effects }
)
)
(kState_RB4DXAutoplayOn
(view confirm_action)
(enter
{$this setup_confirm_actions "If autoplay is not functioning, make sure you have the \qRB4DX-Autoplay.prx\q plugin enabled in \q/data/GoldHEN/plugins.ini\q.
(DISABLES SAVING)" (overshell_confirm_ok)}
)
(SELECT_MSG
{$this show_state kState_RB4DXGPSettings}
{$this trigger_select_effects }
)
(on_cancel
{$this show_state kState_RB4DXGPSettings}
{$this trigger_cancel_effects }
)
)
(kState_RB4DXAutoplayOff
(view confirm_action)
(enter
{$this setup_confirm_actions "You will need to disable and delete the \qRB4DX-Autoplay.prx\q plugin to disable autoplay." (overshell_confirm_ok)}
{$this setup_confirm_actions "You will need to disable and delete the \qRB4DX-Autoplay.prx\q plugin to re-enable saving." (overshell_confirm_ok)}
)
(SELECT_MSG
{$this show_state kState_RB4DXGPSettings}
Expand Down
106 changes: 50 additions & 56 deletions _ark/ps4/dx/ui/dx_init.dta
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,22 @@
{set $dx_initialized TRUE}
{set $calibrationmode FALSE}
{if {file_exists "data:/GoldHEN/RB4DX/ps4/config/include/beatmatcher.dta_dta_ps4"}
{file_delete "data:/GoldHEN/RB4DX/ps4/config/include/beatmatcher.dta_dta_ps4"}
{file_delete "data:/GoldHEN/RB4DX/ps4/config/include/beatmatcher.dta_dta_ps4"}
}
{if {file_exists "data:/GoldHEN/RB4DX/ps4/track/track_camera.script_dta_ps4"}
{file_delete "data:/GoldHEN/RB4DX/ps4/track/track_camera.script_dta_ps4"}
{file_delete "data:/GoldHEN/RB4DX/ps4/track/track_camera.script_dta_ps4"}
}
{if {file_exists "insong.dta"}
{file_delete "data:/GoldHEN/RB4DX/insong.dta"}
{file_delete "data:/GoldHEN/RB4DX/insong.dta"}
}
{if {file_exists "RB4DX.ini"}
{file_delete "data:/GoldHEN/RB4DX/RB4DX.ini"}
{file_delete "data:/GoldHEN/RB4DX/RB4DX.ini"}
}
{write_file "data:/GoldHEN/RB4DX/speedmod.ini" {array ({/ $speedmod 100})}}
{if {file_exists "autoplay.ini"}
{file_delete "data:/GoldHEN/RB4DX/autoplay.ini"}
}
{if_else {file_exists "data:/GoldHEN/plugins/RB4DX-Autoplay.prx"}
{do
{set $autoplayenabled TRUE}
{write_file "data:/GoldHEN/RB4DX/autoplay.ini" $dx_write_nul}
}
{set $autoplayenabled FALSE}
{file_delete "data:/GoldHEN/RB4DX/autoplay.ini"}
}
{set $autoplayexists {file_exists "data:/GoldHEN/plugins/RB4DX-Autoplay.prx"}}
{set $nood {file_exists "nood.dta"}}
{set $practiceod {file_exists "practiceod.dta"}}
{set $blackbg {file_exists "blackbg.dta"}}
Expand All @@ -33,54 +27,54 @@
{set $nowhammyfx {file_exists "nowhammyfx.dta"}}
{set $notifycolored {file_exists "notifycolored.ini"}}
{set $trackmuting
{cond
({file_exists "trackmutingoff.dta"}
off
)
({file_exists "trackmutingon.dta"}
on
)
({&& {! {file_exists "trackmutingoff.dta"}} {! {file_exists "trackmutingon.dta"}}}
vanilla
)
}
{cond
({file_exists "trackmutingoff.dta"}
off
)
({file_exists "trackmutingon.dta"}
on
)
({&& {! {file_exists "trackmutingoff.dta"}} {! {file_exists "trackmutingon.dta"}}}
vanilla
)
}
}
{set $voxslt
{cond
({file_exists "voxgtr.dta"}
gtr
)
({file_exists "voxdrum.dta"}
drum
)
({&& {! {file_exists "voxdrum.dta"}} {! {file_exists "voxgtr.dta"}}}
vox
)
}
{cond
({file_exists "voxgtr.dta"}
gtr
)
({file_exists "voxdrum.dta"}
drum
)
({&& {! {file_exists "voxdrum.dta"}} {! {file_exists "voxgtr.dta"}}}
vox
)
}
}
{set $gtrslt
{cond
({file_exists "gtrvox.dta"}
vox
)
({file_exists "gtrdrum.dta"}
drum
)
({&& {! {file_exists "gtrdrum.dta"}} {! {file_exists "gtrvox.dta"}}}
gtr
)
}
{cond
({file_exists "gtrvox.dta"}
vox
)
({file_exists "gtrdrum.dta"}
drum
)
({&& {! {file_exists "gtrdrum.dta"}} {! {file_exists "gtrvox.dta"}}}
gtr
)
}
}
{set $drmslt
{cond
({file_exists "drumgtr.dta"}
gtr
)
({file_exists "drumvox.dta"}
vox
)
({&& {! {file_exists "drumvox.dta"}} {! {file_exists "drumgtr.dta"}}}
drum
)
}
{cond
({file_exists "drumgtr.dta"}
gtr
)
({file_exists "drumvox.dta"}
vox
)
({&& {! {file_exists "drumvox.dta"}} {! {file_exists "drumgtr.dta"}}}
drum
)
}
}
Binary file modified _build/GoldHEN/plugins/RB4DX-Autoplay.prx
Binary file not shown.

0 comments on commit 468e9d5

Please sign in to comment.