File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -247,7 +247,7 @@ inline std::optional<connection_end_id_t> BlockData::getInputOrBidirectionalConn
247247 }
248248 Vector noOrientationVec = orientation.inverseTransformVectorWithArea (vector, orientation * blockSize);
249249 for (auto & pair : connections) {
250- if (pair.second .positionOnBlock == noOrientationVec && pair.second .portType != ConnectionData::PortType::OUTPUT ) return pair.first ;
250+ if (pair.second .positionOnBlock == noOrientationVec && ( pair.second .portType == ConnectionData::PortType::INPUT || pair. second . portType == ConnectionData::PortType::BIDIRECTIONAL) ) return pair.first ;
251251 }
252252 return std::nullopt ;
253253}
@@ -258,7 +258,7 @@ inline std::optional<connection_end_id_t> BlockData::getOutputOrBidirectionalCon
258258 }
259259 Vector noOrientationVec = orientation.inverseTransformVectorWithArea (vector, orientation * blockSize);
260260 for (auto & pair : connections) {
261- if (pair.second .positionOnBlock == noOrientationVec && pair.second .portType != ConnectionData::PortType::INPUT ) return pair.first ;
261+ if (pair.second .positionOnBlock == noOrientationVec && ( pair.second .portType != ConnectionData::PortType::OUTPUT || pair. second . portType != ConnectionData::PortType::BIDIRECTIONAL) ) return pair.first ;
262262 }
263263 return std::nullopt ;
264264}
You can’t perform that action at this time.
0 commit comments