Hey there I am making a derma menu for my group of servers where a user can type "!community" into the chat and it brings up a dema menu that shows a different tab for each of our servers and a button to connect to each. I am having a few problems with it tho, I am still in the begining stage but I thought I better ask now rather than wait later and waste more time. [U]Any help is greatly appreciated.[/U]
1. Although the picture suggests otherwise the image in my derma constantly is flickering black and clipping for no reason and sometimes turns pure black.
2.I am not exactly sure how I would code the button to take me to a certain server, any ideas ?
3.also I have had no luck getting the "!community" in chat to bring up my menu, I am not sure why either.
4.The donate tab shows the website but it has no way to scroll down or across.
Please like I said , any help at all will mean the world to me. Here is my code:
[QUOTE]function MyCoolMenu()
local MainMenuFrame = vgui.Create( "DFrame" )
MainMenuFrame:SetSize( 900, 500 )
MainMenuFrame:SetTitle("Garrys Community")
MainMenuFrame:Center()
MainMenuFrame:SetVisible( true )
MainMenuFrame:SetDraggable( false )
MainMenuFrame:MakePopup()
local MainMenuSheet = vgui.Create( "DPropertySheet", MainMenuFrame )
MainMenuSheet:SetPos( 5, 27 )
MainMenuSheet:SetSize( 890, 467 )
local TTTTab = vgui.Create( "DPanelList" )
TTTTab:SetPos( 0, 0 )
TTTTab:SetSize( MainMenuSheet:GetWide(), MainMenuSheet:GetTall() )
TTTTab:SetSpacing( 100 )
TTTTab:EnableHorizontal( false )
TTTTab:EnableVerticalScrollbar( true )
local ZSTab = vgui.Create( "DPanelList" )
ZSTab:SetSpacing( 100 )
local DRPTab = vgui.Create( "DPanelList" )
DRPTab:SetSpacing( 100 )
local DonateTab = vgui.Create( "DPanelList" )
DRPTab:SetSpacing( 100 )
local myImage = vgui.Create("DImage", ZSTab)
myImage:SetImage( "VGUI/entities/chickenandpie" )
myImage:SizeToContents() // make the control the same size as the image.
myImage:SetPos(180,100)
local RulesLabel = vgui.Create("DLabel", TTTTab) --
RulesLabel:SetPos(5,20)
RulesLabel:SetColor( Color( 0, 0, 0, 255 ) )
RulesLabel:SetFont("default")
RulesLabel:SetText("I think we should re-new the current GMod Wiki.")
RulesLabel:SizeToContents()
local DermaButton = vgui.Create( "DButton", TTTTab )
DermaButton:SetText( "Kill yourself" )
DermaButton:SetPos( 25, 50 )
DermaButton:SetSize( 150, 50 )
DermaButton.DoClick = function ()
RunConsoleCommand( "kill" ) -- What happens when you press the button
end
local HTMLTest = vgui.Create("HTML",DonateTab)
HTMLTest:SetPos(5,5)
HTMLTest:SetSize(ScrW() - 100, ScrH() - 100)
HTMLTest:OpenURL("http://www.garryscommunity.net/forums/donate")
HTMLTest:SizeToContents()
MainMenuSheet:AddSheet( "Trouble In Terrorist Town", TTTTab, "gui/silkicons/shield", false, false, nil )
MainMenuSheet:AddSheet( "Zombie Survival", ZSTab, "gui/silkicons/shield", false, false, nil )
MainMenuSheet:AddSheet( "Dark Roleplay", DRPTab, "gui/silkicons/shield", false, false, nil )
MainMenuSheet:AddSheet( "Donate", DonateTab, "gui/silkicons/shield", false, false, nil )
end
concommand.Add("open_funfun", MyCoolMenu )[/QUOTE]
[IMG]http://i47.tinypic.com/178gns.jpg[/IMG]
Sorry, you need to Log In to post a reply to this thread.