diff --git a/src/js/game/belt_path.js b/src/js/game/belt_path.js index bf797c61..f172b1a3 100644 --- a/src/js/game/belt_path.js +++ b/src/js/game/belt_path.js @@ -119,14 +119,6 @@ export class BeltPath extends BasicSerializableObject { this.numCompressedItemsAfterFirstItem = 0; } - /** - * Returns whether this path can accept a new item - * @returns {boolean} - */ - canAcceptItem() { - return this.spacingToFirstItem >= globalConfig.itemSpacingOnBelts; - } - /** * Tries to accept the item * @param {BaseItem} item @@ -135,15 +127,10 @@ export class BeltPath extends BasicSerializableObject { tryAcceptItem(item, extraProgress = 0) { if (this.spacingToFirstItem >= globalConfig.itemSpacingOnBelts) { // So, since we already need one tick to accept this item we will add this directly. - // this means we are moving it forwards twice in one tick, but otherwise belts won't be full :( - const beltProgressPerTick = - this.root.hubGoals.getBeltBaseSpeed() * - this.root.dynamicTickrate.deltaSeconds * - globalConfig.itemSpacingOnBelts; // First, compute how much progress we can make *at max* const maxProgress = Math.max(0, this.spacingToFirstItem - globalConfig.itemSpacingOnBelts); - const initialProgress = Math.min(maxProgress, beltProgressPerTick + extraProgress); + const initialProgress = Math.min(maxProgress, extraProgress); this.items.unshift([this.spacingToFirstItem - initialProgress, item]); this.spacingToFirstItem = initialProgress;