Jump to content

Night Turbo EA


saragosa

Recommended Posts

Re: (reg Night Turbo EA)

 

I haven't check, but should work

[spoiler:wd86a3wv]#property copyright "Copyright © 2009, eaturbo.com."

#property link "http://www.eaturbo.com"

 

#import "wininet.dll"

int InternetOpenA(string a0, int a1, string a2, string a3, int a4);

int InternetOpenUrlA(int a0, string a1, string a2, int a3, int a4, int a5);

int InternetReadFile(int a0, string a1, int a2, int& a3[]);

int InternetCloseHandle(int a0);

#import

 

extern int Magic = 1643164;

extern int OrdersType = 0;

extern bool Agressive = FALSE;

extern int MaxOpenTrade = 10;

extern int EnvPeriod = 15;

extern double EnvDev = 0.05;

extern int SL = 25;

extern int TP = 20;

extern bool MM = TRUE;

extern int Risk = 10;

extern double MinLot = 0.1;

extern bool CloseBy = TRUE;

extern int ClosePips = 3;

extern bool Auto_GMT_Offset = FALSE;

extern int Manual_GMT_Offset = 0;

extern string GMT_Trading_Hour = "Default 20 and 0";

extern int OpenHour = 20;

extern int CloseHour = 0;

extern int Friday = 65;

extern int Monday = 5;

extern bool Use_Trailing = FALSE;

extern int TrailingStart = 1;

extern int TrailingStop = 15;

extern double MaxSpread = 4.1;

extern int Slippage = 3;

extern int MaxTrendIndex = 3;

int g_ma_method_196 = MODE_SMA;

int g_applied_price_200 = PRICE_OPEN;

double gd_204;

double gd_212;

double gd_220;

double gd_228;

double gd_236;

double gd_244;

double gd_252;

double gd_260;

double gd_268;

int gi_276 = 0;

string gs_280 = "http://www.eaturbo.com/gmt.php";

string gs_288 = "AlexGmtOffset 1.0";

int gi_296 = -1;

bool gi_unused_300 = TRUE;

bool gi_unused_304 = TRUE;

int gi_308;

string gs_312;

string gs_320;

string gs_328;

string gs_336;

bool gi_344 = TRUE;

bool gi_348;

double gd_unused_352;

double gd_unused_360;

int gi_368;

int gi_372;

string gs_376;

string gs_384 = "Meta Trader";

int g_datetime_392 = 0;

int g_datetime_396 = 0;

int g_datetime_400 = 0;

int g_datetime_404 = 0;

int g_datetime_408 = 0;

int g_datetime_412 = 0;

int g_leverage_416;

string g_comment_420 = "Night Turbo";

string gs_428;

bool g_bool_436;

double gd_440;

string gs_448;

string gs_456;

string gs_464;

int gi_472;

int gi_476;

string gs_484 = "2012.12.31";

bool gi_492 = TRUE;

bool gi_496 = TRUE;

 

void DisplayInfo() {

if (Agressive) gs_448 = "*** AGRESSIVE MODE ***";

else gs_448 = "*** MODERATE MODE ***";

double l_stoplevel_0 = MarketInfo(Symbol(), MODE_STOPLEVEL);

Comment(" ---------------------------------------------"

+ "\n ", gs_448, " ", gs_336,

"\n ---------------------------------------------"

+ "\n :: Maximum Trend Index : ", gd_236,

"\n :: Current Trend Index : ", gd_268, "/", gd_260, "/", gd_252, "/", gd_244,

"\n ---------------------------------------------"

+ "\n :: Take Profit : ", TP,

"\n :: Stop Loss : ", SL,

"\n :: Indi Period : ", EnvPeriod,

"\n :: Indi Dev. : ", EnvDev,

"\n ---------------------------------------------"

+ "\n :: Use Close By: ", ClosePips, " ", gs_312,

"\n :: Use Trailing : ", gs_328,

"\n :: Trailing Stop : ", TrailingStop,

"\n ---------------------------------------------"

+ "\n :: Use MM : ", gs_320,

"\n :: Maximum Risk : ", Risk,

"\n :: Current Lots : ", Lots(),

"\n ---------------------------------------------"

+ "\n :: Symbol : ", Symbol(),

"\n :: Spread : ", MarketInfo(Symbol(), MODE_SPREAD),

"\n :: Stop Level : ", l_stoplevel_0,

"\n :: Magic : ", Magic,

"\n :: Trading Type : ", OrdersType,

"\n ---------------------------------------------"

+ "\n :: GMT Offset : ", DoubleToStr(gi_308, 1), " TT:", TradingTime(),

"\n :: Trade Hour (GMT): ", DoubleToStr(OpenHour, 2), " - ", DoubleToStr(CloseHour, 2),

"\n :: Trade Hour (Server): ", DoubleToStr(gi_472, 2), "-", DoubleToStr(gi_476, 2),

"\n :: Current Hours (server) : ", Hour(), ":", Minute(),

"\n ---------------------------------------------");

}

 

int init() {

Comment("Waiting for quotes...");

if (!IsTesting()) {

if (!IsDllsAllowed()) {

Alert("Set \"AllowDLL Imports\" ON in menu Tools->Options->ExpertAdvisors!");

Print("Set \"AllowDLL Imports\" ON in menu Tools->Options->ExpertAdvisors!");

Comment("Warning: Set Parameter \"AllowDLL Imports\" ON in menu Tools -> Options -> ExpertAdvisors!");

return (0);

}

}

gs_456 = gs_384;

g_bool_436 = IsDemo();

gs_428 = AccountName();

if (Digits == 5) {

TP = 10 * TP;

SL = 10 * SL;

ClosePips = 10 * ClosePips;

TrailingStart = 10 * TrailingStart;

TrailingStop = 10 * TrailingStop;

MaxSpread = 10.0 * MaxSpread;

MaxTrendIndex = 10 * MaxTrendIndex;

Print("Digits = ", Digits);

}

g_leverage_416 = AccountLeverage();

gs_464 = Symbol();

string ls_0 = StringSubstr(gs_464, 0, 6);

if (ls_0 != "EURGBP" && ls_0 != "EURCHF" && ls_0 != "GBPCHF" && ls_0 != "AUDNZD") {

Alert("This EA only designed for EURCHF,EURGPB,GBPCHF,AUDNZD!");

Print("This EA only designed for EURCHF,EURGPB,GBPCHF,AUDNZD!");

Comment("Error: Wrong Currency Pair! Use EA BOSS on EURCHF,EURGPB,GBPCHF,AUDNZD only!");

return (0);

}

if (Auto_GMT_Offset) Manual_GMT_Offset = AutoGMTCalculation();

gi_308 = Manual_GMT_Offset;

if (gi_308 < 0) gi_308 += 24;

if (gi_308 == -2147483624) {

Sleep(60000);

return (0);

}

gi_472 = OpenHour + gi_308;

gi_476 = CloseHour + gi_308;

while (true) {

if (gi_472 >= 24) {

gi_472 -= 24;

continue;

}

if (gi_472 >= 0) break;

gi_472 += 24;

}

while (true) {

if (gi_476 >= 24) {

gi_476 -= 24;

continue;

}

if (gi_476 >= 0) break;

gi_476 += 24;

}

return (0);

}

 

