From 97ffda0ed93bd0d873f86bdfbcf70c96a9c34630 Mon Sep 17 00:00:00 2001 From: Sense101 <67970865+Sense101@users.noreply.github.com> Date: Sat, 2 Jan 2021 21:54:16 +0000 Subject: [PATCH] Update item_processor.js --- src/js/game/systems/item_processor.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/game/systems/item_processor.js b/src/js/game/systems/item_processor.js index f60c2079..c83eb662 100644 --- a/src/js/game/systems/item_processor.js +++ b/src/js/game/systems/item_processor.js @@ -79,7 +79,8 @@ export class ItemProcessorSystem extends GameSystemWithFilter { if (currentCharge) { // Process next charge if (currentCharge.remainingTime > 0.0) { - currentCharge.remainingTime -= this.root.dynamicTickrate.deltaSeconds; + const deltaTime = this.root.dynamicTickrate.deltaSeconds + processorComp.bonusTime; + currentCharge.remainingTime -= deltaTime; if (currentCharge.remainingTime < 0.0) { // Add bonus time, this is the time we spent too much processorComp.bonusTime += -currentCharge.remainingTime;