I've asked this question twice, I got 2 different answers, Yes and No. Is there something wrong in my script?
permission = {"fahmisack123","A380Guy","ismailtheboss","chrysalisever","backflip123456","HeroFrancis30","HeroicFabian"} texture = "www.roblox.com/Gem-Tycoon-VIP-Admin-shirt-item?id=129892951" function checkOkToLetIn(name) for i = 1,#permission do if (string.upper(name) == string.upper(permission[i])) then return true end end return false end local Door = script.Parent function onTouched(hit) print("Door Hit") local human = hit.Parent:findFirstChild("Humanoid") if (human ~= nil ) then if human.Parent.Torso.roblox.Texture == texture or human.leaderstats.Admins >= 1 then -- I also need help in this line --CONTENT CENSORED elseif (checkOkToLetIn(human.Parent.Name)) then --CONTENT CENSORED wait(3) Door.CanCollide = true Door.Transparency = 0 end end end script.Parent.Touched:connect(onTouched)
EXTRA QUESTION Does Roblox Lua use BIDMAS/BODMAS because then I wouldn't get confused if I calculate 1+1*47+3 which is 51 using BIDMAS/BODMAS
permission = {"fahmisack123","A380Guy","ismailtheboss","chrysalisever","backflip123456","HeroFrancis30","HeroicFabian"} texture = "www.roblox.com/Gem-Tycoon-VIP-Admin-shirt-item?id=129892951" function checkOkToLetIn(name) for i = 1,#permission do if (string.upper(name) == string.upper(permission[i])) then return true end end return false end local Door = script.Parent function onTouched(hit) print("Door Hit") local human = hit.Parent:findFirstChild("Humanoid") if human ~= nil then --Removed Parentheses if human.Parent.Torso.roblox.Texture == texture or human.leaderstats.Admins > 1 then -- Changed from >= to > elseif checkOkToLetIn(human.Parent.Name) then --Removed Parentheses Door.CanCollide = false wait(3) Door.CanCollide = true Door.Transparency = 0 end end end script.Parent.Touched:connect(onTouched)