Jump to content
  • 0
Sign in to follow this  
Luffy

[Tulong mga Boss] Donation npc Script.

Question

7 answers to this question

Recommended Posts

  • 0

suggest cashshop_db.conf

 

-	shop	dynamicshop	-1,501:222new_1-1,45,77,4	script	Donation Shop	685,{	set .@currency, 7179; // pods	mes "[Donation Shop]";	mes "What do you want to buy?";	next;	switch(select("Headgears:Item Boost:etc") {		//Headgears		case 1:			setarray .@items, 1750,1,1766,2; // Usage : <item id>,<price>			break;		//Item Boost		case 2:			setarray .@items, 1750,1,1766,2; // Usage : <item id>,<price>			break;		//etc		case 3:			setarray .@items, 1750,1,1766,2; // Usage : <item id>,<price>			break;	}	npcshopitem "dynamicshop",0,0;	for (set .@i, 0; .@i < getarraysize(.@items); set .@i, .@i + 2 ) npcshopadditem "dynamicshop",.@items[.@i], .@items[.@i+1];	callshop "dynamicshop",1;	npcshopattach "dynamicshop";	end;OnBuyItem:	for ( set .@j, 0; .@j < getarraysize(.@items); set .@j, .@j + 2 ) {		for ( set .@k, 0; .@k < getarraysize(@bought_nameid); set .@k, .@k + 1 ) {			if ( @bought_nameid[.@k] == .items[.@j] ) {				if ( checkweight( @bought_nameid[.@k], @bought_quantity[.@k] ) ) {					if ( countitem(.@currency) < .@items[.@j + 1] ) {						mes "You don't have enough " +getitemname(.@currency)+ " to purchase this item.";						close;					} else {						delitem .@currency, .@items[.@j + 1] * @bought_quantity[.@k];						getitem @bought_nameid[.@k], @bought_quantity[.@k];						dispbottom @bought_nameid[.@k]+" "+ .@items[.@j + 1]+" "+ .@currency;						end;					}				} else					dispbottom "You cannot carry out more items with you";					end;			}		}	}	deletearray @bought_quantity, getarraysize(@bought_quantity);	deletearray @bought_nameid, getarraysize(@bought_nameid);	end;	OnInit:	waitingroom "Donation Shop",0;	end;}

Share this post


Link to post
Share on other sites
  • 0

@VyLow di ko parin po ma beta test ung server kahit completo na po set up sa mysql at sa config files

im not sure ano ung na eencounter mong problema haha state it clearly na lng 

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.