🔢 Omega Pattern Sniper – Easy-to-Read Inputs Guide

🔢 Installation
Attach the Indicator
🔹 Step 1 — Copy the indicator file to File → Open Data Folder → MQL5 → Indicators.
🔹 Step 2 — Restart MetaTrader 5 or right-click Indicators in Navigator and select Refresh.
🔹 Step 3 — Drag Omega Pattern Sniper from Navigator onto the chart.
🔹 Step 4 — Open the Common tab and enable Allow DLL imports. This is required for licence verification, Telegram alerts and the WEB / TELEGRAM buttons.
🔹 Step 5 — Open the Inputs tab, enter the licence key and configure the required settings.
🔹 Save / Load Settings — Use the Save / Load buttons on the Inputs tab to store configurations as .set files.
🔢 Calculation Range
🔹 Bars to calculate (0 = all) [MaxBarsCalc] — Default: 3000 — Controls how many recent bars are processed when the indicator loads. 0 calculates the entire history. Recommended: 3000; use 5000–10000 for more statistics on low timeframes.
🔹 Calculation Window — MaxBarsCalc limits how far back pivots are calculated.
🔹 Pattern History Window — MaxHistory controls how far back patterns are detected and counted.
🔹 Effective History — The actual working window is the smaller of MaxBarsCalc and MaxHistory. Keeping both values equal is recommended unless there is a specific reason to change them.
🔢 Licence
🔹 Licence key from eafxstore.com [InpLicenseKey] — Default: (empty) — The licence key received after purchase. The key is automatically trimmed and converted to uppercase. Recommended: enter the exact licence key provided.
🔹 Allow DLL imports — Must be enabled because the licence is verified online.
🔹 Internet Connection — Required for online licence verification.
🔹 Licence Verification — The key is checked together with the trading account number at startup, every 30 minutes and after switching trading accounts.
🔹 Grace Period — If the licence server cannot be reached after a recent successful verification, the indicator normally runs for up to 72 hours.
Common Licence Messages
🔹 “Please enter your licence key.” — The licence field is empty.
🔹 “Please tick Allow DLL imports…” — Enable DLL imports in the indicator's Common tab.
🔹 “Cannot reach the licence server.” — Check the internet connection or firewall and make sure a valid grace period is available.
🔹 “System clock check failed…” — Check that the computer date and time have not been set backwards.
🔹 Other server message — The message may indicate an expired key or account limitation. Contact support when necessary.
🔢 Pivots & Size
These settings control swing detection and the minimum size required for a pattern. They have a major effect on the number of patterns displayed.
🔹 pivot length [PivLen] — Default: 6 — Number of candles on each side required to confirm a swing high or low. Higher values find larger swings; lower values find smaller swings. Recommended: 4 scalping, 6 intraday, 8 swing.
🔹 Pivot Confirmation — A pivot is confirmed PivLen bars after it forms.
🔹 min pattern height (xATR) [MinHeightATR] — Default: 2.0 — Minimum pattern height measured in ATR multiples. Patterns smaller than this are ignored. It also defines the minimum depth of a Cup. Recommended: 1.5–2.5.
🔹 equality tolerance [EqualTolATR] — Default: 0.6 — Defines how close two prices must be in ATR terms to be considered equal for Double Tops, Double Bottoms and Cup rims. Recommended: 0.5–0.8; increase for volatile markets such as gold and crypto.
🔹 ATR [AtrLen] — Default: 14 — ATR period used by ATR-based settings and label spacing. Recommended: 14.
🔹 bars analysed [MaxHistory] — Default: 3000 — Number of recent closed bars used for pattern detection, tracking and statistics. Recommended: same value as MaxBarsCalc.
🔢 Enable Patterns
Pattern Switches
Each switch enables or disables one pattern family. Disabled patterns are not detected, drawn, alerted or included in statistics.
🔹 head & shoulders [UseHS] — Default: true — Detects bearish Head & Shoulders and bullish Inverse Head & Shoulders.
🔹 double top & bottom [UseDouble] — Default: true — Detects bearish Double Tops and bullish Double Bottoms.
🔹 Tam giac (3 loai) / triangles [UseTriangle] — Default: true — Detects Ascending, Descending and Symmetrical Triangles.
🔹 Nem / wedges [UseWedge] — Default: true — Detects Rising Wedges and Falling Wedges.
🔹 Kenh / channels [UseChannel] — Default: true — Detects parallel price channels, with direction determined by the breakout.
🔹 flags / Co [UseFlag] — Default: true — Detects Bull Flags and Bear Flags.
🔹 Cup & Handle [UseCup] — Default: true — Detects bullish Cup & Handle patterns.
🔹 Pattern Statistics Tip — Review the Statistics section of the dashboard after several days. Pattern families showing a low hit rate on a particular symbol can be disabled to reduce noise.
🔢 Pattern Shape Parameters
🔹 flat slope [SlopeFlatATR] — Default: 0.03 — ATR-per-bar threshold used to classify lines as flat, rising or falling. It also controls the tolerance for parallel channel lines. Recommended: 0.02–0.05.
🔹 flag pole [PoleATR] — Default: 3.0 — Minimum flag-pole size in ATR multiples. The flag consolidation must remain within 50% of the pole and retrace no more than about 62%. Recommended: 2.5–4.0.
🔹 pole bars [PoleBars] — Default: 15 — Maximum number of candles used to measure the flag pole. Recommended: 10–20.
🔹 flag bars [FlagMaxBars] — Default: 30 — Maximum age of a flag pattern. The pole top or bottom must be within this number of bars from the current candle. Recommended: 20–40.
🔹 Cup cup min bars [CupMinBars] — Default: 15 — Minimum width of the Cup between its two rims. Helps filter out sharp V-shaped formations. Recommended: 15–30 on intraday charts; larger on low timeframes.
🔢 Pattern States
These settings control the life cycle of a pattern after detection: breakout waiting time, target, failure level and target/failure time limit.
🔹 forming expiry [ExpireBars] — Default: 120 — Number of bars a pattern can wait for a breakout before it becomes Expired and is removed. Recommended: 80 scalping, 120 intraday, 150 swing.
🔹 bars to reach target [TargetBars] — Default: 150 — Number of bars allowed after breakout to reach the target or failure level. If neither is reached, the pattern becomes Timed out and is not counted as a hit or failure. Recommended: 100–200.
🔹 failure level [FailRatio] — Default: 0.5 — Controls the distance of the failure level from the breakout line based on pattern height. Recommended: 0.5; 0.3 gives less room, while 0.7 gives more room.
🔹 target ratio (1.0 = measured move) [TargetRatio] — Default: 1.0 — Sets the target distance based on pattern height. 1.0 represents the classic measured move. Recommended: 0.8 conservative, 1.0 standard, 1.272–1.618 extended.
Simple Target Example
🔹 Double Top Example — Top = 1.1050, neckline = 1.1000, pattern height = 50 pips.
🔹 Bearish Breakout — A candle closes below 1.1000.
🔹 Target — 1.1000 − 50 × 1.0 = 1.0950.
🔹 Failure Level — 1.1000 + 50 × 0.5 = 1.1025.
🔹 Dashboard Risk-to-Reward — Measured from the breakout candle close to the target and failure levels.
🔹 Important — Changing TargetRatio, FailRatio or related state settings also changes the statistics because these values define what counts as a hit or failure. Compare different settings over the same historical period.
🔢 Display
🔹 Giao dien chart / Chart theme [Theme] — Default: Dark — Controls the chart colour theme: None, Dark, Midnight or Light. The theme changes background, grid, candles, bid/ask and chart style. Recommended: Dark or Midnight for the dashboard; use None with a custom template.
🔹 Restore colors on remove [RestoreTheme] — Default: true — Restores the original chart colours when the indicator is removed. Recommended: true.
🔹 target lines [ShowTargets] — Default: true — Displays the gold TP line and grey failure line after a breakout. Recommended: true; disable for a cleaner chart.
🔹 keep failed patterns [ShowFailed] — Default: false — Keeps failed patterns on the chart in grey when enabled. Recommended: false for a clean chart; true for historical review.
🔹 font size [LabelFont] — Default: 8 — Controls the font size of pattern labels and TP price labels. Recommended: 8–10.
🔹 max drawn [MaxDraw] — Default: 8 — Maximum number of patterns displayed on the chart, starting with the most recent. Expired patterns are never drawn. Recommended: 5–10.
🔹 Important — MaxDraw only controls the number of displayed patterns. It does not change pattern detection, alerts or statistics.
🔢 Dashboard
🔹 Show dashboard [ShowDash] — Default: true — Shows or hides the dashboard. Pattern detection and alerts continue even when the dashboard is hidden. Recommended: true.
🔹 Anchor right (false = left) [DashRight] — Default: false — Places the dashboard on the right side instead of the left. Recommended: true if the left side of the chart needs to remain clear.
🔹 X offset (px) [DashX] — Default: 10 — Horizontal distance from the selected chart edge. Recommended: 10–20.
🔹 Y offset (px) [DashY] — Default: 28 — Vertical distance from the top of the chart. 28 leaves room for the one-click trading panel or licence message.
🔹 Panel scale [DashScale] — Default: 1.5 — Controls the overall dashboard size. The panel automatically reduces to fit chart height and 45% of chart width. Recommended: 1.0–1.2 on Full HD and 1.5–2.0 on 2K/4K screens.
🔹 Font adjust (0.8 - 1.3) [DashFontAdj] — Default: 1.0 — Adjusts dashboard text size without changing the panel layout. Recommended: 0.9–1.1.
🔹 minimum scale [DashMinScale] — Default: 1.0 — Minimum scale allowed when the dashboard automatically fits a small chart. The internal lower limit is 0.55. Recommended: 1.0; use 0.7 if the dashboard is cut off on small charts.
Moving the Dashboard
🔹 Drag Dashboard — Drag the dashboard by its header to move it.
🔹 Saved Position — A manually moved dashboard position is saved for that chart and overrides DashX and DashY.
🔹 Reset Position — Press F3, open Global Variables and delete variables beginning with OMPATT_DASH, then re-attach the indicator.
🔢 Alerts
Alerts are sent only for newly closed live candles.
🔹 Popup [AlertPopup] — Default: true — Displays the standard MT5 alert window with sound. Recommended: true when monitoring the chart directly.
🔹 Push notification (MetaQuotes ID) [AlertPush] — Default: false — Sends alerts to the MT5 mobile application. Setup: enter the MetaQuotes ID under Tools → Options → Notifications.
🔹 Am thanh / Sound [AlertSoundOn] — Default: false — Plays the selected sound file when an alert occurs. Useful when popups are disabled.
🔹 AlertSoundFile [AlertSoundFile] — Default: alert.wav — Specifies the sound file located in the terminal's Sounds folder. Any .wav file in that folder can be used.
🔹 new forming pattern [AlertForming] — Default: false — Alerts when a new pattern is detected before breakout. Recommended: false for most traders; enable for early preparation on higher timeframes.
🔹 Pha vo / breakout [AlertBreakout] — Default: true — Alerts when a pattern breaks out and includes price, target and failure information. Recommended: true.
🔹 target or failure [AlertResult] — Default: true — Alerts when a pattern reaches its target or failure level. Recommended: true for position management.
🔢 Telegram
🔹 Gui Telegram / Send to Telegram (Allow DLL imports) [TgEnable] — Default: false — Sends alerts to Telegram as formatted messages containing symbol, timeframe, event, prices and time. Recommended: true after Telegram is configured.
🔹 Bot token (tu @BotFather) [TgToken] — Default: (empty) — Telegram bot API token. Keep the token private.
🔹 Chat ID [TgChatID] — Default: (empty) — Identifies the Telegram chat, group or channel that receives messages.
🔹 Group Chat ID — Group IDs start with -.
🔹 Channel Chat ID — Channel IDs usually start with -100.
Telegram Setup
🔹 Step 1 — Open @BotFather in Telegram, send /newbot and follow the instructions.
🔹 Step 2 — Copy the bot token into TgToken.
🔹 Step 3 — Open the bot chat and press Start, or add the bot to a group/channel as an administrator.
🔹 Step 4 — Obtain the Chat ID using a suitable Telegram method and enter it into TgChatID.
🔹 Step 5 — Set TgEnable = true and make sure Allow DLL imports is enabled.
🔹 Step 6 — Click the gold TEST TG button in the dashboard footer.
🔹 Troubleshooting — If the test fails, check the Experts tab for the reported reason.
🔢 About
🔹 Website [AboutWeb] — Default: https://eafxstore.com — Website opened by the WEB button on the dashboard. Recommended: leave as is.
🔹 Support [AboutTelegram] — Default: https://t.me/eafxstore6789 — Telegram support page opened by the TELEGRAM button. Recommended: leave as is.
🔢 Quick Setup Presets
Parameters not listed below keep their default values.
⚙️ Scalping — M5 to M15
🔹 PivLen — 4
🔹 MinHeightATR — 1.5
🔹 EqualTolATR — 0.5
🔹 ExpireBars — 80
🔹 TargetBars — 100
🔹 TargetRatio — 0.8
🔹 FailRatio — 0.5
🔹 AlertForming — false
⚙️ Intraday — M30 to H1
🔹 PivLen — 6
🔹 MinHeightATR — 2.0
🔹 EqualTolATR — 0.6
🔹 ExpireBars — 120
🔹 TargetBars — 150
🔹 TargetRatio — 1.0
🔹 FailRatio — 0.5
🔹 AlertForming — false
⚙️ Swing — H4 to D1
🔹 PivLen — 8
🔹 MinHeightATR — 2.5
🔹 EqualTolATR — 0.7
🔹 ExpireBars — 150
🔹 TargetBars — 200
🔹 TargetRatio — 1.0
🔹 FailRatio — 0.5
🔹 AlertForming — true
⚙️ Volatile Markets — Gold / Crypto
🔹 PivLen — 6–8
🔹 MinHeightATR — 2.5
🔹 EqualTolATR — 0.8
🔹 ExpireBars — 120
🔹 TargetBars — 150
🔹 TargetRatio — 0.8
🔹 FailRatio — 0.6
🔹 AlertForming — false
🔢 Simple Pattern Detection Logic
🔹 Step 1 — Swing Detection — PivLen identifies important swing highs and lows.
🔹 Step 2 — Pattern Size Check — MinHeightATR filters out patterns that are too small relative to market volatility.
🔹 Step 3 — Pattern Matching — The enabled pattern families are checked against their specific structural conditions.
🔹 Step 4 — Equality Check — EqualTolATR controls how close important price points must be for patterns such as Double Tops, Double Bottoms and Cups.
🔹 Step 5 — Pattern Formation — A detected pattern remains active while waiting for a breakout.
🔹 Step 6 — Forming Expiry — If no breakout occurs within ExpireBars, the pattern becomes Expired.
🔹 Step 7 — Breakout — When the breakout condition occurs, the indicator calculates the target and failure level.
🔹 Step 8 — Target Calculation — The target uses the pattern height multiplied by TargetRatio.
🔹 Step 9 — Failure Calculation — The failure level is determined using FailRatio.
🔹 Step 10 — Result Tracking — The pattern is tracked for TargetBars to determine whether it reaches the target or failure level.
🔢 Recommended Starting Settings
⚙️ Balanced Intraday Setup
🔹 PivLen — 6
🔹 MinHeightATR — 2.0
🔹 EqualTolATR — 0.6
🔹 ATR — 14
🔹 MaxHistory — 3000
🔹 TargetRatio — 1.0
🔹 FailRatio — 0.5
🔹 TargetBars — 150
🔹 ExpireBars — 120
🔹 ShowTargets — true
🔹 ShowFailed — false
🔹 AlertBreakout — true
🔹 AlertResult — true
This configuration follows the standard intraday preset from the source guide.
⚙️ Cleaner Chart / Fewer Patterns
🔹 PivLen — Increase toward 8
🔹 MinHeightATR — Increase toward 2.5
🔹 MaxDraw — Reduce toward 5
🔹 Disable weak pattern families — Turn off pattern switches that produce excessive noise.
⚙️ More Active Pattern Detection
🔹 PivLen — Reduce toward 4
🔹 MinHeightATR — Reduce toward 1.5
🔹 EqualTolATR — Keep within the recommended range.
🔹 Pattern switches — Enable the required pattern families.
🔢 Troubleshooting
🔹 Nothing is drawn and a licence message appears — Check the licence key, DLL permission, internet connection and licence status.
🔹 No patterns appear — Lower PivLen or MinHeightATR, make sure the pattern switches are enabled and confirm that enough history is loaded.
🔹 Too many patterns — Increase PivLen or MinHeightATR, reduce MaxDraw and disable weaker pattern families.
🔹 Dashboard too large or cut off — Lower DashScale or DashMinScale, or drag the dashboard to a clearer area.
🔹 Chart colours changed — Check the Theme setting. Select None to keep custom colours, or remove the indicator to restore the original theme.
🔹 Telegram does not work — Check TgToken, TgChatID, DLL permission and that the bot was started. Use TEST TG and check the Experts tab.
🔹 Statistics show “-” — There are not enough resolved patterns yet. Increase MaxBarsCalc / MaxHistory or allow more historical patterns to accumulate.
🔢 Quick Summary
🔹 For Scalping — Start with PivLen 4, MinHeightATR 1.5, TargetRatio 0.8 and ExpireBars 80.
🔹 For Intraday — Start with PivLen 6, MinHeightATR 2.0, TargetRatio 1.0 and ExpireBars 120.
🔹 For Swing Trading — Start with PivLen 8, MinHeightATR 2.5, TargetRatio 1.0 and ExpireBars 150.
🔹 For Gold / Crypto — Use a higher EqualTolATR, with the source preset using 0.8.
🔹 For Cleaner Signals — Increase pivot length and minimum pattern height.
🔹 For More Patterns — Reduce pivot length and minimum pattern height.
🔹 For Breakout Monitoring — Keep AlertBreakout = true.
🔹 For Result Monitoring — Keep AlertResult = true.
🔹 For Telegram Alerts — Configure TgToken and TgChatID, enable TgEnable and allow DLL imports.








