Added constructor and initial functions for Unit