next pool function and button added