Jump to content
  • 0

How to put quest cooldown 24h in this script?


Noctis

Question


  • Group:  Members
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  226
  • Reputation:   13
  • Joined:  02/17/15
  • Last Seen:  

if (!callfunc("D_huntermark")) {
		mes "You need to have a";
		mes "^4d4dff'Hunter License'^000000";
		mes "to receive this mission.";
		close;
	}
if (checkquest(70255) != -1) {
		if (checkquest(70255,HUNTING) != 2 ) {
			mes "[Leorio Veteran Hunter]";
			mes "Are you done with those Ferus? Quit slacking?";
			next;
			switch(select("Yes:No:I want to withdraw from this mission")) {
			case 1:
				mes "[Leorio Veteran Hunter]";
				mes "Other Hunters would be honoured to receive such an assignment.";
				mes "Don't ever think of coming back until the task is done, got it?";
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "You STILL haven't suceed? Time is short, make it quick!";
				close;
			case 3:
				mes "[Leorio Veteran Hunter]";
				mes "Not everyone's up for a challenge. You need to train harder.";
				mes "Are you 100% sure you want to withdraw?";
				next;
				switch(select("Yes:No")) {
				case 1:
					mes "[Leorio Veteran Hunter]";
					mes "Until we meet again, Hunter.";
					erasequest 70255;
					close;
				case 2:
					mes "[Leorio Veteran Hunter]";
					mes "That's the spirit! No quitters! Give 'em hell!";
					close;
				}
			}
		}
		mes "[Leorio Veteran Hunter]";
		mes "You proved yourself worthy and willing. Congratulations, you've been rewarded.";
		specialeffect2 EF_MAGICALATTHIT;
		specialeffect2 EF_POTION2;
		specialeffect2 EF_ANGEL2;
		getexp 18818,7527;
		erasequest 70255;
		close;
	}
	if ((BaseLevel > 141) && (BaseLevel < 150)) {
		mes "[Leorio Veteran Hunter]";
		mes "Name's Leorio. Im a Veteran Hunter for the Rune Midgard Hunting Elite, we have plenty of tasks that need a hand, and will receive some loot in return.";
		mes "What do you say? Willing to work for us?";
		next;
		switch(select("Sure:No")) {
		case 1:
			mes "Are you absolutely sure about this?";
			next;
			switch(select("Of course:Just kidding")) {
			case 1:
				if(BaseLevel > 151){
					mes "[Leorio Veteran Hunter]";
					mes "Let the low ones get these leftovers, go talk to someone else within the Rune Midgard Hunting Elite.";
					close;
				}
				mes "[Leorio Veteran Hunter]";
				mes "Seems like you can be worthy. Let's see if you can handle my task. I doubt it, but we'll see.";
				setquest 70255;
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "On second thought, I guess there's no harm in joining.";
				close;
			}
		case 2:
			mes "[Leorio Veteran Hunter]";
			mes "We only want the best with us either way.";
			close;
		}
	}
	mes "[Leorio Veteran Hunter]";
	mes "This is way ahead of your league, newbie. Go back to the safety of Prontera.";
	close;
}

 

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.01
  • Content Count:  98
  • Reputation:   74
  • Joined:  12/04/14
  • Last Seen:  

@Noctis Try this ( based on your script )

 

if (!callfunc("D_huntermark")) {
		mes "You need to have a";
		mes "^4d4dff'Hunter License'^000000";
		mes "to receive this mission.";
		close;
	}
if (checkquest(70255) != -1) {
		if (checkquest(70255,HUNTING) != 2 ) {
			mes "[Leorio Veteran Hunter]";
			mes "Are you done with those Ferus? Quit slacking?";
			next;
			switch(select("Yes:No:I want to withdraw from this mission")) {
			case 1:
				mes "[Leorio Veteran Hunter]";
				mes "Other Hunters would be honoured to receive such an assignment.";
				mes "Don't ever think of coming back until the task is done, got it?";
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "You STILL haven't suceed? Time is short, make it quick!";
				close;
			case 3:
				mes "[Leorio Veteran Hunter]";
				mes "Not everyone's up for a challenge. You need to train harder.";
				mes "Are you 100% sure you want to withdraw?";
				next;
				switch(select("Yes:No")) {
				case 1:
					mes "[Leorio Veteran Hunter]";
					mes "Until we meet again, Hunter.";
					erasequest 70255;
					close;
				case 2:
					mes "[Leorio Veteran Hunter]";
					mes "That's the spirit! No quitters! Give 'em hell!";
					close;
				}
			}
		}
		mes "[Leorio Veteran Hunter]";
		mes "You proved yourself worthy and willing. Congratulations, you've been rewarded.";
		specialeffect2 EF_MAGICALATTHIT;
		specialeffect2 EF_POTION2;
		specialeffect2 EF_ANGEL2;
		getexp 18818,7527;
		erasequest 70255;
		close;
	}
	if ((BaseLevel > 141) && (BaseLevel < 150)) {
		mes "[Leorio Veteran Hunter]";
		mes "Name's Leorio. Im a Veteran Hunter for the Rune Midgard Hunting Elite, we have plenty of tasks that need a hand, and will receive some loot in return.";
		mes "What do you say? Willing to work for us?";
		next;
		switch(select("Sure:No")) {
		case 1:
			mes "Are you absolutely sure about this?";
			next;
			switch(select("Of course:Just kidding")) {
			case 1:
				if(BaseLevel > 151){
					mes "[Leorio Veteran Hunter]";
					mes "Let the low ones get these leftovers, go talk to someone else within the Rune Midgard Hunting Elite.";
					close;
				}
				if(character_delay>gettimetick(2)){
					mes "[Leorio Veteran Hunter]";
					mes "You need to wait";
					set .@h,((character_delay-gettimetick(2))/3600);
					set .@m,((character_delay-gettimetick(2))-(.@h*3600))/60;
					if( .@m > 0 ){
						if( .@h > 0 )
							mes "^4d4dff"+.@h+"^000000:^4d4dff"+.@m+"^000000 hour(s)";
						else
							mes "^4d4dff"+.@m+"^000000 minutes";
					}
					mes "to get new mission.";
					close;
				}
				mes "[Leorio Veteran Hunter]";
				mes "Seems like you can be worthy. Let's see if you can handle my task. I doubt it, but we'll see.";
				setquest 70255;
				set character_delay,gettimetick(2)+86400;
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "On second thought, I guess there's no harm in joining.";
				close;
			}
		case 2:
			mes "[Leorio Veteran Hunter]";
			mes "We only want the best with us either way.";
			close;
		}
	}
	mes "[Leorio Veteran Hunter]";
	mes "This is way ahead of your league, newbie. Go back to the safety of Prontera.";
	close;
}

 

