Skip to content

Commit

Permalink
Fix for Biofluid trips with 0 fluid
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakkowww committed Nov 18, 2024
1 parent 8a07ff0 commit 787ca24
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ Version: 3.0.24
Date: ?
Changes:
- Fixed digosaurs pywiki page missing [item=dried-meat] → 1 ore info. Resolves https://github.com/pyanodon/pybugreports/issues/725
- Fixed Biofluid trips with 0 fluid when provider had less to give or requester asked for less than a certain amount
---------------------------------------------------------------------------------------------------
Version: 3.0.23
Date: 2024-11-17
Expand Down
2 changes: 0 additions & 2 deletions scripts/biofluid/biofluid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,7 @@ local function process_unfulfilled_requests(unfulfilled_request, relavant_fluids
error("Invalid operator: " .. operator)
end
end
local can_give = contents.amount - (allocated_fluids_from_providers[p.unit_number] or 0)
provider = p
unfulfilled_request.amount = min(amount, can_give)
break
::continue::
end
Expand Down

0 comments on commit 787ca24

Please sign in to comment.