Jump to content
  • 0

buffer request


orange

Question


  • Group:  Members
  • Topic Count:  39
  • Topics Per Day:  0.01
  • Content Count:  175
  • Reputation:   7
  • Joined:  09/13/12
  • Last Seen:  

hello guys

 

i would like to request for a guild buffer npc

 

this npc would respond only to the guild master during woe. it would b invisible when woe is off and would b visible only when woe is on.

 

the npc would charge a amount of 1000z for each member online. for example, if 10 people are online the 1000z x 10 = 10000z would b charged from the guild master.

 

when this npc is used, the whole guild should b in the same map ( in same city) .if any member is in any other map, then that member will not get this buff. and it would give buffs like heal , agi, buff, impo, assump,etc

 

to avoid abuse, a cooldown time of 10 min should b set.

 

thank you!!

 

Link to comment
Share on other sites

1 answer to this question

Recommended Posts


  • Group:  Developer
  • Topic Count:  10
  • Topics Per Day:  0.00
  • Content Count:  2407
  • Reputation:   613
  • Joined:  07/05/12
  • Last Seen:  

//    ~~~~~ show time left in days, hours, minutes and seconds ~~~~~
function	script	timeleft__	{
    if ( ( .@left = getarg(0) ) <= 0 ) return getarg(0);
    .@day = .@left / 86400;
    .@hour = .@left % 86400 / 3600;
    .@min = .@left % 3600 / 60;
    .@sec = .@left % 60;
    if ( .@day )
        return .@day +" day "+ .@hour +" hour";
    else if ( .@hour )
        return .@hour +" hour "+ .@min +" min";
    else if ( .@min )
        return .@min +" min "+ .@sec +" sec";
    else
        return .@sec +" sec";
}

prontera,166,185,6	script	ghjkl	56,{

	if( !getcharid(2) ) {
		dispbottom "you are not in a guild !";
		end;
	}
	else if( getguildmaster( getcharid(2) ) != strcharinfo(0) ) {
		dispbottom "I only talk to your guildmaster, go away !";
		end;
	}
	else if( cooldown_g > gettimetick(2) ) {
		dispbottom "You must wait "+ callfunc( "timeleft__", cooldown_g - gettimetick(2) );
		end;
	}
	.@size = query_sql( "SELECT name FROM guild_member WHERE guild_id = "+ getcharid(2), .@name$ );
	.@map_leader$ = strcharinfo(3);
	for( .@i = 0; .@i < .@size; .@i++ )
		if( !getmapxy( .@map$, .@x, .@y, 0, .@name$[.@i] ) && .@map$ == .@map_leader$ ) {
			.@s_name$[.@count] = .@name$[.@i];
			.@count++;
		}
	if( Zeny < .cost * .@count ) end;
	Zeny = Zeny - .cost * .@count;
	cooldown_g = gettimetick(2) + 60 * 10;// 10min - should restricted @changegm during woe
	for( .@i = 0; .@i < .@count; .@i++ ) {
		attachrid( getcharid( 3,.@s_name$[.@i] ) );
		percentheal 100,100;
		specialeffect2 EF_INCAGILITY; sc_start SC_INCREASEAGI,240000,5;
		specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,5;
	}
	end;
OnAgitstart:
OnAgitstart2:
	enablenpc strnpcinfo(0);
	end;
OnInit:
	.cost = 1000; // Zeny/member
OnAgitEnd:
OnAgitEnd2:
	disablenpc strnpcinfo(0);
	end;
}

Try this one

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