[Help]need help in cash shop

Newbie Spellweaver
Joined
Mar 1, 2009
Messages
25
Reaction score
0
i need help on setting up a cash shop,i dont know how to set it up... im using eAthena-SVN-10000-trunk-TXT-W32 :(:
 
Re: need help in cash shop

By cash shop I'm going to assume you mean the Kafra Points shop.
Code:
MAP,X,Y,FACING	cashshop	NPCNAME	NPCSPRITE,ITEM1:PRICE,ITEM2:PRICE,etc
An example from my server is:

Code:
turbo_room,106,139,5	cashshop	[Custom]Upper Headgear	70,15003:40,15009:40,15015:40,15021:60,15027:60,15033:60,15039:60,15045:60,9172:1000,9173:1000,9199:1000,14950:5000
 
Re: need help in cash shop

The same way you would add zeny to a player.
The value is #CASHPOINTS,
Or you can use an atcommand in your script.
Here's a small script which changes Mithril Coins into Kafra Points. You can edit it to your likings.
Code:
turbo_room,93,117,4	script	Kafra Point Exchanger	845,{
	mes "[Kafra Point Exchanger]";
	mes "Hey there~";
	next;
	mes "[Kafra Point Exchanger]";
	mes "I can take your Mithril Coins and exchange them for something much better.";
	mes "Kafra Points!";
	next;
	mes "[Kafra Point Exchanger]";
	mes "What do you say, do you want some Kafra Points?";
	next;
	if (select("Yes","No") == 2) {
		mes "[Kafra Point Exchanger]";
		mes "Some other time~";
		close;
	}
	mes "[Kafra Point Exchanger]";
	mes "Alright. How many points do you want?";
	mes "Remember that every 1 Mithril Coin is equal to 1 Kafra Point";
	next;
	input @cpoint;
	if (@cpoint==0) {
		mes "[Kafra Point Exchanger]";
		mes "Please don't waste my time.";
		close;
	}
	if (@cpoint>countitem(674)) {
		mes "[Kafra Point Exchanger]"; 
		mes "I'm sorry, you don't have enough Mithril Coins";
		close;
	}
	mes "[Kafra Point Exchanger]";
	mes "Here are your points!";
	delitem 674,@cpoint;
	atcommand "@cash "+ @cpoint + "";
	close;
}
 
Back