def check_order_triggers(order, event):
    """
    Given an order and a trade event, return a tuple of
    (stop_reached, limit_reached).
    For market orders, will return (False, False).
    For stop orders, limit_reached will always be False.
    For limit orders, stop_reached will always be False.

    Orders that have been triggered already (price targets reached),
    the order's current values are returned.
    """
    if order.triggered:
        return (order.stop_reached, order.limit_reached)

    stop_reached = False
    limit_reached = False
    # if the stop price is reached, simply set stop_reached
    if order.stop is not None:
        if (order.direction * (event.price - order.stop) <= 0):
            # convert stop -> limit or market
            stop_reached = True

    # if the limit price is reached, we execute this order at
    # (event.price + simulated_impact)
    # we skip this order with a continue when the limit is not reached
    if order.limit is not None:
        # if limit conditions not met, then continue
        if (order.direction * (event.price - order.limit) <= 0):
            limit_reached = True

    return (stop_reached, limit_reached)