added pallet grow function and winning fix