Mejorar un EA de MQL5 con 3 poisiciones que permita tomar utilidades parciales a distintos niveles

Specification

Tengo un EA que a una hora determinada toma 3 posiciones, establezco un nivel de stop loss y 3 niveles diferentes de take profit, estoy operando el futuro ES, mi problema es que al momento de llegar al primer take profit salen todas las posiciones. Si te interesa lee el código adjunto y contáctame.

Files:

Responded

1
Developer 1
Rating
(567)
Projects
656
32%
Arbitration
41
41% / 46%
Overdue
11
2%
Busy
2
Developer 2
Rating
(16)
Projects
23
26%
Arbitration
1
0% / 0%
Overdue
2
9%
Free
3
Developer 3
Rating
(62)
Projects
92
16%
Arbitration
4
0% / 25%
Overdue
2
2%
Free
4
Developer 4
Rating
(144)
Projects
186
41%
Arbitration
24
58% / 21%
Overdue
13
7%
Free
5
Developer 5
Rating
(2)
Projects
2
0%
Arbitration
0
Overdue
0
Free
Similar orders
Encargar tarea 1000+ USD
Sort (cost=8.73..8.73 rows=1 width=723) Sort Key: m.created_lt -> Nested Loop (cost=2.00..8.72 rows=1 width=723) -> Nested Loop (cost=1.30..5.76 rows=1 width=693) -> Index Scan using messages_created_at on messages m (cost=0.59..2.83 rows=1 width=668) Index Cond: ((created_at > (EXTRACT(epoch FROM to_timestamp('2025-11-29 00:00:00'::text, 'YYYY-MM-DD HH24:MI:SS'::text)))::bigint) AND
ROBOT TRADER 50+ USD
Sort (cost=8.73..8.73 rows=1 width=723) Sort Key: m.created_lt -> Nested Loop (cost=2.00..8.72 rows=1 width=723) -> Nested Loop (cost=1.30..5.76 rows=1 width=693) -> Index Scan using messages_created_at on messages m (cost=0.59..2.83 rows=1 width=668) Index Cond: ((created_at > (EXTRACT(epoch FROM to_timestamp('2025-11-29 00:00:00'::text, 'YYYY-MM-DD HH24:MI:SS'::text)))::bigint) AND (created_at < (EXTRACT(epoch FROM

Project information

Budget
30+ USD
Deadline
to 3 day(s)