Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function Utility.CreateDummy(cframe, name, parent)
- local model = Instance.new("Model")
- model.Archivable = false
- model.Name = name
- local humanoid = Instance.new("Humanoid", model)
- local head = Instance.new("Part", model)
- local face = Instance.new("Decal", head)
- local head_mesh = Instance.new("SpecialMesh", head)
- local torso = Instance.new("Part", model)
- local right_arm = Instance.new("Part", model)
- local left_arm = Instance.new("Part", model)
- local right_leg = Instance.new("Part", model)
- local left_leg = Instance.new("Part", model)
- local neck = Instance.new("Motor", torso)
- local right_shoulder = Instance.new("Motor", torso)
- local left_shoulder = Instance.new("Motor", torso)
- local right_hip = Instance.new("Motor", torso)
- local left_hip = Instance.new("Motor", torso)
- head.BrickColor = BrickColor.Yellow()
- head.CFrame = cframe * CFrame.new(0, 1.5, 0)
- head.FormFactor = "Symmetric"
- head.Locked = true
- head.Name = "Head"
- head.Size = Vector3.new(2, 1, 1)
- head.TopSurface = "Smooth"
- face.Texture = "rbxasset://textures/face.png"
- head_mesh.Scale = Vector3.new(1.25, 1.25, 1.25)
- torso.BrickColor = BrickColor.Blue()
- torso.CFrame = cframe
- torso.FormFactor = "Symmetric"
- torso.LeftSurface = "Weld"
- torso.Locked = true
- torso.RightSurface = "Weld"
- torso.Name = "Torso"
- torso.Size = Vector3.new(2, 2, 1)
- right_arm.BrickColor = BrickColor.Yellow()
- right_arm.CanCollide = false
- right_arm.CFrame = cframe * CFrame.new(1.5, 0, 0)
- right_arm.FormFactor = "Symmetric"
- right_arm.Locked = true
- right_arm.Name = "Right Arm"
- right_arm.Size = Vector3.new(1, 2, 1)
- left_arm.BrickColor = BrickColor.Yellow()
- left_arm.CanCollide = false
- left_arm.CFrame = cframe * CFrame.new(-1.5, 0, 0)
- left_arm.FormFactor = "Symmetric"
- left_arm.Locked = true
- left_arm.Name = "Left Arm"
- left_arm.Size = Vector3.new(1, 2, 1)
- right_leg.BrickColor = BrickColor.new("Br. yellowish green")
- right_leg.BottomSurface = "Smooth"
- right_leg.CanCollide = false
- right_leg.CFrame = cframe * CFrame.new(0.5, -2, 0)
- right_leg.FormFactor = "Symmetric"
- right_leg.Locked = true
- right_leg.Name = "Right Leg"
- right_leg.Size = Vector3.new(1, 2, 1)
- right_leg.TopSurface = "Smooth"
- left_leg.BrickColor = BrickColor.new("Br. yellowish green")
- left_leg.BottomSurface = "Smooth"
- left_leg.CanCollide = false
- left_leg.CFrame = cframe * CFrame.new(-0.5, -2, 0)
- left_leg.FormFactor = "Symmetric"
- left_leg.Locked = true
- left_leg.Name = "Left Leg"
- left_leg.Size = Vector3.new(1, 2, 1)
- left_leg.TopSurface = "Smooth"
- neck.C0 = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- neck.C1 = CFrame.new(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- neck.Name = "Neck"
- neck.Part0 = torso
- neck.Part1 = head
- right_shoulder.C0 = CFrame.new(1, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
- right_shoulder.C1 = CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
- right_shoulder.MaxVelocity = 0.15
- right_shoulder.Name = "Right Shoulder"
- right_shoulder.Part0 = torso
- right_shoulder.Part1 = right_arm
- left_shoulder.C0 = CFrame.new(-1, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
- left_shoulder.C1 = CFrame.new(0.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
- left_shoulder.MaxVelocity = 0.15
- left_shoulder.Name = "Left Shoulder"
- left_shoulder.Part0 = torso
- left_shoulder.Part1 = left_arm
- right_hip.C0 = CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
- right_hip.C1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
- right_hip.MaxVelocity = 0.1
- right_hip.Name = "Right Hip"
- right_hip.Part0 = torso
- right_hip.Part1 = right_leg
- left_hip.C0 = CFrame.new(-1, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
- left_hip.C1 = CFrame.new(-0.5, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
- left_hip.MaxVelocity = 0.1
- left_hip.Name = "Left Hip"
- left_hip.Part0 = torso
- left_hip.Part1 = left_leg
- humanoid.Died:connect(function()
- wait(5)
- model:Destroy()
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement