From 4b64f1aa93661168bd9338bcf7ca4c3a141b3ff3 Mon Sep 17 00:00:00 2001 From: MrZ_26 <1046101471@qq.com> Date: Mon, 25 Nov 2024 08:49:58 +0800 Subject: [PATCH] =?UTF-8?q?piano=E5=B0=8F=E7=A8=8B=E5=BA=8F=E7=94=A8?= =?UTF-8?q?=E5=8F=B3ctrl/shift=E7=A7=BB=E5=8D=8A=E4=B8=AA=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/scene_app/piano.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/assets/scene_app/piano.lua b/assets/scene_app/piano.lua index 7ebc1684..b58a047b 100644 --- a/assets/scene_app/piano.lua +++ b/assets/scene_app/piano.lua @@ -468,6 +468,10 @@ function scene.keyDown(key,isRep,keyCode) elseif key=='f2' then stopAllSounds() layout=layoutData[TABLE.find(layoutData,layout)%#layoutData+1] + elseif key=='rshift' then + offset=clamp(offset+.5,-12,24) + elseif key=='rctrl' then + offset=clamp(offset-.5,-12,24) elseif key=='right' then offset=clamp(offset+(isKeyDown('left') and 0.5 or 1),-12,24) elseif key=='left' then