How to make Gui Tool System?

Will, there ever be any some sort of is the sort of GUI that will pop up after I take the tool And will there be any GUI that will pop up when I open the door?

Example, you equipped (tools name)

Then later I find the door

GUI “door key used”

1 Like

Horror Game System.rbxl (55.2 KB)

Here is the place file. I added a door and an elevator.

Here are some instructions:

Instructions

How to create the data for an item:

  • Go to ReplicatedStorage > InteractableItems (Folder) then copy one of the templates.

image

The name of the folder is the name the item is referenced by. It needs to be unique. The Value of “InGameName” is the name the players will see. The Value of Image is the URL of the image used to represent the item.


How to make a pick up item:

Copy the template:
image
(note the template is the click detector, not the part. You can put the click detector in models, parts, meshparts, etc)

Set the value of item name to the name of the item you want to give (based on folder name above). Set Destroy on Interact to the instance you want destroyed when the player gets the item (probably the model/part that represents the item).


How to use interactable stuff:

I made two types, one that plays a tween and one that destroys something. Both interactables have a folder with the name “RequiredItems”

image

Put folders with the names of the items you want the player two need inside each of the two folders: MultiUse and SingleUse. Items in SingleUse will be taken from the player. Items in MutliUse will not be taken.

Set DestroyOnInteract to the instance you want to be destroyed (door, wall, gate, etc)

The tween interactable looks a little different:

image

Set the moving part to the part you want to move. Probably a part that acts as a hinge for doors (weld the door to the hinge). Set the FirstPositionPart to a part with the desired first position (for a door probably the closed position). Set the SecondPartPosition to a part with the desired second position (for a door probably the opened door position).


That might look like a lot, but just look at the place file and you’ll get it pretty fast. If it’s hard to use (I’m going to make another one that I’ll open source officially) I can make the doors and stuff for you :+1:

(this version is a bit of a mess XD)

3 Likes

Thank you so so so much for your hard work. It blows my mind!

1 Like

Hi, I got a question, While I am testing the stuff out, are you able to make the other one if that one has more features?

Yeah. It’s going to be a little bit though. I’m working on quite a few different projects right now.

Edit:

I haven’t. SimplyStore, locaiton marker system, school in general, a game I’m making in unity, a cool particle simulation with marching squares algorithm, one or two Roblox games, etc. I’ve got a lot of stuff right now. This one isn’t a very big priority. I wouldn’t expect it to be finished, sorry :frowning_face_with_open_mouth:

1 Like

okay no worries, again TYSM for making this. I am going to give you credit even if you don’t want me too. I would feel terrible if I didn’t.

I tested this out, and this works very well I love this system tysm for making this

Question, have you made the other system?
also what projects have you been working on lately?

ahh, no worries. I hope you can finish your stuff in unity. Good luck with that.

1 Like

Question, How do I make a new Door?

Sorry that I asked again (not trying to spam I just replied to the wrong person lol)

Question, how do you make a NEW door?

so like I have a PBR textured door with a Frame and A Door part (These are Mesh parts)
I looked at the Instructions and I couldnt find anything.

Hey, this is interesting!
Does the key icon
image
that appear inside the door, is made by GUI in Attachment?

1 Like

So you need to add three parts:

  • a part at the initial position+rotation
  • a part at the final position+rotation
  • and a part that you want to move between the positions of the two parts

The third part acts like a hinge: it tweens between the two other part’s CFrames. This means you should have one part that’s at where the hinge should be when the door is closed, and another that’s where the hinge should be when the door is opened (probably just rotated 90 degrees).

Then you need to add a click detector (or proximity prompt, though I think your using CDs) to the part or model (in your case probably the door MeshPart). After you add the click detector, copy the script from the door in the file above:

image

(note the correct script has a Configuration named “(TWEEN INTERACTABLE)” in it).

Then you just need to select the three ObjectValues and change their Value property to the three parts listed above:

Now the door should work. To get the UI to be in the correct position, change the BillboardGui’s Adornee to the door part/MeshPart.

To set the required items, go into the RequiredItems folder and mess around with those.


Yep! It’s a BillboardGui with a UIListLayout.


Edit:

For some reason the video doesn’t seem to have sound, so I’m not quite sure what’s going on in it.

