#property copyright "Copyright © forexeasystems.com" #property link "http://www.forexeasystems.com" #property indicator_chart_window #property indicator_buffers 2 #property indicator_color1 Gray #property indicator_color2 Green extern int Contract_Step = 21; extern int Precision = 5; extern int Shift_Bars = 1; int gi_88 = -1; double g_ibuf_92[]; double g_ibuf_96[]; int init() { IndicatorBuffers(2); SetIndexArrow(0, 159); SetIndexStyle(0, DRAW_ARROW, STYLE_SOLID, 1, Gray); SetIndexDrawBegin(0, -1); SetIndexBuffer(0, g_ibuf_92); SetIndexLabel(0, "Resistance"); SetIndexArrow(1, 159); SetIndexStyle(1, DRAW_ARROW, STYLE_SOLID, 1, Green); SetIndexDrawBegin(1, -1); SetIndexBuffer(1, g_ibuf_96); SetIndexLabel(1, "Support"); return (0); } int start() { double ld_0; int li_20; bool l_bool_24; double ld_28; double ld_8 = (Contract_Step + Precision) * Point; int li_16 = gi_88; if (li_16 <= 0) li_16 = Bars; while (li_16 >= 0) { li_20 = li_16 + Shift_Bars; ld_28 = High[li_20 + 2]; l_bool_24 = ld_28 > High[li_20 + 1] && ld_28 > High[li_20]; ld_0 = g_ibuf_92[li_16 + 1] - ld_28; if (l_bool_24 && ld_0 >= ld_8 || ld_0 < 0.0) g_ibuf_92[li_16] = ld_28 + Precision * Point; else g_ibuf_92[li_16] = g_ibuf_92[li_16 + 1]; ld_28 = Low[li_20 + 2]; l_bool_24 = ld_28 < Low[li_20 + 1] && ld_28 < Low[li_20]; ld_0 = ld_28 - (g_ibuf_96[li_16 + 1]); if (l_bool_24 && ld_0 >= ld_8 || ld_0 < 0.0) g_ibuf_96[li_16] = ld_28 - Precision * Point; else g_ibuf_96[li_16] = g_ibuf_96[li_16 + 1]; li_16--; } return (0); }