Jump to content
Sign in to follow this  
lyravega

[Mod] Priority Sort

Recommended Posts

Hello people. I wrote a simple, small mod for PZ, called Priority Sort. It alters how the "Category" button in inventory panes behave. When you click this existing "Category" button, it'll now cycle between various categories, and push any item belonging to that category to the top of the list. Any other item will first be sorted by alphabetical category order, then by name order. Double sorting the inventory, but first prioritizing the selected category in other words.

Neither overwrites any vanilla files nor affects your saves; only alters the UI to include a custom sort function.

 

You can find this mod in the Steam Workshop as well.

 

Screenshot - PrioritySort.zip

 

Note: Some categories are disabled. The new "ammo" category for example, as the game still treats it like "item" category. Even without this mod, sorting by the alphabetical category order will not result in "ammo" category going to the top. The other disabled categories are disabled as they are very rare and/or redundant ones.

Share this post


Link to post
Share on other sites

Hello again. I looked through the folders a little bit, and found what I seek. The mod was working for all languages actually. So I just went on to make this mod fully compatible with other languages; as long as the localization files are up-to-date, there shouldn't be any problems. The only change is that the category priority shown in "()" will also display in your language choice.

 

Updating the main file, but there aren't any changes aside from localization support, so no need to redownload if you are running the game in English.

Share this post


Link to post
Share on other sites

I am uploading another version, with yet another very small change. Inventory will be double-sorted now; first by the item category, then by the item name - while pushing the prioritized category to the top. Again, not a major change, so no need to redownload unless you want the double-sort. Anyway, happy new year to everyone!

Share this post


Link to post
Share on other sites

Is it compatible with the Customized Categories mod 1.2? 

 

Well, you can use this mod with that one - there are no conflicts, but this one doesn't support that mod.

Share this post


Link to post
Share on other sites

Is it compatible with the Customized Categories mod 1.2? 

From what I can tell, his mod is checking an item's "Type" flag, and not the "DisplayCategory" flag.  He has the sort flag declared manually.

 

My mod added at least 30-40 new categories. There are so many because I had to make new display categories for each weapon type. Those would not sort with the generic displaycategory. IE Base.Axe "Long Blade Weapon - Carpentry" would not sort with Base.Nails "Carpentry". This is actually a vanilla issue as well.

 

The only way I could see this being compatible with mine, is if I were to hook my mod into his, and add a new variable which he could make use of, which stores a list of all the display categories added from all modules. However, I am not yet sure how to do so. I will look into it if I have some time.

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.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

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