public void OnTick() { if (_order.IsRunning && _order.IsOpen) { //_profitProtector.TryProtectProfit(); } else { _ea.OrderCompleted(); } // should trail and lock profit ? }
public void OnTick() { if (_order.IsRunning) { _ea.MoveToOrderRunningState(_order); } else if (!_order.IsValid) { CloseOrder(); _ea.OrderCompleted(); } }