Bug - Fixed Unable to tell how many obsolete free pull items I have in storage, while in run

PeKaJe

Member
storage_amount lists all free pulls as 0, but will show them in available_amount. I am not sure what the reasoning behind that is, but I can for the most part work around it for the needs I have. The problem is that if the path is Standard-restricted, available_amount also says 0 items when the item in question is out of Standard (e.g. time's arrow). This is also correct, as the items can't be pulled. But now I have no way of telling how many I have in storage. Maybe storage_amount should show obsolete free pulls? Or maybe it should just always show free pulls, as it's somewhat confusing behaviour.
 

Veracity

Developer
Staff member
storage_amount lists all free pulls as 0, but will show them in available_amount.
Storage is split into two lists: free pulls and the rest.
storage_amount() looks only at the latter. That is a bug; it should also look at free pull amount.

available_amount() calls InventoryManager.getAccessibleCount, which looks everywhere you can currently access. Which is to say, free pulls if you are in Hardcore or Ronin, and storage if you are out (since free pulls go into general storage when you break Ronin or leave Hardcore).

I am not sure what the reasoning behind that is, but I can for the most part work around it for the needs I have.
The reasoning is that it is a bug.

The problem is that if the path is Standard-restricted, available_amount also says 0 items when the item in question is out of Standard (e.g. time's arrow). This is also correct, as the items can't be pulled.

But now I have no way of telling how many I have in storage. Maybe storage_amount should show obsolete free pulls? Or maybe it should just always show free pulls, as it's somewhat confusing behaviour.
Yes. It should always show free pulls.
 

Veracity

Developer
Staff member
There is one "storage". Some of the items are designated as "free pulls", and can be pulled in Hardcore or Ronin for no cost. The rest use pulls in Ronin and cannot be pulled in Hardcore.

I suppose we could have had three functions:

storage_amount() - for non free pulls
free_pull_amount() - for free pulls
accessible_amount() - includes how many can be pulled without using a "pull"

But, seems to me that since both are "storage", storage_amount() is unambiguous: the item is either on the free pull list or the not free pull list, depending on whether it is a Free Pull.

You can tell if an item is a free pull like this:

Code:
[color=green]> ash boolean_modifier( $item[ jazz soap ], "Free Pull" )[/color]

Returned: true

[color=green]> ash is_unrestricted( $item[ jazz soap ] )[/color]

Returned: true
(I am in aftercore.)

Therefore, seems like the program has everything it needs to know to decide whether the item will take a "pull" to retrieve, how many are in storage, and how many it can put into inventory right now using retrieve_item.
 
Top