Jump to content
  • 0

Can someone edit this?


Meister

Question


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

Good day,

Can someone edit this script I made.. I don't know how to do this in array or what script makers call it :P... So yeah..

The script goes like this..

//Synthesizer quest - Base (EDEN)

prontera,104,54,4	script	Scientist Que	857,{
if (BaseLevel > 70) {
mes "[scientist Que]";
mes "...So you're here for";
mes "the energy crystals.";
mes "You need to hunt 100 monster!";
mes "For every crystal energy!";
next;
mes "[scientist Que]";
mes "So.. choose what energy crystals you want. Goodluck!";
next;
switch(select("Unrefined Crystal Energy:Refined Crystal Energy:Pure Crystal Energy - 5:Pure Cyrstal Energy - 10")) {
case 1:
	if(checkquest(19950) != 1){
	switch(select("Requiem:Bathory:Spring Rabbit:Sleeper:Evil Druid:Petite:Clock")) {
		case 1: callsub L_Quest1,19900,"Requiem";
		case 2: callsub L_Quest1,19901,"Bathory";
		case 3: callsub L_Quest1,19902,"Spring Rabbit";
		case 4: callsub L_Quest1,19903,"Sleeper";
		case 5: callsub L_Quest1,19904,"Evil Druid";
		case 6: callsub L_Quest1,19905,"Petite";
		case 7: callsub L_Quest1,19906,"Clock";
	}
	}else{
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Unrefined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 2:
	if(checkquest(19951) != 1){
	switch(select("Siroma:Dark Priest:Stapo:Solider")) {
		case 1: callsub L_Quest2,19907,"Siroma";
		case 2: callsub L_Quest2,19908,"Dark Priest";
		case 3: callsub L_Quest2,19909,"Stapo";
		case 4: callsub L_Quest2,19910,"Solider";
	}
	}else{
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Refined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 3:
	if(checkquest(19952) != 1){
	switch(select("Desert Wolf:Medusa:Pinguicula:Majoruros")) {
		case 1: callsub L_Quest3,19911,"Desert Wolf";
		case 2: callsub L_Quest3,19912,"Medusa";
		case 3: callsub L_Quest3,19913,"Pinguicula";
		case 4: callsub L_Quest3,19914,"Majoruros";
	}
	}else{
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 4:
	if(checkquest(19953) != 1){
	switch(select("Raydric:Naga:Ancient Mummy:Ancient Mimic")) {
		case 1: callsub L_Quest4,19915,"Raydric";
		case 2: callsub L_Quest4,19916,"Naga";
		case 3: callsub L_Quest4,19917,"Ancient Mummy";
		case 4: callsub L_Quest4,19918,"Ancient Mimic";
	}
	}else{
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
}
end;
}else{
mes "[scientist Que]";
mes "Sorry but you're not strong enough";
mes "to get this quest reward yet!";
mes "Come back again next time!";
mes "Thanks!";
close;
end;
}

L_Quest1:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6623,10;
	setquest 19950;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest2:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6624,10;
	setquest 19951;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest3:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,5;
	setquest 19952;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest4:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,10;
	setquest 19953;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;
}

Link: http://upaste.me/7bd2950715d2628

My problem is..

If player choose Unrefined Crystal, then choose one of the quests. e.g. Requiem he will get it! but still can choose from the unrefined crystal again..

So.. I want that whenever a player already chosen a quest from the category, he/she can't choose quest again with the same category..

Am I understood here? or I freak out because I didn't explain it correctly? hehe. Sorry! yeah so, summarizing it, if player choose one quest from a category. He is prohibited to choose again from the same category until he/she finishes the quest and the cooldown of it.

Thanks!

bumping. sorry.

Edited by emong
Link to comment
Share on other sites

20 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

Ah, okay, I think I got what you meant.

I just assumed that every selection in the menu is a category so this is my solution:

//Synthesizer quest - Base (EDEN)

prontera,104,54,4	script	Scientist Que	857,{
if (BaseLevel > 70) {
mes "[scientist Que]";
mes "...So you're here for";
mes "the energy crystals.";
mes "You need to hunt 100 monster!";
mes "For every crystal energy!";
next;
mes "[scientist Que]";
mes "So.. choose what energy crystals you want. Goodluck!";
next;
switch(select("Unrefined Crystal Energy:Refined Crystal Energy:Pure Crystal Energy - 5:Pure Cyrstal Energy - 10")) {
case 1:
	if(bincat_quel&1) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19950) != 1){
	switch(select("Requiem:Bathory:Spring Rabbit:Sleeper:Evil Druid:Petite:Clock")) {
		case 1: callsub L_Quest1,19900,"Requiem";
		case 2: callsub L_Quest1,19901,"Bathory";
		case 3: callsub L_Quest1,19902,"Spring Rabbit";
		case 4: callsub L_Quest1,19903,"Sleeper";
		case 5: callsub L_Quest1,19904,"Evil Druid";
		case 6: callsub L_Quest1,19905,"Petite";
		case 7: callsub L_Quest1,19906,"Clock";
	}
	set bincat_quel, bincat_quel^1;
	}else{
	set bincat_quel, bincat_quel^1;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Unrefined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 2:
	if(bincat_quel&2) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19951) != 1){
	switch(select("Siroma:Dark Priest:Stapo:Solider")) {
		case 1: callsub L_Quest2,19907,"Siroma";
		case 2: callsub L_Quest2,19908,"Dark Priest";
		case 3: callsub L_Quest2,19909,"Stapo";
		case 4: callsub L_Quest2,19910,"Solider";
	}
	set bincat_quel, bincat_quel^2;
	}else{
	set bincat_quel, bincat_quel^2;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Refined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 3:
	if(bincat_quel&3) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19952) != 1){
	switch(select("Desert Wolf:Medusa:Pinguicula:Majoruros")) {
		case 1: callsub L_Quest3,19911,"Desert Wolf";
		case 2: callsub L_Quest3,19912,"Medusa";
		case 3: callsub L_Quest3,19913,"Pinguicula";
		case 4: callsub L_Quest3,19914,"Majoruros";
	}
	set bincat_quel, bincat_quel^3;
	}else{
	set bincat_quel, bincat_quel^3;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 4:
	if(bincat_quel&4) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19953) != 1){
	switch(select("Raydric:Naga:Ancient Mummy:Ancient Mimic")) {
		case 1: callsub L_Quest4,19915,"Raydric";
		case 2: callsub L_Quest4,19916,"Naga";
		case 3: callsub L_Quest4,19917,"Ancient Mummy";
		case 4: callsub L_Quest4,19918,"Ancient Mimic";
	}
	set bincat_quel, bincat_quel^4;
	}else{
	set bincat_quel, bincat_quel^4;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
}
end;
}else{
mes "[scientist Que]";
mes "Sorry but you're not strong enough";
mes "to get this quest reward yet!";
mes "Come back again next time!";
mes "Thanks!";
close;
end;
}

L_Quest1:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6623,10;
	setquest 19950;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest2:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6624,10;
	setquest 19951;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest3:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,5;
	setquest 19952;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest4:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,10;
	setquest 19953;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;
}

