Files
wnsrc/gamemodes/darkrp/plugins/willardskills/derma/cl_skill_bartering.lua
lifestorm df294d03aa Upload
2024-08-04 23:54:45 +03:00

63 lines
1.3 KiB
Lua
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

--[[
| This file was obtained through the combined efforts
| of Madbluntz & Plymouth Antiquarian Society.
|
| Credits: lifestorm, Gregory Wayne Rossel JR.,
| Maloy, DrPepper10 @ RIP, Atle!
|
| Visit for more: https://plymouth.thetwilightzone.ru/
--]]
local vgui = vgui
local PANEL = {}
function PANEL:Init()
local parent = self:GetParent():GetParent()
self:SetSize(parent.contentPanel:GetSize())
-- Config
self.firstTitle = "Sevkiyat"
self.secondTitle = "Satın Al"
self.thirdTitle = "Önizleme"
self.nothingSelected = "Hiçbir öğe seçili değil"
self.requirementsTitleText = "Gereksinimleri: "
self.skill = "bartering"
self.built = false
ix.city:SyncCityStock()
end
function PANEL:Proceed()
self.built = true
-- Create titles
self:Add("CraftingBaseTopTitleBase")
-- Create inner content
self:Add("CraftingBaseInnerContent")
-- Rebuild inner content
self:Add("CraftingBaseRebuild")
end
function PANEL:Remove()
if (self.model) then
self.model:Remove()
end
end
vgui.Register("BarteringBasePanel", PANEL, "EditablePanel")
local function CreateBarteringPanel(container)
local panel = container:Add("BarteringBasePanel")
ix.gui.barteringpanel = panel
ix.gui.activeSkill = panel
return container
end
hook.Add("CreateSkillPanels", "BarteringBasePanel", function(tabs)
tabs[ix.skill.list["bartering"].uniqueID] = CreateBarteringPanel
end)