• Menu bugs(New Flood Mod)
    7 replies, posted
In the menu I have a DModelPanel named "MENU.Model_Icon" (line 662) in the function BankMenu() and when you change your player model it's the old one on top of the new one. Also I have a DCollapsibleCategory named "MENU.AdminModels" (line 668) in the same function and the SpawnIcon's for it are no where near it. How do I fix these bugs? Photo here [HTML]https://docs.google.com/open?id=0B3mVj2ufceRbX0xlWlRIajVqVnc[/HTML] here is cl_menu.lua [lua] local PANEL = {} function PANEL:Init() if Loaded == false || Loaded == nil || Loaded == NULL || Loaded == "" then AllTools = spawnmenu.GetTools() local Loaded = true end local tTables = AllTools MENU = self MENU:SetTitle("") MENU:ShowCloseButton(false) MENU:SetSize(ScrW() - 50, ScrH() - 50) MENU:SetPos(25, 25) MENU.Paint = function() surface.SetDrawColor(0, 0, 0, 0) surface.DrawRect(0, 0, MENU:GetWide(), MENU:GetTall()) end -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| self.PropPanel = vgui.Create("DPropertySheet") --| Prop tab. self.PropPanel:SetParent(MENU) --| self.PropPanel:SetSize(((MENU:GetWide()*.5 - 5)), MENU:GetTall()) --| self.PropPanel:SetPos(0, 0) --| --| self.PropsBackground = vgui.Create("DPanelList") --| Prop background. self.PropsBackground:EnableHorizontal(true) --| self.PropsBackground:EnableVerticalScrollbar(true) --| self.PropsBackground:SetPadding(5) --| self.PropsBackground:SetSpacing(5) --| self.PropsBackground:SetSize((self.PropPanel:GetWide() - 10), self.PropPanel:GetTall()) --| self.PropsBackground:SetPos(0, 0) --| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| self.ToolPanel = vgui.Create("DPropertySheet") --| Tool tab. self.ToolPanel:SetParent(MENU) --| self.ToolPanel:SetSize(((MENU:GetWide()*.5 - 5)), MENU:GetTall()) --| self.ToolPanel:SetPos(((MENU:GetWide()*.5 + 5)), 0) --| --| self.ToolsBackground = vgui.Create("DPanelList") --| Tool background. self.ToolsBackground:EnableHorizontal(true) --| self.ToolsBackground:EnableVerticalScrollbar(false) --| self.ToolsBackground:SetAutoSize(false) --| self.ToolsBackground:SetPadding(0) --| self.ToolsBackground:SetSpacing(5) --| self.ToolsBackground:SetSize(0, 0) --| self.ToolsBackground:SetPos(0, 0) --| self.ToolsBackground.Paint = function() --| surface.SetDrawColor(170, 170, 170, 255) --| surface.DrawRect(0, 0, self.ToolsBackground:GetWide(), self.ToolsBackground:GetTall()) --| end --| --| self.ToolList = vgui.Create("DPanelList") --| Tool list background. self.ToolsBackground:AddItem(self.ToolList) --| self.ToolList:EnableVerticalScrollbar(true) --| self.ToolList:SetSize(self.ToolPanel:GetWide()*.33, self.ToolPanel:GetTall() - 31) --| self.ToolList:SetPos(0, 0) --| self.ToolList:SetAutoSize( false ) --| self.ToolList:SetSpacing( 1 ) --| self.ToolList:SetPadding( 0 ) --| --| self.Content = vgui.Create("DPanelList") --| Context background. self.ToolsBackground:AddItem(self.Content) --| self.Content:SetSize(self.ToolPanel:GetWide()*.63, self.ToolPanel:GetTall() - 31) --| self.Content:EnableVerticalScrollbar(false) --| self.Content:SetSpacing(0) --| self.Content:SetPadding(5) --| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| self.WeaponsBackground = vgui.Create("DPanelList") --| Weapons background. self.WeaponsBackground:EnableHorizontal(true) self.WeaponsBackground:EnableVerticalScrollbar(false) --| self.WeaponsBackground:SetSize((self.ToolPanel:GetWide() - 10), self.ToolPanel:GetTall()) --| self.WeaponsBackground:SetPos(0, 0) --| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| self.BankBackground = vgui.Create("DPanelList") --| Bank background. self.BankBackground:EnableHorizontal(true) --| self.BankBackground:EnableVerticalScrollbar(false) --| self.BankBackground:SetAutoSize(false) --| self.BankBackground:SetPadding(0) --| self.BankBackground:SetSpacing(5) --| self.BankBackground:SetSize(0, 0) --| self.BankBackground:SetPos(0, 0) --| self.BankBackground.Paint = function() --| surface.SetDrawColor(170, 170, 170, 255) --| surface.DrawRect(0, 0, self.BankBackground:GetWide(), self.BankBackground:GetTall()) --| end --| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -----------------------------------------------------------------------------------------------------------------------------------------------------------------------| Help background. self.HelpBackground = vgui.Create("DPanelList") --| Help background. self.HelpBackground:EnableVerticalScrollbar(false) --| self.HelpBackground:SetSize((self.ToolPanel:GetWide() - 10), self.ToolPanel:GetTall()) --| self.HelpBackground:SetPos(0, 0) --| self.HelpBackground.Paint = function() local Wide = self.HelpBackground:GetWide() local Height = self.HelpBackground:GetTall() local Title = "The 6 golden rules you must follow at all times:" local One = "1. Do NOT cuss or use any vulgar language! (includes the use of *)" local Two = "2. Attatch/constraint/stick props to the map exsept for backups." local Three = "3. Spam mic/chat/props in any way." local Four = "4. NO sharks! No Prop Pushing or Traping!" local Five = "5. Don't be disrespectful in any wat to other players." local Six = "6. Don't exploit any bugs/glitches/errors with the gamemode." local Seven = "If any of these rules are broken, you will be kicked/banned on your fault." surface.SetDrawColor(50, 50, 50, 255) --| surface.DrawRect(0, 0, Wide, self.DonateBackground:GetTall())--| surface.SetTextColor(255, 255, 255, 255) --| surface.SetFont("Trebuchet24") --| local TitleW, TitleH = surface.GetTextSize(Title) surface.SetTextPos(((Wide*.5) - (TitleW*.5)), ((Height*.03) - (TitleH*.5))) --| surface.DrawText(Title) surface.SetFont("Trebuchet18") --| local OneW, OneH = surface.GetTextSize(One) surface.SetTextPos(((Wide*.5) - (OneW*.5)), ((Height*.09) - (OneH*.5))) surface.DrawText(One) --| surface.SetFont("Trebuchet18") --| local TwoW, TwoH = surface.GetTextSize(Two) surface.SetTextPos(((Wide*.5) - (TwoW*.5)), ((Height*.12) - (TwoH*.5)))
You could at least.... try and clean up some of the useless shit so I don't have to read through 3,000 lines of code.
[QUOTE=Lerpaderp;38903902]You could at least.... try and clean up some of the useless shit so I don't have to read through 3,000 lines of code.[/QUOTE] hows that?
[QUOTE=CamDAX;38904099]hows that?[/QUOTE] You could at least use [lua] tags instead of code tags
Tham gia choi game World of Warcraft mi?n phÃ* t?i [url=http://www.player.vn/]http://www.player.vn/[/url] d? tr?i nghi?m vÃ* t?n hu?ng game 3D s? 1 th? gi?i
Could some one at lest be helpful!
I'm kind of confused what the error is. Write a list of everything that's wrong.
The DModelPanel named "MENU.Model_Icon" (line 662) in the function BankMenu() doesn't update properly when you change your player model. Its like two models occupying the same space. The DCollapsibleCategory named "MENU.AdminModels" (line 668) in the same function is super small and doesn't exspand when you click on it. (see [URL="https://docs.google.com/open?id=0B3mVj2ufceRbX0xlWlRIajVqVnc"]https://docs.google.com/open?id=0B3mVj2ufceRbX0xlWlRIajVqVnc[/URL]) its to the right of the Chewbacca model.
Sorry, you need to Log In to post a reply to this thread.