added deal and calc_total