---@class WB_RoundSettle_Item_C:UUserWidget ---@field Image_Icon UImage ---@field TextBlock_Assist UTextBlock ---@field TextBlock_Dead UTextBlock ---@field TextBlock_Kill UTextBlock ---@field TextBlock_Name UTextBlock --Edit Below-- ---@type WB_RoundSettle_Item_C local WB_RoundSettle_Item = { bInitDoOnce = false; }; WB_RoundSettle_Item.OwnerPlayerKey = nil; function WB_RoundSettle_Item:Construct() end -- function WB_RoundSettle_Item:Tick(MyGeometry, InDeltaTime) -- end -- function WB_RoundSettle_Item:Destruct() -- end function WB_RoundSettle_Item:SetPlayerKeyAndKDA(InPlayerKey, InKDA) self.OwnerPlayerKey = InPlayerKey; -- 设置头像 UGCSystemLibrary.DownloadImageToUImage(self.Image_Icon, UGCGameSystem.GameState:GetHeadIconByPlayerKey(InPlayerKey)); self.TextBlock_Name:SetText(UGCGameSystem.GameState:GetPlayerAccountInfo(InPlayerKey).PlayerName); self:SetKDA(InKDA); end function WB_RoundSettle_Item:SetKDA(InKDA) local function Func(InKey) if InKDA[InKey] ~= nil then return tostring(InKDA[InKey]); end return "0" end self.TextBlock_Dead:SetText(Func("Dead")) self.TextBlock_Kill:SetText(Func("Kill")) self.TextBlock_Assist:SetText(Func("Assist")) end function WB_RoundSettle_Item:GetPlayerKey() return self.OwnerPlayerKey; end return WB_RoundSettle_Item;