Refactored Stats counting to use enumeration and flat array instead