My Factory needs a good door

  • Please make sure you are posting in the correct place. Server ads go here and modpack bugs go here
  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

JRRJRR100

New Member
Jul 29, 2019
23
0
0
Ok I havent played FTB much so I dont know everything about FTB mods so I ask here:
Is there possible to do front door for my factory that wont open without acces to open it. I think this is possible with ComputerCraft.
So the door would open with pressure plates and pistons, so it would open "automatically" but is there possible to do it that way there would be a computer and I type password to it and door opens when walking to pressure plates, but when I lock the door from the computer (needs password again to open) it wouldnt open when walking on those pressure plates.
Im sorry, my english isnt good but hope you understand!
 

Bibble

New Member
Jul 29, 2019
1,089
0
0
There're a couple of ways of doing something like this.
Computercraft has a player detector, which will output the name of the player that clicks on it to a computer (which can the activate redstone and do fancy stuff).
It's also got a radar-type thing, which scans an area, and outputs the names of the players it finds.
You can do similar things with item-based systems and filters (throw a torch into the hopper, and it'll let you in.
You could use force fields, which need you to be authorised, and have a special tool to pass through.

Or, there are Thaumcraft arcane doors, which only open for you (and anyone you give permission to with a crafted key).
 

YX33A

New Member
Jul 29, 2019
3,764
1
0
And there is... wait, do you want a cool looking door or a very functional one?

For cool looking doors, you'll want either Carpenter's Blocks(carpenters doors are awesome for this) and can be made to work as an iron door very easily, and there is my personal choice, Tall Doors, which get really big and don't look not half bad either. Bonus points for Tall Doors since it also has Mosaic art, which makes castle building MUCH more cool.

For functional doors, plenty of options depending on if you want to keep people out and only let you in, allow those you wish to allow in access, or doors that are trick doors that are easy to open if you know the trick.
 

DanteGalileo

New Member
Jul 29, 2019
228
0
0
I have no idea which modpacks use which mods but Witchery doors come with a key.

The cook thing about the aforementioned carpenter's blocks doors is that, side-by-side, they function as double doors without needing to wire them.
 

Hoff

Tech Support
Oct 30, 2012
2,901
1,502
218
You could code a computer to check if lock is true/false if false then check side for redstone and if redstone true open door. If lock is true it'd send a redstone signal to a computer on the outside wall that can be accessed which would be checking for said redstone and if redstone is true then it activates the password program.
 

casilleroatr

New Member
Jul 29, 2019
1,360
0
0
In a big creative build I am doing based on Arendelle from the movie Frozen I had a big door based on drawbridges from Tinker's construct that was controlled by computers. It had a blacklist and a whitelist so it would open if any whitelisted people arrived and it would stay shut if a blacklisted person was around even if a whitelisted person wanted to go through. There was also a redstone check in the program that would hold the gate open if the signal was true. The blacklist is not thoroughly tested because I only added it on so that I could blacklist the bad guys (spoiler alert they are mentioned by name in the program) from the film for fun and the whitelist also has characters like Princess Anna on it so it might need some editing if you want to use it.

It uses the sensors from open peripherals to scan for players and it doesn't require password authentication. The code is in the spoiler. I can't guarantee it will work but it might serve as a good baseline for writing your own program. I added a few comments to help out.

Code:
--Finally we're opening up the gates

--//Init

local sensor = peripheral.wrap("left")

--//Variables

local transmitter = "right" -- Set this to the side that controls the gate open/close
local receiver = "back" -- Set this to the side you want to check redstone on to keep the gate open
local delay = 10 -- The frequency of checking for players
local whiteList = {
    [1] = "Queen Elsa of Arendelle",
    [2] = "Princess Anna of Arendelle",
   
    [3] = "Kristoff",
    [4] = "Olaf",
    [5] = "Sven",
    [6] = "Wandering Oaken",
    [7] = "Marshmallow",
    }
   
local blackList = {
    [1] = "Hans of the Southern Isles",
    [2] = "The Duke of Weselton",
    }
   
--//postInit

--//Functions

function checkPlayerPriveleges(id) -- Scans player list against blacklist and then whitelist to see if the door can be opened
    print("Blacklist Check:")
    for i,v in pairs(blackList) do
        print("\tChecking for "..v)
        for k,w in pairs(id) do
            if v == w then
                print("\tNaughty people detected, locking gate")
                return false
            end
        end
    end
    print("Whitelist Check:")
    for i,v in pairs(whiteList) do
        print("\tChecking for "..v)
        for k,w in pairs(id) do
            if v == w then
                print("\tNice person detected, finalising security check")
                return true, w
            end
        end
    end
    return false
end

function isInRange(player) -- Ensures that the player is in range (necessary in my case because of the way the door was laid out. Range is determined as distance from the sensor in meters.
    print(player)
    print("Hello")
    local playerData = sensor.getPlayerData(player)
    local position = playerData["position"]
    if position["y"] == 2 and position["z"] > -4 then
        if (position["x"] < -2 or position["x"] > 4) and position["z"] < 2 then
            return false
        else
            return true
        end
    else
        return false
    end
end

function openDoor(player) -- Opens door for up to 10 seconds
    print("Opening door for "..player)
    redstone.setOutput(transmitter, true)
    sleep(5)
    local playerIDs = sensor.getPlayerNames() -- I should probably have deleted this line it seems unnecessary
    for i = 5,1,-1 do
        local playerIDs = sensor.getPlayerNames()
        local stillInRange = false
        for i,v in pairs(playerIDs) do
            if v == player then
                stillInRange = true
            end
        end
        if stillInRange then
            print(player.." still in range; keeping door open")
            sleep(1)
        else
            print("Player out of range; closing gate")
            redstone.setOutput(transmitter, false)
            return
        end
        print("Countdown remaining: "..i)
        sleep(1)
    end   
    print("Countdown elapsed; auto closing gate")
    redstone.setOutput(transmitter, false)
end

function mainProg() -- Main handler for getting nearby player list and getting there privleges and ensuring they are in range
    print("Scanning the gate zone...")
    local playerIDs = sensor.getPlayerNames()
    if #playerIDs > 0 then
        local playerCheck = {checkPlayerPriveleges(playerIDs)}
        if playerCheck[1] then
            local finalCheck = isInRange(playerCheck[2])
            if finalCheck then
                print(playerCheck[2].." is in range")
                openDoor(playerCheck[2])
            else
                print(playerCheck[2].." is not in range")
            end
        end       
    else
        print("No players in range")
    end
end

--//Main Prog

--sleep(8)
while true do
    term.clear()
    term.setCursorPos(1,1)
    print("Gate Controller")
    if redstone.getInput(receiver) then
        mainProg()
    else -- This will leave the door open based on the way I had redstone set up.
        print("Under Queen Elsa's and Princess Anna's orders, the gates are to remain open for the foreseeable future.")
    end
    sleep(delay)
end
[/spoilers]
 

JRRJRR100

New Member
Jul 29, 2019
23
0
0
Im not very good in coding but I decided to learn atleast coding with ComputerCraft. That code you posted helps me a lot I think. Testing it tonight and posting my results here with pics

In a big creative build I am doing based on Arendelle from the movie Frozen I had a big door based on drawbridges from Tinker's construct that was controlled by computers. It had a blacklist and a whitelist so it would open if any whitelisted people arrived and it would stay shut if a blacklisted person was around even if a whitelisted person wanted to go through. There was also a redstone check in the program that would hold the gate open if the signal was true. The blacklist is not thoroughly tested because I only added it on so that I could blacklist the bad guys (spoiler alert they are mentioned by name in the program) from the film for fun and the whitelist also has characters like Princess Anna on it so it might need some editing if you want to use it.

It uses the sensors from open peripherals to scan for players and it doesn't require password authentication. The code is in the spoiler. I can't guarantee it will work but it might serve as a good baseline for writing your own program. I added a few comments to help out.

Code:
--Finally we're opening up the gates

--//Init

local sensor = peripheral.wrap("left")

--//Variables

local transmitter = "right" -- Set this to the side that controls the gate open/close
local receiver = "back" -- Set this to the side you want to check redstone on to keep the gate open
local delay = 10 -- The frequency of checking for players
local whiteList = {
    [1] = "Queen Elsa of Arendelle",
    [2] = "Princess Anna of Arendelle",

    [3] = "Kristoff",
    [4] = "Olaf",
    [5] = "Sven",
    [6] = "Wandering Oaken",
    [7] = "Marshmallow",
    }

local blackList = {
    [1] = "Hans of the Southern Isles",
    [2] = "The Duke of Weselton",
    }

--//postInit

--//Functions

function checkPlayerPriveleges(id) -- Scans player list against blacklist and then whitelist to see if the door can be opened
    print("Blacklist Check:")
    for i,v in pairs(blackList) do
        print("\tChecking for "..v)
        for k,w in pairs(id) do
            if v == w then
                print("\tNaughty people detected, locking gate")
                return false
            end
        end
    end
    print("Whitelist Check:")
    for i,v in pairs(whiteList) do
        print("\tChecking for "..v)
        for k,w in pairs(id) do
            if v == w then
                print("\tNice person detected, finalising security check")
                return true, w
            end
        end
    end
    return false
end

function isInRange(player) -- Ensures that the player is in range (necessary in my case because of the way the door was laid out. Range is determined as distance from the sensor in meters.
    print(player)
    print("Hello")
    local playerData = sensor.getPlayerData(player)
    local position = playerData["position"]
    if position["y"] == 2 and position["z"] > -4 then
        if (position["x"] < -2 or position["x"] > 4) and position["z"] < 2 then
            return false
        else
            return true
        end
    else
        return false
    end
end

function openDoor(player) -- Opens door for up to 10 seconds
    print("Opening door for "..player)
    redstone.setOutput(transmitter, true)
    sleep(5)
    local playerIDs = sensor.getPlayerNames() -- I should probably have deleted this line it seems unnecessary
    for i = 5,1,-1 do
        local playerIDs = sensor.getPlayerNames()
        local stillInRange = false
        for i,v in pairs(playerIDs) do
            if v == player then
                stillInRange = true
            end
        end
        if stillInRange then
            print(player.." still in range; keeping door open")
            sleep(1)
        else
            print("Player out of range; closing gate")
            redstone.setOutput(transmitter, false)
            return
        end
        print("Countdown remaining: "..i)
        sleep(1)
    end
    print("Countdown elapsed; auto closing gate")
    redstone.setOutput(transmitter, false)
end

function mainProg() -- Main handler for getting nearby player list and getting there privleges and ensuring they are in range
    print("Scanning the gate zone...")
    local playerIDs = sensor.getPlayerNames()
    if #playerIDs > 0 then
        local playerCheck = {checkPlayerPriveleges(playerIDs)}
        if playerCheck[1] then
            local finalCheck = isInRange(playerCheck[2])
            if finalCheck then
                print(playerCheck[2].." is in range")
                openDoor(playerCheck[2])
            else
                print(playerCheck[2].." is not in range")
            end
        end   
    else
        print("No players in range")
    end
end

--//Main Prog

--sleep(8)
while true do
    term.clear()
    term.setCursorPos(1,1)
    print("Gate Controller")
    if redstone.getInput(receiver) then
        mainProg()
    else -- This will leave the door open based on the way I had redstone set up.
        print("Under Queen Elsa's and Princess Anna's orders, the gates are to remain open for the foreseeable future.")
    end
    sleep(delay)
end
[/spoilers]
 

trajing

New Member
Jul 29, 2019
3,091
-14
1
Drawbridges are for the weak.

Using Ars Magica's gateway to get through a one thick wall? Now that's style.
When not using Magitech mods like Technomancy, I tend to keep stuff from magic mods in Mage towers and tech mods in factories.
 

Shazam08

New Member
Jul 29, 2019
364
0
0
When not using Magitech mods like Technomancy, I tend to keep stuff from magic mods in Mage towers and tech mods in factories.

You're no fun...

How about slipstream generators slime channels to launch you WAY up in the air, then a portable hole focus Openblocks elevator to get you to your desired floor? Magic could do it so much better...
 
  • Like
Reactions: SinisterBro :3

YX33A

New Member
Jul 29, 2019
3,764
1
0
A few Portal Mod Launchpads would make a ideal way into any factory IMO, but the Sync idea seems good too.
 

JRRJRR100

New Member
Jul 29, 2019
23
0
0
Didnt got any results because Im not good in this :p I`ll plan my base ready and then start engineering my door.. Posting it whit pics of course.
 

Shevron

Well-Known Member
Aug 12, 2013
838
302
78
Is there any mod that adds larger doors?

A 2 x 3 door would be nice, or something of the sort. When things start getting a bit big, the standard 1x2 door looks a bit silly.

I know there's draw bridges, but they're a different mechanic aesthetically speaking. I like a good old fashioned door on hinges.[DOUBLEPOST=1395764804][/DOUBLEPOST]Should learn to google before posting.

http://modsforminecraft.com/add-dra...s-to-minecraft-with-the-tall-doors-mod-1-6-2/ (!!!)
 

YX33A

New Member
Jul 29, 2019
3,764
1
0
And there is... wait, do you want a cool looking door or a very functional one?

For cool looking doors, you'll want either Carpenter's Blocks(carpenters doors are awesome for this) and can be made to work as an iron door very easily, and there is my personal choice, Tall Doors, which get really big and don't look not half bad either. Bonus points for Tall Doors since it also has Mosaic art, which makes castle building MUCH more cool.

For functional doors, plenty of options depending on if you want to keep people out and only let you in, allow those you wish to allow in access, or doors that are trick doors that are easy to open if you know the trick.
Is there any mod that adds larger doors?

A 2 x 3 door would be nice, or something of the sort. When things start getting a bit big, the standard 1x2 door looks a bit silly.

I know there's draw bridges, but they're a different mechanic aesthetically speaking. I like a good old fashioned door on hinges.[DOUBLEPOST=1395764804][/DOUBLEPOST]Should learn to google before posting.

http://modsforminecraft.com/add-dra...s-to-minecraft-with-the-tall-doors-mod-1-6-2/ (!!!)
Or, y'know, reading every post in the thread?
...unless... are you ignoring me?
 

Shevron

Well-Known Member
Aug 12, 2013
838
302
78
Or, y'know, reading every post in the thread?
...unless... are you ignoring me?
:( .. but I wuv you :(

No really ... apologies. Got a massive headache, so I'm kinda reading but my brain is registering only 30% of the input.
 
  • Like
Reactions: YX33A

YX33A

New Member
Jul 29, 2019
3,764
1
0
:( .. but I wuv you :(

No really ... apologies. Got a massive headache, so I'm kinda reading but my brain is registering only 30% of the input.
It's fine, just wasn't sure what was up with that.

Seriously, though. Big Doors adds Mosaic. Add it for the bigass doors, keep it for the fancy decorations for your house.