public override void Use(GameObject collector) { Score score = collector.GetComponent <Score>(); if (score != null) { score.AddEnergy((config as EnergyOrbCollectible).EnergyAmount); } }