SCPF: Open-Source Doors & Scripts

Hey Guys! So, I am Open-Sourcing a part of a project I was once working on, but we eventually gave up on it.

Some things you should know about the door system:

  • The scripting level used in this is not meant for beginner scripters. If you are a beginner scripter, I would recommend going to this post instead.
  • They are subject to break over time due to the fact that roblox evolves over time.
  • It is not required to give me credit, but it would be appreciated if you did.
  • You are not permmitted to claim it as your own.
  • You may not sell it without my permission.
  • I am not responsible if anything breaks.

Features with the door system:

  • Comes with a clearance system
  • Sounds are customizable
  • Team/Group Locked Door System
  • 7 Different types of Doors
  • And More
Showcase Video

https://youtu.be/aVCymnT4j3Q

Get the file here:
Door System.rbxm (119.3 KB)

23 Likes

here’s some note, The door animation isn’t smooth, make it smooth please

10 Likes

Well it is smooth, it was just when I recorded it my PC had the uh, sounds like whenever you play a ultra-realistic game.

5 Likes

Oh and I’m not much of a scripter, I just started to open source an old project that I have been working on. I’m more of a builder.

3 Likes

if you’re not much of a scripter, then it’s okay! I would need a testing place to see it smoothly

4 Likes

The doors may or may not work, if they do not work, I can try to find the cause.

1 Like

Alright, so I just realised that the doors arnt really working, and I found out why.

The reason is pretty simple, and I find it very stupid about me not putting it in. The reason why the doors weren’t working except for the automatic door, was the missing teams. The Door System has a Team Lock system, so that is most likely why it wasn’t working.

I’ll also be updating the file, but here is the updated file here just incase you get confused or anything.
Door System.rbxm (119.3 KB)

2 Likes

How would you make the door’s team locked?

1 Like

If I remember correctly, if you look into the doors settings, there should be a module called “Clearances.” You then should click it and you should see stuff such as [“TS”] = true, etc.

There should already be a system in the doors that should hopefully know the abbreviations of each department, and just put the abbreviations there. And it should hopefully be teamlocked then.

Currently, every door’s clearance module only contains the group rank “levels”
image
So other than [TS] being the same as the Pending and Test Subject team, there is no way to write in a specific team.

1 Like

Huh. I’m pretty sure you can just add stuff like SD and it should work. But it may have been removed due to technical reasons.

Oh yeah, and if you or anybody else wants to make your own doors, I can show you how to do it.

Can you show us how to make our own doors please?
It would be really useful.

1 Like

I was actually planning on making one! But just haven’t had time to make one. I’ll be sure to make one once I have the time.

How to convert different doors and more

If you are wondering how you can use different models with this system, well here you go!
(Just to let you know, this will have alot of images and it will be long.)

CHAPTER ONE/CONVERTING DOORS
If you look into any of the already existing doors, you will find some core features.

you will find this

Things you would want to keep:

  • Settings
  • InteractPart
  • Base

You can delete the Frame if you want, but it is not mandatory. Now, for doors that are classified as gates, and not doors like this that have left and rights, this part will be fairly simple. We will get onto these doors below soon.

Now, take your model for your gate and name it “Main” if it is a mesh. If it is made up of multiple parts, you can either make it into a union or select a certain part and name it “Main” Make sure that something like this.

image

Once you have named it Main, find the two Sound objects called:

  • DoorClose
  • DoorOpen
    Once you find them, place them into Main. You can also modify the sound of it, to whatever you want it to sound like. Without without these two, your door will not work.

After that, find your InteractPart. It is where the popup will show. Inside of your InteractPart, you will also find two other Sound objects called, “Denied” and “Granted.” These are also mandatory to keep, and you can change the audio to whatever you like. You can also move it wherever you want.

Screenshot 2023-09-30 110940

It is not mandatory to keep the identification scanners, they are just for show.

Onto the Settings.

image

This is also one of the most importants things, since it holds all of the settings for your door. Do not delete anything, as it will affect your door. If you want to make something close automatically, or whatever, please enable the value or whatever.

But, there is a specific property that classifies the door as it is. “Door Type.” It should currently be “bdoor” since you’re using a gate, but you may have already configured it to your likings. This tutorial will go over on how to create your own type of door with the DoorType, but we will cover it later on.

Now, for the other types of doors that are not gates, these will be fairly the same, but just a little different. For these types of doors, you will need hinges. These make your doors move differently from the gate.

I would recommend building off of the original door, as it makes things easier. If you have questions about this, please ask me.

Same goes with this door.

CHAPTER TWO/CREATING DOOR TYPES
Once you have completed the chapter above, you are ready for this section.

Look into ServerScriptService and find “Door System.” There will be a ModuleScript parented to it which holds the door types.

image

Once you have opened it, look for the DoorDictionary. It holds the door types and how it opens.

If you want to a gate, a double door, or a sliding door, you can modify the bdoor for the gate, dsdoor for the sliding door, and dhdoor for the double door.

To modify the positions on how the doors go, you can modify this to your likings.

Just make sure to apply the name of the door type to the DoorType configuration in Settings.

CHAPTER THREE/CREATING CUSTOM RANK PROPERTIES
If you want to create custom group ranks, go find RankHandler. It is also inside of ServerScriptService. Make sure to just change the group id, the group ranks, and the name to your likings.

image

If you want to make it so that its just based on teams, you can use this script.
TeamRankHandler.rbxm (1.8 KB)

This is end of the tutorial! This is essentially my first time making a full on guide on how to do something, and if something is left out that you would like to mention, feel free! I am open to suggestions.

I am not a fan of inserting scripts into every Model/Part when development and often keep everything within a single module.

But these doors do look fire and will probably help other devs to learn how to make doors themselves, pretty cool doors too, I liked the ones where they automatically open when you step near them.

1 Like