我以为这会起作用,但没有
GraphicsWindow.KeyDown = KeyDown
Sub KeyDown
If GraphicsWindow.LastKey = "W" And GraphicsWindow.LastKey = "Space" Then
Do Stuff
EndIf
EndSub
我需要一个解决方案,以便我可以一次从用户那里获得多个键盘输入
你去吧!这应该可以满足您的需求!
GraphicsWindow.KeyDown = KeyDown
GraphicsWindow.KeyUp = KeyUp
While 1 = 1
Program.Delay(10)
If Key["Space"] = "True" And Key["Up"] Then
TextWindow.WriteLine("DOING STUFF!")
EndIf
EndWhile
Sub Keydown
LastKeyDown = GraphicsWindow.LastKey
Key[LastKeyDown] = "True"
EndSub
Sub KeyUp
LastKeyUp = GraphicsWindow.LastKey
Key[LastKeyUp] = "False"
EndSub