Need a little help with Rail/Logic for a flight deck

    Joined
    Jan 27, 2016
    Messages
    169
    Reaction score
    195
    I finally got around to trying my hand at a carrier, and I'm having a little trouble getting the logic and rails down for a flight deck.

    I'm trying to set up a single rail path that will hold six fighters without relying on collision checks. I want to use a flip-flop module to toggle between a launch mode and a recovery mode. Launch mode is easy, all rail blocks forward, but setting up the recovery mode has been a little more difficult.

    I want to use logic to detect where the fighters are on the rails, so that once a fighter in a forward launch position is in place, it will lock down the position behind it. Once the 2nd position is filled, I want the logic to lock down the 3rd position, etc.

    I think I've figured out something that might work, but it seems really clumsy and inefficient. I'm probably over thinking this and any help would be greatly appreciated! :confused:
     
    Joined
    Feb 10, 2017
    Messages
    350
    Reaction score
    776
    • Community Content - Bronze 2
    • Legacy Citizen 5
    • Likeable
    I've actually just finished the logic on a similar system. Don't know if this pic will help any...
    starmade-screenshot-0023.png
    A rail can connect to an activator which will light as long as the rail is occupied. You can use this to make one docking point enable the next docking point using an And...
    I have the docking point rail connected to a button and an activator (where the white light is). When the drone hits the front dock point the rail triggers the button which changes the rail to an unloader. The activator will be lit if there's a drone on that rail/unloader so you use that to connect to an And on the next docking point up the line making it so that when next drone hits the next dock point the And signal and the button signal from the drone now switch the next unloader on. Repeat up the line.
    (The one button and And on their own there are part of the exit logic so exclude them...)
     
    Joined
    Jan 27, 2016
    Messages
    169
    Reaction score
    195
    Oh yeah, I forgot about rails lighting up activator blocks. That's a much more elegant solution then the logic mess I have going now. :^D
    [doublepost=1527314209,1527311364][/doublepost]Cool! It worked, I used my flip flop to set the rail on my farthest parking spot forward to sideway. Then added activation blocks before and after each docking position. In recovery mode, the first activation block encountered feeds into an AND block and toggles the previous position sideways. Then the 2nd activation block just past the parking spot toggles the previous position back to forwards.

    So once a fighter reaches the parking spot at the end of the rail, it will toggle the position behind it sideways, and once that ship parks it will trigger the spot behind it. I got all six fighters docked with no issues. Thanks!
     
    • Like
    Reactions: Brokengauge
    Joined
    Feb 10, 2017
    Messages
    350
    Reaction score
    776
    • Community Content - Bronze 2
    • Legacy Citizen 5
    • Likeable
    Oh yeah, I forgot about rails lighting up activator blocks.
    Did the same thing. Made it way over complicated then remembered and had to redo.

    The Activator on a rail is really useful with automatic plex doors for the hangar as well. Have a row of activators along the rail as it passes through the door. Connect them all to an Or signal and the Or to a Not which goes to the door. as soon as a drone hits the rail, the activator lights, opening the door, as there's activators all along the door it holds the door open as the drone passes through. Best simple automatic door for a rail entity I've been able to find.
     
    Joined
    Nov 3, 2015
    Messages
    24
    Reaction score
    3
    Something like this, where the drones all use a single dock point, but are sorted into multiple launch bays, and the rails are parked so they will not move/collide/overlap and such?

    This one was from before you could link rails to activation modules without them being in contact.
    20160329224049_1.jpg
    20160329223418_1.jpg
    20160329222121_1.jpg
     
    • Like
    Reactions: MrGrey1

    PainNigouto

    Emperor/Toymaker
    Joined
    Aug 11, 2015
    Messages
    47
    Reaction score
    86
    actually, instead of locking the docks starting from the landing side, do it the other way around. do a mechanism on every docking spot with the following rules:

    if entity passes over docking spot AND (next dock is locked OR there is no next dock)
    lock this dock;

    doing so will only lock a specific dock if the system knows the ones coming after it are (going to be) filled, so the ships will slide neatly into place without hiccups.
     

    Edymnion

    Carebear Extraordinaire!
    Joined
    Mar 18, 2015
    Messages
    2,709
    Reaction score
    1,512
    • Purchased!
    • Thinking Positive Gold
    • Legacy Citizen 5
    Piece of advice?

    Single pickup rail points are a nightmare to use. All the drones will cluster around it, knock each other around, and jostle forever trying to get to the docking point.

    The more docking points you have, the better.

    For mine, I use logic to switch the launch rails into pickup rails. The pickup rail, the intangible rails, the shootout rails, they're all flippable with logic.

    So what I do is my rails default to pickup position, pointing in. Then I have my button press that toggles them into launch rails (usually green rails with the last 2 being actual shootout rails), along with a timer. I keep track of how long it takes for the drones to fully deploy, and set the timer for that long plus a second or so, to automatically switch the rails back to recovery mode.

    Because it sucks to do a carrier recall and then find out you still had everything set to deploy.

    Here, I made a quick demo ship to show how to do that part:
    https://starmadedock.net/threads/basic-carrier-logic-demo.30794/
     
    Last edited: