Jump to content
  • 0
Sign in to follow this  
ace9010

request

Question

5 answers to this question

Recommended Posts

  • 0

@@ace9010

 

script is working.

 

Note : to make it work,  put 1st the script before reloading or restarting the server because it has OnPCLoginEvent:

 

Edited by Zhao Chow

Share this post


Link to post
Share on other sites
  • 0

@@ace9010

 

script is working.

 

Note : to make it work,  put 1st the script before reloading or restarting the server because it has OnPCLoginEvent:

 

it;s work now thank ,, need to restart the server , reloadscript wont work ..

Share this post


Link to post
Share on other sites
  • 0

I just want to ask... why? Why did you have to use an endless timer?

OnPCLoginEvent:OnPCLogoutEvent:OnPCBaseLvUpEvent:OnPCJobLvUpEvent:It's pretty obvious when these four special labels will be invoked.
-	script	LevelUpGifts	-1,{end;OnPCLoginEvent: // To give prizes to people who already obtained the levels before script was implemented and are already 99.	.@flag = 1;OnPCBaseLvUpEvent:	if( BaseLevel >= 60 && !(LevelUpPrize&1) ) {		// Insert giving items to level 60 here;		LevelUpPrize |= 1;		if( BaseLevel == 60 )			announce strcharinfo(PC_NAME) + " reached level 60, congratulations!",bc_all|bc_npc|bc_blue;	}	if( BaseLevel >= 70 && !(LevelUpPrize&2) ) {		// Insert giving items to level 70 here;		LevelUpPrize |= 2;		if( BaseLevel == 70 )			announce strcharinfo(PC_NAME) + " reached level 70, way to go!",bc_all|bc_npc|bc_blue;	}	if( BaseLevel >= 80 && !(LevelUpPrize&4) ) {		// Insert giving items to level 80 here;		LevelUpPrize |= 4;		if( BaseLevel == 80 )			announce strcharinfo(PC_NAME) + " reached level 80, hafway to the top!",bc_all|bc_npc|bc_blue;	}	if( BaseLevel >= 90 && !(LevelUpPrize&8) ) {		// Insert giving items to level 90 here;		LevelUpPrize |= 8;		if( BaseLevel == 90 )			announce strcharinfo(PC_NAME) + " reached level 90, you're almost there!",bc_all|bc_npc|bc_blue;	}	if( BaseLevel >= 99 && !(LevelUpPrize&16) ) {		// Insert giving items to level 99 here;		LevelUpPrize |= 16;		if( BaseLevel == 99 && !.@flag ) // Just so players that already got 99'd wouldn't get an announce on login.		// They reached it way long ago 			announce strcharinfo(PC_NAME) + " reached level 99, congratulations!",bc_all|bc_npc|bc_blue;	}end;}

Something like this and checks would run only on leveling up and logging in, instead of running this check on every player every 0.1second >.<

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...
Sign in to follow this  

×
×
  • Create New...

Important Information

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