finally rewritten the chest logging system