Im trying to make a script where lets say if the torso of a player reaches a certain size, i.e. 10, then the torso explodes.
if Torso.Size >= Torso.Size + Vector3.new(10,10,10) then
local explosion = Instance.new("Explosion",Torso)
end
Torso.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
if touchingTorso == false then
print(hit.Parent)
if hit.Parent:FindFirstChild("Torso") then
print(hit.Parent:FindFirstChild("Torso"))
Torso.Size = Torso.Size + Vector3.new(.1,.1,.1)
touchingTorso = true
end
end
end
end)
Torso.TouchEnded:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
if touchingTorso == true then
if hit.Parent:FindFirstChild("Torso") then
touchingTorso = false
end
end
end
end)
this is all i have and all of my attempts of doing this on my own have failed, can anyone help me?

1 comment
Thanks this genuinly helped alot!