added comments to functions and changed resource files dir