From b653fb8a1b763a328f73c5a9d3845bb54a003bb0 Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期一, 28 七月 2025 11:12:47 +0800
Subject: [PATCH] 0312 对象池管理,备份代码
---
Main/System/SkillUI/SkillBaseCell.cs | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/Main/System/SkillUI/SkillBaseCell.cs b/Main/System/SkillUI/SkillBaseCell.cs
index d8dd906..1e1b161 100644
--- a/Main/System/SkillUI/SkillBaseCell.cs
+++ b/Main/System/SkillUI/SkillBaseCell.cs
@@ -71,7 +71,7 @@
{
if (cellContainer != null)
return;
-
+
var tmp = transform.Find("Container_SkillCell");
if (tmp != null)
{
@@ -88,6 +88,13 @@
cellContainer.transform.SetAsFirstSibling();
}
}
+
+ //缂╂斁鍒板拰鐖秗ect涓�鏍峰ぇ
+ var scale = 1f;
+ var rect = cellContainer.GetComponent<RectTransform>();
+ var parentRect = transform.GetComponent<RectTransform>();
+ scale = parentRect.sizeDelta.x / rect.sizeDelta.x;
+ cellContainer.transform.localScale = new Vector3(scale, scale, scale);
}
}
--
Gitblit v1.8.0