setting drop height automatically