Jump to content

guihleao

Members
  • Content Count

    15
  • Joined

  • Last visited

Posts posted by guihleao


  1. Hello guys! So, i got this script from rAthena and I need to do a few modifications that I've tried, but no success.

     

    This is the original script:

    -	script	dualclientkicker	-1,{OnPCLoadMapEvent:	set .@charmap$, strcharinfo(3);	if(!compare(.tmp$,.@charmap$)) end;	set .@len, query_sql("select account_id from `char` right join login on login.account_id = `char`.account_id where `char`.online = 1 and login.last_ip = '"+ getcharip() +"'",.@a ); //Annieruru Addition.	if(.@len-1) {		for(set(.@d,0);.@d<.@len;set(.@d,.@d+1)) {			getmapxy(.@map$,.@x,.@y,0,rid2name(.@a[.@d]));			if(.@charmap$==.@map$&&rid2name(.@a[.@d])!=strcharinfo(0)) {				dispbottom "Dual Client não disponível nesse mapa.";				warp "vilasyn",91,54;			}		}	}	end;	OnInit:	setarray   .maps$  ,	"aldeg_cas01", "gefg_cas01", "payg_cas01", "prtg_cas01", "guild_vs3";	set        .lens   ,	getarraysize(.maps$)                                   ;	for(set(.a,0);.a<.lens;set(.a,.a+1)) {		setmapflag .maps$[.a],	mf_loadevent ;		set .tmp$  ,.tmp$+.maps$[.a]+",";	}}

    I'd like to make it look after the last_mac field instead of the last_ip field. And also, I have a separated login database, I tried this:

     

    query_sql("select account_id from DB1.`char` right join DB2.login on login.account_id = `char`.account_id where `char`.online = 1 and login.last_ip = '"+ getcharip() +"'",.@a );

    But no success.

     

    Could anyone help me in these two situations?

     

    Thanks in advance!


  2. Okay, but that's in a script. I meant by the whole cash system. I believe I have to change the pc.c file, so that the Cash Shop and the command @cash read the new ## variable. I'm not sure if I should change only this file...

     

    For example,

     

    In pc.c

     

    // Cash shop	sd->cashPoints = pc_readaccountreg(sd,script->add_str("#CASHPOINTS"));	sd->kafraPoints = pc_readaccountreg(sd,script->add_str("#KAFRAPOINTS"));

    I think I should change to:

     

    // Cash shop	sd->cashPoints = pc_readaccountreg(sd,script->add_str("##CASHPOINTS"));	sd->kafraPoints = pc_readaccountreg(sd,script->add_str("##KAFRAPOINTS"));

    But I also think I need to change the " pc_readaccountreg" to read the global account, also there are some other modifications in this file I'd need to do.

     

    Am I right or just tripping? 

     

    Thanks!


  3. It stills show the same error :(

     

    Here is the complete NPC:

     

    //==========================================================================================================================//				          Função que adiciona 15 dias Vip ao usuário//==========================================================================================================================function	script	vip15	{set $diasVip, 15;set $verificaVip, 1;	if (getgmlevel() == 1) goto estender;	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(CURDATE(),INTERVAL "+$diasVip+" DAY) WHERE `group_id` = 0 AND `account_id` = "+getcharid(3);	dispbottom "ViP inserido com sucesso! Relogue sua personagem para ativá-lo.";	end;estender:	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(`dt_vip`,INTERVAL "+$diasVip+" DAY) WHERE `group_id` = '1' AND `account_id` = "+getcharid(3);	dispbottom "ViP estendido por mais "+$diasVip+" dias! Relogue sua personagem para ativá-lo.";	end;}//==========================================================================================================================//				          Função que adiciona 30 dias Vip ao usuário//==========================================================================================================================function	script	vip30	{set $diasVip, 30;set $verificaVip, 1;	if (getgmlevel() == 1) goto estender;	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(CURDATE(),INTERVAL "+$diasVip+" DAY) WHERE `group_id` = 0 AND `account_id` = "+getcharid(3);	dispbottom "ViP inserido com sucesso! Relogue sua personagem para ativá-lo.";	end;estender:	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(`dt_vip`,INTERVAL "+$diasVip+" DAY) WHERE `group_id` = '1' AND `account_id` = "+getcharid(3);	dispbottom "ViP estendido por mais "+$diasVip+" dias! Relogue sua personagem para ativá-lo.";	end;}//==========================================================================================================================//				          Função que adiciona 45 dias Vip ao usuário//==========================================================================================================================function	script	vip45	{set $diasVip, 45;set $verificaVip, 1;	if (getgmlevel() == 1) goto estender;	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(CURDATE(),INTERVAL "+$diasVip+" DAY) WHERE `group_id` = 0 AND `account_id` = "+getcharid(3);	dispbottom "ViP inserido com sucesso! Relogue sua personagem para ativá-lo.";	end;estender:	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(`dt_vip`,INTERVAL "+$diasVip+" DAY) WHERE `group_id` = '1' AND `account_id` = "+getcharid(3);	dispbottom "ViP estendido por mais "+$diasVip+" dias! Relogue sua personagem para ativá-lo.";	end;}//==========================================================================================================================//				          Função que adiciona 60 dias Vip ao usuário//==========================================================================================================================function	script	vip60	{set $diasVip, 60;set $verificaVip, 1;	if (getgmlevel() == 1) goto estender;	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(CURDATE(),INTERVAL "+$diasVip+" DAY) WHERE `group_id` = 0 AND `account_id` = "+getcharid(3);	dispbottom "ViP inserido com sucesso! Relogue sua personagem para ativá-lo.";	end;estender:	query_sql "UPDATE `login` SET `group_id` = '1', `dt_vip` = DATE_ADD(`dt_vip`,INTERVAL "+$diasVip+" DAY) WHERE `group_id` = '1' AND `account_id` = "+getcharid(3);	dispbottom "ViP estendido por mais "+$diasVip+" dias! Relogue sua personagem para ativá-lo.";	end;}//==========================================================================================================================//			    Função que controla a data de término da conta vip e anúncios ao logar//==========================================================================================================================-	script	GerenciadorVip	-1,{		OnPCLoginEvent:			query_sql "UPDATE `login` SET `group_id`= 0 WHERE `group_id` = '1' AND (`dt_vip` IS NULL OR `dt_vip` < CURDATE())";		query_sql "SELECT (`dt_vip` IS NULL OR `dt_vip` < CURDATE()) FROM `login` WHERE `account_id` = "+getcharid(3), @verificaVip;		if (@verificaVip) {		dispbottom "Torne-se um(a) jogador(a) ViP e tenha benefícios exclusivos!";		end;}	query_sql "SELECT DATE_FORMAT(`dt_vip`, '%d/%m/%Y') FROM `login` WHERE `account_id` = "+getcharid(3), @dataVencimento$;	dispbottom "Sua conta ViP é válida até o dia "+@dataVencimento$+".";	end;}

    Thanks :)


  4. Hello guys, i'm having a problem of Conv_str in a NPC. Could you guys help me fix it?

     

    Here's the code:

     

    -	script	GerenciadorVip	-1,{		OnPCLoginEvent:			query_sql "UPDATE `login` SET `group_id`= 0 WHERE `group_id` = "+$nivelVip+" AND (`dt_vip` IS NULL OR `dt_vip` < CURDATE())";		query_sql "SELECT (`dt_vip` IS NULL OR `dt_vip` < CURDATE()) FROM `login` WHERE `account_id` = "+getcharid(3), @verificaVip;		if (@verificaVip) {		dispbottom "Torne-se um(a) jogador(a) ViP e tenha benefícios exclusivos!";		dispbottom "Acesse site e saiba mais!";		end;}	query_sql "SELECT DATE_FORMAT(`dt_vip`, '%d/%m/%Y') FROM `login` WHERE `account_id` = "+getcharid(3), @dataVencimento$;	dispbottom "Sua conta ViP é válida até o dia "+@dataVencimento$+".";	end;}

    And this is the error when I log in:

     

    [Error]: script:conv_str: cannot convert to string, defaulting to "" 

     

    Thanks!


  5.  

     

    Excellent tool! I'm having some problems though...

     

    I can't rename it, If i rename, after I login it appears an "Error box". It only works with the name "Loki Launcher.exe" is there anyway I can fix it?

     

    Thanks!

     

     

    PRE-SOLVED:
     
    If I change file name, it will work only if I Run as Adm, how can I make it run like "Loki Launcher.exe" with no need of permission?

    dunno man, check new just tested vb6 on win10, lel still use this they have restore login window diff

     

    Ok, I tried the new one and it's working great, I can change name!

     

    BUT THERE'S ANOTHER PROBLEM!

     

    I believe the MD5 option is not working properly. I use MD5 on my server, If i set the option to TRUE, it doesnt work, If I select FALSE, then it works. Could you take a look?

     

    Thanks mleo1!! Best launcher =D


  6. Hello guys, I'm having problem setting up FluxCP for multi servers.

     

    I have 3 servers, each one of them use a different database. The only thing in common is that they use the same login database (which is one of the 3 servers). So I need FluxCP to register only in one DB. How can I add them to FluxCP?

     

    Thanks!


  7. Excellent tool! I'm having some problems though...

     

    I can't rename it, If i rename, after I login it appears an "Error box". It only works with the name "Loki Launcher.exe" is there anyway I can fix it?

     

    Thanks!

     

     

    PRE-SOLVED:
     
    If I change file name, it will work only if I Run as Adm, how can I make it run like "Loki Launcher.exe" with no need of permission?

  8. Nemo please repl my question :( i need your info :( "i use client 2012-04-10aragexe.exe "Increase Headgear ViewID" its not work, when i tried to using new headgear, (ViewID up to 1000++), my client crash, and then when i use WeeDiffPatcher, its work. can you help me? :("

     

    I am having this same problem, really need to fix it if possible...

     

    Thanks

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.