Jump to content
  • 0

Floating Rates Script


xmaniacx

Question


  • Group:  Members
  • Topic Count:  39
  • Topics Per Day:  0.01
  • Content Count:  110
  • Reputation:   1
  • Joined:  04/03/12
  • Last Seen:  

can i ask a floating rates script which gives a x2 exp on 4.00PM~11.00P.M from monday to friday then at saturday 12:00A.M it will give x3 Exp until Monday 12:00A.M

Edited by xmaniacx
Link to comment
Share on other sites

12 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  79
  • Reputation:   0
  • Joined:  06/27/12
  • Last Seen:  

Hello Try this scripts(It's my first)

- script triple_exp -1,{
OnInit:
// original Base/Job Exp and Drop Rates
set .bexp_rate, rate_exp; //Put you rate...
set .jexp_rate, rate_job; //put you rate...

OnClock1600:
	  if(gettime(4)==0  || gettime(4)==1  || gettime(4)==2  || gettime(4)==3  || gettime(4)==4 ) { // Monday to Friday
	  setbattleflag "base_exp_rate", .bexp_rate*100 * 2;
	  setbattleflag "job_exp_rate", .jexp_rate*100 * 2;

	  atcommand "@reloadmobdb";
	  announce "Double Event Starting!", bc_all;
	  end;
}  
OnClock2300:
	 if(gettime(4)==0  || gettime(4)==1  || gettime(4)==2  || gettime(4)==3  || gettime(4)==4 ) { // Monday to Friday
	 setbattleflag "base_exp_rate", .bexp_rate*100;
	 setbattleflag "job_exp_rate", .jexp_rate*100;

	 atcommand "@reloadmobdb";
	 announce "Double Event is finished!",bc_all,0xFF6060;
	 end;
}
OnClock2301:
	  if(gettime(4)==4  || gettime(4)==5  || gettime(4)==6  || gettime(4)==0  ) { // friday to monday
	  setbattleflag "base_exp_rate", .bexp_rate*100 * 3;
	  setbattleflag "job_exp_rate", .jexp_rate*100 * 3;

	  atcommand "@reloadmobdb";
	  announce "Triple Event is Starting!",bc_all,0xFF6060;
	  end;
}
OnClock1200:
	  if(gettime(4) == 0) { //Triple Exp Week-end is finished!!!
	  setbattleflag "base_exp_rate", .bexp_rate*100;
	  setbattleflag "job_exp_rate", .jexp_rate*100;

	  atcommand "@reloadmobdb";
	  announce "Triple Event is finished!",bc_all,0xFF6060;
	  end;
}

Edited by Loki81
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  39
  • Topics Per Day:  0.01
  • Content Count:  110
  • Reputation:   1
  • Joined:  04/03/12
  • Last Seen:  

thank you loki..........

Link to comment
Share on other sites


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

@Loki

Some mistake

He asks for Double rate on Monday to Friday

*gettime(<type>)

...

4 - Week day (0 for Sunday, 6 is Saturday)

and you put

if(gettime(4)==0  || gettime(4)==1  || gettime(4)==2  || gettime(4)==3  || gettime(4)==4 ) {

Then saturday to Monday

// friday to monday

Missing one curly too.

I have updated your script if you don't mind

-	script	triple_exp	-1,{
OnInit:
// original Base/Job Exp and Drop Rates
set .bexp_rate, 1; //Put you rate...
set .jexp_rate, 1; //put you rate...


OnHour16:
OnHour23:
if( gettime(4) != 0 && gettime(4) != 6 || ( gettime(4) == 1 && gettime(3) >= 16 ) ) { // Monday to Friday
	if( gettime(3) >= 23 || gettime(3) < 16 ) {
		announce "Double Event is finished!",bc_all,0xFF6060;
		callsub L_ratio, 1;
	}
	else {
		announce "Double Event Starting!", bc_all;
		callsub L_ratio, 2;
	}
}
OnHour12:
if( !gettime(4) || ( gettime(4) == 6 && gettime(3) >= 12 ) || ( gettime(4) == 1 && gettime(3) < 12 ) ) {
	announce "Triple Event is Starting!",bc_all,0xFF6060;
	callsub L_ratio, 3;
}
else if( gettime(4) == 1 && gettime(3) == 12 ) {
	announce "Triple Event is finished!",bc_all,0xFF6060;
	callsub L_ratio, 1;
}
else
	callsub L_ratio, 1;
end;


L_ratio:
setbattleflag "base_exp_rate", .bexp_rate * 100 * getarg( 0 );
setbattleflag "job_exp_rate", .jexp_rate * 100 * getarg( 0 );
atcommand "@reloadmobdb";
end;
}

Edited by Capuche
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  194
  • Topics Per Day:  0.04
  • Content Count:  499
  • Reputation:   3
  • Joined:  03/11/12
  • Last Seen:  

@Loki

Some mistake

He asks for Double rate on Monday to Friday

*gettime(<type>)

...

4 - Week day (0 for Sunday, 6 is Saturday)

and you put

if(gettime(4)==0  || gettime(4)==1  || gettime(4)==2  || gettime(4)==3  || gettime(4)==4 ) {

Then saturday to Monday

// friday to monday

Missing one curly too.

I have updated your script if you don't mind

-	script	triple_exp	-1,{
OnInit:
// original Base/Job Exp and Drop Rates
set .bexp_rate, 1; //Put you rate...
set .jexp_rate, 1; //put you rate...


OnHour16:
OnHour23:
if( gettime(4) != 0 && gettime(4) != 6 || ( gettime(4) == 1 && gettime(3) >= 16 ) ) { // Monday to Friday
	if( gettime(3) >= 23 || gettime(3) < 16 ) {
		announce "Double Event is finished!",bc_all,0xFF6060;
		callsub L_ratio, 1;
	}
	else {
		announce "Double Event Starting!", bc_all;
		callsub L_ratio, 2;
	}
}
OnHour12:
if( !gettime(4) || ( gettime(4) == 6 && gettime(3) >= 12 ) || ( gettime(4) == 1 && gettime(3) < 12 ) ) {
	announce "Triple Event is Starting!",bc_all,0xFF6060;
	callsub L_ratio, 3;
}
else if( gettime(4) == 1 && gettime(3) == 12 ) {
	announce "Triple Event is finished!",bc_all,0xFF6060;
	callsub L_ratio, 1;
}
else
	callsub L_ratio, 1;
end;


L_ratio:
setbattleflag "base_exp_rate", .bexp_rate * 100 * getarg( 0 );
setbattleflag "job_exp_rate", .jexp_rate * 100 * getarg( 0 );
atcommand "@reloadmobdb";
end;
}

can you put an announce on the script about what is the current EXP rates every 01 Minute of every Hour so that player's know what's going on

Link to comment
Share on other sites


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

can you put an announce on the script about what is the current EXP rates every 01 Minute of every Hour so that player's know what's going on

A flood ? oO I don't like this idea sorry. It's better to write news on NPC.

Edited by Capuche
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  194
  • Topics Per Day:  0.04
  • Content Count:  499
  • Reputation:   3
  • Joined:  03/11/12
  • Last Seen:  

can you put an announce on the script about what is the current EXP rates every 01 Minute of every Hour so that player's know what's going on

A flood ? oO I don't like this idea sorry. It's better to write news on NPC.

i thinks its not a flood....... coz it's every hour......... anyway i tried making some code on it.......but i'm getting error..... can check if its correct


- script FloatingAnn -1,{

OnMinute01:
if(gettime(4)==4 || gettime(4)==5 || gettime(4)==6 ) {
announce "Weekend Triple EXP Event is currently in affect, Enjoy and have a great day!",bc_all,0xFF6060;
}

end;
}

Edited by caspa
Link to comment
Share on other sites


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

I get it now. I thought it was every minute of every hour lol

btw your script trigger every minute 01 of Thursday, Friday and Saturday. So it's not correct.

*gettime(<type>)

...

4 - Week day (0 for Sunday, 6 is Saturday)

Edit:

-    script    triple_exp    -1,{
OnInit:
   // original Base/Job Exp and Drop Rates
   set .bexp_rate, 1; //Put you rate...
   set .jexp_rate, 1; //put you rate...


OnHour16:
OnHour23:
   if( gettime(4) != 0 && gettime(4) != 6 || ( gettime(4) == 1 && gettime(3) >= 16 ) ) { // Monday to Friday
       if( gettime(3) >= 23 || gettime(3) < 16 ) {
           announce "Double Event is finished!",bc_all,0xFF6060;
           callsub L_ratio, 1;
       }
       else {
           announce "Double Event Starting!", bc_all;
           callsub L_ratio, 2;
       }
   }
OnHour12:
   if( !gettime(4) || ( gettime(4) == 6 && gettime(3) >= 12 ) || ( gettime(4) == 1 && gettime(3) < 12 ) ) {
       announce "Triple Event is Starting!",bc_all,0xFF6060;
       callsub L_ratio, 3;
   }
   else if( gettime(4) == 1 && gettime(3) == 12 ) {
       announce "Triple Event is finished!",bc_all,0xFF6060;
       callsub L_ratio, 1;
   }
   else
       callsub L_ratio, 1;
   end;


L_ratio:
   setbattleflag "base_exp_rate", .bexp_rate * 100 * getarg( 0 );
   setbattleflag "job_exp_rate", .jexp_rate * 100 * getarg( 0 );
   set .ratio, getarg( 0 );
   atcommand "@reloadmobdb";
   end;

OnMinute01:
   if( .ratio == 3 )
       announce "Weekend Triple EXP Event is currently in affect, Enjoy and have a great day!",bc_all,0xFF6060;
   end;
}

Edited by Capuche
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  39
  • Topics Per Day:  0.01
  • Content Count:  110
  • Reputation:   1
  • Joined:  04/03/12
  • Last Seen:  

I get it now. I thought it was every minute of every hour lol

btw your script trigger every minute 01 of Thursday, Friday and Saturday. So it's not correct.

*gettime(<type>)

...

4 - Week day (0 for Sunday, 6 is Saturday)

Edit:

-	script	triple_exp	-1,{
OnInit:
// original Base/Job Exp and Drop Rates
set .bexp_rate, 1; //Put you rate...
set .jexp_rate, 1; //put you rate...


OnHour16:
OnHour23:
if( gettime(4) != 0 && gettime(4) != 6 || ( gettime(4) == 1 && gettime(3) >= 16 ) ) { // Monday to Friday
	if( gettime(3) >= 23 || gettime(3) < 16 ) {
		announce "Double Event is finished!",bc_all,0xFF6060;
		callsub L_ratio, 1;
	}
	else {
		announce "Double Event Starting!", bc_all;
		callsub L_ratio, 2;
	}
}
OnHour12:
if( !gettime(4) || ( gettime(4) == 6 && gettime(3) >= 12 ) || ( gettime(4) == 1 && gettime(3) < 12 ) ) {
	announce "Triple Event is Starting!",bc_all,0xFF6060;
	callsub L_ratio, 3;
}
else if( gettime(4) == 1 && gettime(3) == 12 ) {
	announce "Triple Event is finished!",bc_all,0xFF6060;
	callsub L_ratio, 1;
}
else
	callsub L_ratio, 1;
end;


L_ratio:
setbattleflag "base_exp_rate", .bexp_rate * 100 * getarg( 0 );
setbattleflag "job_exp_rate", .jexp_rate * 100 * getarg( 0 );
set .ratio, getarg( 0 );
atcommand "@reloadmobdb";
end;

OnMinute01:
if( .ratio == 3 )
	announce "Weekend Triple EXP Event is currently in affect, Enjoy and have a great day!",bc_all,0xFF6060;
end;
}

Thank you very much...........

Link to comment
Share on other sites


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

You're welcome /no1

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  58
  • Topics Per Day:  0.01
  • Content Count:  208
  • Reputation:   1
  • Joined:  01/06/12
  • Last Seen:  

how to make this sat and sunday whole day

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  1125
  • Reputation:   236
  • Joined:  07/30/12
  • Last Seen:  

how to make this sat and sunday whole day

 

if(gettime(4)==5 || gettime(4)==6 ) { //Saturday, Sunday
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  114
  • Topics Per Day:  0.03
  • Content Count:  298
  • Reputation:   4
  • Joined:  03/13/12
  • Last Seen:  

is it like for example server current exp is 6k so it will be 6k *2? 12000?

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