Examples of SignalAspect


Examples of mods.railcraft.api.signals.SignalAspect

                markBlockForUpdate();
            }
            return;
        }
        controller.tickServer();
        SignalAspect prevAspect = controller.getAspect();
        if (controller.isBeingPaired())
            controller.setAspect(SignalAspect.BLINK_YELLOW);
        else if (controller.isPaired())
            controller.setAspect(determineAspect());
        else
View Full Code Here

Examples of mods.railcraft.api.signals.SignalAspect

        }
        return false;
    }

    private SignalAspect determineAspect() {
        SignalAspect newAspect = powered ? poweredAspect : defaultAspect;
        for (int side = 2; side < 6; side++) {
            ForgeDirection forgeSide = ForgeDirection.getOrientation(side);
            TileEntity t = tileCache.getTileOnSide(forgeSide);
            if (t instanceof TileBoxBase) {
                TileBoxBase tile = (TileBoxBase) t;
View Full Code Here

Examples of mods.railcraft.api.signals.SignalAspect

        if (Game.isNotHost(getWorld())) {
            receiver.tickClient();
            return;
        }
        receiver.tickServer();
        SignalAspect prevAspect = receiver.getAspect();
        if (receiver.isBeingPaired()) {
            receiver.setAspect(SignalAspect.BLINK_YELLOW);
        } else if (!receiver.isPaired()) {
            receiver.setAspect(SignalAspect.BLINK_RED);
        }
View Full Code Here

Examples of mods.railcraft.api.signals.SignalAspect

            signalBlock.tickClient();
            return;
        }
        controller.tickServer();
        signalBlock.tickServer();
        SignalAspect prevAspect = controller.getAspect();
        if (controller.isBeingPaired()) {
            controller.setAspect(SignalAspect.BLINK_YELLOW);
        } else {
            controller.setAspect(signalBlock.getSignalAspect());
        }
View Full Code Here

Examples of mods.railcraft.api.signals.SignalAspect

            return SignalAspect.BLINK_YELLOW;
        }
        if (!isPaired()) {
            return SignalAspect.BLINK_RED;
        }
        SignalAspect aspect = SignalAspect.GREEN;
        for (WorldCoordinate otherCoord : pairings) {
            aspect = SignalAspect.mostRestrictive(aspect, aspects.get(otherCoord));
        }
        return aspect;
    }
View Full Code Here

Examples of mods.railcraft.api.signals.SignalAspect

        return aspect;
    }

    @Override
    protected SignalAspect getSignalAspectForPair(WorldCoordinate otherCoord) {
        SignalAspect aspect = SignalAspect.GREEN;
        for (Map.Entry<WorldCoordinate, SignalAspect> entry : aspects.entrySet()) {
            if (entry.getKey().equals(otherCoord)) {
                continue;
            }
            aspect = SignalAspect.mostRestrictive(aspect, entry.getValue());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.