--by pavetr.top local hitsounds, hitsoundwh local onsuka = 1 local hiton = 0 local values = "bell" local values1 = false -- Then font named "Font" compacted on one line. surface.CreateFont("suchka", { font = "Roboto", extended = true, size = 20 }) surface.CreateFont("airsex", { font = "Consolas", extended = true, size = 30 }) local clr = Color(0, 0, 0, 255) local function mainpansukas() local mainpansuka = vgui.Create("DFrame") mainpansuka:SetSize(200, 130) mainpansuka:Center() mainpansuka:SetTitle("") mainpansuka:MakePopup() mainpansuka:ShowCloseButton( false ) mainpansuka.Paint = function(self, w, h) draw.RoundedBox(8, 0, 0, w, h, clr) draw.SimpleText("ON/OFF", "suchka", 75, 20, color_white, TEXT_ALIGN_CENTER, TEXT_ALIGN_TOP) draw.SimpleText("HitSound", "airsex", 98, 85, color_white, TEXT_ALIGN_CENTER, TEXT_ALIGN_TOP) end function mainpansuka.OnClose() onsuka = 0 end local closebtn = vgui.Create( "DImageButton", mainpansuka ) closebtn:SetPos( 175, 10 ) closebtn:SetSize( 32, 32 ) closebtn:SetImage( "icon16/stop.png" ) closebtn:SizeToContents() closebtn.DoClick = function() mainpansuka:Close() end local first = mainpansuka:Add( "DCheckBox" ) first:SetPos( 20, 20 ) first:SetSize( 20, 20 ) first:SetValue( values1 ) first.Lerp = 0 function first:Paint(w, h) draw.RoundedBox(8, 0, 0, w, h, Color(255,255,255)) if self:GetChecked() then self.Lerp = Lerp(0.1, self.Lerp, 255) else self.Lerp = Lerp(0.1, self.Lerp, 0) end draw.RoundedBox(8, 5, 5, w - 10, h - 10, Color(184, 66, 252, self.Lerp)) end function first:OnChange() if hiton == 0 then values1 = true hiton = 1 else values1 = false hiton = 0 end end local choice = vgui.Create( "DComboBox", mainpansuka ) choice:SetPos( 20, 55 ) choice:SetSize( 100, 20 ) choice:SetFont("suchka") choice:SetValue( values ) choice:AddChoice( "cod" ) choice:AddChoice( "bell" ) choice:AddChoice( "shoot" ) choice:AddChoice( "pop" ) choice:AddChoice( "meow" ) choice:AddChoice( "minecraft" ) choice:AddChoice( "think" ) choice:AddChoice( "uwu" ) choice:AddChoice( "cowbell" ) choice.OnSelect = function( self, index, value ) if value == "bell" then values = "bell" hitsounds = "1.wav" elseif value == "cod" then values = "cod" hitsounds = "2.wav" elseif value == "pop" then values = "pop" hitsounds = "4.wav" elseif value == "shoot" then values = "shoot" hitsounds = "3.wav" elseif value == "meow" then values = "meow" hitsounds = "7.wav" elseif value == "minecraft" then values = "minecraft" hitsounds = "6.wav" elseif value == "think" then values = "think" hitsounds = "5.wav" elseif value == "uwu" then values = "uwu" hitsounds = "8.wav" elseif value == "cowbell" then values = "cowbell" hitsounds = "9.wav" end end end me = LocalPlayer() gameevent.Listen("player_hurt") hook.Add("player_hurt", "Hitsound", function (data) if hiton == 1 then if(data.attacker != me:UserID()) then return end sound.PlayFile(hitsounds, "mono", function(s) s:SetVolume(80) end) end end) concommand.Add("hits", function() if onsuka == 0 then onsuka = 1 mainpansukas() end end) mainpansukas()