Advertisement
SlyHades66

R15 No Collision

May 7th, 2017
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.66 KB | None | 0 0
  1. local function Ghostify(model)
  2.     for _, v in pairs(model:GetChildren()) do
  3.         if (v:FindFirstChild("Humanoid") or v.Name == "ParkGuest") then
  4.             v:Destroy();
  5.         else
  6.             Ghostify(v);
  7.             if (v:IsA("BasePart")) then
  8.                 v.Transparency = (1 - (1 - v.Transparency) / 2);
  9.                 v.BrickColor = BrickColor.new("Institutional white");
  10.                 v.Material = Enum.Material.SmoothPlastic;
  11.                 v.CanCollide = false;
  12.                 if (v:IsA("UnionOperation")) then
  13.                     v.UsePartColor = true;
  14.                 end
  15.             elseif (v:IsA("Decal")) then
  16.                 v.Transparency = (1 - (1 - v.Transparency) / 2);
  17.             elseif (v:IsA("SpecialMesh")) then
  18.                 v.TextureId = "";
  19.             end
  20.         end
  21.     end
  22. end
  23.  
  24. return Ghostify;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement