How to start a class properly