From a96b4a290d7bbe907cac17c749ffce01a413a149 Mon Sep 17 00:00:00 2001 From: Mike Winger Date: Fri, 26 Jun 2020 20:00:44 -0600 Subject: [PATCH] Fix tunnel incorrect delete bug --- src/js/game/systems/underground_belt.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/game/systems/underground_belt.js b/src/js/game/systems/underground_belt.js index 0456638a..a1e3855e 100644 --- a/src/js/game/systems/underground_belt.js +++ b/src/js/game/systems/underground_belt.js @@ -88,10 +88,12 @@ export class UndergroundBeltSystem extends GameSystemWithFilter { } const contentsUndergroundComp = contents.components.UndergroundBelt; + const contentsStaticComp = contents.components.StaticMapEntity; if ( contentsUndergroundComp && contentsUndergroundComp.tier === undergroundComp.tier && - contentsUndergroundComp.mode === enumUndergroundBeltMode.sender + contentsUndergroundComp.mode === enumUndergroundBeltMode.sender && + enumAngleToDirection[contentsStaticComp.rotation] === direction ) { matchingEntrance = { entity: contents,