Jump to content
Sign in to follow this  
4144

Some upcoming hercules features

Recommended Posts

Now hercules version released and this features can be used from stable or master branch.

Share this post


Link to post
Share on other sites

already mentioned in script_commands.txt

*expandInventory(<value>)

Adjust player inventory to given value.
Maximum inventory size is MAX_INVENTORY.
Minimum inventory size is FIXED_INVENTORY_SIZE.
For supported clients it send inventory change packet. For old clients,
this change is silent.
Current max inventory size can be read by function getInventorySize().

https://github.com/HerculesWS/Hercules/blob/82d634ad431b2ffe7077a561f4eafd2486ede44b/doc/script_commands.txt#L10349

https://github.com/HerculesWS/Hercules/blob/82d634ad431b2ffe7077a561f4eafd2486ede44b/src/common/mmo.h#L170

Share this post


Link to post
Share on other sites

In other words default values for MAX_INVENTORY is 200

for FIXED_INVENTORY_SIZE is 100

 

Share this post


Link to post
Share on other sites

wait a moment ... why the *expandInventory has the I as capital letter ?

I remember there was a script standardization topic, forgot where issit now, discussed years ago

1. all constants should be CAPITAL LETTERS -> QUEUEOPT_LOGOUT, IOT_PARTY,  GETTIME_WEEKDAY ...
2. all functions start with F_, and Capitial Letters only on word -> F_MesInfo, F_MesColor, F_InsertComma, F_SaveQuestSkills
3. all script commands should be low cap
4. and the ... no idea when ... variables ...

for example your *getInventorySize() has I and S capital, opposed to *getinventorylist() all low cap

 

hercules script engine is case-sensitive, so we have to be extra be careful when apply the capital letters
... although there are already some controversial ... like the "All" vs "all" ... reported #784

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...
Sign in to follow this  

×
×
  • Create New...

Important Information

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