I am trying to start and stop a timer I made in love2d, but I want to be able to start and stop it even when the window does not have focus. Is this possible? I already tried the Keypress callback and love.keyboard.isDown() but they don't work without focus.
Any help is greatly appreciated!
Any events that don't need window focus?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
-
- Prole
- Posts: 1
- Joined: Wed Oct 07, 2015 11:58 pm
- zorg
- Party member
- Posts: 3477
- Joined: Thu Dec 13, 2012 2:55 pm
- Location: Absurdistan, Hungary
- Contact:
Re: Any events that don't need window focus?
Unless you get some kind of hooking library that notifies your program about keypresses/whatever as the os receives them, i don't think it's possible.
Me and my stuff
True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.

Re: Any events that don't need window focus?
I think it's deliberate that input (keyboard, mouse, etc) shouldn't affect a window that's not in focus. love.update still runs, but you can't (and shouldn't) be able to access any input.
If you need that, it sounds like you're choosing the wrong tool for the job.
If you need that, it sounds like you're choosing the wrong tool for the job.
My game called Hat Cat and the Obvious Crimes Against the Fundamental Laws of Physics is out now!
Who is online
Users browsing this forum: Ahrefs [Bot] and 10 guests