1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2024-10-27 20:34:29 +00:00

Minor polishing and standlaone adjustments

This commit is contained in:
tobspr 2022-06-20 12:17:19 +02:00
parent 0052c30553
commit 88f5c41716
7 changed files with 28 additions and 8 deletions

View File

@ -381,7 +381,10 @@
justify-content: center; justify-content: center;
flex-direction: column; flex-direction: column;
background: $colorBlueBright; background: $colorBlueBright;
grid-row: 1 / 2; height: 100%;
grid-row: 1 / 4;
width: 100%;
box-sizing: border-box;
position: relative; position: relative;
@include S(padding, 20px); @include S(padding, 20px);
@include S(border-radius, $globalBorderRadius); @include S(border-radius, $globalBorderRadius);
@ -529,6 +532,7 @@
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
@include S(border-radius, $globalBorderRadius);
pointer-events: all; pointer-events: all;
:last-child { :last-child {
@ -1009,15 +1013,16 @@
> a, > a,
.sidelinks > a { .sidelinks > a {
background-color: rgba($darkModeControlsBackground, 0.3); background-color: rgba($darkModeControlsBackground, 0.3);
color: #eee; color: #333538;
&:hover { &:hover {
background-color: rgba(darken($darkModeControlsBackground, 5), 0.5); background-color: rgba(darken($darkModeControlsBackground, 5), 0.4);
} }
} }
.thirdpartyLogo.githubLogo { .thirdpartyLogo.githubLogo {
filter: invert(1); // filter: invert(1);
opacity: 0.7;
} }
} }
} }

View File

@ -6,6 +6,7 @@ export const CHANGELOG = [
"Reworked the tutorial to be simpler and more interactive", "Reworked the tutorial to be simpler and more interactive",
"General polishing", "General polishing",
"Fix being unable to delete savegame when the savegame file was deleted externally", "Fix being unable to delete savegame when the savegame file was deleted externally",
"New sfx when unlocking upgrades",
"Updated translations", "Updated translations",
], ],
}, },

View File

@ -16,9 +16,9 @@ import { Vector } from "../../../core/vector";
import { MetaMinerBuilding } from "../../buildings/miner"; import { MetaMinerBuilding } from "../../buildings/miner";
import { gMetaBuildingRegistry } from "../../../core/global_registries"; import { gMetaBuildingRegistry } from "../../../core/global_registries";
import { MetaBeltBuilding } from "../../buildings/belt"; import { MetaBeltBuilding } from "../../buildings/belt";
import { BeltComponent } from "../../components/belt";
import { MetaTrashBuilding } from "../../buildings/trash"; import { MetaTrashBuilding } from "../../buildings/trash";
import { SOUNDS } from "../../../platform/sound"; import { SOUNDS } from "../../../platform/sound";
import { THEME } from "../../theme";
// @todo: Make dictionary // @todo: Make dictionary
const tutorialsByLevel = [ const tutorialsByLevel = [
@ -174,9 +174,15 @@ export class HUDInteractiveTutorial extends BaseHUDPart {
this.elementGif = makeDiv(this.element, null, ["helperGif"]); this.elementGif = makeDiv(this.element, null, ["helperGif"]);
} }
cleanup() {
document.documentElement.setAttribute("data-tutorial-step", "");
}
initialize() { initialize() {
this.domAttach = new DynamicDomAttach(this.root, this.element, { trackHover: true }); this.domAttach = new DynamicDomAttach(this.root, this.element, { trackHover: true });
this.currentHintId = new TrackedState(this.onHintChanged, this); this.currentHintId = new TrackedState(this.onHintChanged, this);
document.documentElement.setAttribute("data-tutorial-step", "");
} }
onHintChanged(hintId) { onHintChanged(hintId) {
@ -376,7 +382,7 @@ export class HUDInteractiveTutorial extends BaseHUDPart {
parameters.context.translate(-worldPos.x, -worldPos.y); parameters.context.translate(-worldPos.x, -worldPos.y);
} }
parameters.context.fillStyle = "rgb(30, 40, 60)"; parameters.context.fillStyle = THEME.map.tutorialDragText;
parameters.context.font = "15px GameFont"; parameters.context.font = "15px GameFont";
if (staticComp.rotation === 0) { if (staticComp.rotation === 0) {

View File

@ -607,7 +607,8 @@ export class HUDWaypoints extends BaseHUDPart {
// Render the background rectangle // Render the background rectangle
parameters.context.globalAlpha = this.currentMarkerOpacity * (isSelected ? 1 : 0.7); parameters.context.globalAlpha = this.currentMarkerOpacity * (isSelected ? 1 : 0.7);
parameters.context.fillStyle = "rgba(255, 255, 255, 0.7)"; parameters.context.fillStyle = "rgba(255, 255, 255, 0.7)";
parameters.context.fillRect(bounds.x, bounds.y, bounds.w, bounds.h); parameters.context.beginRoundedRect(bounds.x, bounds.y, bounds.w, bounds.h, 6);
parameters.context.fill();
// Render the text // Render the text
if (waypointData.item) { if (waypointData.item) {

View File

@ -12,6 +12,8 @@
"chunkBorders": "rgba(127, 190, 255, 0.04)", "chunkBorders": "rgba(127, 190, 255, 0.04)",
"tutorialDragText": "rgb(74, 237, 134)",
"directionLock": { "directionLock": {
"regular": { "regular": {
"color": "rgb(74, 237, 134)", "color": "rgb(74, 237, 134)",

View File

@ -13,6 +13,8 @@
"chunkBorders": "rgba(0, 30, 50, 0.03)", "chunkBorders": "rgba(0, 30, 50, 0.03)",
"tutorialDragText": "rgb(30, 40, 60)",
"directionLock": { "directionLock": {
"regular": { "regular": {
"color": "rgb(74, 237, 134)", "color": "rgb(74, 237, 134)",

View File

@ -112,7 +112,10 @@ export class ClientAPI {
return Promise.resolve({ token }); return Promise.resolve({ token });
} }
return ipcRenderer.invoke("steam:get-ticket").then( return Promise.race([
ipcRenderer.invoke("steam:get-ticket"),
new Promise((resolve, reject) => setTimeout(() => reject("timeout"), 15000)),
]).then(
ticket => { ticket => {
logger.log("Got auth ticket:", ticket); logger.log("Got auth ticket:", ticket);
return this._request("/v1/public/login", { return this._request("/v1/public/login", {