Jump to content
  • 0

Quest Delay


tokisboy

Question


  • Group:  Members
  • Topic Count:  5
  • Topics Per Day:  0.00
  • Content Count:  6
  • Reputation:   0
  • Joined:  01/22/19
  • Last Seen:  

good day i want to ask where do i put the script that enable the npc make a cooldown before talking the quest again

 

where do i place it ? if possible please tell me what the codes is i want to put 1 hr cooldown on this script

mvp_ladder.txt

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  34
  • Topics Per Day:  0.01
  • Content Count:  159
  • Reputation:   58
  • Joined:  07/11/14
  • Last Seen:  

I haven't tested it, but I hope it's the way you asked.


you define the cooldown in:

set .@cooldown,60; //time in minute

 

the changes I made for you to understand
 

~1 before

if ( strcharinfo(3) == strnpcinfo(4))
  .@online++;

~ afeter
  
if ( strcharinfo(3) == strnpcinfo(4) && RoomCD < gettimetick(2)) .@online++; else set .@CDnicks$,.@CDnicks$+strcharinfo(0)+", ";


~2 before

else if ( .party_id ) {
 mes "[MvP Ladder Warper]";
 mes "I'm sorry, but a party is currently playing the game. Please standby until the party is finished.";
 mes "Thank you.";
 close;
}

~ afeter

else if ( .@CDnicks$ != "" ) {
 mes "[MvP Ladder Warper]";
 mes "There are players in your group with active cooldown!";
 mes "^FF0000"+.@CDnicks$+"^000000";
 close;
}

~3 before
  
 Zeny -= .register_cost;
 announce "The party ["+ strcharinfo(1) +"] has started the MvP ladder game.", bc_all;
 set .party_id, getcharid(1);
 set .@time_enter, gettimetick(2);

~ afeter

 Zeny -= .register_cost;
 announce "The party ["+ strcharinfo(1) +"] has started the MvP ladder game.", bc_all;
 set .party_id, getcharid(1);
 set .@time_enter, gettimetick(2);
 set .@cooldown,60; //time in minute

~4 before

 announce "You have "+ .timeout +" minutes to complete "+ .totalround +" rounds.", bc_self;
 .@name$[.@c] = strcharinfo(0);
 .@c++;

~ afeter

 announce "You have "+ .timeout +" minutes to complete "+ .totalround +" rounds.", bc_self;
 .@name$[.@c] = strcharinfo(0);
 RoomCD = gettimetick(2)+(60*.@cooldown);
 .@c++;

mvp_ladder.txt

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