Files
2025-05-29 22:31:40 +03:00

32 lines
731 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using InfallibleCode;
public class PhotographChange : MonoBehaviour
{
public ExaminableItem examinableItem;
Animator _photographAnimator;
bool PhotographChanged;
private void Start()
{
_photographAnimator = GetComponent<Animator>();
examinableItem = GetComponentInParent<ExaminableItem>();
}
private void Update()
{
ChangePhotograph();
}
void ChangePhotograph()
{
if(examinableItem.examineItem.CurrenltyExaminingObj && !PhotographChanged)
{
_photographAnimator.SetBool("IsAppearing", true);
PhotographChanged = true;
}
}
}