private void Start() { g = Mathf.Abs(Physics2D.gravity.y); line = gameObject.GetComponent <LineRenderer>(); line.enabled = false; fc = GetComponent <Flare_Counter>(); }
public void Refill() { Flare_Counter fc = arm.GetComponent<Flare_Counter>(); int flaresgiven = fc.maxflares - fc.flares; if(flaresAvailable < flaresgiven) { fc.flares += flaresAvailable; flaresAvailable = 0; } else { fc.flares += flaresgiven; flaresAvailable -= flaresgiven; } }
private void Start() { fc = GetComponent <Flare_Counter>(); }