Repopulate with the latest changes

my code is in the unitlogic method of the unitmanager class