Jump to content
  • 0

NPC Message Bug? (emulator)


danielps

Question


  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  174
  • Reputation:   18
  • Joined:  10/09/14
  • Last Seen:  

Hello everyone,

So, i'll be very direct.

Some times when i talk with a npc that i created it shows-me a whit screen (like a empt mes ""; with no "next;")
Like this one that i attached...

and it makes no sense, once my script is perfectly normal..

My script is:

1@gen,103,91,3	script	Premiador	416,{
	mes "[^FF0000 Premiador ^000000]";
	//mes "Olá "+strcharinfo(0)+",";
	mes "Parabéns pela vitória, como posso lhe ajudar?";
	main:
	switch(select($menu$+"Sortear premio",$menu$+"Informações")){
		next;
		mes "[^FF0000 Premiador ^000000]";
		case 1:
			mes "Muito bem, vamos sortear o seu prêmio....";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Prontinho, já tenho aqui seu premio, até mais!";
			close2;
			/*do{
				set @item,rand(31272,31310); //MASSA DE ITENS DO SISTEMA DE ENCANTAMENTO
			} 
			while ((@item>=31311 && @item<=31315) || @item>31336); //IDS QUE ESTÁ NO MEIO DESSE INTERVALO E QUE ESTÁ VAZIO
			*/
			set @item,rand(31272,31289); //MASSA DE ITENS DO SISTEMA DE ENCANTAMENTO
			if(rand(1,10)<7){// 70% de não conseguir o anel
					//mes "Parabéns! Seu premio sorteado foi 1x ^0000FF"+getitemname(@item)+"^000000!";
					//next;
					getitem @item,1;
					warp "prontera",155,208;
					end;
			}
			
			//mes "Parabéns! Seu premio sorteado foi 1x ^0000FFAnel de GM^000000!";
			//next;
			getitem 31354,1;// DA ANEL DE GM
			//getitem @item,1; // DA PREMIO SORTEADO
			warp "prontera",155,208;
			end;
			
			fim:
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Agora vou leva-l"+(Sex?"o":"a")+" de volta a prontera!";
			warp "prontera",155,208;
			end;
		break;
		case 2:
			mes "Bom, todos que derrotam o GM Himura são recompensados com uma pedra de encantamento aleatória, e 40% de chance de ganhar um Anel de GM";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "As pedras podem ser dos tipos:";
			mes "1- Pedras de atributo encantam equipiamentos com +5, +10 ou +15 de algum atributo.";
			mes "2- Pedras de habilidades, encantam equipamentos com uma habilidade, ex: nevasca nivel 3.";
			mes "3- Pedras de bonus, encantam equipamentos com um bonus, ex: 10%dano em humano.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Já o Anel de GM, é um acessório fraco mas pode ser extremamente poderoso, ele exige refinamento para se tornar forte, dando +1 em todos os estatus e habilidades e bonus para cada refinamento. Os atributos e bonus são acumulados até refinamento +15.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Bom é isso ai, posso ajudar em algo mais?";
			goto main;
		break;
	}

}

 

I commented strcharinfo(0) cause i tought it maybe the name, some caracter in the nick, but stil having some problens...

Some times wheni talk with npc, it shows the message normaly, sometimes show the white screen atached here... wtf is it randon? some timrs bug some times not? o.O
I really never saw that, i don't understand...

 

85dad671-0489-431c-97b5-20c9931cb9c5.jpg

Link to comment
Share on other sites

8 answers to this question

Recommended Posts

  • 0

  • Group:  Developer
  • Topic Count:  50
  • Topics Per Day:  0.02
  • Content Count:  763
  • Reputation:   227
  • Joined:  02/11/17
  • Last Seen:  

