Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Flyff > Flyff Private Server > Flyff PServer Guides & Releases
You last visited: Today at 21:20

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Mini-Release] More NPC Vendor Inventory

Discussion on [Mini-Release] More NPC Vendor Inventory within the Flyff PServer Guides & Releases forum part of the Flyff Private Server category.

Reply
 
Old   #1
 
Steffen Tequila's Avatar
 
elite*gold: 51
Join Date: May 2009
Posts: 338
Received Thanks: 76
More NPC Vendor Inventory

Hey guys!

Many people know that you can only add a maximum of 100 items to an NPC shop,
here I will quickly explain how to increase it.

Example for 150 instead of 100 items for an npc shop


Step 1:
add "__MORE_VENDOR_INVENTORY 150" to your commons
Code:
#define __MORE_VENDOR_INVENTORY 150

Step 2:
search here: ProjectCmn.h(_Common)
this: MAX_VENDOR_INVENTORY

you will find this:

Code:
#define	MAX_VENDOR_INVENTORY	100
change that to:

Code:
#ifndef __MORE_VENDOR_INVENTORY
#define	MAX_VENDOR_INVENTORY	100
#endif // __MORE_VENDOR_INVENTORY
most people when they want to change the slots are just changing one thing like that: MAX_VENDOR_INVENTORY 100 but if you change only this then your neuz leads to a crash if your vendor shop has more as 100 items and you open it. A fix with this is step 3.

Step 3:
search here: WndItemCtrl.h(_Interface)
this: m_pArrayItemElem

you will find this:

Code:
CItemElem*		m_pArrayItemElem[100];
change that to:

Code:
#ifdef __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[__MORE_VENDOR_INVENTORY];
#else // __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[100];
#endif // __MORE_VENDOR_INVENTORY
now you can compile and add more items to an npc shop without crash.

greez, stevyboy.
Steffen Tequila is offline  
Old 11/04/2021, 16:26   #2
 
Nιgнтмαяε's Avatar
 
elite*gold: 0
Join Date: Jul 2018
Posts: 434
Received Thanks: 310
Not sure how this is a release really lol...

Why are you doing this:
Code:
#ifdef __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[150];
#else
CItemElem*		m_pArrayItemElem[100];
#endif
When you can just do:
Code:
#ifdef __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[MAX_VENDOR_INVENTORY];
#else
CItemElem*		m_pArrayItemElem[100];
#endif
Nιgнтмαяε is offline  
Old 11/04/2021, 17:38   #3
 
elite*gold: 0
Join Date: Sep 2021
Posts: 8
Received Thanks: 1
I mean, if you're wanting to increase the amount a tab could contain in a shop, then you should also fix the offscreen rendering issue that will lower the user's frames or increase cpu usage in the OnDraw function.
WaterIsSand is offline  
Old 11/04/2021, 17:54   #4
 
Steffen Tequila's Avatar
 
elite*gold: 51
Join Date: May 2009
Posts: 338
Received Thanks: 76
Quote:
Originally Posted by Nιgнтмαяε View Post
Not sure how this is a release really lol...

Why are you doing this:
Code:
#ifdef __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[150];
#else
CItemElem*		m_pArrayItemElem[100];
#endif
When you can just do:
Code:
#ifdef __MORE_VENDOR_INVENTORY
CItemElem*		m_pArrayItemElem[MAX_VENDOR_INVENTORY];
#else
CItemElem*		m_pArrayItemElem[100];
#endif
Its was an example. Of course u can set it 1% easier but the sense is the same and not more importment.
Steffen Tequila is offline  
Reply


Similar Threads Similar Threads
[RELEASE] Template to make a Vendor NPC
06/04/2013 - EO PServer Guides & Releases - 3 Replies
Hey, Murtah here. Ive made a Template for people to make their own NPC..Just replace things like *ID 1* With an Id that Isnt used in cq_action..and put the ID's into the other spots it says. Goodluck! If you have any Problems add me to MSN at [email protected]
[WTB] unded mini ghostly/mini panada/mini polar bear
05/07/2012 - Guild Wars Trading - 2 Replies
Hi, Would like to buy one of those pets. Make me an offer if you got one. Thanks.



All times are GMT +1. The time now is 21:20.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.