A friend showed me how to create instances something like a year ago, but my style of handling them hasn't changed in a very long time. I would like to know if there is currently a better way of doing it.
Thats an implementation of the Singleton design pattern. It's still used, albeit you can do it 100 diff ways. The way I do it is very similar to that (as a prof developer). Just be aware that it's not thread-safe.
You can google "Singleton design pattern" and see other ways to implement it. Nothing wrong with that way though.