using UnityEngine; namespace RR.Common.Behaviour { public class MessagePlaceholder : MonoBehaviour { private void Update() { // Используем childCount вместо GetComponentsInChildren — намного быстрее if (transform.childCount == 0) { Destroy(gameObject); } } } }