Specifiche
I trade all sessions, so there should be no time restrictions.
MY TRADING STYLE (Important for EA Design)
• Manual XAUUSD trader
• I trade all sessions
• 1–3 trades per day
• 0.5% risk per trade
• SL/TP always attached
• Minimum 60–90 seconds hold time
• Market execution only
• One‑Click Trading enabled
• Fixed SL/TP in points (e.g., 200 SL, 500 TP)
The EA must support this workflow.
RULES THE EA MUST ENFORCE
1. Mandatory SL/TP at Entry
- Block any trade opened without both SL and TP
- If missing, auto‑attach SL/TP using inputs (SL_Points, TP_Points)
- If SL/TP cannot be attached, cancel the order
- Show message: “SL/TP required at entry.”
2. Minimum 60‑Second Hold Time
- When a trade opens, start a timer
- If I try to close before 60 seconds, block the closure
- Show message: “Minimum hold time not reached.”
- After 60 seconds, allow normal closure
- Must work for all symbols, but I mainly trade XAUUSD
3. Daily Gross Profit Cap
- Track rolling 24‑hour gross profit
- If gross profit ≥ $2,500, block new trades
- Show message: “Daily profit cap reached — trading disabled.”
- Do NOT close open trades
- Only block new ones
4. 0.5% XAUUSD Risk Model
The EA must calculate lot size based on:
- Account equity
- 0.5% risk
- SL distance in points
- XAUUSD tick value
Display on panel:
- Equity
- Risk amount ($)
- Calculated lot size
- SL distance
- TP distance
If I open a trade with a lot size higher than the calculated risk, show warning:
“Lot size exceeds 0.5% risk model.”
ON‑CHART COMPLIANCE DASHBOARD
Panel Title:
AM – Prop‑Firm Compliance Dashboard
Panel Sections:
A) Account & Risk
- Equity
- Risk per trade: 0.5%
- Risk amount ($)
- Calculated lot size
B) Rule Status
- SL/TP at Entry: ✔️/❌
- Minimum Hold Time: countdown or ✔️
- Daily Profit Cap: ✔️/Cap Reached
- Trading Allowed: ✔️/❌
C) Daily Profit Tracker
- Gross Profit (24h)
- Daily Cap: $2,500
- Remaining before cap
D) Trade Timer
If trade open:
- Ticket
- Open time
- Time open
- Time remaining
- Status: “Holding…” or “Allowed to Close”
If no trades:
- “No Active Trades”
E) Alerts
Non‑blocking alerts for:
- Missing SL/TP
- Early close attempt
- Daily cap reached
- Lot size too large
5. ON‑CHART COMPLIANCE DASHBOARD
Panel Title:
AM – Prop‑Firm Compliance Dashboard
Panel Sections:
A) Account & Risk
- Equity
- Risk per trade: 0.5%
- Risk amount ($)
- Calculated lot size
B) Rule Status
- SL/TP at Entry: ✔️/❌
- Minimum Hold Time: countdown or ✔️
- Daily Profit Cap: ✔️/Cap Reached
- Trading Allowed: ✔️/❌
C) Daily Profit Tracker
- Gross Profit (24h)
- Daily Cap: $2,500
- Remaining before cap
D) Trade Timer
If trade open:
- Ticket
- Open time
- Time open
- Time remaining
- Status: “Holding…” or “Allowed to Close”
If no trades:
- “No Active Trades”
E) Alerts
Non‑blocking alerts for:
- Missing SL/TP
- Early close attempt
- Daily cap reached
- Lot size too large
🔷 GENERAL REQUIREMENTS
- MT5 only
- Must not auto‑trade
- Must not auto‑close trades
- Must not interfere with SL/TP
- Must not freeze terminal
- Must include full source code (.mq5)
- Must be stable on XAUUSD volatility