Advertisement
scriptplacerbx

2D_script roblox script

Oct 10th, 2022
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.64 KB | None | 0 0
  1. for _, plr in pairs(game.Players:GetChildren()) do -- Gets the players and sets them to plr
  2.         for _, obj in pairs(plr.Character:GetChildren()) do -- Gets everyone's character and sets anything in their character to obj
  3.                 if (obj.Name == "Head") then -- If the name of the thing in the character is = to "Head" then that now only stands for obj
  4.                 obj.Mesh.MeshType = "Brick" -- Changes the mesh inside of the Head to a brick mesh
  5.                 obj.Mesh.Scale = Vector3.new(1, 1, .01); -- Changes the scale (size) of the mesh to 1, 1, .01
  6.                 obj.Mesh:Clone().Parent = plr.Character["Torso"]; -- Clones the mesh to the players torso
  7.                 obj.Mesh:Clone().Parent = plr.Character["Left Arm"]; -- Clones the mesh to the players left arm
  8.                 obj.Mesh:Clone().Parent = plr.Character["Right Arm"]; -- Clones the mesh to the players right arm
  9.                 obj.Mesh:Clone().Parent = plr.Character["Left Leg"]; -- Clones the mesh to the players left leg
  10.                 obj.Mesh:Clone().Parent = plr.Character["Right Leg"]; -- Clones the mesh to the players right leg
  11.                 obj.Mesh:Clone().Parent = plr.Character["Head"]; -- Clones the mesh to the players head
  12.                         for _, plra in pairs(game.Players:GetChildren()) do -- Sets all the players to plra
  13.                                 for _, obja in pairs(plra.Character:GetChildren()) do -- Gets everyone's character and sets anything in their character to obja
  14.                                         if (obja:IsA("Hat")) then -- If the name of the thing in the character is a "Hat" then that now only stands for obja
  15.                                                 for _, objas in pairs(obja:GetChildren()) do -- Gets anything in the player(s) hat(s) and sets them to objas
  16.                                                 objas.Mesh.Scale = Vector3.new(1, 1, .01) -- Changes the scale of the mesh in the hat to 1, 1, .01
  17.                                                 end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  18.                                         end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  19.                                 end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  20.                         end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  21.                 end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  22.         end  -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
  23. end -- All "end"(s) end the parrelel blue highlighted word such as "for" or "if"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement