so i have some code to run a function named seatCheck()
and I was wondering if it was possible to condense it?
so here’s my code:
seat1:GetPropertyChangedSignal("Occupant"):Connect(function()
if seat1.Occupant then
seatCheck()
else
seatCheck()
end
end)
seat2:GetPropertyChangedSignal("Occupant"):Connect(function()
if seat2.Occupant then
seatCheck()
else
seatCheck()
end
end)
but i kinda want it to be like (pseudocode):
seat1:GPCS("Occupant"):Connect(function()...) or seat2:GPCS("Occupant"):Connect(function()...)
Also I have been suggested:
seat1:GetPropertyChangedSignal("Occupant"):Connect(seatCheck)
seat2:GetPropertyChangedSignal("Occupant"):Connect(seatCheck)
however this didn’t activate