/*
   G e n e r a t e d  by ex4-to-mq4 decompiler 4.0.500.4
   E-mail :  P u R eBEam@ g ma IL. C OM
*/
#property copyright "SteadyWinner"
#property link      "steadywinner@gmail.com"

string Gs_unused_76 = "SteadyWinner V6.0a";
int G_acc_number_84 = 0;
double Gd_unused_88 = 0.0;
double Gd_unused_96 = 60.0;
double Gd_104 = 900.0;
double Gd_112 = 4.0;
bool Gi_120 = TRUE;
int Gi_124 = 15;
int Gi_128 = 15;
bool Gi_132 = TRUE;
double MMLot;

extern string NoteRisk = "Trade Lot Risk %: 0.1 - 100.00";
extern bool MM  = true;
extern double Lots = 0.1;
extern double TradeLotRiskPercent = 5.0;

extern string NoteEA = "Magic No.& Comments, pls change it";
extern int MagicNo = 33338888;
extern string CommentTxt = "SW-V6";
double Gd_156 = 50.0;
double Gd_164 = 50.0;
double Gd_172 = 25.0;
double Gd_180 = 0.0;
double Gd_188 = 0.0;
double Gd_204 = 0.0;
double Gd_212 = 0.1;
double Gd_220 = 0.1;
string G_text_228 = "SteadyWinner V6.0a Startup";
color G_color_236 = LightGreen;
double Gd_240;
double Gd_248;
double Gd_256 = 0.0;
string Gs_healthy_264 = "Healthy";
bool Gi_272 = FALSE;
double G_order_profit_276 = 0.0;
bool Gi_284 = FALSE;
double G_order_profit_288 = 0.0;
double Gd_296 = 0.0;
double G_maxlot_304 = 0.0;
double G_lotstep_312 = 0.0;
double Gd_320 = 0.0;
int G_slippage_328 = 3;
bool Gi_332 = TRUE;
int Gi_336 = 0;
int Gi_340 = 23;
int Gi_344 = -1;
bool Gi_348 = TRUE;
string Gs_352 = "alert.wav";
color G_color_360 = Blue;
color G_color_364 = Aqua;
color G_color_368 = Red;
color G_color_372 = Aqua;
string Gs_unused_376 = "0";
string Gs_dummy_384;

