修正一处手柄事件可能爆炸
This commit is contained in:
@@ -397,7 +397,7 @@ function love.joystickremoved(JS)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
function love.gamepadaxis(JS,axis,val)
|
function love.gamepadaxis(JS,axis,val)
|
||||||
if JS==jsState[1]._jsObj then
|
if jsState[1]and JS==jsState[1]._jsObj then
|
||||||
local js=jsState[1]
|
local js=jsState[1]
|
||||||
if axis=='leftx'or axis=='lefty'or axis=='rightx'or axis=='righty'then
|
if axis=='leftx'or axis=='lefty'or axis=='rightx'or axis=='righty'then
|
||||||
local newVal=--range: [0,1]
|
local newVal=--range: [0,1]
|
||||||
|
|||||||
Reference in New Issue
Block a user