CASE 
WHEN `action_type` = 'multiple' THEN 
    CASE 
        WHEN `action` = '1' THEN Bet 
        WHEN `action` = '3' THEN -amount 
        ELSE 0 
    END
ELSE 
CASE 
 WHEN `action` = '2' THEN Bet 
 WHEN `action` = '3' THEN -Bet 
ELSE 0 
END
END