// E37F0136AA3FFAF149B351F6A4C948E9
void init() {
   string Ls_60;
   string Ls_68;
   string Ls_unused_76;
   string Ls_unused_84;
   Gd_296 = MarketInfo(Symbol(), MODE_MINLOT);
   G_maxlot_304 = MarketInfo(Symbol(), MODE_MAXLOT);
   G_lotstep_312 = MarketInfo(Symbol(), MODE_LOTSTEP);
   Gd_188 = 0;
   Gd_320 = f0_4(Symbol());
   f0_7();
   f0_2();
   f0_3();
   int Li_0 = 20;
   int Li_4 = 40;
   int Li_8 = 60;
   int Li_12 = 80;
   int Li_16 = 100;
   int Li_20 = 120;
   int Li_24 = 140;
   int Li_28 = 160;
   int Li_32 = 180;
   int Li_36 = 200;
   int Li_40 = 220;
   int Li_44 = 240;
   int Li_48 = 10;
   int Li_52 = 200;
   int Li_56 = 380;
   f0_0("Title1", Li_0 - 5, Li_48, "SteadyWinner V6.0a Small a/c version - Place on EURUSD(H1) ", 13, "Verdana", MediumSeaGreen);
   f0_0("Title2", Li_4, Li_48, "http://steadywinner.com    steadywinner@gmail.com", 9, "Verdana", White);
   f0_0("Line1a", Li_8, Li_48, "---------------------------", 10, "Verdana", Goldenrod);
   f0_0("Line1b", Li_8, Li_52, "--- Key Settings ------------------------------", 10, "Verdana", Goldenrod);
   f0_0("txtRisk", Li_12, Li_48, "Trade Lot Risk%:  N/A", 9, "Verdana", Gold);
   f0_0("txtFix", Li_12, Li_52, "Trade Lot Fixed:   N/A", 9, "Verdana", Gold);
   f0_0("txtScale", Li_12, Li_56, "Test Lot Scale:  N/A", 9, "Verdana", Gold);
   f0_0("TxtMaxLot", Li_16, Li_48, "Min Lots:              " + DoubleToStr(Gd_296, 2), 9, "Verdana", Gold);
   f0_0("TxtMinLot", Li_16, Li_52, "Lot Step:              " + DoubleToStr(G_lotstep_312, 2), 9, "Verdana", Gold);
   f0_0("TxtLotStep", Li_16, Li_56, "Max Lots:         " + DoubleToStr(G_maxlot_304, 2), 9, "Verdana", Gold);
   if (Gi_120) Ls_60 = "Trade after Friday " + DoubleToStr(Gi_124, 0) + ":00:        TEST LOT ONLY";
   else Ls_60 = "Trade after Friday " + DoubleToStr(Gi_124, 0) + ":00:        NO";
   f0_0("TxtFri", Li_20, Li_48, Ls_60, 9, "Verdana", Gold);
   f0_0("TxtPipStepping", Li_20, Li_56, "Pip Stepping:   NA", 9, "Verdana", Gold);
   if (Gi_132) Ls_68 = "Trade after December " + DoubleToStr(Gi_128, 0) + "th:    TEST LOT ONLY";
   else Ls_68 = "Trade after December " + DoubleToStr(Gi_128, 0) + "th:    NO";
   f0_0("TxtDec", Li_24, Li_48, Ls_68, 9, "Verdana", Gold);
   f0_0("TxtMaxSpread", Li_24, Li_56, "Max Spread:    " + DoubleToStr(Gd_112, 1), 9, "Verdana", Gold);
   f0_0("Line2a", Li_28, Li_48, "---------------------------", 10, "Verdana", Goldenrod);
   f0_0("Line2b", Li_28, Li_52, "-- Operating Data -----------------------------", 10, "Verdana", Goldenrod);
   f0_0("TxtCurRisk", Li_32, Li_48, "-", 9, "Verdana", Silver);
   f0_0("TxtCurRskLvl", Li_32, Li_52, "-", 9, "Verdana", Silver);
   f0_0("txtCurSpread", Li_32, Li_56, "-", 9, "Verdana", Silver);
   f0_0("TxtCurBal", Li_36, Li_48, "-", 9, "Verdana", Silver);
   f0_0("TxtTradeLots", Li_36, Li_52, "-", 9, "Verdana", Silver);
   f0_0("TxtTestLots", Li_36, Li_56, "-", 9, "Verdana", Silver);
   f0_0("Line3a", Li_40, Li_48, "---------------------------", 10, "Verdana", Goldenrod);
   f0_0("Line3b", Li_40, Li_52, "---- EA Message ------------------------------", 10, "Verdana", Goldenrod);
   f0_0("TxtMM", Li_44, Li_48, G_text_228, 9, "Verdana", G_color_236);
}
		 		 	 	 		 				   			   	 		  		 	 	 	 	  		    		      		  		   	 		  		  				  	  											   		  	  		 	  	   			 			   					 	   	 	 	  	