int start() {

int l_str2time_0;

int li_4;

double l_price_48;

double l_price_56;

int l_ticket_64;

int li_68;

int li_72;

int li_76;

int li_80;

int l_ticket_84;

int l_ticket_88;

double l_ord_open_price_92;

double l_ord_open_price_100;

int li_108;

if (Period() != PERIOD_M5) {

Comment("\n Period M5 only!");

return;

}

if (MarketInfo(Symbol(), MODE_SPREAD) > MaxSpread) {

Comment("\n Spread too big!",

"\n Max Spread Setting : ", MaxSpread,

"\n Current Spread : ", (Ask - Bid) / Point,

"\n If you still want to trade, change MaxSpead Setting");

return;

}

gs_376 = gs_456;

if (gi_492) {

l_str2time_0 = StrToTime(gs_484);

if (TimeCurrent() >= l_str2time_0) {

Alert("Your EA Error " + g_leverage_416 + ", please contact eaturbo.com");

return (0);

}

}

 

double l_ima_8 = iMA(NULL, 0, 15, 0, MODE_SMA, PRICE_MEDIAN, 0);

double l_ima_16 = iMA(NULL, 0, 15, 0, MODE_SMA, PRICE_MEDIAN, 6);

double l_ima_24 = iMA(NULL, 0, 15, 0, MODE_SMA, PRICE_MEDIAN, 12);

double l_ima_32 = iMA(NULL, 0, 15, 0, MODE_SMA, PRICE_MEDIAN, 18);

double l_ima_40 = iMA(NULL, 0, 15, 0, MODE_SMA, PRICE_MEDIAN, 24);

gd_204 = l_ima_8 - l_ima_16;

gd_212 = l_ima_16 - l_ima_24;

gd_220 = l_ima_24 - l_ima_32;

gd_228 = l_ima_32 - l_ima_40;

if (gd_204 < 0.0) gd_204 = -1.0 * gd_204;

if (gd_212 < 0.0) gd_212 = -1.0 * gd_212;

if (gd_220 < 0.0) gd_220 = -1.0 * gd_220;

if (gd_228 < 0.0) gd_228 = -1.0 * gd_228;

gd_244 = NormalizeDouble(gd_204 / Point, 0);

gd_252 = NormalizeDouble(gd_212 / Point, 0);

gd_260 = NormalizeDouble(gd_220 / Point, 0);

gd_268 = NormalizeDouble(gd_228 / Point, 0);

gd_236 = MaxTrendIndex;

if (gd_244 > gd_236 || gd_252 > gd_236 || gd_260 > gd_236 || gd_268 > gd_236) {

if (OrdersType == 1) fOrderDeleteLimit();

gs_336 = "No Trade";

DisplayInfo();

if (OrdersTotal() > 0) {

Use_Trailing = TRUE;

fTrailingStop();

}

return (0);

}

DisplayInfo();

if (CloseBy) gs_312 = "ON";

else gs_312 = "OFF";

if (MM) gs_320 = "ON";

else gs_320 = "OFF";

if (Use_Trailing) gs_328 = "ON";

else gs_328 = "OFF";

if (CloseBy) CloseProfit();

if (Friday > 0) {

if (TimeDayOfWeek(TimeCurrent()) == 5) {

if (TimeCurrent() > 86400 * (TimeCurrent() / 86400) + 86400 - 60 * Friday) {

fOrderDeleteLimit();

fOrderCloseMarket();

return (0);

}

}

}

if (Monday > 0) {

if (TimeDayOfWeek(TimeCurrent()) == 1)

if (TimeCurrent() < 86400 * (TimeCurrent() / 86400) + 60 * Monday) return (0);

}

if (Ask - Bid <= MaxSpread * Point) {

if (TradingTime() == 1) {

if (gi_344) {

gd_unused_352 = Ask;

gd_unused_360 = Bid;

gi_344 = FALSE;

return (0);

}

gs_336 = "";

if (Agressive) {

if (OrdersTotal() > MaxOpenTrade) {

fTrailingStop();

return (0);

}

}

if (OrdersType == 0) {

l_price_48 = ND(iEnvelopes(NULL, 0, EnvPeriod, g_ma_method_196, 0, g_applied_price_200, EnvDev, MODE_UPPER, 0));

l_price_56 = ND(iEnvelopes(NULL, 0, EnvPeriod, g_ma_method_196, 0, g_applied_price_200, EnvDev, MODE_LOWER, 0));

li_68 = 0;

li_72 = 0;

li_76 = 0;

li_80 = 0;

li_108 = fOrdersCounter(li_68, li_72, li_76, li_80, l_ord_open_price_92, l_ord_open_price_100, l_ticket_84, l_ticket_88);

if (li_108 == -1) return;

if (li_76 == 0 && li_68 == 0 || Agressive) {

if (Close[0] < l_price_56 && gi_368 != Time[0]) {

l_ticket_64 = OrderSend(Symbol(), OP_BUY, Lots(), Ask, Slippage, Ask - SL * Point, Ask + TP * Point, g_comment_420, Magic, 0, Blue);

if (l_ticket_64 > 0) gi_368 = Time[0];

Print(GetLastError());

Sleep(500);

RefreshRates();

}

}

if (li_80 == 0 && li_72 == 0 || Agressive) {

if (Close[0] > l_price_48 && gi_372 != Time[0]) {

l_ticket_64 = OrderSend(Symbol(), OP_SELL, Lots(), Bid, Slippage, Bid + SL * Point, Bid - TP * Point, g_comment_420, Magic, 0, Red);

if (l_ticket_64 > 0) gi_372 = Time[0];

Print(GetLastError());

Sleep(500);

RefreshRates();

}

}

}

if (OrdersType == 1) {

l_price_48 = ND(iEnvelopes(NULL, 0, EnvPeriod, g_ma_method_196, 0, g_applied_price_200, EnvDev, MODE_UPPER, 0));

l_price_56 = ND(iEnvelopes(NULL, 0, EnvPeriod, g_ma_method_196, 0, g_applied_price_200, EnvDev, MODE_LOWER, 0));

li_68 = 0;

li_72 = 0;

li_76 = 0;

li_80 = 0;

li_108 = fOrdersCounter(li_68, li_72, li_76, li_80, l_ord_open_price_92, l_ord_open_price_100, l_ticket_84, l_ticket_88);

if (li_108 == -1) return;

if (li_76 == 0 && li_68 == 0) {

if (l_price_56 < ND(Ask - Point * MarketInfo(Symbol(), MODE_STOPLEVEL))) {

l_ticket_64 = OrderSend(Symbol(), OP_BUYLIMIT, Lots(), l_price_56, 0, l_price_56 - SL * Point, l_price_56 + TP * Point, g_comment_420, Magic, 0, DarkGreen);

Print("BuyLimit: " + GetLastError());

Sleep(500);

RefreshRates();

}

} else {

if (ND(l_ord_open_price_92) != l_price_56 && gi_368 != Time[0]) {

OrderModify(l_ticket_84, l_price_56, l_price_56 - SL * Point, l_price_56 + TP * Point, 0, DarkGreen);

gi_368 = Time[0];

Print("Modify BuyLimit: " + GetLastError());

Sleep(500);

RefreshRates();

}

}

if (li_80 == 0 && li_72 == 0) {

if (l_price_48 > ND(Bid + Point * MarketInfo(Symbol(), MODE_STOPLEVEL))) {

l_ticket_64 = OrderSend(Symbol(), OP_SELLLIMIT, Lots(), l_price_48, 0, l_price_48 + SL * Point, l_price_48 - TP * Point, g_comment_420, Magic, 0, DeepPink);

Print("SellLimit: " + GetLastError());

Sleep(500);

RefreshRates();

}

} else {

if (ND(l_ord_open_price_100) != l_price_48 && gi_372 != Time[0]) {

OrderModify(l_ticket_88, l_price_48, l_price_48 + SL * Point, l_price_48 - TP * Point, 0, DarkGreen);

gi_372 = Time[0];

Print("Modify SellLimit: " + GetLastError());

Sleep(500);

RefreshRates();

}

}

}

} else {

gs_336 = "Waiting for trading hour!";

if (OrdersType == 1) fOrderDeleteLimit();

}

}

gd_unused_352 = Ask;

gd_unused_360 = Bid;

if (Use_Trailing) fTrailingStop();

return (0);

}

 

