Editing Unity variables – Encapsulation & [SerializeField]

Link to Article: Editing Unity variables - Encapsulation & [SerializeField]

I wrote up a quick post about Unity & Encapsulation. I’ve been a big proponent of using private fields only and always avoiding public fields, but I’ve had countless people ask for a real explanation of why.

Hopefully this article provides a good enough argument to convert readers and helps them in future projects.

1 Like

I also blogged about that in the past: http://www.tallior.com/unity-encapsulate-your-fields/

1 Like