Jump to content
Jezu

Customize NPC Shop

Recommended Posts

Hello guys!

 

As you can see, customize NPC shops like Euphy's script is a bit hard but it is understand-able when you read it throughly. Why don't we make it simple. 

 

 

Just like 'cashshop' and 'shop' on ordinary NPC. This is an example and it comes the idea from eAmod.

 

 

 

prontera,156,176,5,<itemid><tab>Headgears<tab>900,ItemID:Amount,ItemID:Amount,...

 

the <itemid> will be the currency of the said NPC. It will be much easier and can be more customizable. 

 

Helpful with rewards, main currencies, etc etc.

Edited by Jezu

Share this post


Link to post
Share on other sites

I made this, Just Wait for some minute for me to upload this patch.

File : ItemShop-May15.diff

 

Usage:

<map name>,<x>,<y>,<facing>,<item_id>    ishop    <npc name>    <spriteid>,<itemid>:<amount>,..... 

Once download gets approved by mods, http://herc.ws/board/files/file/6-customized-shop-needs-item/

Tested And Working.

Edited by dastgirpojee

Share this post


Link to post
Share on other sites

I made this, Just Wait for some minute for me to upload this patch.

File : attachicon.gifItemShop-May15.diff

 

Usage:

<map name>,<x>,<y>,<facing>,<item_id>    ishop    <npc name>    <spriteid>,<itemid>:<amount>,..... 

Once download gets approved by mods, http://herc.ws/board/files/file/6-customized-shop-needs-item/

Tested And Working.

 

 

Wow! This is great! :3 What a nice response from dastgir :3 Thanks a lot for this patch! It will be easier now to create customize shops.

Share this post


Link to post
Share on other sites

I made this, Just Wait for some minute for me to upload this patch.

File : attachicon.gifItemShop-May15.diff

 

Usage:

<map name>,<x>,<y>,<facing>,<item_id>    ishop    <npc name>    <spriteid>,<itemid>:<amount>,..... 

Once download gets approved by mods, http://herc.ws/board/files/file/6-customized-shop-needs-item/

Tested And Working.

 

Hi! Can you make in this format <itemid>:<amount>:<item_required>,<itemid>:<amount>:<item_required>,..... I think its better this way. Suggestion only :)

Edited by kyeme

Share this post


Link to post
Share on other sites

 

I made this, Just Wait for some minute for me to upload this patch.

File : attachicon.gifItemShop-May15.diff

 

Usage:

<map name>,<x>,<y>,<facing>,<item_id>    ishop    <npc name>    <spriteid>,<itemid>:<amount>,..... 

Once download gets approved by mods, http://herc.ws/board/files/file/6-customized-shop-needs-item/

Tested And Working.

 

Hi! Can you make in this format <itemid>:<amount>:<item_required>,<itemid>:<amount>:<item_required>,..... I think its better this way. Suggestion only :)

It would be a problem then , bcoz we can't differentiate items , nor we can change item name, since the packet is sended in the form of item_id not item_name.

Share this post


Link to post
Share on other sites

if you use git as command line :

git apply filename

 

I don't know about softwares, bcoz i use git command-line.

Share this post


Link to post
Share on other sites

Excuse me but I'm here to report some bugs.

I diffed the file, and when I recompiled, I got errors :

 
 
patching file map/npc.c
Hunk #1 succeeded at 1203 (offset -10 lines).
Hunk #2 succeeded at 1308 (offset -10 lines).
Hunk #3 succeeded at 1357 (offset -10 lines).
Hunk #4 succeeded at 1440 (offset -10 lines).
Hunk #5 succeeded at 1488 (offset -10 lines).
Hunk #6 succeeded at 1867 (offset -11 lines).
Hunk #7 succeeded at 2213 (offset -9 lines).
Hunk #8 FAILED at 2337.
Hunk #9 FAILED at 2638.
Hunk #10 FAILED at 2691.
Hunk #11 succeeded at 3713 (offset -46 lines).
 
 
patching file map/npc.h
Hunk #1 FAILED at 37.
 
Can you please help me ? Guess I did everything right. Thanks in advance.

Share this post


Link to post
Share on other sites

We already have been discussing how to implement such things for some time now, should be out once we wrap it up.

Share this post


Link to post
Share on other sites

i have a question regarding on this mod, how can i possibly make it as callshop? i want only 1 npc and then there are multiple categories,

 

i always got errors when i trying to make this mod to callshop

 

ex:

 

close2;

callshop "ishop",1;

break;

 

my question is, what should i use in this script?

 

 

cashshop? shop? or ishop? thanks.

Share this post


Link to post
Share on other sites

I think you should call the shop name, not the shop type.

 

Example (as said in doc/script_commands.txt):

//Will call the shop named DaShop and opens the buy menu.callshop "DaShop",1;

 

The first argument passed to callshop is the NPC name that has the shop, as you can see. You should declare a shop with your very own name elsewhere and then call it (by its name) from callshop.

Share this post


Link to post
Share on other sites

yes, i know about that, but there's a error when i use this script

 

-<tab>ishop<tab>DaShop<tab>-1,501:10

 

the problem is where should i put the item_id that will set in my shop? ex: 7227 - TCG CARD

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
Reply to this topic...

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

×
×
  • Create New...

Important Information

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