Decorate Inventory sorting functions

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

Decorate Inventory sorting functions

Postby wildweasel » Sun Dec 04, 2011 10:09 pm

I would like to see a feature that allows one to specify in which order ZDoom will display inventory items on the bar when given to the player. Currently, it seems that they are sorted in the order which the player obtains them, but I would like to know if it's possible to make them sort in a predetermined order, similar to Weapon.SelectionOrder and associated properties.
User avatar
wildweasel
change o' pace.
Moderator Team Lead
 
Joined: 15 Jul 2003

Re: Decorate Inventory sorting functions

Postby Enjay » Mon Dec 05, 2011 11:55 am

Yes, that would be nice. I'd use it to specify special items (like puzzle items and so on that are single use and in one location only) to be at one end of the inventory and useful, frequent-use items to be at the other.
User avatar
Enjay
Everyone is a moon, and has a dark side which he never shows to anybody. Twain
 
 
 
Joined: 15 Jul 2003
Location: Scotland

Re: Decorate Inventory sorting functions

Postby Xtyfe » Mon Dec 05, 2011 12:49 pm

Not sure how this relates to what you are asking, but from my own findings in making an inventory system for doom items. it seems that if I use give all and then receive these inventory items in the new system. They will appear in the order of how they were defined in decorate :shock:
User avatar
Xtyfe
Neque Deos, Neque Dominos
 
Joined: 14 Dec 2007
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: nVidia with Vulkan support

Re: Decorate Inventory sorting functions

Postby Gez » Mon Dec 05, 2011 2:15 pm

When you use the give all cheat, the engine just goes through the entire list of actor and goes "is this an inventory item y/n if yes add it". That master list of actors is filled in the order the actors are defined, so there's nothing mindboggling to the fact that items are added in the order they are defined. And they're sorted by the order in which they are added, so, again, what happens is a logical extension of how things work.

But you're not really supposed to use give all when playing.
Gez
 
 
 
Joined: 06 Jul 2007

Re: Decorate Inventory sorting functions

Postby jpalomo » Mon Dec 05, 2011 3:18 pm

I can see this not only being useful on a modder's perspective, but for a player's as well. I have found times in Heretic and Strife when I want a certain item and have to scroll through a bunch of junk to get to it. Inventory.SelectionOrder seems like an appropriate name for the function. Lower numbers would place the item higher in the list. If 2 actors have the same number, the original behavior takes place.
User avatar
jpalomo
 
Joined: 17 May 2010

Re: Decorate Inventory sorting functions

Postby Slasher » Mon Dec 05, 2011 3:48 pm

wildweasel wrote:I would like to see a feature...

Oh God he's channeling SamuraiClinton! :lol:
User avatar
Slasher
It smells like luncheon meat that's been walking around in the sun too long.
 
Joined: 17 Mar 2008
Location: California


Return to Feature Suggestions

Who is online

Users browsing this forum: No registered users and 0 guests