added slide def, fixed random range