Watch how to download trading robots for free
Find us on Telegram!
Join our fan page
Interesting script?
So post a link to it -
let others appraise it
You liked the script? Try it in the MetaTrader 5 terminal
Experts

RiskPilot Pro — Drag-to-Trade Risk Panel with Break-Even, Trailing and a Daily Loss Guard - expert for MetaTrader 5

ALI RAJPUT
Published by:
Rana Ali
Rana Ali
  • MQL5 Developer & Algorithmic Trading Specialist at  Freelance
  • Pakistan
  • 183
Hi, I'm Ali. 24 years old, trading for around 5 years, and developing MQL5/MQL4 tools. I mainly work on automating manual strategies, fixing broken EA logic, and building clean indicators. I care more about clean architecture and proper risk management than over-complicated code. Always down to talk
Views:
80
Published:
RiskPilotPro1.mq5 (24.24 KB) view
MQL5 Freelance Need a robot or indicator based on this code? Order it on Freelance Go to Freelance
RiskPilot Pro — Drag-to-Trade Risk Panel with Break-Even, Trailing and a Daily Loss GuardI built this after getting tired of     switching between a lot-size calculator, the chart, and the order ticket every single time I wanted to place a trade. RiskPilot Pro puts three lines directly on the chart — entry, stop loss, and take profit — and you just drag them where your analysis says they should go. The panel recalculates your lot size the moment you let go of the mouse.

Everything is based on a fixed percentage of your account balance, not a fixed lot size, so your risk stays consistent whether you're trading a 5-pip scalp or a 50-pip swing. It also handles cross pairs correctly — most free calculators quietly get this wrong on symbols like USDCHF or USDJPY because they assume your account currency matches the symbol's profit currency. This one asks the broker directly for the real conversion, so the numbers hold up on any pair.

What it does:
- Drag Entry/SL/TP lines directly on the chart, lot size updates live
- One click to open the trade with the size already calculated
- RESET button snaps the lines back to an ATR-based distance if you want a volatility-based stop instead of guessing
- Automatic break-even and trailing stop once a trade moves in your favor
- A daily loss limit and a max-drawdown guard — cross either one and it closes every position it opened and blocks new trades until the next day (useful if you're trading a prop-firm challenge with hard daily limits)
- A running total of how much you'd have at risk across all open positions if you took the trade you're previewing, so you don't stack more risk than you meant to

External variables:
InpRiskPercent — how much of your balance you're willing to lose on one trade.
InpRewardRatio — used to auto-place the take-profit line relative to your stop.
InpUseATRForReset / InpATRPeriod / InpATRMultiplier — control where RESET puts your stop.
InpEnableBreakEven / InpBreakEvenTriggerPips / InpBreakEvenOffsetPips — when and how far to lock in.
InpEnableTrailing / InpTrailingStartPips / InpTrailingStepPips — trailing behavior.
InpDailyLossLimitPercent / InpMaxDrawdownPercent — the two account guards.
InpMaxBasketRiskPercent — warns you when combined open risk gets too high.

Tested on a demo account across EURUSD and USDCHF — lot sizing, margin, and the currency conversion all checked out against manual calculation before I published this.
Extract information from the MT5 broker Extract information from the MT5 broker

This MT5 EA is a diagnostic tool that does not execute trades, but collects and displays technical specifications relating to the broker and the trading environment. The code is structured into four main blocks: Data Collection (CollectAll): Retrieves information on the account (leverage, currency), the symbol (digits, spread, swap, volumes, stop levels), latency (ping) and time zone (Server-UTC difference). Calculates the swap in real currency. Sampling (OnTick): Updates spread statistics (minimum, average, maximum) in real time. Output: Prints the data to the ‘Experts’ log, saves it to a CSV file and displays it on a graphical panel on the chart (UpdatePanel). Helper: Functions such as CalcSwapInCurrency and various *ToStr functions convert the broker’s raw numerical data into readable strings.

Contract Sizer: ladder, floor and a breaker that survives a deposit Contract Sizer: ladder, floor and a breaker that survives a deposit

Three position-sizing protections that do different things; confusing them is why so many accounts get wiped out: - ladder: one contract per X of balance, always applied as a CAP, even with manual lot sizing; - floor: below the minimum capital it does not trade; a new deposit is needed; - breaker: stops at X% below the peak, at any account size, and does not rearm by itself. What this library solves and almost none does: a deposit is not profit, and a withdrawal is not a loss. The breaker measures the drop against the balance peak. Untreated, a deposit made DURING a drawdown lifts balance and peak together, and the protection stops seeing the drop exactly when it would help. Here deposits and withdrawals shift the peak by the same amount. The peak is persisted to a file: a breaker that forgets the peak on a terminal restart is not a breaker. The demo simulates a deposit at the bottom of a drawdown. Run it with the deposit on and off and compare the "drop" column.

SMC Liquidity Sweep Scalper (Order Block EA with Live Win-Rate Tracking) SMC Liquidity Sweep Scalper (Order Block EA with Live Win-Rate Tracking)

A liquidity-sweep / order-block scalper with ATR-based sizing and a higher-timeframe trend filter. Every trade is tagged on the chart with the live historical win rate of that setup type — a running scorecard, not just boxes.

MACD Signals MACD Signals

Indicator edition for new platform.