Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

Only certain people can get through the door script?

Asked by 11 years ago

I can't get this script to work. Is there something that I typed wrong in it?

01local door = script.Parent
02 
03function open() -- This Function will make the door open.
04    door.CanCollide = false -- Makes players able to walk through door.
05 
06    for transparency = 0, 1, .1 do
07        door.Transparency = transparency
08        wait (.1)
09    end
10end
11function close() -- This Function will close the door
12    for transparency = 1, 0, .1 do
13        door.Transparency = transparency
14        wait (.1)
15    end
View all 35 lines...

Guys please help!

0
I found that i the local allow part I had Id as ID but that still didn't fix it. Bangels8 0 — 11y

2 answers

Log in to vote
1
Answered by 11 years ago

Here ya go. This script does both. But only works with T-Shirts not Gamepasses

01print ("VIP T-Shirt Door Script Loaded")
02 
03 
04permission = { "yzeerf1313" } --Put who ever you want to go through the door without the T shirt
05-- TextureId of the VIP shirt.
06texture = "" -- Put the asset of the t shirt here. The whole link
07 
08function checkOkToLetIn(name)
09    for i = 1,#permission do
10 
11 
12 
13        if (string.upper(name) == string.upper(permission[i])) then return true end
14    end
15    return false
View all 45 lines...
0
Just people I want but right now I plan to just be me so thats why I have the "local allow = (game.CreatorId == player.userId)" part in there right now Bangels8 0 — 11y
Ad
Log in to vote
0
Answered by
LevelKap 114
11 years ago

wow that's super complicated above. I recommend making a table

Vip = {"Insertnamehere","ETC","ETC"}

function isPlayerVip(name) for i, v in pairs do if name == v then -- do stuff here like make the door uncancollide or whatever else -- break their joints or whatever you want end end end

Answer this question