Jump to content
  • 0
Noire

Script that checks Zeny.

Question

Can i request a script that warn a PLAYER if he/she almost exceed that Zeny Limit, for example the server zeny limit is 2 billion zeny if the player will convert the coins to zeny from the npc it will notify them, that player almost exceed the zeny limit. 

Link to comment
Share on other sites

10 answers to this question

Recommended Posts

  • 0
mes "[Coin Master]";

mes "How many coins would you like to trade?";

set @mamount,0;

input @mamount;

if (@mamount <= 0) goto L_Sorry2;

if (countitem(673) < @mamount) goto L_Sorry2;

set Zeny,(Zeny + (50000000* @mamount));

delitem 673,@mamount;

close;

Edited by Noire
  • Upvote 1
Link to comment
Share on other sites

  • 0

	mes "[Coin Master]";

mes "How many coins would you like to trade?";

input [email protected],0,30000;

if ( [email protected] <= 0 || countitem(673) < [email protected] ) goto L_Sorry2;

set [email protected]_zeny, ( 1000000000 - Zeny );

set [email protected]_zeny,( 50000000 * [email protected] );

if ( [email protected]_zeny > [email protected]_zeny ) {

mes "Over zeny limit.";

}

else {

set Zeny, Zeny + [email protected]_zeny;

delitem 673,@mamount;

}

close;

Link to comment
Share on other sites

  • 0
	mes "[Coin Master]";
	mes "How many coins would you like to trade?";
	input [email protected],0,30000;
	if ( [email protected] <= 0 || countitem(673) < [email protected] )  goto L_Sorry2;
	set [email protected]_zeny, ( 1000000000 - Zeny );
	set [email protected]_zeny,( 50000000 * [email protected] );
	if ( [email protected]_zeny > [email protected]_zeny ) {
		mes "Over zeny limit.";
	}
	else {
		set Zeny, Zeny + [email protected]_zeny;
		delitem 673,@mamount;
	}
	close;

Thank you Emistry !! but can i ask how this code work? input .@amount,0,30000; ?

Edited by Noire
Link to comment
Share on other sites

  • 0

limit the input value between 0 ~ 30000. read input for more details. :D

Ohh right, sorry lol i forgot that guide again :/ thank you again.

Link to comment
Share on other sites

  • 0
	mes "[Coin Master]";
	mes "How many coins would you like to trade?";
	input [email protected],0,30000;
	if ( [email protected] <= 0 || countitem(673) < [email protected] )  goto L_Sorry2;
	set [email protected]_zeny, ( 1000000000 - Zeny );
	set [email protected]_zeny,( 50000000 * [email protected] );
	if ( [email protected]_zeny > [email protected]_zeny ) {
		mes "Over zeny limit.";
	}
	else {
		set Zeny, Zeny + [email protected]_zeny;
		delitem 673,@mamount;
	}
	close;

Hi, I just discover it checks zeny but don't it delete the coin/673 after exchanging it still converts zeny.

Edited by Noire
Link to comment
Share on other sites

  • 0

Typo? @mamount <- easily spotted, just change that line.

 

woot i found the problem thanks for the heads* up. i should replace it w/ [email protected] not @amount thanks again panda and for the script emistry.

Edited by Noire
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...

Important Information

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