It's working with bits and xor.

I use the character-var bincat_quel and every category has a bit, so since there are 4 categories, there are 4 bits.

When you start one quest the bit should be set to 1 of the category.

Selecting the same category will activate the if clause which says, that you're already doing one quest of this category.

set bincat_quel, bincat_quel^1; Sets the first bit or unsets it ( Example first bit = 0 it will be set to 1 if it's 1 it will be set to 0.)

Hope this will work, never worked with bits in eathena's script language.

EDIT:

It seems that the script is talking about a cooldown of 23 hours but doesn't set it.

Should I add that too or do you got it already?

Edited by skyleo
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

Ah, okay, I think I got what you meant.

I just assumed that every selection in the menu is a category so this is my solution:

//Synthesizer quest - Base (EDEN)

prontera,104,54,4	script	Scientist Que	857,{
if (BaseLevel > 70) {
mes "[scientist Que]";
mes "...So you're here for";
mes "the energy crystals.";
mes "You need to hunt 100 monster!";
mes "For every crystal energy!";
next;
mes "[scientist Que]";
mes "So.. choose what energy crystals you want. Goodluck!";
next;
switch(select("Unrefined Crystal Energy:Refined Crystal Energy:Pure Crystal Energy - 5:Pure Cyrstal Energy - 10")) {
case 1:
	if(bincat_quel&1) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19950) != 1){
	switch(select("Requiem:Bathory:Spring Rabbit:Sleeper:Evil Druid:Petite:Clock")) {
		case 1: callsub L_Quest1,19900,"Requiem";
		case 2: callsub L_Quest1,19901,"Bathory";
		case 3: callsub L_Quest1,19902,"Spring Rabbit";
		case 4: callsub L_Quest1,19903,"Sleeper";
		case 5: callsub L_Quest1,19904,"Evil Druid";
		case 6: callsub L_Quest1,19905,"Petite";
		case 7: callsub L_Quest1,19906,"Clock";
	}
	set bincat_quel, bincat_quel^1;
	}else{
	set bincat_quel, bincat_quel^1;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Unrefined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 2:
	if(bincat_quel&2) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19951) != 1){
	switch(select("Siroma:Dark Priest:Stapo:Solider")) {
		case 1: callsub L_Quest2,19907,"Siroma";
		case 2: callsub L_Quest2,19908,"Dark Priest";
		case 3: callsub L_Quest2,19909,"Stapo";
		case 4: callsub L_Quest2,19910,"Solider";
	}
	set bincat_quel, bincat_quel^2;
	}else{
	set bincat_quel, bincat_quel^2;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Refined Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 3:
	if(bincat_quel&3) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19952) != 1){
	switch(select("Desert Wolf:Medusa:Pinguicula:Majoruros")) {
		case 1: callsub L_Quest3,19911,"Desert Wolf";
		case 2: callsub L_Quest3,19912,"Medusa";
		case 3: callsub L_Quest3,19913,"Pinguicula";
		case 4: callsub L_Quest3,19914,"Majoruros";
	}
	set bincat_quel, bincat_quel^3;
	}else{
	set bincat_quel, bincat_quel^3;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
case 4:
	if(bincat_quel&4) {
		mes "You're already doing one quest of this category, please complete it before starting a new one.";
		close;
	}
	if(checkquest(19953) != 1){
	switch(select("Raydric:Naga:Ancient Mummy:Ancient Mimic")) {
		case 1: callsub L_Quest4,19915,"Raydric";
		case 2: callsub L_Quest4,19916,"Naga";
		case 3: callsub L_Quest4,19917,"Ancient Mummy";
		case 4: callsub L_Quest4,19918,"Ancient Mimic";
	}
	set bincat_quel, bincat_quel^4;
	}else{
	set bincat_quel, bincat_quel^4;
	mes "[scientist Que]";
	mes "You have just finished..";
	mes "Pure Energy Crystal Quest";
	mes "Comeback after 23 hours!";
	close;
	}
}
end;
}else{
mes "[scientist Que]";
mes "Sorry but you're not strong enough";
mes "to get this quest reward yet!";
mes "Come back again next time!";
mes "Thanks!";
close;
end;
}

