That feature is actually in the script, however, what usually happens is that the bets keep doubling/tripling until you get the message "you can't bet more than you have".
At that time, you can, if you want, take some meat out of your closet & keep raising the stakes, or just eat the loss and...