for (const key_switch_selector of document.querySelectorAll('[id^="key_switch_to_"]')) {
const action = key_switch_selector.id.slice("key_switch_to_".length);
- const msg = "[" + mode_helps[action].short + "]: ";
- key_switch_selector.parentNode.prepend(msg);
+ key_switch_selector.parentNode.prepend(mode_helps[action].short + ': ');
}
function restore_selector_value(selector) {
}
this.empty_input();
this.restore_input_values();
- document.getElementById("take_thing").disabled = true;
- document.getElementById("drop_thing").disabled = true;
- document.getElementById("flatten").disabled = true;
- document.getElementById("teleport").disabled = true;
- document.getElementById("toggle_map_mode").disabled = true;
- document.getElementById("switch_to_chat").disabled = true;
- document.getElementById("switch_to_play").disabled = true;
- document.getElementById("switch_to_study").disabled = true;
- document.getElementById("switch_to_edit").disabled = true;
- document.getElementById("switch_to_portal").disabled = true;
- document.getElementById("switch_to_annotate").disabled = true;
- document.getElementById("switch_to_password").disabled = true;
- document.getElementById("switch_to_admin").disabled = true;
- document.getElementById("switch_to_control_pw_type").disabled = true;
- document.getElementById("switch_to_control_tile_type").disabled = true;
- document.getElementById("move_left").disabled = true;
- document.getElementById("move_upleft").disabled = true;
- document.getElementById("move_up").disabled = true;
- document.getElementById("move_upright").disabled = true;
- document.getElementById("move_downleft").disabled = true;
- document.getElementById("move_down").disabled = true;
- document.getElementById("move_downright").disabled = true;
- document.getElementById("move_right").disabled = true;
+ for (let el of document.getElementsByTagName("button")) {
+ el.disabled = true;
+ }
+ document.getElementById("help").disabled = false;
if (this.mode.name == 'play' || this.mode.name == 'study' || this.mode.name == 'control_tile_draw') {
document.getElementById("move_left").disabled = false;
document.getElementById("move_right").disabled = false;