L_Quest1:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6623,10;
	setquest 19950;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest2:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6624,10;
	setquest 19951;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest3:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,5;
	setquest 19952;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;

L_Quest4:
if (checkquest(getarg(0),HUNTING) == 2) {
	mes "[scientist Que]";
	mes "Wow! You're amazing!";
	mes "You hunted all 100 "+getarg(1)+".";
	next;
	mes "[scientist Que]";
	mes "As a reward, here is your unrefined crystal energy..";
	mes "Hope you can make the improved item of your choice!..";
	next;
	erasequest getarg(0);
	getitem 6625,10;
	setquest 19953;
	mes "[scientist Que]";
	mes "Wooohoo!";
	mes "Good luck.";
	close;
}
if (checkquest(getarg(0)) == -1) {
	setquest getarg(0);
	mes "[scientist Que]";
	mes "Please hunt 100 "+getarg(1)+" and return here.";
	close;
}
mes "[scientist Que]";
mes "Umm? You didn't hunt";
mes "all 100 "+getarg(1)+" yet...";
mes "Will you check again?";
close;
}

It's working with bits and xor.

I use the character-var bincat_quel and every category has a bit, so since there are 4 categories, there are 4 bits.

When you start one quest the bit should be set to 1 of the category.

Selecting the same category will activate the if clause which says, that you're already doing one quest of this category.

