Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion UI/TradeSupport.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1121,7 +1121,8 @@ function GetTripsRequiredFromTradePathLength(tradePathLength:number)
-- Previous formula that is semi correct
-- local tripsToDestination = 1 + math.floor(iSpeedCostMultiplier/tradePathLength * 0.1);
-- NOTE: Not 100% sure of this formula. Ran a few experiments and it seems to be this one
local iMinTurnsRequired = (math.floor(iSpeedCostMultiplier * 0.1) * 2.0) + 1
local iTurnDurationBase = GameInfo.GlobalParameters["TRADE_ROUTE_TURN_DURATION_BASE"].Value;
local iMinTurnsRequired = (math.floor(iTurnDurationBase * (iSpeedCostMultiplier / 100.0))) + 1;

-- Expansion 2 added a modifier called TradeRouteMinimumEndTurnChange that changes required turns based on Era
if GameInfo.Eras_XP2 ~= nil then
Expand Down