整理框架代码

整理手柄的摇杆/扳机支持代码
This commit is contained in:
MrZ626
2021-11-22 15:59:57 +08:00
parent d38897b54d
commit 940ac3736c
4 changed files with 72 additions and 147 deletions

View File

@@ -162,7 +162,7 @@ function scene.update()
if kb.isDown("down","s")then dy=dy-10 F=true end
if kb.isDown("left","a")then dx=dx+10 F=true end
if kb.isDown("right","d")then dx=dx-10 F=true end
local js1=joysticks[1]
local js1=Z.js[1]
if js1 then
local dir=js1:getAxis(1)
if dir~="c"then