E to interact system

I want to make an interaction system like Welcome to Bloxburg

Like if your a certain permission level you can interact with these things in someone’s house, you can also interact with certain things if its for everyone, like getting a motorbike and grabbing a pizza from the pizza planet.

Also if you interact with objects such as cars, fridges, there are more interaction options, I always wondered how to make that.

These interactions work by pressing the keybind E or tapping on mobile or clicking on the object with your mouse and it gives the prompts.

If anyone can give any examples to how I can accomplish this, please comment it, thank you.

Maybe try Proximity Prompts.

1 Like

yeah but how would i make it like have more options when they interact for certain objects?

Hello, use BillboardGui to make gui and UserInputService to work with input.
You can use this code for getting distance between player and the gui to then toggle scripts and gui:

(HumanoidRootPart.Position - Part.Position).Magnitude

HumanoidRootPart is HumanoidRootPart of your character, Part is part with BillboardGui

1 Like

You can look at the code ROBLOX provided in the documentation to how they created the ProximityPrompts, and use that, but also look at @rkdss’s post.

oh so like if they are near this part a UI shows up and it does a couple if statements, then userinputservice to see the object

yeah i was just wondering how to make my own billboardgui instead of using proximityprompt

That’s a bit hard, you need to design it good and code every movement

yeah i think ill go with prompts and use the custom prompt style

I don’t know anything about custom prompt style, so I can’t help here, sorry
Edit: Oh yeah, thanks for reminder @GuySalami

Roblox has a tutorial here.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.