Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions phira/locales/en-US/settings.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ item-show-acc = Real-Time Accuracy
item-dc-pause = Double-Tap to Pause
item-dhint = Simultaneous Hint
item-dhint-sub = Highlight notes that are meant to be hit at the same time.
item-shader-effect = Shader Effect
item-shader-effect-sub = You can turn off this option if you experience lag when playing a chart with shader effects.
item-opt = Chart Optimization
item-opt-sub = Significantly increase peformance while playing. (If unintended behavior arises, disable this.)
item-speed = Speed
Expand Down
2 changes: 2 additions & 0 deletions phira/locales/zh-CN/settings.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ item-show-acc = 显示实时准度
item-dc-pause = 双击暂停
item-dhint = 双押提示
item-dhint-sub = 同时触线的音符将会被高亮
item-shader-effect = 着色器效果
item-shader-effect-sub = 如果你在播放包含着色器效果的谱面时遇到卡顿,可以关闭此选项以提升流畅度。
item-opt = 激进优化
item-opt-sub = 采用激进的优化策略,提升性能但可能导致部分谱面显示出错
item-speed = 速度
Expand Down
10 changes: 10 additions & 0 deletions phira/src/page/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -639,6 +639,7 @@ struct ChartList {
show_acc_btn: DRectButton,
dc_pause_btn: DRectButton,
dhint_btn: DRectButton,
shader_effect_btn: DRectButton,
opt_btn: DRectButton,
speed_slider: Slider,
size_slider: Slider,
Expand All @@ -650,6 +651,7 @@ impl ChartList {
show_acc_btn: DRectButton::new(),
dc_pause_btn: DRectButton::new(),
dhint_btn: DRectButton::new(),
shader_effect_btn: DRectButton::new(),
opt_btn: DRectButton::new(),
speed_slider: Slider::new(0.5..2., 0.05),
size_slider: Slider::new(0.8..1.2, 0.005),
Expand All @@ -675,6 +677,10 @@ impl ChartList {
config.double_hint ^= true;
return Ok(Some(true));
}
if self.shader_effect_btn.touch(touch, t) {
config.disable_effect ^= true;
return Ok(Some(true));
}
if self.opt_btn.touch(touch, t) {
config.aggressive ^= true;
return Ok(Some(true));
Expand Down Expand Up @@ -718,6 +724,10 @@ impl ChartList {
render_title(ui, tl!("item-dhint"), Some(tl!("item-dhint-sub")));
render_switch(ui, rr, t, &mut self.dhint_btn, config.double_hint);
}
item! {
render_title(ui, tl!("item-shader-effect"), Some(tl!("item-shader-effect-sub")));
render_switch(ui, rr, t, &mut self.shader_effect_btn, !config.disable_effect);
}
item! {
render_title(ui, tl!("item-opt"), Some(tl!("item-opt-sub")));
render_switch(ui, rr, t, &mut self.opt_btn, config.aggressive);
Expand Down