mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
Add setting to always show shape tooltip
This commit is contained in:
parent
ae6c5b151e
commit
f61f25934f
@ -3,7 +3,7 @@ export const CHANGELOG = [
|
|||||||
version: "1.4.3",
|
version: "1.4.3",
|
||||||
date: "28.08.2021",
|
date: "28.08.2021",
|
||||||
entries: [
|
entries: [
|
||||||
"You can now hold 'ALT' while hovering a building to see its output! (Thanks to Sense101)",
|
"You can now hold 'ALT' while hovering a building to see its output! (Thanks to Sense101) (PS: There is now a setting to have it always on!)",
|
||||||
"The map overview should now be much more performant! As a consequence, you can now zoom out farther! (Thanks to PFedak)",
|
"The map overview should now be much more performant! As a consequence, you can now zoom out farther! (Thanks to PFedak)",
|
||||||
"Puzzle DLC: There is now a 'next puzzle' button!",
|
"Puzzle DLC: There is now a 'next puzzle' button!",
|
||||||
"Puzzle DLC: There is now a search function!",
|
"Puzzle DLC: There is now a search function!",
|
||||||
|
@ -29,9 +29,13 @@ export class HUDShapeTooltip extends BaseHUDPart {
|
|||||||
isActive() {
|
isActive() {
|
||||||
const hudParts = this.root.hud.parts;
|
const hudParts = this.root.hud.parts;
|
||||||
|
|
||||||
|
const active =
|
||||||
|
this.root.app.settings.getSetting("shapeTooltipAlwaysOn") ||
|
||||||
|
this.root.keyMapper.getBinding(KEYMAPPINGS.ingame.showShapeTooltip).pressed;
|
||||||
|
|
||||||
// return false if any other placer is active
|
// return false if any other placer is active
|
||||||
return (
|
return (
|
||||||
this.root.keyMapper.getBinding(KEYMAPPINGS.ingame.showShapeTooltip).pressed &&
|
active &&
|
||||||
!this.isPlacingBuilding &&
|
!this.isPlacingBuilding &&
|
||||||
!hudParts.massSelector.currentSelectionStartWorld &&
|
!hudParts.massSelector.currentSelectionStartWorld &&
|
||||||
hudParts.massSelector.selectedUids.size < 1 &&
|
hudParts.massSelector.selectedUids.size < 1 &&
|
||||||
|
@ -257,6 +257,7 @@ export const allApplicationSettings = [
|
|||||||
}),
|
}),
|
||||||
|
|
||||||
new BoolSetting("enableMousePan", enumCategories.advanced, (app, value) => {}),
|
new BoolSetting("enableMousePan", enumCategories.advanced, (app, value) => {}),
|
||||||
|
new BoolSetting("shapeTooltipAlwaysOn", enumCategories.advanced, (app, value) => {}),
|
||||||
new BoolSetting("alwaysMultiplace", enumCategories.advanced, (app, value) => {}),
|
new BoolSetting("alwaysMultiplace", enumCategories.advanced, (app, value) => {}),
|
||||||
new BoolSetting("zoomToCursor", enumCategories.advanced, (app, value) => {}),
|
new BoolSetting("zoomToCursor", enumCategories.advanced, (app, value) => {}),
|
||||||
new BoolSetting("clearCursorOnDeleteWhilePlacing", enumCategories.advanced, (app, value) => {}),
|
new BoolSetting("clearCursorOnDeleteWhilePlacing", enumCategories.advanced, (app, value) => {}),
|
||||||
@ -307,6 +308,7 @@ class SettingsStorage {
|
|||||||
this.autosaveInterval = "two_minutes";
|
this.autosaveInterval = "two_minutes";
|
||||||
|
|
||||||
this.alwaysMultiplace = false;
|
this.alwaysMultiplace = false;
|
||||||
|
this.shapeTooltipAlwaysOn = false;
|
||||||
this.offerHints = true;
|
this.offerHints = true;
|
||||||
this.enableTunnelSmartplace = true;
|
this.enableTunnelSmartplace = true;
|
||||||
this.vignette = true;
|
this.vignette = true;
|
||||||
@ -536,7 +538,7 @@ export class ApplicationSettings extends ReadWriteProxy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getCurrentVersion() {
|
getCurrentVersion() {
|
||||||
return 30;
|
return 31;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @param {{settings: SettingsStorage, version: number}} data */
|
/** @param {{settings: SettingsStorage, version: number}} data */
|
||||||
@ -683,6 +685,11 @@ export class ApplicationSettings extends ReadWriteProxy {
|
|||||||
data.version = 30;
|
data.version = 30;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (data.version < 31) {
|
||||||
|
data.settings.shapeTooltipAlwaysOn = false;
|
||||||
|
data.version = 31;
|
||||||
|
}
|
||||||
|
|
||||||
return ExplainedResult.good();
|
return ExplainedResult.good();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1286,6 +1286,11 @@ settings:
|
|||||||
description: >-
|
description: >-
|
||||||
Controls the size of the shapes on the map overview (when zooming out).
|
Controls the size of the shapes on the map overview (when zooming out).
|
||||||
|
|
||||||
|
shapeTooltipAlwaysOn:
|
||||||
|
title: Shape Tooltip - Show Always
|
||||||
|
description: >-
|
||||||
|
Whether to always show the shape tooltip when hovering buildings, instead of having to hold 'ALT'.
|
||||||
|
|
||||||
keybindings:
|
keybindings:
|
||||||
title: Keybindings
|
title: Keybindings
|
||||||
hint: >-
|
hint: >-
|
||||||
|
Loading…
Reference in New Issue
Block a user