void CloseProfit() {

int li_unused_0 = 0;

int li_unused_4 = 0;

double ld_unused_8 = 0;

if (OrdersTotal() > 0) {

for (int l_pos_16 = OrdersTotal() + 1; l_pos_16 >= 0; l_pos_16--) {

if (OrderSelect(l_pos_16, SELECT_BY_POS, MODE_TRADES)) {

if (OrderSymbol() == Symbol()) {

if (OrderMagicNumber() == Magic) {

if (OrderCloseTime() == 0) {

if (OrderType() == OP_BUY) {

RefreshRates();

if (Bid > OrderOpenPrice() + ClosePips * Point) {

Print("del");

del(OrderTicket());

}

}

if (OrderType() == OP_SELL) {

RefreshRates();

if (Ask < OrderOpenPrice() - ClosePips * Point) {

Print("del");

del(OrderTicket());

}

}

}

}

}

}

}

}

}

 

void del(int a_ticket_0) {

int l_error_4;

string l_symbol_8;

double l_bid_16;

for (int l_count_24 = 0; l_count_24 < 1; l_count_24++) {

GetLastError();

OrderSelect(a_ticket_0, SELECT_BY_TICKET, MODE_TRADES);

l_symbol_8 = OrderSymbol();

if (OrderType() == OP_BUY) {

RefreshRates();

l_bid_16 = MarketInfo(l_symbol_8, MODE_BID);

if (!OrderClose(a_ticket_0, OrderLots(), l_bid_16, 3, Green)) l_error_4 = GetLastError();

}

if (OrderType() == OP_SELL) {

RefreshRates();

l_bid_16 = MarketInfo(l_symbol_8, MODE_ASK);

if (!OrderClose(a_ticket_0, OrderLots(), l_bid_16, 3, Green)) l_error_4 = GetLastError();

}

if (l_error_4 == 0/* NO_ERROR */) {

PlaySound("expert.wav");

return;

}

if (l_error_4 != 0/* NO_ERROR */) {

PlaySound("timeout.wav");

Print("Error for Close Funtion =", l_error_4);

}

while (!IsTradeAllowed()) Sleep(5000);

if (l_error_4 == 146/* TRADE_CONTEXT_BUSY */) while (IsTradeContextBusy()) Sleep(11000);

}

}

 

