added state class as a foundation to animation