set bincat_quel, bincat_quel^1; Sets the first bit or unsets it ( Example first bit = 0 it will be set to 1 if it's 1 it will be set to 0.)

Hope this will work, never worked with bits in eathena's script language.

EDIT:

It seems that the script is talking about a cooldown of 23 hours but doesn't set it.

Should I add that too or do you got it already?

Can you do it too? I already have the cooldown but i might mess your script. If you won't mind! Thanks! Imma try this asap!

It's still the same. player can still choose from the category even he already chose one..

Edited by emong
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

I don't think you can mess up my script since I explained my changes.

Just add your cooltime yourself, cause you need to learn it, not me. :D

I won't support lazy persons.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

I don't think you can mess up my script since I explained my changes.

Just add your cooltime yourself, cause you need to learn it, not me. :D

I won't support lazy persons.

Okay thanks anyways.. but the script still let me choose under the same category even if I have already chosen one.. :( didn't really changed..

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

It works only when you accepted the quest when you used my script.

Important Tip:

Don't complete the quest with my script when you've started the quest with you're old one.

This will mix it up.

Edited by skyleo
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

yes. I used it but still let me choose under the same category..

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

So you used my one to accept the quest?

I hope you didn't also use it for completing a quest, which you had started with your old script.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

So you used my one to accept the quest?

I hope you didn't also use it for completing a quest, which you had started with your old script.

I started a new one.. deleted my old ragnarok schema to delete everything and run it again. and yeah. it didn't work out. still letting me choose the same category. no back records of my old script :(

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

Can I see the finished script please?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

Can I see the finished script please?

actually I just copy paste your script and it doesn't work.. for the cooldown it is already coded their at L_Quest1 down to L_Quest4 by means of setting quest 19951-53 it is an entry on quest_db that has 23 hours cooldown.. and yeah.. after copy pasting your script. it really doesn't work.. don't know what happened..

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

Maybe the Script doesn't get as far to set variable.

When there was a close at the labels called with callsub it will be skipped.

So just put the set bincat_quel, bincat_quel^1; before the } else { at the beginning of the quest in the labels.

Okay?

(Don't forget Category 1 = set bincat_quel, bincat_quel^1; Category 2: set bincat_quel, bincat_quel^1;)

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

I don't get id. Can you give an example? or show an example?

cause by this.. you have already set the bincat before the } else {

if(checkquest(19951) != 1){

switch(select("Siroma:Dark Priest:Stapo:Solider")) {

case 1: callsub L_Quest2,19907,"Siroma";

case 2: callsub L_Quest2,19908,"Dark Priest";

case 3: callsub L_Quest2,19909,"Stapo";

case 4: callsub L_Quest2,19910,"Solider";

}

set bincat_quel, bincat_quel^2;

}else{

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

I think it won't reach this part, because the content in the called ( of callsub ) will have a close;.

To test this you can just write a mes "I want to know if the script reachs this part"; before the setting.

Do it since we're debugging :D

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

@skyleo: sorry for the late reply.. Callsub can't get be called back.after doing the script :(

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  39
  • Reputation:   2
  • Joined:  08/19/12
  • Last Seen:  

...

It's your script shouldn't you be able to find a part where you can just include this code?

Didn't I explain it enough?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

okay thanks.

Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

you can try this if you want...

http://pastebin.com/raw.php?i=PKfEi9RS

// Reward + Amount
setarray .@ItemID[0],607,1;
// Quest List
setarray .@QuestID[0],60119,60120,60121;
// Target Amount List
setarray .@QuestAmount[0],50,100,150;
// Target Name List
setarray .@QuestName$[0],"Alligator 1","Alligator 2","Alligator 3";
break;

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

you can try this if you want...

http://pastebin.com/raw.php?i=PKfEi9RS

// Reward + Amount
setarray .@ItemID[0],607,1;
// Quest List
setarray .@QuestID[0],60119,60120,60121;
// Target Amount List
setarray .@QuestAmount[0],50,100,150;
// Target Name List
setarray .@QuestName$[0],"Alligator 1","Alligator 2","Alligator 3";
break;

@emistry: Thanks! I've tried it already.. so here's what I found..

Chose category 1 and get quest. After getting the quest. I can still choose the same quest at the same category.. And if my previous quest is still on going. after talking to the NPC. my quest is gone. The NPC is deleting the quest log...

After doing the completing the quest. There's no cooldown to it. :( How can I set a 23 hours cooldown?

Edited by emong
Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

this part remove the quest if you cant finish ur quest within the time limit you set in the quest.....

 Case 1:
  mes "You hunted all ^0055FF"+.@QuestAmount[.@choose]+" x "+.@QuestName$[.@choose]+"^000000.";
  mes "But too bad....you cant make it in time.....";
  erasequest getd("Quest"+.@quest );
  setd("Quest"+.@quest ),0;
  break;


check cooldown...

  mes "[scientist Que]";
  if( getd("QuestDelay"+.@quest ) > gettimetick(2) ){
   mes "Please wait for 23 Hours before you can do again.";
  }
  switch( checkquest( getd("Quest"+.@quest),HUNTING ) ){

add cooldown

  setd("Quest"+.@quest ),0;
  getitem .@ItemID[0],.@ItemID[1];
  set setd("QuestDelay"+.@quest ), gettimetick(2)+ ( 23 * 3600 );  

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  280
  • Topics Per Day:  0.06
  • Content Count:  841
  • Reputation:   17
  • Joined:  04/16/12
  • Last Seen:  

Edit Solved! Thanks!

Edited by emong
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...