betting functionaliy