local l={ping={Function=function(l,g)local c=tick()local N=main.signals.GetPing:InvokeServer(math.random(1,1000))local I=tick()-c local Y=I/2 local o=Y*1000 local h=1000 local m=math.floor(o*h+.5)/h;(main:GetModule("\078\111\116\105\099\101\115")):Notice("\078\111\116\105\099\101",main.hdAdminCoreName,"\089\111\117\114 \112\105\110\103 \105\115 "..(m.."\033"))end},blur={Function=function(l,g)main.blur.Size=g[2]~=0 and g[2]or 20 end;UnFunction=function(l,g)main.blur.Size=0 end};showGuis={Function=function(l,g)for l,g in pairs(hiddenGuis)do l.Enabled=true end hiddenGuis={}end};hideGuis={Function=function(l,g)for l,g in pairs(main.playerGui:GetChildren())do if g:IsA("\083\099\114\101\101\110\071\117\105")and(g.Name~="\067\104\097\116"and g.Name~="\072\068\065\100\109\105\110\071\085\073\115")then if g.Enabled==true then hiddenGuis[g]=true end g.Enabled=false end end end},view={Function=function(l,g)local c=g[1]local N=(main:GetModule("\099\102")):GetHumanoid(c)if N then(main:GetModule("\099\102")):SetCameraSubject(N)end end;UnFunction=function(l,g)local c=(main:GetModule("\099\102")):GetHumanoid(l)if c then main.signals.SetCameraSubject:FireClient(l,c)end end},nightVision={Function=function(l,g)for l,g in pairs(main.players:GetChildren())do local c=(main:GetModule("\099\102")):GetHead(g)if g.Name~=main.player.Name and c then for l,g in pairs(g.Character:GetChildren())do if g:IsA("\066\097\115\101\080\097\114\116")and g:FindFirstChild("\072\068\078\105\103\104\116\086\105\115\105\111\110")==nil then for l=1,6,1 do local c=main.client.Assets.NightVision:Clone()c.Parent=g c.Face=l-1 c.Name="\072\068\065\100\109\105\110\078\105\103\104\116\086\105\115\105\111\110"end end end local l=main.client.Assets.Nickname:Clone()l.TextLabel.Text=g.Name l.Parent=c l.Name="\072\068\065\100\109\105\110\078\105\103\104\116\086\105\115\105\111\110"end end end,UnFunction=function(l,g)for l,g in pairs(main.players:GetChildren())do if g.Character then for l,g in pairs(g.Character:GetDescendants())do if g.Name=="\072\068\065\100\109\105\110\078\105\103\104\116\086\105\115\105\111\110"then g:Destroy()end end end end end};cmdbar={Function=function(l,g)(main:GetModule("\067\109\100\066\097\114")):OpenCmdBar()end},cmdbar2={Function=function(l,g)(main:GetModule("\099\102")):CreateNewCommandMenu("\099\109\100\098\097\114\050",{},2)end};rainbowFart={Function=function(l,g)local c=g[1]local N=20 local I={174658105;148635119}local function Y(l,g)local c=Instance.new("\083\111\117\110\100",g)c.SoundId="\114\098\120\097\115\115\101\116\105\100\058\047\047"..l c.Volume=.5 c:Play()local N=c.IsPlaying or c.Played:Wait()wait()end local function o(l,g,c,I,o)local h=main.client.Assets.Poop:Clone()Y(c,h)h.CanCollide=false local m=N local K=1/m local U=(I-1)*K local r=Color3.fromHSV(U,.7,.7)h.Color=r h.CFrame=g.Seat.CFrame*CFrame.new(0,I*1-.5,0)l:SetPrimaryPartCFrame(h.CFrame*CFrame.new(0,3,0))h.Parent=o end local h=(main:GetModule("\099\102")):GetHead(c)if not h then return end local m=h.CFrame c.Character.Parent=nil local K,U=(main:GetModule("\099\102")):CreateClone(c.Character)if U.sit.Length<=0 then repeat wait()until U.sit.Length>0 end K.Head.CFrame=m if c==main.player then(main:GetModule("\099\102")):Movement(false);(main:GetModule("\099\102")):SetCameraSubject(K.Humanoid)end local r=0 local M=Instance.new("\077\111\100\101\108",workspace)local R=main.client.Assets.Toilet:Clone()M.Name=c.Name.."\'\115 \112\111\111\112"R.PrimaryPart=R.Seat R:SetPrimaryPartCFrame(K.HumanoidRootPart.CFrame*CFrame.new(0,-1,0))R.Parent=workspace R.Seat:Sit(K.Humanoid)U.sit:Play(0)K.Head.face.Texture="\114\098\120\097\115\115\101\116\105\100\058\047\047\051\048\052\057\048\055\049\048\056"wait()K.PrimaryPart=K.Head K:SetPrimaryPartCFrame(R.PrimaryPart.CFrame*CFrame.new(0,3,0))for l,g in pairs(K:GetChildren())do if g:IsA("\066\097\115\101\080\097\114\116")and g.Name~="\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116"then g.Anchored=true end end wait(1)Y(174658105,K.HumanoidRootPart)wait(2)r=r+1 o(K,R,148635119,r,M,M)K.Head.face.Texture="\114\098\120\097\115\115\101\116\105\100\058\047\047\051\051\056\051\049\050\049\052\057"wait(1.5)K.Head.face.Texture="\114\098\120\097\115\115\101\116\105\100\058\047\047\051\049\054\053\052\053\055\049\049"for l=1,N,1 do if l==N-2 then for l,g in pairs(K:GetChildren())do if g:IsA("\066\097\115\101\080\097\114\116")and g.Name~="\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116"then g.Anchored=false end end local l=Instance.new("\069\120\112\108\111\115\105\111\110")l.Position=K.Head.Position l.Parent=K l.DestroyJointRadiusPercent=0 K:BreakJoints()elseif l>N-1 then for l,g in pairs(M:GetChildren())do g.Anchored=false g.CanCollide=true end end r=r+1 if l>=N then wait(1.5)else o(K,R,I[math.random(1,#I)],r,M)wait()end end wait(3)M:Destroy()R:Destroy()K:Destroy()if c==main.player then local l=(main:GetModule("\099\102")):GetHumanoid(c)if l then(main:GetModule("\099\102")):Movement(true);(main:GetModule("\099\102")):SetCameraSubject(l)end end c.Character.Parent=workspace end};icecream={Function=function(l,g)local c=g[1]c.Character.Parent=nil local N,I=(main:GetModule("\099\102")):CreateClone(c.Character)local Y=N:FindFirstChild("\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116")if Y==nil then N:Destroy()return end Y.Anchored=true local o=main.client.Assets.IcecreamVan:Clone()o.PrimaryPart=o.VanDoor.Part1 o:SetPrimaryPartCFrame((Y.CFrame*CFrame.new(-210,3,-4))*CFrame.Angles(0,math.rad(90),0))o.Parent=workspace if c==main.player then(main:GetModule("\099\102")):Movement(false);(main:GetModule("\099\102")):SetCameraSubject(N.Humanoid)for l,g in pairs(o:GetDescendants())do if g:IsA("\066\097\115\101\080\097\114\116")then g.CanCollide=true end end end local h=(main:GetModule("\099\102")):CreateSound({SoundId=260910474;Volume=.5;Parent=o.PrimaryPart})local m=(main:GetModule("\099\102")):CreateSound({SoundId=861942173,Volume=4,Parent=o.PrimaryPart})local K=(main:GetModule("\099\102")):CreateSound({SoundId=2628538600,Volume=.15;Parent=o.PrimaryPart})local U=(main:GetModule("\099\102")):CreateSound({SoundId=147758746,Volume=.8,Parent=o.PrimaryPart})h:Play();(main:GetModule("\099\102")):TweenModel(o,o.PrimaryPart.CFrame*CFrame.new(0,0,210),TweenInfo.new(8))wait(8.1)local r=main.tweenService:Create(h,TweenInfo.new(.5),{Volume=0})r:Play()r.Completed:Wait()h:Stop()h:Destroy()wait(1)o.VanDoor.Part1.Transparency=1 o.VanDoor.Part2.Transparency=1 wait(1)N.PrimaryPart=N.Head N:SetPrimaryPartCFrame((o.Clown.Head.CFrame*CFrame.new(0,0,-2.5))*CFrame.Angles(0,math.rad(180),0))local M=c.CameraMinZoomDistance local R=c.CameraMaxZoomDistance if c==main.player then c.CameraMaxZoomDistance=.5 spawn(function()c.CameraMaxZoomDistance=1 end)end local z=N.Head:FindFirstChild("\102\097\099\101")if z then z.Texture="\114\098\120\097\115\115\101\116\105\100\058\047\047\051\051\056\051\049\050\049\052\057"end m:Play()wait(1)o.VanDoor.Part1.Transparency=0 o.VanDoor.Part2.Transparency=0 N.Parent=o for l,g in pairs(N:GetChildren())do if g:IsA("\065\099\099\101\115\115\111\114\121")then g:remove()end end h:Play();(main:GetModule("\099\102")):TweenModel(o,o.PrimaryPart.CFrame*CFrame.new(0,0,400),TweenInfo.new(14,Enum.EasingStyle.Quad,Enum.EasingDirection.In))wait(4)local G=o.Clown["\082\105\103\104\116 \065\114\109"]G.CFrame=G.CFrame*CFrame.fromEulerAnglesXYZ(math.rad(45),0,0)for l,g in pairs(o.Doll:GetChildren())do g.Transparency=0 end o.Doll.Head.face.Transparency=0 wait(.1)K:Play()wait(1.5)U:Play()if z then z.Texture="\114\098\120\097\115\115\101\116\105\100\058\047\047\050\056\056\057\049\056\050\051\054"end wait(2.5)if c==main.player then local l=Instance.new("\069\120\112\108\111\115\105\111\110")l.Position=N.Head.Position l.Parent=N N:BreakJoints()main.audio.Oof:Play()end wait(5)if c==main.player then local l=(main:GetModule("\099\102")):GetHumanoid(c)if l then(main:GetModule("\099\102")):Movement(true);(main:GetModule("\099\102")):SetCameraSubject(l)end c.CameraMaxZoomDistance=20 wait()c.CameraMinZoomDistance=20 wait()c.CameraMinZoomDistance=M c.CameraMaxZoomDistance=R end if c.Character then c.Character.Parent=workspace end o:Destroy()end},laserEyes={DisplayLaser=function(l,g,c)local N=g:FindFirstChild("\076\101\102\116\066\101\097\109")if N then N.Enabled=c g.RightBeam.Enabled=c g.MidAttachment.GlowHit.Enabled=c end end,Activate=function(l)local g=l.Name local c=(main:GetModule("\099\102")):GetHead()local N=(main:GetModule("\099\102")):GetHumanoid()local I=(main:GetModule("\099\102")):GetHRP()if c and(N and main.mouseDown)then local Y=c:FindFirstChild("\072\068\065\100\109\105\110\076\097\115\101\114\072\101\097\100")local o=(main:GetModule("\099\102")):GetNeck()local h=false if N.RigType==Enum.HumanoidRigType.R6 then h=true end c.Parent.PrimaryPart=I if Y and o then local I=30 local m=tick()-1 local K=o.C0 local U=N.HipHeight/2.5 local r=Y.LaserTarget local M=r.MidAttachment2.Fire local R=r.MidAttachment.Sparks local z=main.audio.Sizzle local G=main.audio.Sizzle2 z:Play()l.DisplayLaser(Y,r,true)repeat local N,Y=(main:GetModule("\099\102")):GetMousePoint(main.lastHitPosition)local K=CFrame.new(Y,c.Position)local z=main.player:DistanceFromCharacter(K.p)local Q=false if z>I then K=K*CFrame.new(0,0,I-z)Q=true end r.CFrame=K local f=c.Position local e=r.Position local P=(Vector3.new(e.X,f.Y,e.Z)-c.Position).Unit if c.Parent.PrimaryPart==nil then c.Parent.PrimaryPart=c.parent.HumanoidRootPart end local X=CFrame.new(Vector3.new(),c.Parent.PrimaryPart.CFrame:VectorToObjectSpace(P))if h then X=(X*CFrame.new(0,1,0))*CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(180),0)else X=X*CFrame.new(0,U,0)end o.C0=X if tick()-.6>m then m=tick();(main:GetModule("\099\102")):ReplicateEffect(l.Name,{K;X})end if N and(not Q and(N.Parent:FindFirstChild("\072\117\109\097\110\111\105\100")or N.Name=="\072\097\110\100\108\101"))then M.Enabled=true R.Enabled=true if not G.Playing then G:Play()end else M.Enabled=false R.Enabled=false if G.Playing then G:Stop()end end wait()until not main.mouseDown or not main.commandsActive[g]or not c or not c.Parent or not o o.C0=K l.DisplayLaser(Y,r,false)M.Enabled=false R.Enabled=false z:Stop()G:Stop()end end main.commandsActive[g]=nil end,ReplicationEffect=function(l,g,c)local N,I=g[1],g[2]local Y=l local o=(main:GetModule("\099\102")):GetHead(Y)if o then local l=o:FindFirstChild("\072\068\065\100\109\105\110\076\097\115\101\114\072\101\097\100")local g=(main:GetModule("\099\102")):GetNeck(Y)if l and g then local o=l.LaserTarget if lasersActive[Y]then lasersActive[Y]=lasersActive[Y]+1 else lasersActive[Y]=1 originalNecks[Y]=g.C0 local h=math.random(10,40)-15 o.CFrame=N*CFrame.new(0,0,h)g.C0=I o.MidAttachment.GlowHit.Rate=50 c.DisplayLaser(l,o,true)end;(main.tweenService:Create(o,laserTweenInfo,{CFrame=N})):Play();(main.tweenService:Create(g,laserTweenInfo,{C0=I})):Play()wait(laserTweenTime)lasersActive[Y]=lasersActive[Y]-1 if lasersActive[Y]<=0 then c.DisplayLaser(l,o,false)g.C0=originalNecks[Y]originalNecks[Y]=nil lasersActive[Y]=nil end end end end},warp={Function=function(l,g)local c=1 local N=.005 local I=c-N local Y=-N repeat main.runService.RenderStepped:Wait()if I<N then I=N Y=N elseif I>c then I=c Y=-N end main.camera.CFrame=main.camera.CFrame*CFrame.new(0,0,0,I,0,0,0,I,0,0,0,1)I=I+Y until I>c end},fly={Activate=function(l)(main:GetModule("\070\108\121\067\111\109\109\097\110\100")):Fly(l.Name)end};fly2={Activate=function(l)(main:GetModule("\070\108\121\067\111\109\109\097\110\100")):Fly(l.Name)end};noclip={Activate=function(l)local g=l.Name local c=(main:GetModule("\099\102")):GetHumanoid()local N=(main:GetModule("\099\102")):GetHRP()if c and N then local l=tick()N.Anchored=true c.PlatformStand=true repeat wait()local c=tick()-l local I=(main.camera.Focus.p-main.camera.CFrame.p).unit local Y=(main:GetModule("\099\102")):GetNextMovement(c,main.commandSpeeds[g])local o=N.Position N.CFrame=CFrame.new(o,o+I)*Y l=tick()until not main.commandsActive[g]if N and c then N.Anchored=false N.Velocity=Vector3.new()c.PlatformStand=false end end end},noclip2={Activate=function(l)(main:GetModule("\070\108\121\067\111\109\109\097\110\100")):Fly(l.Name,true)end},clip={Function=function(l,g,c)(main:GetModule("\099\102")):DeactivateCommand("\110\111\099\108\105\112")end},boing={ExpandTime=4,ExpandAmount=3;EndBoing={},Function=function(l,g,c)local N=g[1]local I=(main:GetModule("\099\102")):GetHead(N)local Y=(main:GetModule("\099\102")):GetHumanoid(N)if I and(Y and not c.UnFunction(l,g,c))then local l=I:FindFirstChild("\077\101\115\104")if l then local g={}local I=N.Character for l,c in pairs(I:GetChildren())do if c:IsA("\065\099\099\101\115\115\111\114\121")then table.insert(g,c)c.Parent=nil end end local o=l.Scale local h=main.tweenService:Create(l,TweenInfo.new(c.ExpandTime,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out),{Scale=Vector3.new(o.X,o.Y*c.ExpandAmount,o.Z)})h:Play()local m=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")c.EndBoing[N]=m;(main:GetModule("\099\102")):WaitForEvent(m,Y.Died,N.CharacterAdded)c.EndBoing[N]=nil m:Destroy()if l then local g=main.tweenService:Create(l,TweenInfo.new(2,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out),{Scale=o})g:Play()g.Completed:Wait()end for l,g in pairs(g)do if I then g.Parent=I else g:Destroy()end end end end end,UnFunction=function(l,g,c)local N=g[1]local I=c.EndBoing[N]if I then I:Fire()return true end end}}

local module = {
	
	----------------------------------------------------------------------
	["ping"] = {
		Function = function(speaker, args)
			local startTime = tick()
			local returnValue = main.signals.GetPing:InvokeServer(math.random(1,1000))
			local timeTaken = tick() - startTime
			local ping = timeTaken/2
			local pingMs = ping*1000
			local depth = 1000
			local pingMsRounded = math.floor((pingMs*depth)+0.5)/depth
			main:GetModule("Notices"):Notice("Notice", main.hdAdminCoreName, "Your ping is "..pingMsRounded.."!")
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["blur"] = {
		Function = function(speaker, args)
			main.blur.Size = (args[2] ~= 0 and args[2]) or 20
		end;
		UnFunction = function(speaker, args)
			main.blur.Size = 0
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["showGuis"] = {
		Function = function(speaker, args)
			for a,b in pairs(hiddenGuis) do
				a.Enabled = true
			end
			hiddenGuis = {}
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["hideGuis"] = {
		Function = function(speaker, args)
			for a,b in pairs(main.playerGui:GetChildren()) do
				if b:IsA("ScreenGui") and b.Name ~= "Chat" and b.Name ~= "HDAdminGUIs" then
					if b.Enabled == true then
						hiddenGuis[b] = true
					end
					b.Enabled = false
				end
			end
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["view"] = {
		Function = function(speaker, args)
			local plr = args[1]
			local humanoid = main:GetModule("cf"):GetHumanoid(plr)
			if humanoid then
				main:GetModule("cf"):SetCameraSubject(humanoid)
			end
		end;
		UnFunction = function(speaker, args)
			local humanoid = main:GetModule("cf"):GetHumanoid(speaker)
			if humanoid then
				main.signals.SetCameraSubject:FireClient(speaker, (humanoid))
			end
		end
		};
	
	
	
	
	----------------------------------------------------------------------
	["nightVision"] = {
		Function = function(speaker, args)
			for _,plr in pairs(main.players:GetChildren()) do
				local head = main:GetModule("cf"):GetHead(plr)
				if plr.Name ~= main.player.Name and head then
					for a,b in pairs(plr.Character:GetChildren()) do
						if b:IsA("BasePart") and b:FindFirstChild("HDNightVision") == nil then
							for i = 1,6 do
								local nv = main.client.Assets.NightVision:Clone()
								nv.Parent = b 
								nv.Face = i-1
								nv.Name = "HDAdminNightVision"
							end
						end
					end
					local nv = main.client.Assets.Nickname:Clone()
					nv.TextLabel.Text = plr.Name
					nv.Parent = head
					nv.Name = "HDAdminNightVision"
				end
			end
		end;
		UnFunction = function(speaker, args)
			for _,plr in pairs(main.players:GetChildren()) do
				if plr.Character then
					for a,b in pairs(plr.Character:GetDescendants()) do
						if b.Name == "HDAdminNightVision" then
							b:Destroy()
						end
					end
				end
			end
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["cmdbar"] = {
		Function = function(speaker, args)
			main:GetModule("CmdBar"):OpenCmdBar()
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["cmdbar2"] = {
		Function = function(speaker, args)
			main:GetModule("cf"):CreateNewCommandMenu("cmdbar2", {}, 2)
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["rainbowFart"] = {
		Function = function(speaker, args)
			local plr = args[1]
			local maxPoops = 20
			local poopSounds = {174658105,148635119}
			local function poopSound(sound_id,part)
				local soundPoop = Instance.new("Sound",part)
				soundPoop.SoundId = "rbxassetid://"..sound_id
				soundPoop.Volume = 0.5
				soundPoop:Play()
				local soundPlaying = soundPoop.IsPlaying or soundPoop.Played:Wait()
				--repeat wait() until soundPoop.IsPlaying
				wait()
			end
			local function poop(clone,toilet,sound_id,poopCount, poopGroup)
				local poop = main.client.Assets.Poop:Clone()
				poopSound(sound_id,poop)
				poop.CanCollide = false
				-- Changed to 'rainbow' as Roblox 'do not allow the use of commands where the central focus is the egregious act of defecation'
				local totalPoops = maxPoops
				local increment = 1/totalPoops
				local newH = (poopCount-1)*increment
				local newColor = Color3.fromHSV(newH, 0.7, 0.7)
				poop.Color = newColor
				--
				poop.CFrame = toilet.Seat.CFrame * CFrame.new(0,(poopCount*1)-0.5,0)
				clone:SetPrimaryPartCFrame(poop.CFrame * CFrame.new(0,3,0))
				poop.Parent = poopGroup
			end
			
			local head = main:GetModule("cf"):GetHead(plr)
			if not head then return end
			
			local originalCFrame = head.CFrame
			
			plr.Character.Parent = nil
			local clone, tracks = main:GetModule("cf"):CreateClone(plr.Character)
			--
			if tracks.sit.Length <= 0 then repeat wait() until tracks.sit.Length > 0 end
			--
			clone.Head.CFrame = originalCFrame
			if plr == main.player then
				main:GetModule("cf"):Movement(false)
				main:GetModule("cf"):SetCameraSubject(clone.Humanoid)
			end
			--main:GetModule("cf"):SetTransparency(plr.Character, 1)
			
			
			local poopCount = 0
			local poopGroup = Instance.new("Model",workspace)
			local toilet = main.client.Assets.Toilet:Clone()
			
			poopGroup.Name = plr.Name.."'s poop"
			toilet.PrimaryPart = toilet.Seat
			toilet:SetPrimaryPartCFrame(clone.HumanoidRootPart.CFrame * CFrame.new(0,-1,0)) --* CFrame.Angles(0,math.rad(90), 0))
			toilet.Parent = workspace
			toilet.Seat:Sit(clone.Humanoid)
			tracks.sit:Play(0)
			clone.Head.face.Texture = "rbxassetid://304907108"
			wait()
			clone.PrimaryPart = clone.Head
			clone:SetPrimaryPartCFrame(toilet.PrimaryPart.CFrame * CFrame.new(0,3,0))
			for a,b in pairs(clone:GetChildren()) do
				if b:IsA("BasePart") and b.Name ~= "HumanoidRootPart" then
					b.Anchored = true
				end
			end
			wait(1)
			--
			poopSound(174658105,clone.HumanoidRootPart)
			wait(2)
			poopCount = poopCount + 1
			poop(clone,toilet,148635119,poopCount, poopGroup, poopGroup)
			clone.Head.face.Texture = "rbxassetid://338312149"
			wait(1.5)
			clone.Head.face.Texture = "rbxassetid://316545711"
			for i = 1,maxPoops do
				if i == maxPoops-2 then
					for a,b in pairs(clone:GetChildren()) do
						if b:IsA("BasePart") and b.Name ~= "HumanoidRootPart" then
							b.Anchored = false
						end
					end
					local explosion = Instance.new("Explosion")
					explosion.Position = clone.Head.Position
					explosion.Parent = clone
					explosion.DestroyJointRadiusPercent = 0
					clone:BreakJoints()
				elseif i > maxPoops-1 then
					for a,b in pairs(poopGroup:GetChildren()) do
						b.Anchored = false
						b.CanCollide = true
					end
				end
				poopCount = poopCount + 1
				if i >= maxPoops then
					wait(1.5)
				else
					poop(clone,toilet,poopSounds[math.random(1,#poopSounds)],poopCount, poopGroup)
					wait()
				end
			end
			
			wait(3)
			poopGroup:Destroy()
			toilet:Destroy()
			clone:Destroy()
			
			if plr == main.player then
				local humanoid = main:GetModule("cf"):GetHumanoid(plr)
				if humanoid then
					main:GetModule("cf"):Movement(true)
					main:GetModule("cf"):SetCameraSubject(humanoid)
				end
			end
			--main:GetModule("cf"):SetTransparency(plr.Character, 0)
			plr.Character.Parent = workspace
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["icecream"] = {
		Function = function(speaker, args)
			local plr = args[1]
			
			--Create clone and hide char
			plr.Character.Parent = nil
			local clone, tracks = main:GetModule("cf"):CreateClone(plr.Character)
			local hrp = clone:FindFirstChild("HumanoidRootPart")
			if hrp == nil then clone:Destroy() return end
			hrp.Anchored = true
			--tracks.idle:Play()
			--main:GetModule("cf"):SetTransparency(plr.Character, 1)
			
			--Create van
			local van = main.client.Assets.IcecreamVan:Clone()
			van.PrimaryPart = van.VanDoor.Part1
			van:SetPrimaryPartCFrame(hrp.CFrame * CFrame.new(-210,3,-4) * CFrame.Angles(0,math.rad(90), 0))
			van.Parent = workspace
			
			--Disable movement and set camera if player == plr
			if plr == main.player then
				main:GetModule("cf"):Movement(false)
				main:GetModule("cf"):SetCameraSubject(clone.Humanoid)
				for a,b in pairs(van:GetDescendants()) do
					if b:IsA("BasePart") then
						b.CanCollide = true
					end
				end
			end
			
			--Setup Sounds
			local soundIcecream = main:GetModule("cf"):CreateSound{SoundId = 260910474, Volume = 0.5, Parent = van.PrimaryPart}
			local soundClowns = main:GetModule("cf"):CreateSound{SoundId = 861942173, Volume = 4, Parent = van.PrimaryPart}
			local soundBaby = main:GetModule("cf"):CreateSound{SoundId = 2628538600, Volume = 0.15, Parent = van.PrimaryPart}
			local soundScream = main:GetModule("cf"):CreateSound{SoundId = 147758746, Volume = 0.8, Parent = van.PrimaryPart}
			
			--Tween van to plr
			soundIcecream:Play()
			main:GetModule("cf"):TweenModel(van, van.PrimaryPart.CFrame * CFrame.new(0, 0, 210), TweenInfo.new(8))
			wait(8.1)
			local tween = main.tweenService:Create(soundIcecream, TweenInfo.new(0.5), {Volume = 0})
			tween:Play()
			tween.Completed:Wait()
			soundIcecream:Stop()
			soundIcecream:Destroy()
			wait(1)
			
			--Open doors, get plr and close doors
			van.VanDoor.Part1.Transparency = 1
			van.VanDoor.Part2.Transparency = 1
			wait(1)
			clone.PrimaryPart = clone.Head
			clone:SetPrimaryPartCFrame(van.Clown.Head.CFrame * CFrame.new(0,0,-2.5) * CFrame.Angles(0,math.rad(180), 0))
			local originalMinZoom = plr.CameraMinZoomDistance
			local originalMaxZoom = plr.CameraMaxZoomDistance
			if plr == main.player then
				plr.CameraMaxZoomDistance = 0.5
				spawn(function()
					plr.CameraMaxZoomDistance = 1
				end)
			end
			local face = clone.Head:FindFirstChild("face")
			if face then
				face.Texture = "rbxassetid://338312149"
			end
			soundClowns:Play()
			wait(1)
			van.VanDoor.Part1.Transparency = 0
			van.VanDoor.Part2.Transparency = 0
			clone.Parent = van
			for a,b in pairs(clone:GetChildren()) do
				if b:IsA("Accessory") then
					b:remove()
				end
			end
			
			--Tween van away
			soundIcecream:Play()
			main:GetModule("cf"):TweenModel(van, van.PrimaryPart.CFrame * CFrame.new(0, 0, 400), TweenInfo.new(14, Enum.EasingStyle.Quad, Enum.EasingDirection.In))
			
			--Show scary stuff and scream
			wait(4)
			local arm = van.Clown["Right Arm"]
			arm.CFrame = arm.CFrame * CFrame.fromEulerAnglesXYZ(math.rad(45), 0, 0)
			for a,b in pairs(van.Doll:GetChildren()) do
				b.Transparency = 0
			end
			van.Doll.Head.face.Transparency = 0
			wait(0.1)
			soundBaby:Play()
			wait(1.5)
			soundScream:Play()
			if face then
				face.Texture = "rbxassetid://288918236"
			end
			wait(2.5)
			
			--Explode
			if plr == main.player then
				local explosion = Instance.new("Explosion")
				explosion.Position = clone.Head.Position
				explosion.Parent = clone
				clone:BreakJoints()
				main.audio.Oof:Play()
			end
			
			wait(5)
			--Destroy van and reset player
			if plr == main.player then
				local humanoid = main:GetModule("cf"):GetHumanoid(plr)
				if humanoid then
					main:GetModule("cf"):Movement(true)
					main:GetModule("cf"):SetCameraSubject(humanoid)
				end
				plr.CameraMaxZoomDistance = 20
				wait()
				plr.CameraMinZoomDistance = 20
				wait()
				plr.CameraMinZoomDistance = originalMinZoom
				plr.CameraMaxZoomDistance = originalMaxZoom
			end
			--main:GetModule("cf"):SetTransparency(plr.Character, 0)
			if plr.Character then
				plr.Character.Parent = workspace
			end
			van:Destroy()
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["laserEyes"] = {
		DisplayLaser = function(laserHead, laserTarget, status)
			local leftBeam = laserTarget:FindFirstChild("LeftBeam")
			if leftBeam then
				leftBeam.Enabled = status
				laserTarget.RightBeam.Enabled = status
				laserTarget.MidAttachment.GlowHit.Enabled = status
			end
		end;
		
		Activate = function(self)
			local commandName = self.Name
			local head = main:GetModule("cf"):GetHead()
			local humanoid = main:GetModule("cf"):GetHumanoid()
			local hrp = main:GetModule("cf"):GetHRP()
			if head and humanoid and main.mouseDown then
				local laserHead = head:FindFirstChild("HDAdminLaserHead")
				local neck = main:GetModule("cf"):GetNeck()
				local r6 = false
				if humanoid.RigType == Enum.HumanoidRigType.R6 then
					r6 = true
				end
				head.Parent.PrimaryPart = hrp
				if laserHead and neck then
					
					local maxDistance = 30
					local lastUpdate = tick()-1
					local originalC0 = neck.C0
					local additionalY =  humanoid.HipHeight/2.5
					local laserTarget = laserHead.LaserTarget
					local fire = laserTarget.MidAttachment2.Fire
					local sparks = laserTarget.MidAttachment.Sparks
					local sizzle = main.audio.Sizzle
					local sizzle2 = main.audio.Sizzle2
					sizzle:Play()
					self.DisplayLaser(laserHead, laserTarget, true)
					
					repeat
						local hit, position = main:GetModule("cf"):GetMousePoint(main.lastHitPosition)
						local targetCFrame = CFrame.new(position, head.Position)
						local distanceFromPlayer = main.player:DistanceFromCharacter(targetCFrame.p)
						local exceededMaxDistance = false
						if distanceFromPlayer > maxDistance then
							targetCFrame = targetCFrame * CFrame.new(0, 0, maxDistance-distanceFromPlayer)
							exceededMaxDistance = true
						end
						laserTarget.CFrame = targetCFrame
						local headPos = head.Position
						local targetPos = laserTarget.Position
						local direction = (Vector3.new(targetPos.X, headPos.Y, targetPos.Z) - head.Position).Unit
						if head.Parent.PrimaryPart == nil then
							head.Parent.PrimaryPart = head.parent.HumanoidRootPart
						end
						local lookCFrame = (CFrame.new(Vector3.new(), (head.Parent.PrimaryPart.CFrame):VectorToObjectSpace(direction)))
						if r6 then
							lookCFrame = lookCFrame * CFrame.new(0,1,0) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(180),0)
						else
							lookCFrame = lookCFrame * CFrame.new(0,additionalY,0)
						end
						neck.C0 = lookCFrame
						if tick() - 0.6 > lastUpdate then
							lastUpdate = tick()
							main:GetModule("cf"):ReplicateEffect(self.Name, {targetCFrame, lookCFrame})
						end
						if hit and not exceededMaxDistance and (hit.Parent:FindFirstChild("Humanoid") or hit.Name == "Handle") then
							fire.Enabled = true
							sparks.Enabled = true
							if not sizzle2.Playing then
								sizzle2:Play()
							end
						else
							fire.Enabled = false
							sparks.Enabled = false
							if sizzle2.Playing then
								sizzle2:Stop()
							end
						end
						wait()
						
					until not main.mouseDown or not main.commandsActive[commandName] or not head or not head.Parent or not neck
					neck.C0 = originalC0
					self.DisplayLaser(laserHead, laserTarget, false)
					fire.Enabled = false
					sparks.Enabled = false
					sizzle:Stop()
					sizzle2:Stop()
				end
			end
			main.commandsActive[commandName] = nil
		end;
		
		ReplicationEffect = function(speaker, args, self)
			local targetCFrame, lookCFrame = args[1], args[2]
			local plr = speaker
			local head = main:GetModule("cf"):GetHead(plr)
			if head then
				local laserHead = head:FindFirstChild("HDAdminLaserHead")
				local neck = main:GetModule("cf"):GetNeck(plr)
				if laserHead and neck then
					local laserTarget = laserHead.LaserTarget
					--Laser is already active
					if lasersActive[plr] then
						lasersActive[plr] = lasersActive[plr] + 1
					else -- New laser
						lasersActive[plr] = 1
						originalNecks[plr] = neck.C0
						local randomZ = math.random(10,40) - 15
						laserTarget.CFrame = targetCFrame * CFrame.new(0, 0, randomZ)
						neck.C0 = lookCFrame
						laserTarget.MidAttachment.GlowHit.Rate = 50
						self.DisplayLaser(laserHead, laserTarget, true)
					end
					main.tweenService:Create(laserTarget, laserTweenInfo, {CFrame = targetCFrame}):Play()
					main.tweenService:Create(neck, laserTweenInfo, {C0 = lookCFrame}):Play()
					wait(laserTweenTime)
					lasersActive[plr] = lasersActive[plr] - 1
					if lasersActive[plr] <= 0 then
						self.DisplayLaser(laserHead, laserTarget, false)
						neck.C0 = originalNecks[plr]
						originalNecks[plr] = nil
						lasersActive[plr] = nil
					end
				end
			end
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["warp"] = {
		Function = function(speaker, args)
			local maxDistort = 1
			local increment = 0.005
			local distort = maxDistort-increment
			local distortDirection = -increment
			repeat main.runService.RenderStepped:Wait()
				if distort < increment then
					distort = increment
					distortDirection = increment
				elseif distort > maxDistort then
					distort = maxDistort
					distortDirection = -increment
				end
				main.camera.CFrame = main.camera.CFrame*CFrame.new(0,0,0,distort,0,0,0,distort,0,0,0,1)
				distort = distort + distortDirection
			until distort > maxDistort
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["fly"] = {
		Activate = function(self)
			main:GetModule("FlyCommand"):Fly(self.Name)
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["fly2"] = {
		Activate = function(self)
			main:GetModule("FlyCommand"):Fly(self.Name)
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["noclip"] = {
		Activate = function(self)
			local commandName = self.Name
			local humanoid = main:GetModule("cf"):GetHumanoid()
			local hrp = main:GetModule("cf"):GetHRP()
			if humanoid and hrp then
				local lastUpdate = tick()
				hrp.Anchored = true
				humanoid.PlatformStand = true
				repeat wait()
					local delta = tick()-lastUpdate
					local look = (main.camera.Focus.p-main.camera.CFrame.p).unit
					local move = main:GetModule("cf"):GetNextMovement(delta, main.commandSpeeds[commandName])
					local pos = hrp.Position
					hrp.CFrame = CFrame.new(pos,pos+look) * move
					lastUpdate = tick()
					
				until not main.commandsActive[commandName]
				if hrp and humanoid then
					hrp.Anchored = false
					hrp.Velocity = Vector3.new()
					humanoid.PlatformStand = false
				end
			end
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["noclip2"] = {
		Activate = function(self)
			main:GetModule("FlyCommand"):Fly(self.Name, true)
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["clip"] = {
		Function = function(speaker, args, self)
			main:GetModule("cf"):DeactivateCommand("noclip")
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	["boing"] = {
		ExpandTime = 4;
		ExpandAmount = 3;
		EndBoing = {};
		Function = function(speaker, args, self)
			local plr = args[1]
			local head = main:GetModule("cf"):GetHead(plr)
			local humanoid = main:GetModule("cf"):GetHumanoid(plr)
			if head and humanoid and not self.UnFunction(speaker, args, self) then
				local headMesh = head:FindFirstChild("Mesh")
				if headMesh then
					local hats = {}
					local character = plr.Character
					for a,b in pairs(character:GetChildren()) do
						if b:IsA("Accessory") then
							table.insert(hats, b)
							b.Parent = nil
						end
					end
					local originalScale = headMesh.Scale
					local tween = main.tweenService:Create(headMesh, TweenInfo.new(self.ExpandTime, Enum.EasingStyle.Elastic, Enum.EasingDirection.Out), {Scale = Vector3.new(originalScale.X, originalScale.Y * self.ExpandAmount, originalScale.Z)})
					tween:Play()
					--
					local endEvent = Instance.new("BindableEvent")
					self.EndBoing[plr] = endEvent
					main:GetModule("cf"):WaitForEvent(endEvent, humanoid.Died, plr.CharacterAdded)
					self.EndBoing[plr] = nil
					endEvent:Destroy()
					--
					if headMesh then
						local tween = main.tweenService:Create(headMesh, TweenInfo.new(2, Enum.EasingStyle.Elastic, Enum.EasingDirection.Out), {Scale = originalScale})
						tween:Play()
						tween.Completed:Wait()
					end
					for i,v in pairs(hats) do
						if character then
							v.Parent = character
						else
							v:Destroy()
						end
					end
				end
			end
		end;
		UnFunction = function(speaker, args, self)
			local plr = args[1]
			local endEvent = self.EndBoing[plr]
			if endEvent then
				endEvent:Fire()
				return true
			end
		end;
		};
	
	
	
	
	----------------------------------------------------------------------
	
};


