Note: getting granaries are more complicated than I thought. I didn't try to determine exactly how they work--the amount of food in a granary may be a factor.
Note: Narf determined that Caesar III warehouse getting cart pushers are affected by quantity, and this may apply to Pharaoh getting cart pushers.
To calculate the building where a Pharaoh getting cart pusher will go, a key factor (discovered by Trium) is the building's "access point". The access point is the first road tile adjacent to the side of a building encountered when circling the building clockwise starting at the north tile. It may be roadblocked. A getting cart pusher goes from the access point of one building to the access point of another.
For each building, the "access distance" is the shortest distance from the map entry point to its access point while sticking to the NE-SW and NW-SE axes and staying on passable tiles.
The "getting distance" from one building to another is the sum of two terms. One term is the absolute value of the difference between the access distances of the two buildings. The other term is the normal as-the-crow-flies distance between the north tiles of the two buildings, counting tiles horizontally, vertically, or diagonally. When selecting from a group of buildings, a getting cart pusher goes to the building with the lowest getting distance. If multiple buildings have the same getting distance, I don't know which one is selected.
A storage yard getting cart pusher selects a building from all connected and unconnected granaries and storage yards that have the good that he wants and are not set to get that good. If the building selected is an unconnected storage yard, the cart pusher goes off-road. If the building selected is an unconnected granary, the cart pusher disappears almost immediately.
A granary getting cart pusher selects a granary from all connected granaries that have the good that he wants and are not set to get that good, but does not necessary choose the one with the lowest getting distance. If there is no such granary, he may follow the same procedure as a storage yard getting cart pusher, but if the building selected is unconnected, the cart pusher disappears almost immediately.
If a getting cart pusher arrives at his destination and finds that the good he is getting is no longer in the destination building, he receives a new assignment as if he was starting at his building. (His current location is irrelevant.)
In this example, north is up-left. The isolated road tile on the bottom right is the map entry point. All granaries and storage yards contain 400 game meat. The south storage yard (the right one on the bottom) will get game meat. In the table, (a) is the access distance of the building, (b) is the absolute value of the difference between (a) and the access distance of the south storage yard (11), (c) is the normal as-the-crow-flies distance from the north tile of the building to the north tile of the south storage yard, and (d) is the sum of (b) and (c) (the getting distance):
(a) (b) (c) (d)
north storage yard 17 6 6 12
northeast granary 13 2 7 9
east storage yard 10 1 6 7
west granary 18 7 7 14
southwest storage yard 14 3 3 6
If the south storage yard is set to Get 1/4 game meat, then (after it gets 400 game meat) to Get 1/2 game meat, then (after it gets another 800 game meat) to Get 3/4 game meat, its cart pusher will get game meat from the southwest storage yard, east storage yard, northeast granary, north storage yard, and west granary. Instead, if the plaza is first deleted (so that the longer roads are disconnected) and the same procedure is followed, its cart pusher will get game meat from the southwest storage yard, east storage yard (going off-road), and repeatedly appear and disappear since he is not connected to the northeast granary.
If the south storage yard is replaced by a granary with its north tile in the same position, its access distance will be the same (11). If the same procedure is followed, its cart pusher will get game meat from the northeast granary, west granary, southwest storage yard, east storage yard, and north storage yard. Instead, if the plaza is first deleted (so that the longer roads are disconnected) and the same procedure is followed, its cart pusher will get game meat from the west granary, southwest storage yard, and repeatedly appear and disappear since he is not connected to the northeast granary.
[Changed "counterclockwise" to "clockwise".]
[Added "Note: getting granaries are more complicated than I thought. I didn't try to determine exactly how they work--the amount of food in a granary may be a factor.", added ", but does not necessary choose the one with the lowest getting distance", and changed "he follows" to "he may follow".]
[Added "Note: Narf determined that Caesar III warehouse getting cart pushers are affected by quantity, and this may apply to Pharaoh getting cart pushers."][This message has been edited by Brugle (edited 05-28-2023 @ 07:44 AM).]