Redone the events and checks to make it efficient.