private void Start() { station = GameObject.FindGameObjectWithTag("Station").GetComponent <StationController>(); rb = GetComponent <Rigidbody>(); anim = new AstronautAnimController(GetComponentInChildren <Animator>()); oxygenSliderImg = oxygenSlider.transform.Find("Fill Area/Fill").GetComponent <Image>(); fuelSliderImg = fuelSlider.transform.Find("Fill Area/Fill").GetComponent <Image>(); PaintSliders(); }
private void Start() { station = transform.parent.GetComponentInParent <StationController>(); Fix(); timeToExplode = settingsList[settingId].maxTimeToExplode; materialProperty = new MaterialPropertyBlock(); matRenderer = GetComponent <Renderer>(); sliderImage = healthSlider.transform.Find("Fill Area/Fill").GetComponent <Image>(); Debug.Log(duration); }