Made disabling payload conveyors output from routers more reliable. (#4433)
Prevented reconstructors from being roughted to when disabled. Co-authored-by: frederick_efd <frederick.doering@nordson.com>
This commit is contained in:
@@ -217,11 +217,9 @@ public class PayloadConveyor extends Block{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean acceptPayload(Building source, Payload payload){
|
public boolean acceptPayload(Building source, Payload payload){
|
||||||
if(source == this){
|
return this.item == null
|
||||||
return this.item == null && payload.fits(payloadLimit);
|
&& payload.fits(payloadLimit)
|
||||||
}
|
&& (source == this || this.enabled && progress <= 5f);
|
||||||
//accepting payloads from units isn't supported
|
|
||||||
return this.item == null && progress <= 5f && payload.fits(payloadLimit);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -106,6 +106,7 @@ public class Reconstructor extends UnitBlock{
|
|||||||
@Override
|
@Override
|
||||||
public boolean acceptPayload(Building source, Payload payload){
|
public boolean acceptPayload(Building source, Payload payload){
|
||||||
return this.payload == null
|
return this.payload == null
|
||||||
|
&& this.enabled
|
||||||
&& relativeTo(source) != rotation
|
&& relativeTo(source) != rotation
|
||||||
&& payload instanceof UnitPayload
|
&& payload instanceof UnitPayload
|
||||||
&& hasUpgrade(((UnitPayload)payload).unit.type);
|
&& hasUpgrade(((UnitPayload)payload).unit.type);
|
||||||
|
|||||||
Reference in New Issue
Block a user