UGCProjects/TwoOnTwo/Script/UI/StatusUI/Round/WB_PlaceItemCountInfo.lua

34 lines
816 B
Lua
Raw Permalink Normal View History

2025-01-04 23:00:19 +08:00
---@class WB_PlaceItemCountInfo_C:UUserWidget
---@field TextBlock_Count UTextBlock
---@field TextBlock_ItemName UTextBlock
--Edit Below--
local WB_PlaceItemCountInfo = { bInitDoOnce = false; };
--[==[ Construct
function WB_PlaceItemCountInfo:Construct()
end
-- Construct ]==]
-- function WB_PlaceItemCountInfo:Tick(MyGeometry, InDeltaTime)
-- end
-- function WB_PlaceItemCountInfo:Destruct()
-- end
function WB_PlaceItemCountInfo:Init(InPlaceItemType)
self.PlaceItemType = InPlaceItemType
self.TextBlock_ItemName:SetText(PlacementModeConfig.ItemInfo[self.PlaceItemType].Name)
end
function WB_PlaceItemCountInfo:SetCount(InCount)
self.TextBlock_Count:SetText("×" .. InCount)
end
function WB_PlaceItemCountInfo:GetPlaceItemType()
return self.PlaceItemType
end
return WB_PlaceItemCountInfo;