Try Removing This part i had a same case with my npc fixed it by removing the mes before a case.

	switch(select($menu$+"Sortear premio",$menu$+"Informações")){
		next;
		mes "[^FF0000 Premiador ^000000]"; <-----
		case 1:

 

Edited by crazyarashi
Adding info
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  174
  • Reputation:   18
  • Joined:  10/09/14
  • Last Seen:  

9 minutes ago, crazyarashi said:

Try Removing This part i had a same case with my npc fixed it by removing the mes before a case.


	switch(select($menu$+"Sortear premio",$menu$+"Informações")){
		next;
		mes "[^FF0000 Premiador ^000000]"; <-----
		case 1:

 

Ok i'll try, but see the print screen..

if it were the problema, why the switch dont show de menu? or the message before? "

mes "Parabéns pela vitória, como posso lhe ajudar?";"

?

And i make all my npc like that...

switch( select (menu here){
 next;
mes;
case 1:

case 2:
}

And everythig is normal, only that one has this problem =/
Anyway i'll try and i tell you!
 

Link to comment
Share on other sites

  • 0

  • Group:  Developer
  • Topic Count:  50
  • Topics Per Day:  0.02
  • Content Count:  763
  • Reputation:   227
  • Joined:  02/11/17
  • Last Seen:  

Just now, danielps said:

Ok i'll try, but see the print screen..

if it were the problema, why the switch dont show de menu? or the message before? "


mes "Parabéns pela vitória, como posso lhe ajudar?";"

?

And i make all my npc like that...

switch( select (menu here){
 next;
mes;
case 1:

case 2:
}

And everythig is normal, only that one has this problem =/
Anyway i'll try and i tell you!
 

Tested it :D

screenStormRO054.jpg

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  8
  • Topics Per Day:  0.00
  • Content Count:  72
  • Reputation:   28
  • Joined:  12/21/16
  • Last Seen:  

try this?

1@gen,103,91,3	script	Premiador	416,{
	mes "[^FF0000 Premiador ^000000]";
	mes "Olá "+strcharinfo(0);
	mes "Parabéns pela vitória, como posso lhe ajudar?";
	main:
	switch(select($menu$+"Sortear premio",$menu$+"Informações")){
		next;
		mes "[^FF0000 Premiador ^000000]";
		case 1:
			mes "Muito bem, vamos sortear o seu prêmio....";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Prontinho, já tenho aqui seu premio, até mais!";
			close2;			
			if(rand(1,10)<8){						// 70% de não conseguir o anel		
					set .@i,rand(1,2);
					if (.@i>1) getitem 31272,1;
					else getitem 31289,1;
					warp "prontera",155,208;
					end;
			}			
			getitem 31354,1;						// DA ANEL DE GM
			warp "prontera",155,208;
			end;
		case 2:
			mes "Bom, todos que derrotam o GM Himura são recompensados com uma pedra de encantamento aleatória, e 40% de chance de ganhar um Anel de GM";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "As pedras podem ser dos tipos:";
			mes "1- Pedras de atributo encantam equipiamentos com +5, +10 ou +15 de algum atributo.";
			mes "2- Pedras de habilidades, encantam equipamentos com uma habilidade, ex: nevasca nivel 3.";
			mes "3- Pedras de bonus, encantam equipamentos com um bonus, ex: 10%dano em humano.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Já o Anel de GM, é um acessório fraco mas pode ser extremamente poderoso, ele exige refinamento para se tornar forte, dando +1 em todos os estatus e habilidades e bonus para cada refinamento. Os atributos e bonus são acumulados até refinamento +15.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Bom é isso ai, posso ajudar em algo mais?";
			goto main;
	}

}

i dont understand what this npc talkin about :blink:

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  912
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

When done doing conversation and adding next menu the coversation should be like this as always

example 
 

mes "text";
next;
switch(select(("test","test")){
case 1:
		mes"test"
		close;
case 2:
		mes"test"
		close;
}

to avoid error

  • Upvote 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  174
  • Reputation:   18
  • Joined:  10/09/14
  • Last Seen:  

2 hours ago, Poring King said:

When done doing conversation and adding next menu the coversation should be like this as always

example 
 


mes "text";
next;
switch(select(("test","test")){
case 1:
		mes"test"
		close;
case 2:
		mes"test"
		close;
}

to avoid error

I like put next after switch select, why? simples, it's more beaty, cause player select a menu and than click next to see next page =D If i do like you, he don't see the menu, he first click next than he see the menu, and when he select the menu the message of case 1 or case 2 they willl show in the same page of menu question... its very ugly '-'

i prefer my way....

 

2 hours ago, crazyarashi said:

Tested it :D

screenStormRO054.jpg

Ok but did you test first my original script? It give whit screen some times to you? try testin many times both my original script and your version, see if mine or your show you white screen...

 

2 hours ago, Valor said:

try this?


1@gen,103,91,3	script	Premiador	416,{
	mes "[^FF0000 Premiador ^000000]";
	mes "Olá "+strcharinfo(0);
	mes "Parabéns pela vitória, como posso lhe ajudar?";
	main:
	switch(select($menu$+"Sortear premio",$menu$+"Informações")){
		next;
		mes "[^FF0000 Premiador ^000000]";
		case 1:
			mes "Muito bem, vamos sortear o seu prêmio....";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Prontinho, já tenho aqui seu premio, até mais!";
			close2;			
			if(rand(1,10)<8){						// 70% de não conseguir o anel		
					set .@i,rand(1,2);
					if (.@i>1) getitem 31272,1;
					else getitem 31289,1;
					warp "prontera",155,208;
					end;
			}			
			getitem 31354,1;						// DA ANEL DE GM
			warp "prontera",155,208;
			end;
		case 2:
			mes "Bom, todos que derrotam o GM Himura são recompensados com uma pedra de encantamento aleatória, e 40% de chance de ganhar um Anel de GM";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "As pedras podem ser dos tipos:";
			mes "1- Pedras de atributo encantam equipiamentos com +5, +10 ou +15 de algum atributo.";
			mes "2- Pedras de habilidades, encantam equipamentos com uma habilidade, ex: nevasca nivel 3.";
			mes "3- Pedras de bonus, encantam equipamentos com um bonus, ex: 10%dano em humano.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Já o Anel de GM, é um acessório fraco mas pode ser extremamente poderoso, ele exige refinamento para se tornar forte, dando +1 em todos os estatus e habilidades e bonus para cada refinamento. Os atributos e bonus são acumulados até refinamento +15.";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Bom é isso ai, posso ajudar em algo mais?";
			goto main;
	}

}

i dont understand what this npc talkin about :blink:

Dont think it will change anything... i use this in all my scripts... its just a , afeter the name, when player talk with npc it will be show like this:
Hello player,
Nice to see you.

You way would be:
Hello player
Nice to see you

And the npc is talking portuguese =D

I'll try your way @crazyarashi even i think it would not change hehe but from all opinions this is the only that make a little os sence... 

Link to comment
Share on other sites

  • 0

  • Group:  Developer
  • Topic Count:  50
  • Topics Per Day:  0.02
  • Content Count:  763
  • Reputation:   227
  • Joined:  02/11/17
  • Last Seen:  

2 minutes ago, danielps said:

I like put next after switch select, why? simples, it's more beaty, cause player select a menu and than click next to see next page =D If i do like you, he don't see the menu, he first click next than he see the menu, and when he select the menu the message of case 1 or case 2 they willl show in the same page of menu question... its very ugly '-'

i prefer my way....

 

Ok but did you test first my original script? It give whit screen some times to you? try testin many times both my original script and your version, see if mine or your show you white screen...

 

Dont think it will change anything... i use this in all my scripts... its just a , afeter the name, when player talk with npc it will be show like this:
Hello player,
Nice to see you.

You way would be:
Hello player
Nice to see you

And the npc is talking portuguese =D

I'll try your way @crazyarashi even i think it would not change hehe but from all opinions this is the only that make a little os sence... 

If that didnt work try giving this a try :)) 

ra_temsky,148,135,4	script	Premiador	416,{
	mes "[^FF0000 Premiador ^000000]";
	mes "Ola "+strcharinfo(0)+",";
	mes "Parabens pela vitoria, como posso lhe ajudar?";
	goto main;
	next;	

	main:
	switch(select($menu$+"Sortear premio",$menu$+"Informacoes")){
		next;
		case 1:
			mes "[^FF0000 Premiador ^000000]";
			mes "Muito bem, vamos sortear o seu premio....";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Prontinho, ja tenho aqui seu premio, ate mais!";
			close2;

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  174
  • Reputation:   18
  • Joined:  10/09/14
  • Last Seen:  

1 minute ago, crazyarashi said:

If that didnt work try giving this a try :)) 


ra_temsky,148,135,4	script	Premiador	416,{
	mes "[^FF0000 Premiador ^000000]";
	mes "Ola "+strcharinfo(0)+",";
	mes "Parabens pela vitoria, como posso lhe ajudar?";
	goto main;
	next;	

	main:
	switch(select($menu$+"Sortear premio",$menu$+"Informacoes")){
		next;
		case 1:
			mes "[^FF0000 Premiador ^000000]";
			mes "Muito bem, vamos sortear o seu premio....";
			next;
			mes "[^FF0000 Premiador ^000000]";
			mes "Prontinho, ja tenho aqui seu premio, ate mais!";
			close2;

 

I'll try both, even it looks me like " jerry-rigged" hahah thanks !
Soon i tell you if it worked!

Link to comment
Share on other sites

Join the conversation

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

Guest
Answer this question...

×   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...