If you send me the door model I can set it up for you. Basically you create two parts, then a third part (with the door mesh welded to it) that you want to tween between the positions+rotations of the other two parts.

To set a part, select the ObjectValue, look in properties, select the value property (the textbox-like thing), then select the desired part/instance.

Edit:
Looking at the video:

  • You want to tween the position of the hinge, a new part. If you tween the position of the door, it makes it move weirdly between the two parts (it moves the position in a straight line to the goal, while you want the position to move in a circular path)
  • The goal cframe parts should be where you want the hinge part to move to.

Edit 2:
I think I saw you click on your door and the other door moved, this is because you need to select the hinge+target parts in the script that’s inside your door.

2 Likes

Nice!
Thank for answering my question.

2 Likes

TYSM!!! YOU’RE AWESOME!!! this is very helpful thank you! Hopefully I can figure it out lol

1 Like

Hello, I just reviewed the answer you gave me on how I can make a new door and I was confused on what you meant by adding the new parts to a different position and I made a video explaining this and trying it out I reccomend you do watch this for more information on this.

Thank you

1 Like

The door model that I used is here:PBR Proximity Prompt Door - Roblox

1 Like

What I was confused on is what do you mean by adding three parts and having that at a position because On your model I see that ALL of the parts are in one spot. Also, what does rotation of this have to do with this and how do I see which one is facing the right way (the Part). I have all my questions on this UPDATED version of the video:2022 01 12 17 16 04 - YouTube

1 Like

Whoops, I meant a different position+rotation. They have a different rotation. That’s why the hinge part rotates instead of going up like the elevator.

I’d recommend either testing it or welding your door to your hinge part, then duplicating that to get two more, rotating the two doors to where you want them, then removing the extra doors.

I can just set up the door if you’d like.

In a few mins I’ll add video of me setting up a door like yours below:

Edit: Don’t forget (like me) to make those three parts transparent since players don’t need to see them. I also didn’t rotate the SecondPositionPart/FinalPositionPart as much as I should have, which made the door only 70% open. You can just select that part and rotate it more.

Place file:

HGSD Example Door.rbxl (70.7 KB)

General overview:

  • Get the door model
  • Dup the click detector and its script
  • Create the hinge part
  • Create the initial position part (same rotation and position as hinge part initially)
  • Dup the hinge part and move it to where I want the hinge to finish at (just rotate it some amount)
  • Set all three of those parts in the script settings (ObjectValues are a type of instance, like a Part or MeshPart, the names of the three ObjectValues are FirstPositionPart, SecondPositionPart, and MovingPart)
  • Remember to unanchored the door part and to anchor the hinges
  • Set the BillBoardGui’s Adornee to the door part (DoorFrame)

Edit:
Video questions:

  • Where should the three parts be at?

    • The hinge/MovingPart should be at the center of rotation (aka on the axis of rotation). Place it where a normal door hinge would be.
    • Yep! You basically just rotate the FinalPositionPart. The initial position part should probably be at the same CFrame (CFrame is a combination of position and rotation, stands for coordinate frame) as the hinge/MovingPart. The final/second postion part should be at the same position but rotated. Think of where the hinge of a door would be if it was opened vs closed (same position but rotated).
  • Want to have an other frame and decided to set it to CanCollide off:

    • The door opens by directly setting the CFrame, so it doesn’t use physics. This means it doesn’t matter if stuff gets in the way, even if that stuff can collide.
  • What? Where are the ObjectValues:

    • The ObjectValues are just a type of Instance. Instances are things like Parts, MeshParts, PointLights, and Tools. ObjectValues have a finger pointing at a box icon. The three you’re looking for are located inside the InteractableScript’s Folder.
  • Where is the Adornee property?

    • A property is something you can see the Properties window. Stuff like Color, Size, Material, Position, Rotation, and CanCollide. If you look in the properties window you should see the Adornee property. You can also search for it with the search bar of the properties window.

I’m really sorry I made this so messily. There is a lot of naming I should have done more clearly and things I should have made automatic (like setting the BillboardGui’s Adornee).

1 Like

Thank you so much man, I figured this out and this was really helpful you’re definetly a Chad LOL.
also how do I make to where it can close again because the door only opens and when I click on it, the door stays open and I cant close it (I used the Video and Copied EVERYTHING you did so I can learn.)