From 96a2732f3daae727644ddac5cbe636bd467d884f Mon Sep 17 00:00:00 2001 From: Fesiug Date: Sun, 22 Oct 2023 00:37:12 -0400 Subject: [PATCH] Spawnmenu tweak --- .../benny/gamemode/modules/player/sh_basic.lua | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/gamemodes/benny/gamemode/modules/player/sh_basic.lua b/gamemodes/benny/gamemode/modules/player/sh_basic.lua index bc958f1..aa4fd4d 100644 --- a/gamemodes/benny/gamemode/modules/player/sh_basic.lua +++ b/gamemodes/benny/gamemode/modules/player/sh_basic.lua @@ -161,12 +161,17 @@ if CLIENT then local itemlist = smenu:Add("DScrollPanel") itemlist:Dock( FILL ) + + local List = vgui.Create( "DIconLayout", itemlist ) + List:Dock( FILL ) + List:SetSpaceX( 5 ) + List:SetSpaceY( 5 ) for ClassName, Class in SortedPairsByMemberValue( WEAPONS, "Name" ) do local button = vgui.Create( "DButton" ) - itemlist:AddItem( button ) - button:SetSize( 1, ss(30) ) - button:Dock( TOP ) + List:Add( button ) + button:SetSize( ss(96), ss(22) ) + --button:Dock( TOP ) button:DockMargin( 0, 0, 0, ss(4) ) button.Text_Name = Class.Name @@ -190,9 +195,9 @@ if CLIENT then surface.SetTextPos( ss(4), ss(4) ) surface.DrawText( self.Text_Name ) - surface.SetFont( "Benny_12" ) - surface.SetTextPos( ss(4), ss(4 + 12) ) - surface.DrawText( self.Text_Desc ) + -- surface.SetFont( "Benny_10" ) + -- surface.SetTextPos( ss(4), ss(4 + 12) ) + -- surface.DrawText( self.Text_Desc ) return true end end