Jump to content
  • 0
IndieRO

Help with npc buffer

Question

hi, i use this script

-	script	Healer	-1,{	.@price = 0;	// Zeny required for heal	.@Buffs = 1;	// Also buff players? (1: yes / 0: no)	.@Delay = 2;	// Heal delay, in seconds	if (@HD > gettimetick(2)) end;	if (.@price) {		message strcharinfo(0),"Healing costs "+.@price+" Zeny.";		if (Zeny < .@price) end;		if(select("^0055FFHeal^000000:^777777Cancel^000000") == 2) close;		Zeny -= .@price;	}	specialeffect2 EF_HEAL2; percentheal 100,100;	if (.@Buffs) {		specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10;		specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10;	}	if (.@Delay) @HD = gettimetick(2)+.@Delay;	close;}
how to change if base lv <99 u get more buff and if baselv> 150 player just get bless and agi.somebody help mesorry for bad english

Share this post


Link to post
Share on other sites

9 answers to this question

Recommended Posts

  • 0

I think you're in the wrong section (should be in support, not request).

 

For your problem, add a check in .@Buffs section to verify the BaseLevel value, and use different bonus affectations according to the level.

Share this post


Link to post
Share on other sites
  • 0

im sorry im noob ..you means is like this???

.@price = 0;	// Zeny required for heal	.@Buffs = 1;	// Also buff players? (1: yes / 0: no)	.@Delay = 2;	// Heal delay, in seconds	if (@HD > gettimetick(2)) end;	if (.@price) {		message strcharinfo(0),"Healing costs "+.@price+" Zeny.";		if (Zeny < .@price) end;		if(select("^0055FFHeal^000000:^777777Cancel^000000") == 2) close;		Zeny -= .@price;	}	specialeffect2 EF_HEAL2; percentheal 100,100;	if (.@Buffs) {		if(BaseLevel150) goto Buffer;		Buffer:		specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10;		specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10;		Buff:		skilleffect 361,0; sc_start SC_ASSUMPTIO,360000,5;		skilleffect 34,0; sc_start SC_BLESSING,300000,10;		skilleffect 29,0; sc_start SC_INCREASEAGI,300000,10;	    skilleffect 112,0; sc_start SC_WEAPONPERFECTION,360000,10;	    skilleffect 380,0; sc_start SC_TRUESIGHT,360000,5;	    skilleffect 464,0; sc_start SC_KAUPE,360000,3;		skilleffect 33,0; sc_start SC_ANGELUS,360000,10;		skilleffect 463,0; sc_start SC_KAAHI,360000,7;		skilleffect 383,0; sc_start SC_WINDWALK,360000,5;		skilleffect 66,0; sc_start SC_IMPOSITIO,360000,5;		skilleffect 67,0; sc_start SC_SUFFRAGIUM,360000,3;	}	if (.@Delay) @HD = gettimetick(2)+.@Delay;	close;}
i was try like this but when player click npc buffer player get stuck and can't move like get effect stone curse.please fix my script if any wrong edit

Share this post


Link to post
Share on other sites
  • 0
.@price = 0;	// Zeny required for heal	.@Buffs = 1;	// Also buff players? (1: yes / 0: no)	.@Delay = 2;	// Heal delay, in seconds	if (@HD > gettimetick(2)) end;	if (.@price) {		message strcharinfo(0),"Healing costs "+.@price+" Zeny.";		if (Zeny < .@price) end;		if(select("^0055FFHeal^000000:^777777Cancel^000000") == 2) close;		Zeny -= .@price;	}	specialeffect2 EF_HEAL2; percentheal 100,100;	if (.@Buffs) {		if(BaseLevel == 150) 		{			goto Buffer;		}		else 		{			goto Buffs;		}	}	close;	Buffer:	specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10;	specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10;	if (.@Delay) 	{		@HD = gettimetick(2)+.@Delay;	}	close;Buff:	skilleffect 361,0; sc_start SC_ASSUMPTIO,360000,5;	skilleffect 34,0; sc_start SC_BLESSING,300000,10;	skilleffect 29,0; sc_start SC_INCREASEAGI,300000,10;	skilleffect 112,0; sc_start SC_WEAPONPERFECTION,360000,10;	skilleffect 380,0; sc_start SC_TRUESIGHT,360000,5;	skilleffect 464,0; sc_start SC_KAUPE,360000,3;	skilleffect 33,0; sc_start SC_ANGELUS,360000,10;	skilleffect 463,0; sc_start SC_KAAHI,360000,7;	skilleffect 383,0; sc_start SC_WINDWALK,360000,5;	skilleffect 66,0; sc_start SC_IMPOSITIO,360000,5;	skilleffect 67,0; sc_start SC_SUFFRAGIUM,360000,3;	if (.@Delay) 	{		@HD = gettimetick(2)+.@Delay;	}		close;}

Couldn't test it right now, but it should do the job.

Share this post


Link to post
Share on other sites
  • 0

There's no error on the script.

Try with that (didn't actually read the entire script, but I think your test on price, buff and delay aren't correct):

 

prontera,19,22,5	script	Devil Square Guardian	852,{	.@price = 0;	// Zeny required for heal	.@Buffs = 1;	// Also buff players? (1: yes / 0: no)	.@Delay = 2;	// Heal delay, in seconds	if (@HD > gettimetick(2)) end;	if (.@price != 0) {		message strcharinfo(0),"Healing costs "+.@price+" Zeny.";		if (Zeny < .@price) end;		if(select("^0055FFHeal^000000:^777777Cancel^000000") == 2) close;		Zeny -= .@price;	}	specialeffect2 EF_HEAL2; percentheal 100,100;	if (.@Buffs == 1) {		if(BaseLevel == 150) 		{			goto Buffer;		}		else 		{			goto Buffs;		}	}	close;	Buffer:	specialeffect2 EF_INCAGILITY; sc_start SC_INC_AGI,240000,10;	specialeffect2 EF_BLESSING; sc_start SC_BLESSING,240000,10;	if (.@Delay >= 1) 	{		@HD = gettimetick(2)+.@Delay;	}	close;Buff:	skilleffect 361,0; sc_start SC_ASSUMPTIO,360000,5;	skilleffect 34,0; sc_start SC_BLESSING,300000,10;	skilleffect 29,0; sc_start SC_INCREASEAGI,300000,10;	skilleffect 112,0; sc_start SC_WEAPONPERFECTION,360000,10;	skilleffect 380,0; sc_start SC_TRUESIGHT,360000,5;	skilleffect 464,0; sc_start SC_KAUPE,360000,3;	skilleffect 33,0; sc_start SC_ANGELUS,360000,10;	skilleffect 463,0; sc_start SC_KAAHI,360000,7;	skilleffect 383,0; sc_start SC_WINDWALK,360000,5;	skilleffect 66,0; sc_start SC_IMPOSITIO,360000,5;	skilleffect 67,0; sc_start SC_SUFFRAGIUM,360000,3;	if (.@Delay >= 1) 	{		@HD = gettimetick(2)+.@Delay;	}		close;}

Share this post


Link to post
Share on other sites
  • 0

Hum don't really know...Do you got an error on your map server? I don't see something which should block...Try commenting the bonus 1 by one to see which one is blocking if there's no error.

Share this post


Link to post
Share on other sites
  • 0

try change your code

if (.@Buffs == 1) {		if(BaseLevel == 150) 		{			goto Buffer;		}		else 		{			goto Buffs;		}	}	close;
into
if (.@Buffs == 1) {		if(BaseLevel == 150) 		{			goto Buffer;		}		else 		{			goto Buff;		}	}	close;
player where lv <149 he will be stuck like get effect stone curse

Share this post


Link to post
Share on other sites
  • 0

the "stone curse" error is because you are using wrong SC_ names, for example "SC_INCREASEAGI" was changed to "SC_INC_AGI" here in hercules and so on, just look at db/sc_config.txt or const.txt to find out their proper names

Share this post


Link to post
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.   Restore formatting

  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.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.