using System; using System.Collections; using System.Collections.Generic; using UnityEngine; [Serializable] public class FireFlowControl : MonoBehaviour { public bool CatchFire; public void GetFireFlowData(BoiloverData data) { data.name = gameObject.name; data.boxsize = GetComponent().size; data.bottomScale = transform.Find("BottomOil").transform.localScale; data.nowScale = transform.Find("BottomOil").GetComponent().ranyouScale; data.shapRadius = transform.Find("FireBottom").GetComponent().NowShape; data.catchFire = CatchFire; } public void SetFireFlowData(BoiloverData data) { GetComponent().size = data.boxsize; transform.Find("BottomOil").transform.localScale = data.bottomScale; transform.Find("BottomOil").GetComponent().ranyouScale = data.nowScale; transform.Find("FireBottom/fire (8)").GetComponent().NowShape = data.shapRadius; transform.Find("FireBottom").GetComponent().NowShape = data.shapRadius; CatchFire = data.catchFire; } }