private void Gain(GameObject collectableObject) { ICollectable collectable = collectableObject.GetComponent <ICollectable>(); collectable.Gain(gameObject); }