OPEN-SOURCE SCRIPT
Updated Order Block Sniper v2

Indicator Logic:
Detects Break of Structure (BOS) — when the close breaks the previous swing high (for bullish) or swing low (for bearish).
Upon BOS, it identifies the Order Block — the last opposite candle before the breakout (bearish candle before bullish BOS, and vice versa).
Draws an OB zone (box) with:
Equilibrium line (50% level)
SL line
Three TP lines (1R, 2R, 3R)
Waits for mitigation — when price returns to the OB zone → generates an ENTRY signal.
A/B/C Grading:
A = Stop hunt + ultra high volume
B = Increased volume
C = Basic
What you see on the chart:
Zones labeled: BUY HUNT [A] RR 1:2.5 or SELL ZONE [C] RR 1:1.3
Dashed TP1 / TP2 / TP3 target lines
Dashed SL line
Upon mitigation: ENTRY A / ENTRY B / ENTRY C label + arrow
Optional FVG zones
Dashboard showing: Trend, Zone (Premium/Discount), Active OBs, Volume, Entries count
Clean zones labeled with A or B (max 3 zones displayed).
TP/SL lines are hidden until price retraces back into the zone.
When price returns to the zone: display ENTRY A 78.5 label + TP1 / TP2 / TP3 target lines with corresponding labels.
Detects Break of Structure (BOS) — when the close breaks the previous swing high (for bullish) or swing low (for bearish).
Upon BOS, it identifies the Order Block — the last opposite candle before the breakout (bearish candle before bullish BOS, and vice versa).
Draws an OB zone (box) with:
Equilibrium line (50% level)
SL line
Three TP lines (1R, 2R, 3R)
Waits for mitigation — when price returns to the OB zone → generates an ENTRY signal.
A/B/C Grading:
A = Stop hunt + ultra high volume
B = Increased volume
C = Basic
What you see on the chart:
Zones labeled: BUY HUNT [A] RR 1:2.5 or SELL ZONE [C] RR 1:1.3
Dashed TP1 / TP2 / TP3 target lines
Dashed SL line
Upon mitigation: ENTRY A / ENTRY B / ENTRY C label + arrow
Optional FVG zones
Dashboard showing: Trend, Zone (Premium/Discount), Active OBs, Volume, Entries count
Clean zones labeled with A or B (max 3 zones displayed).
TP/SL lines are hidden until price retraces back into the zone.
When price returns to the zone: display ENTRY A 78.5 label + TP1 / TP2 / TP3 target lines with corresponding labels.
Release Notes
bug fixedOpen-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.