The PRINTSCREEN button is a valid recognized key by Factorio in the controls UI but pressing the key will never trigger the script event.
If you change the mod key from PRINTSCREEN to F12, for example the script event triggers when F12 is pressed.
Use the controls UI to change it back to PRINTSCREEN and the script event won't trigger anymore.
Really want to make that the shortcut-key for a screenshot mod.
[0.14.8][Twinsen] Control UI accepts key but won't fire mod event.
Re: [0.14.8] Control UI accepts key but won't fire mod event.
Thanks for the report,
I can confirm it isn't just a mod issue,
I rebinded a key to 'PRINTSCREEN',
But then pressing printscreen doesn't activate that key in the game
I can confirm it isn't just a mod issue,
I rebinded a key to 'PRINTSCREEN',
But then pressing printscreen doesn't activate that key in the game
Re: [0.14.8] Control UI accepts key but won't fire mod event.
I haven't gone testing all the keys on the keyboard just yet but some of the other "odd" keys might also suffer the same problem.
"Scroll Lock", "Pause/Break", "Insert", "Home", Delete", "End", "Page Up", and "Page Down" are the "odd" keys I referred too.
I'll test every key on my 104 Key keyboard tonight. See if there are any others.
"Scroll Lock", "Pause/Break", "Insert", "Home", Delete", "End", "Page Up", and "Page Down" are the "odd" keys I referred too.
I'll test every key on my 104 Key keyboard tonight. See if there are any others.
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
Re: [0.14.8] Control UI accepts key but won't fire mod event.
Is there a list of the key and modifier names that the game recognises in the `custom-input` prototypes?
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
Re: [0.14.8] Control UI accepts key but won't fire mod event.
Seems PRINTSCREEN is the only key on my 104 US keyboard that did not work.
The only exception being the mouse buttons. Those are all mouse-button-X where X is a number
1 is left click
2 is right click
3 is middle click
Then if your mouse is like mine you will have a 4 and 5 too.
Mouse Wheel Up is mouse-wheel-up....I think.
Mouse Wheel Down is mouse-wheel-down...I think again.
I just try assigning a key to something. Whatever you see there is exactly what you need to put as the hotkey in your mod. Then I the key I changed I change back.aubergine18 wrote:Is there a list of the key and modifier names that the game recognises in the `custom-input` prototypes?
The only exception being the mouse buttons. Those are all mouse-button-X where X is a number
1 is left click
2 is right click
3 is middle click
Then if your mouse is like mine you will have a 4 and 5 too.
Mouse Wheel Up is mouse-wheel-up....I think.
Mouse Wheel Down is mouse-wheel-down...I think again.
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
Re: [0.14.8] Control UI accepts key but won't fire mod event.
Thanks for infos, particularly about mouse stuff!
As for testing other keys, I'm a bit limited because I'm on a Mac and it has a rather strange keyboard: No 'Del' key, no "PrtScr" key, etc. I can probably get those keys using shortcuts, but even the the game would probably show the shortcut and not the shortcut that results from the shortcut *brain explodes*.
As for testing other keys, I'm a bit limited because I'm on a Mac and it has a rather strange keyboard: No 'Del' key, no "PrtScr" key, etc. I can probably get those keys using shortcuts, but even the the game would probably show the shortcut and not the shortcut that results from the shortcut *brain explodes*.
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
Re: [0.14.8][Twinsen] Control UI accepts key but won't fire mod event.
For some reason Windows does not send key-down events for PRINTSCREEN or SCROLLLOCK.
I made a special case that will trigger events for those keys on key-up instead of key-down.
Fixed in Version: 0.14.15
I made a special case that will trigger events for those keys on key-up instead of key-down.
Fixed in Version: 0.14.15