double ND(double ad_0) {

return (NormalizeDouble(ad_0, Digits));

}

 

int fOrdersCounter(int &a_count_0, int &a_count_4, int &a_count_8, int &a_count_12, double &a_ord_open_price_16, double &a_ord_open_price_24, int &a_ticket_32, int &a_ticket_36) {

a_count_0 = 0;

a_count_4 = 0;

a_count_8 = 0;

a_count_12 = 0;

a_ord_open_price_16 = 0;

a_ord_open_price_24 = 0;

a_ticket_32 = 0;

a_ticket_36 = 0;

for (int l_pos_40 = 0; l_pos_40 < OrdersTotal(); l_pos_40++) {

if (OrderSelect(l_pos_40, SELECT_BY_POS, MODE_TRADES)) {

if (OrderSymbol() == Symbol()) {

if (OrderMagicNumber() == Magic) {

switch (OrderType()) {

case OP_BUY:

a_count_0++;

break;

case OP_SELL:

a_count_4++;

break;

case OP_BUYLIMIT:

a_count_8++;

a_ord_open_price_16 = OrderOpenPrice();

a_ticket_32 = OrderTicket();

break;

case OP_SELLLIMIT:

a_count_12++;

a_ord_open_price_24 = OrderOpenPrice();

a_ticket_36 = OrderTicket();

}

}

}

} else return (-1);

}

return (a_count_0 + a_count_4);

}

 

double Lots() {

int li_0;

double ld_4 = NormalizeDouble(MarketInfo(Symbol(), MODE_LOTSTEP), 2);

if (ld_4 == 0.01) li_0 = 2;

else li_0 = 1;

if (MM) gd_440 = NormalizeDouble(AccountFreeMargin() * Risk / 100000.0 / (g_leverage_416 / 100), li_0);

else gd_440 = MinLot;

double ld_12 = NormalizeDouble(MarketInfo(Symbol(), MODE_MINLOT), 2);

double ld_20 = NormalizeDouble(MarketInfo(Symbol(), MODE_MAXLOT), 2);

if (gd_440 < ld_12) gd_440 = ld_12;

if (gd_440 > ld_20) gd_440 = ld_20;

return (gd_440);

}

 

