wait() if script.Parent then if not script.Parent:IsA("Script") or not script.Parent.Name == "StarterGear" then local debris = game:GetService("Debris") local backpack = script.Parent local player = backpack.Parent while player.Character == nil do wait() end local character = player.Character if character then while character:FindFirstChild("Humanoid") == nil do wait() end local hum = character:FindFirstChild("Humanoid")
-- Logia local charparts = character:GetChildren() for i = 1, #charparts do local charpart = charparts[i] if charpart:IsA("BasePart") then charpart.Touched:connect(function(hit) if charpart:FindFirstChild("Hide") then return end local stop = true if hit ~= nil then if hit.Parent ~= nil then if hit:FindFirstChild("creator") or hit.Parent:FindFirstChild("creator") then stop = false elseif hit.Parent:FindFirstChild("Humanoid") then if hit.Parent:FindFirstChild("Humanoid") ~= hum then stop = false end
So I have a script where if you touch a part of a ROBLOXian, it changes colors and materials, but I can't seem to resize it specifically for a torso or head without messing up other parts. Help? end end end if stop then return end local hidemesh = Instance.new("SpecialMesh") hidemesh.Name = "Hide" hidemesh.MeshType = "FileMesh" hidemesh.MeshId = "" hidemesh.Scale = Vector3.new(0, 0, 0) hidemesh.Parent = charpart debris:AddItem(hidemesh, 1.5)
local bodyeffect = Instance.new("Part") bodyeffect.Name = "BodyEffect" bodyeffect.Transparency = 0 bodyeffect.BrickColor = BrickColor.new("Really red") bodyeffect.CanCollide = true bodyeffect.FormFactor = "Custom" bodyeffect.Size = Vector3.new(1, 2, 1) bodyeffect.TopSurface = "Smooth" bodyeffect.BottomSurface = "Smooth" bodyeffect.CFrame = charpart.CFrame bodyeffect.Material = "Granite" bodyeffect.Parent = charpart.Parent local weld = Instance.new("ManualWeld") weld.Part0 = bodyeffect weld.Part1 = charpart weld.C1 = charpart.CFrame:inverse() * bodyeffect.CFrame weld.Parent = bodyeffect debris:AddItem(bodyeffect, 1.5) end) end
end end end end