Make delay for re-checking for available refinery customisable and increase default
This commit is contained in:
@@ -55,9 +55,9 @@ namespace OpenRA.Mods.Common.Activities
|
|||||||
if (harv.LinkedProc == null || !harv.LinkedProc.IsInWorld)
|
if (harv.LinkedProc == null || !harv.LinkedProc.IsInWorld)
|
||||||
harv.ChooseNewProc(self, null);
|
harv.ChooseNewProc(self, null);
|
||||||
|
|
||||||
// No refineries exist; check again after delay of 1s.
|
// No refineries exist; check again after delay defined in Harvester.
|
||||||
if (harv.LinkedProc == null)
|
if (harv.LinkedProc == null)
|
||||||
return Util.SequenceActivities(new Wait(25), this);
|
return Util.SequenceActivities(new Wait(harvInfo.SearchForDeliveryBuildingDelay), this);
|
||||||
|
|
||||||
var proc = harv.LinkedProc;
|
var proc = harv.LinkedProc;
|
||||||
var iao = proc.Trait<IAcceptResources>();
|
var iao = proc.Trait<IAcceptResources>();
|
||||||
|
|||||||
@@ -23,6 +23,9 @@ namespace OpenRA.Mods.Common.Traits
|
|||||||
{
|
{
|
||||||
public readonly string[] DeliveryBuildings = { };
|
public readonly string[] DeliveryBuildings = { };
|
||||||
|
|
||||||
|
[Desc("How long (in ticks) to wait until (re-)checking for a nearby available DeliveryBuilding if not yet linked to one.")]
|
||||||
|
public readonly int SearchForDeliveryBuildingDelay = 125;
|
||||||
|
|
||||||
[Desc("How much resources it can carry.")]
|
[Desc("How much resources it can carry.")]
|
||||||
public readonly int Capacity = 28;
|
public readonly int Capacity = 28;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user