推进度!

This commit is contained in:
SoulliesOfficial
2025-11-25 21:49:03 -05:00
parent f0c06f0337
commit ad4948207e
1068 changed files with 418853 additions and 1047 deletions

View File

@@ -0,0 +1,34 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace SpriteShadersUltimate.Demo
{
public class Demo_DisplayTitle : MonoBehaviour
{
public Transform target;
RectTransform rectTransform;
RectTransform rectParent;
void Start()
{
rectTransform = GetComponent<RectTransform>();
rectParent = transform.parent.GetComponent<RectTransform>();
}
void LateUpdate()
{
Vector3 screenPosition = RectTransformUtility.WorldToScreenPoint(Camera.main, target.position);
Vector2 rectPosition;
RectTransformUtility.ScreenPointToLocalPointInRectangle(rectParent, screenPosition, Camera.main, out rectPosition);
rectTransform.anchoredPosition = rectPosition;
transform.localScale = target.lossyScale;
}
}
}