#Scripting help please

1 messages · Page 1 of 1 (latest)

vivid wren
#

hi im working on a closet where you can hide everything is working but theres a problem with exiting the closet.
when holding "e" on the exit prompt the player never exits the closet the exit animation never runs, camera doesn't switch back, and the player stays stuck inside

dim rune
#

send script bruh

vivid wren
#

one sec

#

i cant send in the same moment

#

the problem is because before i made it so you could leave the closet with wasd

inner iceBOT
#

studio** You are now Level 3! **studio

vivid wren
#

but you cant play on the phone

#

then i wanted to change it to a proximity promot

#

and it wont work

dim rune
#

may be this line failed silently if not player:FindFirstChild("Hiding") or closet:GetAttribute("Occupied") then return end

vivid wren
#

thats so 2 people cant go inside at the same time i dont know what to do about it

dim rune
#

don't add return end replace return edd with

if _ then
    error(_)
end
lethal halo
#

i smell chatgpt

vivid wren
#

it is

#

so what

#

i cant do it by myself 😦

#

nah it didnt fix it

#

idk what to do

#

i gave up like a week ago but i really want it to work now

#

idk if its a problem in the server script or closet

#

when you enter its

if closet:IsA("Model") and closet:FindFirstChild("PromptPart") then
local prompt = closet.PromptPart:FindFirstChild("Prompt")

#

and when you leave its just

local exitPrompt = closet:FindFirstChild("ExitPrompt"):FindFirstChild("PromptExit")

#

maybe i should change it to be the same

#

or it doesent matter

#

omgg why doesent it workk

dim rune
#

learn how to debugging duh

vivid wren
#

how bro

fading patio
#

by printing

vivid wren
#

ah ok

#

i will

fading patio
#

find out where and why the code aint working

vivid wren
#

you know?

hoary elk
#

What did you thought ?