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

How do I get a model to disappear and reappear using scripts?

Asked by 10 years ago

How do I get a model to disappear and reappear using scripts? I've been to training centers and I've seen people say "load/obby1" or "end/obby1." I was just wondering how you would script that.

2 answers

Log in to vote
3
Answered by
Tuneable 100
10 years ago

If I were you I wouldn't choose making everything in the model transparent and can collide false. Reparenting would be the best option in my opinion.

Example

local Maps = game.ServerStorage.Maps

local function HideMap(MapName)
    if Workspace:FindFirstChild(MapName) then
        Workspace[MapName].Parent = Maps
    end
end

local function LoadMap(MapName)
    if Workspace:FindFirstChild(MapName) == nil then
        Maps[MapName].Parent = Workspace
    end
end
Ad
Log in to vote
-1
Answered by 10 years ago

run a loop to get all the things inside a model for each small increment and get all the parts and lower the transparency, im not making the script for u, but telling u how to do it

Answer this question