Added some major changes. added shutdonwn hook, removed depricated files.