FantasyAsset/Assets/Scripts/EnableOnAwake.cs
naumanbutt0000 587a78ef61 iceTemple
added IceTempleScene in FantastAssests
2025-09-23 23:10:39 +05:00

26 lines
562 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace LegendaryCavesAndDungeons
{
public class EnableOnAwake : MonoBehaviour
{
public GameObject EnableObject;
// Update is called once per frame
void Awake()
{
EnableObject.SetActive( false );
StartCoroutine( ExampleCoroutine() );
}
private IEnumerator ExampleCoroutine()
{
yield return new WaitForSeconds( 2 );
EnableObject.SetActive( true );
}
}
}