OPEN-SOURCE SCRIPT
OSOK SafePad

OSOK SafePad is a lightweight price-level tool for marking a configurable safety buffer above and below the current reference price. It is designed for traders who want a clean visual guide for breakout, stop-entry, or event-driven execution plans without cluttering the historical chart.
Key features
How it works
Before the freeze time, SafePad tracks the latest chart price and displays the pad levels from the current candle. When freeze mode is enabled and the chart enters the configured freeze window, the indicator captures that candle’s open as the reference price and locks the pad levels from that point onward.
For example, with a 25-point pad, the Upper Pad is drawn 25 points above the reference price and the Lower Pad is drawn 25 points below it.
Take-profit and stop-loss guides
The optional TP and SL lines are derived from the configured dollar target, order size, and the symbol’s point value. These levels are visual planning aids for a hypothetical buy-stop at the Upper Pad and sell-stop at the Lower Pad.
Notes and limitations
Key features
- Plots an Upper Pad and Lower Pad around the reference price.
- Configurable pad size in points.
- Optional freeze mode to lock levels at the start of a chosen session window, defaulting to 8:30 New York time.
- Optional take-profit and stop-loss guide levels for both long and short stop-entry scenarios.
- TP and SL levels are calculated from account-currency targets using the symbol point value and order size.
- Lines extend to the right for easier monitoring without leaving historical marks as new bars print.
- Clean, low-saturation colour palette designed to work on both dark and light charts.
How it works
Before the freeze time, SafePad tracks the latest chart price and displays the pad levels from the current candle. When freeze mode is enabled and the chart enters the configured freeze window, the indicator captures that candle’s open as the reference price and locks the pad levels from that point onward.
For example, with a 25-point pad, the Upper Pad is drawn 25 points above the reference price and the Lower Pad is drawn 25 points below it.
Take-profit and stop-loss guides
The optional TP and SL lines are derived from the configured dollar target, order size, and the symbol’s point value. These levels are visual planning aids for a hypothetical buy-stop at the Upper Pad and sell-stop at the Lower Pad.
Notes and limitations
- This is a visual planning indicator, not an automated trading system.
- TP/SL calculations depend on TradingView’s syminfo.pointvalue; verify values for the instrument and broker feed you trade.
- No trading signals, alerts, or order execution are included.
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。