local I={}local T=12 local N=false local l=script.Parent.Parent.Water local x=script.Parent.Parent.ToiletBowl.Sound x:Play()wait(.65)for I,T in pairs(script.Parent.Parent:GetChildren())do if T.Name=="\087\097\116\101\114\083\119\105\114\108"then T.ParticleEmitter.Transparency=NumberSequence.new(.9)T.ParticleEmitter.Rate=40 end end for I=1,4,1 do l.CFrame=l.CFrame*CFrame.new(0,.01,0)wait()end for I=1,22,1 do l.Mesh.Scale=l.Mesh.Scale+Vector3.new(-0.02,0,-0.02)l.CFrame=l.CFrame*CFrame.new(0,-0.015,0)wait()end if script.Parent.Parent.ToiletUsed.Value==true then l.BrickColor=BrickColor.new("\080\097\115\116\101\108 \121\101\108\108\111\119")end wait(1.55)for I=1,10,1 do for T,N in pairs(script.Parent.Parent:GetChildren())do if N.Name=="\087\097\116\101\114\083\119\105\114\108"then N.ParticleEmitter.Transparency=NumberSequence.new(.9+.015*I)if I==10 then N.ParticleEmitter.Rate=0 end end end wait(.2)end script.Parent.Parent.ToiletUsed.Value=false l.BrickColor=BrickColor.new("\070\111\103")for I=1,66,1 do l.Mesh.Scale=l.Mesh.Scale+Vector3.new(.0066,0,.0066)l.CFrame=l.CFrame*CFrame.new(0,.00409,0)wait()end l.CFrame=script.Parent.Parent.WaterResetPos.CFrame l.Mesh.Scale=Vector3.new(1,0,1)N=false script.Disabled=true
--local ClickerModule = require(343254562)
--local clickEvent = ClickerModule.RemoteEvent
local interactiveParts = {}
local activationDistance = 12
local flushing = false
local water = script.Parent.Parent.Water
local sound = script.Parent.Parent.ToiletBowl.Sound
sound:Play()
wait(0.65)

for i, v in pairs(script.Parent.Parent:GetChildren()) do
	if v.Name == "WaterSwirl" then
		v.ParticleEmitter.Transparency = NumberSequence.new(0.9)
		v.ParticleEmitter.Rate = 40
	end
end

for i = 1, 4 do
	water.CFrame = water.CFrame * CFrame.new(0, 0.01, 0)
	wait()
end
for i = 1, 22 do
	water.Mesh.Scale = water.Mesh.Scale + Vector3.new(-0.02, 0, -0.02)
	water.CFrame = water.CFrame * CFrame.new(0, -0.015, 0)
	wait()
end

if script.Parent.Parent.ToiletUsed.Value == true then
	water.BrickColor = BrickColor.new("Pastel yellow")
end

wait(1.55)

for i = 1, 10 do
	for ii, v in pairs(script.Parent.Parent:GetChildren()) do
		if v.Name == "WaterSwirl" then
			v.ParticleEmitter.Transparency = NumberSequence.new(0.9 + (0.015 * i))
			if i == 10 then
				v.ParticleEmitter.Rate = 0
			end
		end
	end
	wait(0.2)
end

script.Parent.Parent.ToiletUsed.Value = false
water.BrickColor = BrickColor.new("Fog")

for i = 1, 66 do
	water.Mesh.Scale = water.Mesh.Scale + Vector3.new(0.0066, 0, 0.0066)
	water.CFrame = water.CFrame * CFrame.new(0, 0.00409, 0)
	wait()
end
water.CFrame = script.Parent.Parent.WaterResetPos.CFrame
water.Mesh.Scale = Vector3.new(1, 0, 1)
flushing = false
script.Disabled = true
