//+------------------------------------------------------------------+
//|                                                super-signals.mq4 |
//|                Copyright © 2006, Nick Bilak, beluck[AT]gmail.com |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2006, Nick Bilak"
#property link      "http://www.forex-tsd.com/"

#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 Red
#property indicator_color2 Aqua

int dist=24;
double b1[];
double b2[];

int init()  {
   SetIndexBuffer(0,b1); SetIndexStyle(0,DRAW_ARROW); SetIndexArrow(0,159); 
   SetIndexBuffer(1,b2); SetIndexStyle(1,DRAW_ARROW); SetIndexArrow(1,159); 
   return(0);
}
int start() {
   int counted_bars=IndicatorCounted();
   int i,limit,hhb,llb;

   if(counted_bars<0) return(-1);
   if(counted_bars>0) counted_bars--;
           limit=Bars-counted_bars;
           limit=MathMax(limit,dist);
   
   //
   //
   //
   //
   //
   
   for (i=limit;i>=0;i--)   
   {
      hhb = iHighest(NULL,0,MODE_HIGH,dist,i-dist/2);
      llb =  iLowest(NULL,0,MODE_LOW, dist,i-dist/2);
      b1[i] = EMPTY_VALUE;
      b2[i] = EMPTY_VALUE;
      if (i==hhb)
           b1[i] = High[i]+10*Point;
      else b1[i] = b1[i+1]; 
      
      if (i==llb)
           b2[i] = Low[i]-10*Point;
      else b2[i] = b2[i+1]; 
   }
   return(0);
}


