summaryrefslogtreecommitdiff
path: root/drivers/chibi/cp_player_data.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/chibi/cp_player_data.cpp')
-rw-r--r--drivers/chibi/cp_player_data.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/chibi/cp_player_data.cpp b/drivers/chibi/cp_player_data.cpp
index 324c3f7c36..99bc4fddd2 100644
--- a/drivers/chibi/cp_player_data.cpp
+++ b/drivers/chibi/cp_player_data.cpp
@@ -125,7 +125,7 @@ int64_t CPPlayer::get_channel_last_note_time_usec(int p_channel) const {
void CPPlayer::set_channel_global_volume(int p_channel,int p_volume) {
CP_FAIL_INDEX(p_channel,64);
- control.channel[p_channel].channel_global_volume=p_volume;
+ control.channel[p_channel].channel_global_volume=CLAMP(p_volume,0,255);
}