Rick Posted January 9, 2016 Share Posted January 9, 2016 If I do the following it doesn't play the sound: if window:KeyHit(Key.Space) then self.cellphone:Play() end If I use any other key it works: if window:KeyHit(Key.Tab) then self.cellphone:Play() end In the docs it says it should be Space http://www.leadwerks.com/werkspace/page/api-reference/_/key/ What am I missing? Link to comment Share on other sites More sharing options...
Ma-Shell Posted January 9, 2016 Share Posted January 9, 2016 For me this works: function Script:UpdateWorld() if window:KeyHit(Key.Space) then System:Print("foobar") end end So the space-key is working... Link to comment Share on other sites More sharing options...
Rick Posted January 9, 2016 Author Share Posted January 9, 2016 Are you in beta? Link to comment Share on other sites More sharing options...
Josh Posted January 9, 2016 Share Posted January 9, 2016 Do you have a call to the same key hit somewhere else? My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Ma-Shell Posted January 9, 2016 Share Posted January 9, 2016 Are you in beta? Nope Link to comment Share on other sites More sharing options...
Rick Posted January 9, 2016 Author Share Posted January 9, 2016 Do you have a call to the same key hit somewhere else? Ah. KeyHit() strikes again. 1 Link to comment Share on other sites More sharing options...
Recommended Posts