mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 17:51:24 +01:00
v1.3.29
This commit is contained in:
parent
5d0c51f6be
commit
79e9a12d99
1 changed files with 4 additions and 1 deletions
|
|
@ -338,7 +338,10 @@ document.addEventListener("keyup", event => {
|
||||||
if (active === "DIV" && document.activeElement.contentEditable === "true") return; // don't trigger if user inputs a text
|
if (active === "DIV" && document.activeElement.contentEditable === "true") return; // don't trigger if user inputs a text
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
|
|
||||||
const key = event.keyCode, ctrl = event.ctrlKey || event.metaKey, shift = event.shiftKey, alt = event.altKey;
|
const key = event.keyCode;
|
||||||
|
const ctrl = event.ctrlKey || event.metaKey || key === 17;
|
||||||
|
const shift = event.shiftKey || key === 16;
|
||||||
|
const alt = event.altKey || key === 18;
|
||||||
|
|
||||||
if (key === 112) showInfo(); // "F1" to show info
|
if (key === 112) showInfo(); // "F1" to show info
|
||||||
else if (key === 113) regeneratePrompt(); // "F2" for new map
|
else if (key === 113) regeneratePrompt(); // "F2" for new map
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue