Payout
Descreption of how does the Config.DistancePayout work
This feature adds a dynamic bonus to the player's reward based on the distance traveled between the starting point and the delivery destination.
How it works: The script attempts to calculate the actual road travel distance using the native
CalculateTravelDistanceBetweenPoints(). If this native fails or returns invalid data, the script automatically falls back to a raw Euclidean (straight-line) distance calculation to ensure a payout is still generated.Known Limitation: Due to the nature of the game's native pathfinding, the calculated distance can sometimes be inconsistent. This may result in slight variations in the final reward amount for the same route.
Configuration
A. Enable Distance Payout Toggles the dynamic payout system on or off.
true: Calculates distance and adds a bonus to the job reward.false: Disables distance calculations; players receive fixed rewards only.
Default: false
Config.DistancePayout = falsePrice Per Mile Sets the monetary bonus amount added for every mile traveled.
Calculation Logic: The script converts game units into miles. For example, if the distance is 6500 units (approx. 6.5 miles) and the price is $100, the player receives an extra $650.
Formula:
(Distance / 1000) * PricePerMile
Default: 100
Config.PricePerMile = 100This value by default is set to $100 per mile, so when the calculated distance is 6500 units, in addition the the reward value set for the job another $650 will be added on top of it.
Last updated