// 52D46093050F38C27267BCE42543EF60
void deinit() {
   ObjectDelete("Title1");
   ObjectDelete("Title2");
   ObjectDelete("Line1a");
   ObjectDelete("Line1b");
   ObjectDelete("Line2a");
   ObjectDelete("Line2b");
   ObjectDelete("Line3a");
   ObjectDelete("Line3b");
   ObjectDelete("TxtRisk");
   ObjectDelete("TxtFix");
   ObjectDelete("TxtScale");
   ObjectDelete("TxtCurBal");
   ObjectDelete("TxtTradeLots");
   ObjectDelete("TxtTestLots");
   ObjectDelete("TxtMinLot");
   ObjectDelete("TxtLotStep");
   ObjectDelete("TxtMaxLot");
   ObjectDelete("TxtCurRisk");
   ObjectDelete("TxtCurRskLvl");
   ObjectDelete("TxtCurSpread");
   ObjectDelete("TxtMaxSpread");
   ObjectDelete("TxtFri");
   ObjectDelete("TxtPipStepping");
   ObjectDelete("TxtDec");
   ObjectDelete("TxtFXOpenECN");
   ObjectDelete("TxtMM");
}
///////////////////Money Managment///////////////////////////////
double GetSizeLot()
{
  if (MM==false)
      MMLot=Lots;
 
  if (MM==true)                                                
     {                                                         
      MMLot=((AccountFreeMargin()*TradeLotRiskPercent)/100000);
     }                                                        
  if(MMLot < MarketInfo(Symbol(), MODE_MINLOT))
     MMLot = MarketInfo(Symbol(), MODE_MINLOT);
  return(MMLot);                                               
}
/////////////////////////////////////////////////////////////////	    						 	 	 		 	  		 			   		   	      	   	 		 		 	 		 			  	  	 		  			 	 		  			 	 	   	 		 	   			   			   		 	   	 		  	 	 	  	    	  		
// EA2B2676C28C0DB26D39331A336C6B92
int start() {
   int is_closed_128;
   int is_closed_132;
   bool Li_140;
   f0_3();
   ObjectSetText("TxtCurBal", "Acct Balance:      " + DoubleToStr(Gd_240, 2), 9, "Verdana", Silver);
   ObjectSetText("TxtTradeLots", "Trade Lot Size:     " + DoubleToStr(Gd_212, 2), 9, "Verdana", Silver);
   ObjectSetText("TxtTestLots", "Test Lot Size:    " + DoubleToStr(Gd_220, 2), 9, "Verdana", Silver);
   ObjectSetText("TxtCurRisk", "Cur Risk%:          " + DoubleToStr(Gd_256, 2), 9, "Verdana", Silver);
   ObjectSetText("TxtCurRskLvl", "Cur Risk Level:     " + Gs_healthy_264, 9, "Verdana", Silver);
   ObjectSetText("TxtCurSpread", "Cur Spread:      " + DoubleToStr(Gd_248, 1), 9, "Verdana", Silver);
   ObjectSetText("TxtMM", G_text_228, 9, "Verdana", G_color_236);
   if (Gi_332) {
      if (!(Hour() >= Gi_336 && Hour() <= Gi_340)) {
         Comment("Time for trade has not come else!");
         return (0);
      }
   }
   if (Bars < 100) {
      Print("bars less than 100");
      return (0);
   }
   if (G_acc_number_84 > 0 && G_acc_number_84 != AccountNumber()) {
      Comment("Trade on account :" + AccountNumber() + " FORBIDDEN!");
      return (0);
   }
   double ima_0 = iMA(NULL, PERIOD_M15, 100, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_8 = iMA(NULL, PERIOD_M15, 200, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_16 = iMA(NULL, PERIOD_M15, 300, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_24 = iMA(NULL, PERIOD_M15, 400, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_32 = iMA(NULL, PERIOD_M15, 500, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_40 = iMA(NULL, PERIOD_M15, 600, 0, MODE_EMA, PRICE_CLOSE, 0);
   double iclose_48 = iClose(NULL, PERIOD_M1, 0);
   double ima_56 = iMA(NULL, PERIOD_M1, 700, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_64 = iMA(NULL, PERIOD_M5, 600, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_72 = iMA(NULL, PERIOD_M15, 500, 0, MODE_EMA, PRICE_CLOSE, 0);
   double ima_80 = iMA(NULL, PERIOD_M30, 400, 0, MODE_EMA, PRICE_CLOSE, 0);
   double iwpr_88 = iWPR(NULL, PERIOD_H1, 5, 0);
   double imfi_96 = iMFI(NULL, PERIOD_M15, 1, 0);
   double idemarker_104 = iDeMarker(NULL, PERIOD_M15, 1, 0);
   bool bool_112 = FALSE;
   bool bool_116 = FALSE;
   bool bool_120 = FALSE;
   bool bool_124 = FALSE;
   f0_7();
   if (G_order_profit_276 > 0.0) {
      bool_112 = idemarker_104 < 0.01 && imfi_96 < 0.01 && iwpr_88 < -99.99 && ima_56 < iclose_48 && ima_64 < iclose_48 && ima_72 < iclose_48 && ima_80 < iclose_48 && ima_8 > ima_16 &&
         ima_16 > ima_24 && ima_24 > ima_32 && ima_32 > ima_40;
      bool_116 = idemarker_104 > 0.99 && imfi_96 > 99.9 && iwpr_88 > -0.01 && ima_56 > iclose_48 && ima_64 > iclose_48 && ima_72 > iclose_48 && ima_80 > iclose_48 && ima_8 < ima_16 &&
         ima_16 < ima_24 && ima_24 < ima_32 && ima_32 < ima_40;
   } else {
      bool_112 = OrderType() == OP_SELL && TimeCurrent() - OrderOpenTime() > Gd_104 && (idemarker_104 < 0.01 && imfi_96 < 0.01 && iwpr_88 < -99.99);
      bool_116 = OrderType() == OP_BUY && TimeCurrent() - OrderOpenTime() > Gd_104 && (idemarker_104 > 0.99 && imfi_96 > 99.9 && iwpr_88 > -0.01);
   }
   f0_2();
   if (G_order_profit_288 > 0.0) {
      bool_120 = idemarker_104 > 0.5 && imfi_96 > 50.0 && iwpr_88 > -50.0;
      bool_124 = idemarker_104 < 0.5 && imfi_96 < 50.0 && iwpr_88 < -50.0;
   } else {
      bool_120 = idemarker_104 > 0.99 && imfi_96 > 99.9 && iwpr_88 > -0.01;
      bool_124 = idemarker_104 < 0.01 && imfi_96 < 0.01 && iwpr_88 < -99.99;
   }
   if (!Gi_284) {
      Gi_344 = -1;
      if (bool_112) {
         f0_3();
         Gi_344 = 0;
         Gd_204 = 0;
         f0_6();
         return (0);
      }
      if (bool_116) {
         f0_3();
         Gi_344 = 0;
         Gd_204 = 0;
         f0_8();
         return (0);
      }
   }
   if (Gi_284) {
      if (Gi_344 < 1) {
      }
      if (OrderType() == OP_BUY) {
         if (bool_120) {
            is_closed_128 = OrderClose(OrderTicket(), OrderLots(), Bid, G_slippage_328, G_color_364);
            if (!(is_closed_128 && Gi_348)) return (0);
            PlaySound(Gs_352);
            return (0);
         }
      }
      if (OrderType() == OP_SELL) {
         if (bool_124) {
            is_closed_132 = OrderClose(OrderTicket(), OrderLots(), Ask, G_slippage_328, G_color_372);
            if (!(is_closed_132 && Gi_348)) return (0);
            PlaySound(Gs_352);
            return (0);
         }
      }
   }
   if (Gd_172 > 0.0 || Gd_172 > 0.0) {
      for (int pos_136 = 0; pos_136 < OrdersTotal(); pos_136++) {
         if (OrderSelect(pos_136, SELECT_BY_POS, MODE_TRADES)) {
            Li_140 = TRUE;
            if (MagicNo > 0 && OrderMagicNumber() != MagicNo) Li_140 = FALSE;
            if (OrderSymbol() == Symbol() && Li_140) {
               if (OrderType() == OP_BUY && Gd_172 > 0.0) {
                  if (Bid - OrderOpenPrice() > Gd_172 * Gd_320) {
                     if (OrderStopLoss() < Bid - (Gd_172 + Gd_204) * Gd_320) {
                        if (Gi_344 == 0) {
                           f0_1(Bid - NormalizeDouble((Gd_172 - Gd_180) * Gd_320, 5));
                           Gi_344 = 1;
                           Gd_204 = Gd_188;
                        } else f0_1(Bid - NormalizeDouble(Gd_172 * Gd_320, 5));
                     }
                  }
               }
               if (OrderType() == OP_SELL) {
                  if (OrderOpenPrice() - Ask > Gd_172 * Gd_320) {
                     if (OrderStopLoss() > Ask + (Gd_172 + Gd_204) * Gd_320 || OrderStopLoss() == 0.0) {
                        if (Gi_344 == 0) {
                           f0_1(Ask + NormalizeDouble((Gd_172 - Gd_180) * Gd_320, 5));
                           Gi_344 = 1;
                           Gd_204 = Gd_188;
                           continue;
                        }
                        f0_1(Ask + NormalizeDouble(Gd_172 * Gd_320, 5));
                     }
                  }
               }
            }
         }
      }
   }
   return (0);
}
	 	  	  		  	  					     	 	  	 	 	 	 		  		  	  	  			  	  		 	 		 	      		  				 		 		      					  	 			  	    			  	    					   	 	   	 	 	 	
// 3C863AD0C977F1D5AECF9C46698968EF
int f0_2() {
   bool Li_4;
   G_order_profit_288 = 0;
   Gi_284 = FALSE;
   for (int pos_0 = 0; pos_0 < OrdersTotal(); pos_0++) {
      if (OrderSelect(pos_0, SELECT_BY_POS, MODE_TRADES)) {
         Li_4 = TRUE;
         if (MagicNo > 0 && OrderMagicNumber() != MagicNo) Li_4 = FALSE;
         if (OrderSymbol() == Symbol() && Li_4) {
            G_order_profit_288 = OrderProfit();
            Gi_284 = TRUE;
            return (1);
         }
      }
   }
   return (0);
}
	 	  			 	  	 	  			  				 	   	  	 	   	 		   			  		 			  			 			 	 			  		 	  		 			       	  			   	 		  				 			 	 	   		      	  		 	 	  	 
// B0ADBDE9D79D72BCCE71E4E58415F42E
int f0_7() {
   G_order_profit_276 = 0;
   Gi_272 = FALSE;
   for (int pos_0 = OrdersHistoryTotal() - 1; pos_0 >= 0; pos_0--) {
      OrderSelect(pos_0, SELECT_BY_POS, MODE_HISTORY);
      if (OrderMagicNumber() == MagicNo) {
         G_order_profit_276 = OrderProfit();
         pos_0 = 0;
         Gi_272 = TRUE;
      }
   }
   return (0);
}
		    		  	 			    	 				 		 	 	 	  		  		 	 	 		 	 	  		 	 	 	 	   											     	 	  		  		    	 	 	      				 				 			 	    		 		 			  		 	 
// 22822FDC40653E4686F7A95F3B0D0FEC
void f0_1(double Ad_0) {
   bool bool_8 = OrderModify(OrderTicket(), NormalizeDouble(OrderOpenPrice(), 5), NormalizeDouble(Ad_0, 5), NormalizeDouble(OrderTakeProfit(), 5), 0, CLR_NONE);
   if (bool_8 && Gi_348) PlaySound(Gs_352);
}
		   		   	 	 		   	  	 	 		     	  	  			 	    	 	 		  	 	 					   	 	 					 		    				 		   		   	         		 		 		 					 		 	 		 	   		  	    
// A5475BEEA729819A4699A3F14CBC7B39
void f0_6() {
   double price_0;
   double price_8;
   int ticket_16;
   if (Lots != 0.0) {
      price_0 = 0;
      price_8 = 0;
      ticket_16 = OrderSend(Symbol(), OP_BUY, GetSizeLot(), Ask, G_slippage_328, 0, 0, CommentTxt, MagicNo, 0, G_color_360);
      if (ticket_16 > -1) {
         OrderSelect(ticket_16, SELECT_BY_TICKET);
         if (Gd_156 > 0.0) price_0 = NormalizeDouble(OrderOpenPrice() - Gd_156 * Gd_320, Digits);
         if (Gd_164 > 0.0) price_8 = NormalizeDouble(OrderOpenPrice() + Gd_164 * Gd_320, Digits);
         OrderModify(OrderTicket(), OrderOpenPrice(), price_0, price_8, 0, Green);
      }
      if (ticket_16 > -1 && Gi_348) PlaySound(Gs_352);
   }
}
	 			  	 	 	 	   		 		 			  				  		 		 	 	 						 	  				 	    				 	 		    	   			       			   		 				 				  		 	  	  	  	  	    	 				 		 			 
// B6832796D33422B67F3123C913057ADB
void f0_8() {
   double price_0;
   double price_8;
   int ticket_16;
   if (Lots != 0.0) {
      price_0 = 0;
      price_8 = 0;
      ticket_16 = OrderSend(Symbol(), OP_SELL, GetSizeLot(), Bid, G_slippage_328, 0, 0, CommentTxt, MagicNo, 0, G_color_368);
      if (ticket_16 > -1) {
         OrderSelect(ticket_16, SELECT_BY_TICKET);
         if (Gd_156 > 0.0) price_0 = NormalizeDouble(OrderOpenPrice() + Gd_156 * Gd_320, Digits);
         if (Gd_164 > 0.0) price_8 = NormalizeDouble(OrderOpenPrice() - Gd_164 * Gd_320, Digits);
         OrderModify(OrderTicket(), OrderOpenPrice(), price_0, price_8, 0, Green);
      }
      if (ticket_16 > -1 && Gi_348) PlaySound(Gs_352);
   }
}
	 		 	 	 	 		    		    			    		  			 	 	 	   				 							 			  					  		   	    					     	     		   		 			 	 		 	 	   	  				    		 			 			 		 
// 49259CD8EB29D7792A0C35AF855F3E73
void f0_3() {
   Gd_248 = f0_9(Symbol());
   Gd_240 = AccountBalance();
   //Gd_212 = 2.0 * Gd_296;
   //Gd_220 = Gd_296;
   double Ld_0 = Gd_212 * (Gd_156 * f0_5(Symbol())) / 0.02;
   Gd_256 = 100.0 * (Gd_156 * f0_5(Symbol()) * Gd_212 / Gd_240);
   if (Gd_256 <= 2.0) Gs_healthy_264 = "Healthy";
   else {
      if (Gd_256 <= 5.0) Gs_healthy_264 = "Medium";
      else {
         if (Gd_256 <= 10.0) Gs_healthy_264 = "High";
         else Gs_healthy_264 = "Too High";
      }
   }
   if (Gi_272) {
      if (G_order_profit_276 > 0.0) {
         G_text_228 = "Last order was a winner, SW will open Trade Lot order next";
         G_color_236 = LightGreen;
         Lots = Gd_212;
      } else {
         G_text_228 = "Last order wasn`t a winner, SW will open Test Lot order next";
         G_color_236 = Pink;
         Lots = Gd_220;
      }
   } else {
      G_text_228 = "Last order not found, SW will begin with a Test Lot order";
      G_color_236 = Silver;
      Lots = Gd_220;
   }
   if (DayOfWeek() == 5 && Hour() > Gi_124) {
      G_text_228 = "It\'s Friday after " + DoubleToStr(Gi_124, 0) + ":00, ";
      G_color_236 = Silver;
      if (!Gi_120) {
         Lots = 0;
         G_text_228 = G_text_228 + "SW will not open new order";
      } else {
         Lots = Gd_220;
         G_text_228 = G_text_228 + "SW will open Test Lot order only";
      }
   }
   if (Month() == 12 && Day() > Gi_128) {
      G_text_228 = "It\'s December after " + DoubleToStr(Gi_128, 0) + "th, ";
      G_color_236 = Silver;
      if (!Gi_132) {
         Lots = 0;
         G_text_228 = G_text_228 + "SW will not open new order";
      } else {
         Lots = Gd_220;
         G_text_228 = G_text_228 + "SW will open new Test Lot orders only";
      }
   }
   if (Gd_248 > Gd_112) {
      G_text_228 = "Spread is too high, SW will not open new orders";
      G_color_236 = Silver;
      Lots = 0;
   }
   if (Gs_healthy_264 == "High") {
      G_text_228 = "SW ALERT: CurRisk > 5%, pls bring Acct Balance above $" + DoubleToStr(Ld_0, 0);
      G_color_236 = Pink;
   }
   if (Gs_healthy_264 == "Too High") {
      G_text_228 = "SW STOPPED: CurRisk > 10%, Pls bring Acct balance above $" + DoubleToStr(Ld_0, 0);
      G_color_236 = HotPink;
      Lots = 0;
   }
   if (Gi_284) {
      G_text_228 = "SW IS TRADING: Pls leave it alone";
      G_color_236 = Yellow;
   }
}
					  		  	 	  	 	 		 	    								 		  		 				   	  		   	      		 	 	 	   	  	 		    		 			  	 	 					 			  	 		  	   	 	  	 		 	 			 			 				
// 881D1F32F6A9ED23E19957A630CA09BA
double f0_4(string A_symbol_0) {
   int digits_16 = MarketInfo(A_symbol_0, MODE_DIGITS);
   double Ld_ret_8 = 0.0001;
   if (digits_16 == 2 || digits_16 == 3) Ld_ret_8 = 0.01;
   return (Ld_ret_8);
}
			    	    		    		 	 		  	 			 		 			 				 				   	 			   	   	 	 		 			 			    	 	    	   	    		 			  	    							  		  	 	  	  							 				 
// 9069BDD57A9D7956EF32D73486F16C6D
double f0_5(string A_symbol_0) {
   double tickvalue_32 = MarketInfo(A_symbol_0, MODE_TICKVALUE);
   double ticksize_24 = MarketInfo(A_symbol_0, MODE_TICKSIZE);
   double Ld_16 = f0_4(A_symbol_0);
   double Ld_ret_8 = tickvalue_32 * (Ld_16 / ticksize_24);
   return (Ld_ret_8);
}
			  	 	    	     		   		  	  		 		 	 	 				  			   					   		  	 	 	  			 		     	 		   	        		  		  	  	 						   		  			  	  	 					 	 		 
// E453997FF5EF56CA86A2E8CD16AACA49
double f0_9(string A_symbol_0) {
   double ticksize_24 = MarketInfo(A_symbol_0, MODE_TICKSIZE);
   double Ld_16 = f0_4(A_symbol_0);
   double Ld_ret_8 = MarketInfo(A_symbol_0, MODE_SPREAD) * (ticksize_24 / Ld_16);
   return (Ld_ret_8);
}
		  		 	  	        		  		 			 		 	    	 		 		 			 	  				 	  	  	      					         	   		 	      		 		    		 			 	    			  		  		   				    		 
// 1D1BC127C8E92D60E674F9FBE1494CF8
void f0_0(string A_name_0, int A_y_8, int A_x_12, string A_text_16, int A_fontsize_24, string A_fontname_28, color A_color_36) {
   ObjectCreate(A_name_0, OBJ_LABEL, 0, 0, 0);
   ObjectSet(A_name_0, OBJPROP_CORNER, 0);
   ObjectSet(A_name_0, OBJPROP_XDISTANCE, A_x_12);
   ObjectSet(A_name_0, OBJPROP_YDISTANCE, A_y_8);
   ObjectSetText(A_name_0, A_text_16, A_fontsize_24, A_fontname_28, A_color_36);
}