I want my door to accept variety of tools (ex. L1, L2, L3) whether it resides in their backpack or their character.
I tried this,
function open(player)
local card = player.Backpack:FindFirstChild(acceptedCards) or player.Character:FindFirstChild(acceptedCards)
local other = player.Backpack:FindFirstChild(otherCards) or player.Character:FindFirstChild(otherCards)
if card then
(opens)
elseif other then
(opens but in different way so it's important)
else
(denied)
end
end
end
but that only worked when acceptedCards was only one item when I want it to be multiple items which is the problem. Please help and thank you!

5 comments
Sorry what I want is for the door to accept one of the acceptedCards which is supposed to be a list of names that can be accepted. The problem is the script I have right now only works if acceptedCards or otherCards is equal to one name. I want it to work if acceptedCards is a list or multiple names
i edited my answer
Thank you I'll try this!
Yeah I'm either doing it wrong or it doesn't work
how does the acceptedCards list look?