int fOrderDeleteLimit(bool ai_0 = TRUE, bool ai_4 = TRUE) {

int li_ret_8 = 0;

for (int l_pos_12 = OrdersTotal() - 1; l_pos_12 >= 0; l_pos_12--) {

if (OrderSelect(l_pos_12, SELECT_BY_POS, MODE_TRADES)) {

if (OrderSymbol() == Symbol()) {

if (OrderType() == OP_BUYLIMIT) {

if (ai_0) {

RefreshRates();

if (!IsTradeContextBusy()) {

if (!OrderDelete(OrderTicket())) li_ret_8 = -1;

} else {

if (TimeCurrent() > g_datetime_392 + 20) {

g_datetime_392 = TimeCurrent();

Print("Need delete BUYLIMIT " + OrderTicket() + ". Trade Context Busy");

}

return (-2);

}

}

}

if (OrderType() == OP_SELLLIMIT) {

if (ai_4) {

RefreshRates();

if (!IsTradeContextBusy()) {

if (!OrderDelete(OrderTicket())) li_ret_8 = -1;

} else {

if (TimeCurrent() > g_datetime_396 + 20) {

g_datetime_396 = TimeCurrent();

Print("Need delete SELLSTOP " + OrderTicket() + ". Trade Context Busy");

}

return (-2);

}

}

}

}

}

}

return (li_ret_8);

}

 

int fOrderCloseMarket(bool ai_0 = TRUE, bool ai_4 = TRUE) {

int l_error_8;

int li_ret_12 = 0;

for (int l_pos_16 = OrdersTotal() - 1; l_pos_16 >= 0; l_pos_16--) {

if (OrderSelect(l_pos_16, SELECT_BY_POS, MODE_TRADES)) {

if (OrderSymbol() == Symbol()) {

if (ai_0) {

if (OrderType() == OP_BUY) {

RefreshRates();

if (!IsTradeContextBusy()) {

if (!OrderClose(OrderTicket(), OrderLots(), ND(Bid), 3, CLR_NONE)) {

l_error_8 = GetLastError();

Print("Error close BUY " + OrderTicket() + " " + l_error_8);

li_ret_12 = -1;

}

} else {

if (TimeCurrent() > g_datetime_400 + 0) {

g_datetime_400 = TimeCurrent();

Print("Need close BUY " + OrderTicket() + ". Trade Context Busy");

}

return (-2);

}

}

}

if (ai_4) {

if (OrderType() == OP_SELL) {

RefreshRates();

if (!IsTradeContextBusy()) {

if (!OrderClose(OrderTicket(), OrderLots(), ND(Ask), 3, CLR_NONE)) {

l_error_8 = GetLastError();

Print("Error close SELL " + OrderTicket() + " " + l_error_8);

li_ret_12 = -1;

}

} else {

if (TimeCurrent() > g_datetime_404 + 20) {

g_datetime_404 = TimeCurrent();

Print("Need close SELL " + OrderTicket() + ". Trade Context Busy");

}

return (-2);

}

}

}

}

}

}

return (li_ret_12);

}

 

