Jump to content
  • 0

Check party members timer


Question

Posted

I need something like this.

On trying to enter:
	if (anypartymember #partyquest1 > 0) {
	mes "Any of your party members didn't wait 6 hours before trying to start the PQ again";
	}


OnFinish: // This part is done.

	set #partyquest1, gettimetick ( 2 ) + 21600;
	end;

I need a entrance check of timer.

If any of the party members have #partyquest1 timer, they cant enter the partyquest.

7 answers to this question

Recommended Posts

  • 0
Posted

something similar ....

.@origin_aid = getcharid(3);
getpartymember getcharid(1),2;
for ( .@i = 0; .@i < $@partymembercount && !.@fail; .@i++ )
	if ( attachrid( $@partymemberaid[.@i] ) 
		if ( #partyquest1 > 0 ) {
			.@fail;
		}
attachrid( .@origin_aid );
if ( .@fail ) {
	mes "Any of your party members didn't wait 6 hours before trying to start the PQ again";
}

  • 0
Posted

It starts at line 271

getpartymember getcharid(1),1;
getpartymember getcharid(1),2;
for(set .@j, 0; .@j < $@partymembercount; .@j++){
	if(isloggedin($@partymemberaid[.@j], $@partymembercid[.@j])){
		if(attachrid($@partymemberaid[.@j])){
			if(h_run==1 && getcharid(3) != .@killerid && .@currentquest$ == currentquest$ && HP > 0){
				getmapxy(.@map2$,.@x2,.@y2,0);
				if(.@map1$ == .@map2$ && distance(.@x1,.@y1,.@x2,.@y2) < .party_range){
					if(getd(.@currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")<getd("."+.@currentquest$+"_huntingmob["+.@i+"]"))
					{
						setd(.@currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount", getd(.@currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+1);
						dispbottom getd("."+.@currentquest$+"_huntingname$")+": ["+strmobinfo(1,.@currentmob)+"] ("+ getd(.@currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+"/"+getd("."+.@currentquest$+"_huntingmob["+.@i+"]")+")";
					}
				}
			}
		}
	}
}
attachrid(.@killerid);

  • 0
Posted

 

something similar ....

.@origin_aid = getcharid(3);
getpartymember getcharid(1),2;
for ( .@i = 0; .@i < $@partymembercount && !.@fail; .@i++ )
	if ( attachrid( $@partymemberaid[.@i] ) 
		if ( #partyquest1 > 0 ) {
			.@fail;
		}
attachrid( .@origin_aid );
if ( .@fail ) {
	mes "Any of your party members didn't wait 6 hours before trying to start the PQ again";
}

 

Fking love u. Really thanks mate.

 

Another question, trying to store account cooldown and getting this:

http://prntscr.com/bmfxnr

 

Script:

	set #partyquest1, gettimetick ( 2 ) + 21600;

Its just 6 hours (360 mins)

and showing 24mil mins and storing:

1467198312 secs in acc_reg_num table.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...