// Start is called before the first frame update void Start() { rangeDif = clearRange.GetDifference(); blockMat = GetComponent <Renderer>().material; blockedColor = blockMat.GetColor("_Color"); //This transform is where we will be reading the distance from OverlayAdjuster overlay = null; if ((overlay = GetComponentInParent <OverlayAdjuster>()) != null) { distanceFrom = overlay.transform; } }