This commit is contained in:
SoulliesOfficial
2025-10-23 00:49:44 -04:00
parent 9b1b5ca93f
commit 61a397dd4c
9846 changed files with 2618439 additions and 793547 deletions

View File

@@ -0,0 +1,23 @@
using UnityEngine;
using UnityEngine.UI;
namespace AllIn1VfxToolkit.Demo.Scripts
{
public class AllIn1ChangeAllChildTextFonts : MonoBehaviour
{
[SerializeField] private Font newFont;
[SerializeField] private bool changeFontOnStart;
private void Start()
{
if(changeFontOnStart) ChangeFonts();
}
[ContextMenu("ChangeFonts")]
private void ChangeFonts()
{
Text[] canvasTexts = GetComponentsInChildren<Text>();
for(int i = 0; i < canvasTexts.Length; i++) canvasTexts[i].font = newFont;
}
}
}