I haven't tested but i think it will work :) 

Edited by Keitenai
  • Upvote 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  117
  • Topics Per Day:  0.03
  • Content Count:  312
  • Reputation:   34
  • Joined:  10/15/12
  • Last Seen:  

i think through quest_db you can adjust the cool down of the quest

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  226
  • Reputation:   13
  • Joined:  02/17/15
  • Last Seen:  

27 minutes ago, iubantot said:

i think through quest_db you can adjust the cool down of the quest

In quest db there is only the time limit for the quest

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  226
  • Reputation:   13
  • Joined:  02/17/15
  • Last Seen:  

7 minutes ago, Keitenai said:

@Noctis Try this ( based on your script )

 


if (!callfunc("D_huntermark")) {
		mes "You need to have a";
		mes "^4d4dff'Hunter License'^000000";
		mes "to receive this mission.";
		close;
	}
if (checkquest(70255) != -1) {
		if (checkquest(70255,HUNTING) != 2 ) {
			mes "[Leorio Veteran Hunter]";
			mes "Are you done with those Ferus? Quit slacking?";
			next;
			switch(select("Yes:No:I want to withdraw from this mission")) {
			case 1:
				mes "[Leorio Veteran Hunter]";
				mes "Other Hunters would be honoured to receive such an assignment.";
				mes "Don't ever think of coming back until the task is done, got it?";
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "You STILL haven't suceed? Time is short, make it quick!";
				close;
			case 3:
				mes "[Leorio Veteran Hunter]";
				mes "Not everyone's up for a challenge. You need to train harder.";
				mes "Are you 100% sure you want to withdraw?";
				next;
				switch(select("Yes:No")) {
				case 1:
					mes "[Leorio Veteran Hunter]";
					mes "Until we meet again, Hunter.";
					erasequest 70255;
					close;
				case 2:
					mes "[Leorio Veteran Hunter]";
					mes "That's the spirit! No quitters! Give 'em hell!";
					close;
				}
			}
		}
		mes "[Leorio Veteran Hunter]";
		mes "You proved yourself worthy and willing. Congratulations, you've been rewarded.";
		specialeffect2 EF_MAGICALATTHIT;
		specialeffect2 EF_POTION2;
		specialeffect2 EF_ANGEL2;
		getexp 18818,7527;
		erasequest 70255;
		close;
	}
	if ((BaseLevel > 141) && (BaseLevel < 150)) {
		mes "[Leorio Veteran Hunter]";
		mes "Name's Leorio. Im a Veteran Hunter for the Rune Midgard Hunting Elite, we have plenty of tasks that need a hand, and will receive some loot in return.";
		mes "What do you say? Willing to work for us?";
		next;
		switch(select("Sure:No")) {
		case 1:
			mes "Are you absolutely sure about this?";
			next;
			switch(select("Of course:Just kidding")) {
			case 1:
				if(BaseLevel > 151){
					mes "[Leorio Veteran Hunter]";
					mes "Let the low ones get these leftovers, go talk to someone else within the Rune Midgard Hunting Elite.";
					close;
				}
				if(character_delay>gettimetick(2)){
					mes "[Leorio Veteran Hunter]";
					mes "You need to wait";
					set .@h,(((character_delay-gettimetick(2))/24)/60)/60;
					set .@m,((character_delay-gettimetick(2))/24)/60;
					if( .@m > 0 ){
						if( .@h > 0 )
							mes "^4d4dff"+.@h+"^000000:^4d4dff"+.@m+"^000000 hour(s)";
						else
							mes "^4d4dff"+.@m+"^000000 minutes";
					}
					mes "to get new mission.";
					close;
				}
				mes "[Leorio Veteran Hunter]";
				mes "Seems like you can be worthy. Let's see if you can handle my task. I doubt it, but we'll see.";
				setquest 70255;
				set character_delay,gettimetick(2)+86400;
				close;
			case 2:
				mes "[Leorio Veteran Hunter]";
				mes "On second thought, I guess there's no harm in joining.";
				close;
			}
		case 2:
			mes "[Leorio Veteran Hunter]";
			mes "We only want the best with us either way.";
			close;
		}
	}
	mes "[Leorio Veteran Hunter]";
	mes "This is way ahead of your league, newbie. Go back to the safety of Prontera.";
	close;
}

 

I haven't tested but i think it will work :) 

It worked thx <3

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