void fTrailingStop() {

double l_price_0;

int l_error_8;

for (int l_pos_12 = 0; l_pos_12 < OrdersTotal(); l_pos_12++) {

if (OrderSelect(l_pos_12, SELECT_BY_POS, MODE_TRADES)) {

if (OrderSymbol() == Symbol() && OrderMagicNumber() == Magic) {

if (OrderType() == OP_BUY) {

RefreshRates();

if (ND(Bid - OrderOpenPrice()) <= ND((-Point) * TrailingStart)) {

l_price_0 = ND(Bid + Point * TrailingStop);

if (ND(OrderTakeProfit()) > l_price_0 || ND(OrderTakeProfit()) == 0.0) {

if (!IsTradeContextBusy()) {

if (!OrderModify(OrderTicket(), OrderOpenPrice(), OrderStopLoss(), l_price_0, 0, CLR_NONE)) {

l_error_8 = GetLastError();

Print("Error trailingprofit BUY " + OrderTicket() + " - " + l_error_8);

}

} else {

if (g_datetime_408 + 15 < TimeCurrent()) {

g_datetime_408 = TimeCurrent();

Print("Need trailingprofit BUY " + OrderTicket() + ". Trade Context Busy");

}

}

}

}

}

if (OrderType() == OP_SELL) {

RefreshRates();

if (ND(OrderOpenPrice() - Ask) <= ND((-Point) * TrailingStart)) {

l_price_0 = ND(Ask - Point * TrailingStop);

if (!IsTradeContextBusy()) {

if (ND(OrderTakeProfit()) < l_price_0) {

if (!OrderModify(OrderTicket(), OrderOpenPrice(), OrderStopLoss(), l_price_0, 0, CLR_NONE)) {

l_error_8 = GetLastError();

Print("Error trailingprofit SELL " + OrderTicket() + " - " + l_error_8);

}

}

} else {

if (g_datetime_412 + 15 < TimeCurrent()) {

g_datetime_412 = TimeCurrent();

Print("Need trailingprofit SELL " + OrderTicket() + ". Trade Context Busy");

}

}

}

}

}

}

}

}

 

int AutoGMTCalculation() {

string ls_0;

int li_ret_8;

int li_12;

gi_296 = InternetOpenA(gs_288, 0, "0", "0", 0);

string ls_16 = "XXXXXXXXXX";

if (!GetData(gs_280, ls_16)) {

if (gi_276 == 0) ls_0 = "Error getting data to server.";

else ls_0 = "Apaan sih";

Comment(ls_0);

Print(ls_0);

li_ret_8 = -2147483648;

} else {

li_12 = TimeCurrent() - StrToInteger(ls_16);

li_ret_8 = MathFloor((li_12 + 1800) / 3600);

}

InternetCloseHandle(gi_296);

return (li_ret_8);

}

 

 

 

bool GetData(string as_0, string &as_8) {

int li_16 = InternetOpenUrlA(gi_296, as_0, "0", 0, -2080374528, 0);

if (li_16 == 0) return (FALSE);

int lia_20[] = {1};

string ls_24 = "xxxxxxxxxx";

int li_32 = InternetReadFile(li_16, ls_24, 10, lia_20);

if (li_16 != 0) InternetCloseHandle(li_16);

as_8 = ls_24;

return (TRUE);

}

 

int TradingTime() {

gi_348 = FALSE;

if (gi_472 > gi_476) {

if (TimeHour(TimeCurrent()) >= gi_472 || TimeHour(TimeCurrent()) < gi_476) gi_348 = TRUE;

} else

if (TimeHour(TimeCurrent()) >= gi_472 && TimeHour(TimeCurrent()) < gi_476) gi_348 = TRUE;

return (gi_348);

}[/spoiler:wd86a3wv]

Link to comment
Share on other sites

Re: (reg Night Turbo EA)

 

Obviously this EA is modified(probably heavily) EA BOSS which we all know is modified FapTurbo but anyway, maby this time the clone is better than the original.

 

Comment("Error: Wrong Currency Pair! Use EA BOSS on EURCHF,EURGPB,GBPCHF,AUDNZD only!")

 

 

It gives me this multiple times: 2009.12.15 23:15:47 NightTurbo EURCHF,M5: 130

Same for Eur/Gbp.

Broker: FXCM UK demo account

Can it be fixed?

Link to comment
Share on other sites

Re: (reg Night Turbo EA)

 

total fail (like many eurchf/eurgbp asian EAs) over the past couple of months in testing. bin for me.

 

Anyway, somebody please take a look at why error 130 appears all the time since I'm with FXCM and they have no restrictions regarding limit orders and stops.

Thank you in advance.

Link to comment
Share on other sites

  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...