Changed unit hierarchy and logic