Add generate obstacle condition in move_obstacle