Theoretical Question about instances of Ball inside PinSetter.cs

In our PinSetter.cs, we Require the Pin component - [RequireComponent(typeof(Pin))] -, but we do not require the Ball component.
Willing to know a bit more of theory, I would like to understand how can we initiate an instance of the Ball class from within PinSetter.cs, as we do by assigning the variable private Ball ball;… “Ball” even becomes blue automatically, even though we never required/imported Ball.cs into PinSetter.cs.

Thanks anyone in advance :slight_smile:
Daniel

Privacy & Terms