Here is the video of my problem:
I tried cloning the banana bod to the character but it would just spawn on top of the players head.
Here is my script:
local plr = game.Players:GetPlayerFromCharacter(script.Parent)
local infected = script.Parent.Infected;
local character = script.Parent;
local player = game.Players.LocalPlayer;
local Humanoid = script.Parent:FindFirstChild("Humanoid")
plr.TeamColor = game.Teams.Human.TeamColor
function cover(part,x,y,z,mesh)
local Goo = game.Lighting.Goo:Clone()
Goo.Parent = part.Parent
Goo.Size = part.Size
Goo.Color = script.Color.Value
Goo.Mesh.MeshType = Enum.MeshType.FileMesh
Goo.Mesh.MeshId = mesh
Goo.Mesh.Scale = Vector3.new(part.Size.X,0,part.Size.Z)
local weld = Instance.new("Weld",part)
weld.Part0 = part
weld.Part1 = Goo
game:GetService("TweenService"):Create(Goo.Mesh, TweenInfo.new(0.75,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut),
{Scale = Vector3.new(x,y,z),Offset = Vector3.new(0,0,0)}):Play()
Goo.Noise:Play()
end
function HatGive(instance)
for e = 1, #instance, 1 do
plr:LoadCharacterAppearance(instance[e])
end
end
infected.Changed:Connect(function()
Humanoid:LoadAnimation(script.Sleep):Play();
plr.TeamColor = game.Teams.Infected.TeamColor
local old_walkspeed = Humanoid.WalkSpeed;
local old_jump = Humanoid.JumpPower
Humanoid.WalkSpeed = 0;
Humanoid.JumpPower = 0;
--Cover script
cover(script.Parent["Left Arm"],1.05, 1.05, 1.05, "rbxassetid://430080282")
wait(0.667)
cover(script.Parent["Right Arm"],1.05, 1.05, 1.05, "rbxassetid://430080282")
wait(1)
cover(script.Parent["Torso"],2.05, 1.05, 1.05, "rbxassetid://430080282")
wait(2.267)
cover(script.Parent["Left Leg"],1.05, 1.05, 1.05, "rbxassetid://430080282")
wait(1)
cover(script.Parent["Right Leg"],1.05, 1.05, 1.05, "rbxassetid://430080282")
for _, accessory in pairs(script.Parent.Humanoid:GetAccessories()) do
accessory:Destroy();
end
local array_holder = {game.Lighting.BananaBod:Clone(), game.Lighting.MonkeyHat:Clone();}
HatGive(array_holder)
local grab = game.Lighting.Grab;
local copy = grab:Clone()
copy.Parent = game.Players:GetPlayerFromCharacter(script.Parent).Backpack
local trans = game.Lighting.Transfur;
local copy = trans:Clone()
copy.Parent = game.Players:GetPlayerFromCharacter(script.Parent).Backpack
script.Parent.Head.Color = script.Color.Value;
wait(2.5)
script.Revive:Play();
Humanoid.WalkSpeed = old_walkspeed;
Humanoid.JumpPower = old_jump;
end)