added betting tracking and logic