Remap use/speak keys and update help/changelog
This commit is contained in:
@@ -5,7 +5,9 @@
|
|||||||
"items": [
|
"items": [
|
||||||
"Added support for Dropbox links and HTTP streams for item sounds and radio stations.",
|
"Added support for Dropbox links and HTTP streams for item sounds and radio stations.",
|
||||||
"You will no longer repeatedly hit walls.",
|
"You will no longer repeatedly hit walls.",
|
||||||
"Added user volume control and calibration."
|
"Added user volume control and calibration.",
|
||||||
|
"Added up/down arrows and page up/page down for numeric field adjustment.",
|
||||||
|
"Moved Use item to Enter Key instead of u, moved speak users to U from Shift U."
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
"description": "List users; Enter teleports to that user"
|
"description": "List users; Enter teleports to that user"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"keys": "Shift+U",
|
"keys": "U",
|
||||||
"description": "Speak connected users"
|
"description": "Speak connected users"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -82,7 +82,7 @@
|
|||||||
"description": "Delete item"
|
"description": "Delete item"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"keys": "U",
|
"keys": "Enter",
|
||||||
"description": "Use item"
|
"description": "Use item"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
@@ -132,7 +132,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"keys": "V",
|
"keys": "V",
|
||||||
"description": "Set microphone gain"
|
"description": "Set mic volume"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"keys": "Shift+V",
|
"keys": "Shift+V",
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
// Maintainer-controlled web client version.
|
// Maintainer-controlled web client version.
|
||||||
// Format: YYYY.MM.DD Rn (example: 2026.02.20 R2)
|
// Format: YYYY.MM.DD Rn (example: 2026.02.20 R2)
|
||||||
window.CHGRID_WEB_VERSION = "2026.02.22 R156";
|
window.CHGRID_WEB_VERSION = "2026.02.22 R157";
|
||||||
// Optional display timezone for timestamps. Falls back to America/Detroit if unset/invalid.
|
// Optional display timezone for timestamps. Falls back to America/Detroit if unset/invalid.
|
||||||
window.CHGRID_TIME_ZONE = "America/Detroit";
|
window.CHGRID_TIME_ZONE = "America/Detroit";
|
||||||
|
|||||||
@@ -16,7 +16,8 @@ export type MainModeCommand =
|
|||||||
| 'speakCoordinates'
|
| 'speakCoordinates'
|
||||||
| 'openMicGainEdit'
|
| 'openMicGainEdit'
|
||||||
| 'calibrateMicrophone'
|
| 'calibrateMicrophone'
|
||||||
| 'useItemOrUsersSummary'
|
| 'useItem'
|
||||||
|
| 'speakUsers'
|
||||||
| 'addItem'
|
| 'addItem'
|
||||||
| 'locateOrListItems'
|
| 'locateOrListItems'
|
||||||
| 'pickupDropOrDelete'
|
| 'pickupDropOrDelete'
|
||||||
@@ -46,7 +47,8 @@ export function resolveMainModeCommand(code: string, shiftKey: boolean): MainMod
|
|||||||
if (code === 'Minus' || code === 'NumpadSubtract') return 'effectValueDown';
|
if (code === 'Minus' || code === 'NumpadSubtract') return 'effectValueDown';
|
||||||
if (code === 'KeyC') return 'speakCoordinates';
|
if (code === 'KeyC') return 'speakCoordinates';
|
||||||
if (code === 'KeyV') return shiftKey ? 'calibrateMicrophone' : 'openMicGainEdit';
|
if (code === 'KeyV') return shiftKey ? 'calibrateMicrophone' : 'openMicGainEdit';
|
||||||
if (code === 'KeyU') return 'useItemOrUsersSummary';
|
if (code === 'Enter') return 'useItem';
|
||||||
|
if (code === 'KeyU') return 'speakUsers';
|
||||||
if (code === 'KeyA') return 'addItem';
|
if (code === 'KeyA') return 'addItem';
|
||||||
if (code === 'KeyI') return 'locateOrListItems';
|
if (code === 'KeyI') return 'locateOrListItems';
|
||||||
if (code === 'KeyD') return 'pickupDropOrDelete';
|
if (code === 'KeyD') return 'pickupDropOrDelete';
|
||||||
|
|||||||
@@ -1376,34 +1376,33 @@ function handleNormalModeInput(code: string, shiftKey: boolean): void {
|
|||||||
case 'calibrateMicrophone':
|
case 'calibrateMicrophone':
|
||||||
void calibrateMicInputGain();
|
void calibrateMicInputGain();
|
||||||
return;
|
return;
|
||||||
case 'useItemOrUsersSummary':
|
case 'useItem': {
|
||||||
if (shiftKey) {
|
const carried = getCarriedItem();
|
||||||
const allUsers = [state.player.nickname, ...Array.from(state.peers.values()).map((p) => p.nickname)];
|
if (carried) {
|
||||||
const label = allUsers.length === 1 ? 'user' : 'users';
|
useItem(carried);
|
||||||
updateStatus(`${allUsers.length} ${label}: ${allUsers.join(', ')}`);
|
|
||||||
audio.sfxUiBlip();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
{
|
const squareItems = getItemsAtPosition(state.player.x, state.player.y);
|
||||||
const carried = getCarriedItem();
|
const usable = squareItems.filter((item) => item.capabilities.includes('usable'));
|
||||||
if (carried) {
|
if (usable.length === 0) {
|
||||||
useItem(carried);
|
updateStatus('No usable items here.');
|
||||||
return;
|
audio.sfxUiCancel();
|
||||||
}
|
|
||||||
const squareItems = getItemsAtPosition(state.player.x, state.player.y);
|
|
||||||
const usable = squareItems.filter((item) => item.capabilities.includes('usable'));
|
|
||||||
if (usable.length === 0) {
|
|
||||||
updateStatus('No usable items here.');
|
|
||||||
audio.sfxUiCancel();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (usable.length === 1) {
|
|
||||||
useItem(usable[0]);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
beginItemSelection('use', usable);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (usable.length === 1) {
|
||||||
|
useItem(usable[0]);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
beginItemSelection('use', usable);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
case 'speakUsers': {
|
||||||
|
const allUsers = [state.player.nickname, ...Array.from(state.peers.values()).map((p) => p.nickname)];
|
||||||
|
const label = allUsers.length === 1 ? 'user' : 'users';
|
||||||
|
updateStatus(`${allUsers.length} ${label}: ${allUsers.join(', ')}`);
|
||||||
|
audio.sfxUiBlip();
|
||||||
|
return;
|
||||||
|
}
|
||||||
case 'addItem': {
|
case 'addItem': {
|
||||||
const itemTypeSequence = getItemTypeSequence();
|
const itemTypeSequence = getItemTypeSequence();
|
||||||
if (itemTypeSequence.length === 0) {
|
if (itemTypeSequence.length === 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user