bug fixes and behavior shuffling