1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2026-03-02 03:39:21 +00:00

Fix throughput goals and add layer preview to producer

This commit is contained in:
tobspr
2020-09-29 12:58:16 +02:00
parent 8ec2a90ae3
commit e96821b555
3 changed files with 15 additions and 7 deletions

View File

@@ -6,6 +6,7 @@ import { blueprintShape, UPGRADES } from "../../upgrades";
import { enumHubGoalRewards } from "../../tutorial_goals";
import { enumAnalyticsDataSource } from "../../production_analytics";
import { T } from "../../../translations";
import { globalConfig } from "../../../core/config";
/**
* Manages the pinned shapes on the left side of the screen
@@ -265,10 +266,11 @@ export class HUDPinnedShapes extends BaseHUDPart {
let currentValueFormatted = formatBigNumber(currentValue);
if (handle.throughputOnly) {
currentValue = this.root.productionAnalytics.getCurrentShapeRate(
enumAnalyticsDataSource.delivered,
handle.definition
);
currentValue =
this.root.productionAnalytics.getCurrentShapeRate(
enumAnalyticsDataSource.delivered,
handle.definition
) / globalConfig.analyticsSliceDurationSeconds;
currentValueFormatted = T.ingame.statistics.shapesDisplayUnits.second.replace(
"<shapes>",
String(currentValue)