Proximity Prompt's aren't triggering

You can write your topic however you want, but you need to answer these questions:
I want my local function to run when I press the button, although the script isn’t receiving the buttons “signal”
I’ve looked through the script but haven’t found any issues so far.

After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!

	local tweenService = game:GetService("TweenService")
	local isOpen = script.Parent.Parent.Parent.IsOpen.Value
	local debounce = false
	local configFolder = script.Parent.Parent.Parent.Config
	local doorSpeed = configFolder.DoorSpeed.Value
	--PARTS
	local doorM = script.Parent.Parent.Parent.MainM.Position
	local doorMPart = script.Parent.Parent.Parent.MainM
	local doorF = script.Parent.Parent.Parent.MainF.Position
	local doorFPart = script.Parent.Parent.Parent.MainF
	local lightPart = script.Parent.Parent.Parent.Light.Light
	local event = script.Parent.Parent.Parent.Secondary
	local button1 = script.Parent.Button1.ProximityPrompt
	local button2 = script.Parent.Button2.ProximityPrompt
	--{PARTS}
	
	local info1 = TweenInfo.new(
		doorSpeed,
 		Enum.EasingStyle.Linear,
		Enum.EasingDirection.Out,
		0,
		false,
		0
)
local info2 = TweenInfo.new(
	doorSpeed,
	Enum.EasingStyle.Linear,
	Enum.EasingDirection.In,
	0,
	false,
	0
)

	local tweenM1 = tweenService:Create(doorMPart, info1, {Position = doorMPart.Position + Vector3.new(14, 0, 0)})
	local tweenF1 = tweenService:Create(doorFPart, info1, {Position = doorFPart.Position - Vector3.new(14, 0, 0)})
	local tweenM2 = tweenService:Create(doorMPart, info2, {Position = doorMPart.Position - Vector3.new(0, 0, 0)})
	local tweenF2 = tweenService:Create(doorFPart, info2, {Position = doorFPart.Position + Vector3.new(0, 0, 0)})

local function openDoor()
	print("Recieved")
	if not isOpen and not debounce then
		if configFolder.DoorSoundsActive and not debounce then
			configFolder.DoorAlarm:Play()
			configFolder.DoorMove:Play()
			configFolder.DoorLockSound:Play()
		end
		lightPart.Material = Enum.Material.Neon
		lightPart.PointLight.Enabled = true
		wait(1)
		isOpen = true
		tweenM1:Play()
		tweenF1:Play()
		debounce = true
		wait(doorSpeed)
		debounce = false
		configFolder.DoorMove:stop()
		configFolder.DoorLockSound:Play()
		wait(1)
		configFolder.DoorAlarm:stop()
		lightPart.Material = Enum.Material.Glass
		lightPart.PointLight.Enabled = false
	elseif isOpen and not debounce then
		if configFolder.DoorSoundsActive and not debounce then
			configFolder.DoorAlarm:Play()
			configFolder.DoorMove:Play()
			configFolder.DoorLockSound:Play()
		end
		lightPart.Material = Enum.Material.Neon
		lightPart.PointLight.Enabled = true
		wait(1)
		isOpen = false
		tweenM2:Play()
		tweenF2:Play()
		debounce = true
		wait(doorSpeed)
		debounce = false
		configFolder.DoorMove:stop()
		configFolder.DoorLockSound:Play()
		wait(1.5)
		configFolder.DoorAlarm:stop()
		lightPart.Material = Enum.Material.Glass
		lightPart.PointLight.Enabled = false
	end
end



button1.Triggered:Connect(function()
	print("Triggered")
	openDoor()
end)

button2.Triggered:Connect(function()
	print("Triggered")
	openDoor()
end)

The part that seemingly isn’t working is the bottom, "button1.Triggered:Connect(function() and the button2 one.

Could you send a screenshot of where the script is located?

image

It’s just located in this model, and in a server script…

try checking if the problem is the proximityprompt or your function

button2.Triggered:Connect(function()
	print("Triggered")
end)

if it prints “Triggered” that means the problem is probably in your function