Fresh MQL5 code release – perfect for enhancing your MT4/MT5 strategies.


G7 FVG OB Confluence AutoTrader is an institutional-grade algorithmic trading system and quantitative trading utility developed for MetaTrader 5.
Reduce lag and improve accuracy with the NonLagMA Expert Advisor for MT4/MT5. Discover it.
Unlike conventional indicators that trade individual Fair Value Gaps or isolated Order Blocks, the G7 system requires strict physical confluence: a high-probability trade entry is only validated when an institutional Order Block (OB) and an imbalance Fair Value Gap (FVG) coincide at the exact same price structure.
Featuring a sleek obsidian glassmorphism HUD directly on your chart, the system provides full transparency into institutional liquidity dynamics, macro news forecasts, USD correlation alignment, and multi-factor AI confidence scoring.
====================================================================
KEY ARCHITECTURAL HIGHLIGHTS
====================================================================
1. DUAL-ENGINE SMC DETECTION & OVERLAP CONFLUENCE
• Scans M15 institutional Order Blocks identified by strong impulse displacement (> 1.6x ATR).
• Scans 3-bar Fair Value Gaps (FVG) where price imbalances have not yet been mitigated.
• Matches overlapping zones: When both an OB and an FVG align, the system draws a highlighted Golden Confluence Zone on the chart.
2. 6-CARD AI CONFIDENCE RADAR
The on-chart HUD computes a real-time confluence score (0% to 100%):
• Card 1: NY Zone Macro News — Detects upcoming high-impact USD events and enforces a news volatility filter.
• Card 2: USD Correlation (DXY) — Cross-analyzes US Dollar index alignment against the traded asset.
• Card 3: FVG / Imbalance — Displays active bullish/bearish imbalances and timeframes scanned.
• Card 4: SMC Liquidity Sweep — Evaluates Buy-Side (BSL) and Sell-Side (SSL) liquidity pool grabs.
• Card 5: ICT Order Block — Monitors institutional supply/demand order blocks.
• Card 6: Overall AI Confidence — Computes weighted multi-factor confidence. Automatically cap-locks score during conflicting market structure.
3. INTERACTIVE 1-CLICK TRADER HUD
Execute and manage trades directly from the chart:
• Interactive Lot Sizer: Increase or decrease lot size directly on the chart (+ / -).
• Dynamic SL & TP Controls: Adjust protective Stop Loss and Take Profit in pips without opening EA properties.
• Auto-Execute Toggle: Enable or disable autonomous entry on confluence detection with one click.
• 1-Click Action Buttons: Instant [ BUY ], [ SELL ], [ BREAKEVEN ALL ], and emergency [ CLOSE ALL ].
4. PROP FIRM EQUITY PROTECTOR (FTMO / FUNDED ACCOUNTS)
• Daily Loss Circuit Breaker: Automatically terminates all open positions and locks trading if daily equity drops past your threshold (default: -4.0%).
• Daily Profit Target Lock: Secures profits once daily goal (default: +8.0%) is reached.
• Dynamic Breakeven Shield & Trailing Stop: Moves SL to entry (+ lock pips) once trade moves into profit, with trailing stop options.
• Maximum Spread Filter: Rejects execution during rollover or high-spread news spikes.
====================================================================
INPUT PARAMETERS GUIDE
====================================================================
[ SMC ANALYSIS SETTINGS ]
• InpSmcTimeframe: Timeframe for SMC zone scanning (Default: PERIOD_M15).
• InpLookbackBars: Depth of bar history analyzed (Default: 150 bars).
• InpMinFvgPips: Minimum size in pips required to validate an FVG imbalance (Default: 3.0 pips).
• InpObDisplacementMult: ATR displacement impulse required for Order Blocks (Default: 1.6).
• InpRemoveMitigated: Automatically cleans mitigated zones from chart (Default: true).
[ CONFLUENCE & EXECUTION SETTINGS ]
• InpRequireOverlap: Requires physical overlap between OB and FVG (Default: true).
• InpOverlapTolerancePips: Proximity tolerance for zone matching (Default: 2.0 pips).
• InpTriggerMode: Execution trigger mode (Zone Touch / Mitigation / Bar Close).
• InpMinConfidenceToTrade: Minimum AI confidence percentage required to execute (Default: 70%).
• InpDefaultAutoTrade: Enable automatic execution on valid signal (Default: true).
[ RISK & TRADING PREFERENCES ]
• InpDefaultLot: Initial base lot size (Default: 0.01).
• InpDefaultSL_Pips: Protective Stop Loss in pips (Default: 25.0 pips).
• InpDefaultTP_Pips: Target Take Profit in pips (Default: 50.0 pips).
• InpEnableAutoBE: Automatically shifts SL to breakeven once in profit (Default: true).
• InpBETriggerPips: Profit distance in pips to trigger breakeven (Default: 15.0 pips).
• InpBELockPips: Guaranteed profit locked above entry price (Default: 3.0 pips).
• InpEnableTrailing: Activates dynamic trailing stop (Default: true).
[ PROP FIRM SHIELD & UI ]
• InpEnablePropGuard: Enables daily drawdown circuit breaker (Default: true).
• InpMaxDailyLossPct: Maximum daily loss percentage before emergency shutdown (Default: 4.0%).
• InpMaxDailyProfitPct: Maximum daily profit goal lock (Default: 8.0%).
• InpMaxSpreadAllowed: Maximum allowed spread in pips (Default: 4.0 pips).
• InpApplyChartTheme: Automatically applies clean Gold Bull / Red Bear luxury chart styling (Default: true).
• InpShowWatermark: Renders subtle G7 institutional background watermark (Default: true).
====================================================================
RECOMMENDED SETUP & BEST PRACTICES
====================================================================
• Recommended Asset: XAUUSD (Gold Spot), EURUSD, GBPUSD, US30, NAS100.
• Recommended Timeframe: Attach to M15 or M5 chart.
• Account Types: Compatible with both Hedging and Netting accounts, Prop Firm challenge phases, and standard broker accounts.
• Requirements: Enable "Allow Algo Trading" in your MetaTrader 5 terminal.
Build better strategies with RobotFX professional tools – check them out.
79285