Commit Graph

39 Commits

Author SHA1 Message Date
Paul Chote
cf427f8cb3 Drop invalid power references when loading save games. 2019-10-01 19:25:30 +02:00
tovl
4a609bbee8 Allow units to give way when path is blocked by oncoming unit. 2019-09-15 17:51:34 +01:00
Paul Chote
815ea1e13b Make LastSearchFailed local to FindAndDeliverResources. 2019-08-25 17:20:38 +02:00
Paul Chote
8b0f2e1462 Fix NRE in SquadManagerBotModule. 2019-08-24 14:33:11 +02:00
tovl
8690a4a6ce CLean up type check in harvesterbotmodule. 2019-08-10 19:12:50 +01:00
tovl
1b4ab564fe Fix AI harvester not resuming after chronoshift. 2019-08-10 19:12:50 +01:00
teinarss
2ddf9fa826 Using Locomotor instead of Info for pathfinding 2019-07-26 15:54:22 +02:00
Paul Chote
674155a8dd Move ctor initializers to their own line. 2019-06-08 18:44:50 +02:00
Paul Chote
353db73381 Fix a collection of minor style violations.
This enables several new StyleCopAnalyzer rules to
be enabled immediately during migration.
2019-05-09 20:40:08 +02:00
Paul Chote
100ec17ef0 Implement IGameSaveTraitData on BotModules. 2019-05-05 09:30:58 +02:00
reaperrr
bc0d8ca015 Remove ResupplyAircraft and AllowYieldingReservation
The few extra things those two activities did can be done
in Resupply, making them redundant.
2019-04-29 01:40:52 +01:00
reaperrr
ba4b5738d7 Merge Rearm and Repair into Resupply activity
Allows parallel rearming and repairing.
2019-04-29 01:40:52 +01:00
tovl
ea4f24d0b7 Rework harvester automation. 2019-04-04 19:22:25 +02:00
Mustafa Alperen Seki
2aebb05cd0 Implement Building/UnitDelays 2019-03-14 01:36:44 +01:00
Paul Chote
c7d9d9613e Remove Order.TargetLocation from Harvester. 2019-03-04 18:08:42 +00:00
reaperrr
31f4b0a5c4 Fix D2k bots wasting cash on building repairs
D2k bots not repairing buildings when damaged due to placement
without concrete was intentional, and this was bleed's default behavior
before BuildingRepairBotModule got introduced, too.
2019-02-03 18:24:15 +01:00
Paul Chote
fd013ad9d0 Remove unnecessary trait queries from HarvesterBotModule 2019-02-03 15:54:07 +01:00
reaperrr
4da2d32bc5 Fix that bots don't re-use capturers
They were never removed from activeCapturers when their target becomes invalid,
preventing the bot from reusing them.
2019-02-03 12:12:34 +00:00
reaperrr
32a3caf423 Fix CaptureManagerBotModule crashing on multiple Capturable
By removing the now-redundant CaptureTarget class.
2019-02-03 12:12:34 +00:00
abcdefg30
cadbd0d9ab Change the year number in all cs headers from 2018 to 2019 2019-01-26 23:15:21 +01:00
reaperrr
b05d246c48 Add BotDebug message for external unit build requests
For easier bot debugging of things like MCV- and harvester replacement.
2019-01-06 08:39:45 +01:00
reaperrr
3a1656c3dd Remove unused BuildUnit overload from UnitBuilderBotModule
Unused and didn't check things like Buildable, so better just remove it.
2019-01-06 08:39:45 +01:00
reaperrr
137d3be346 Add plumbing for bots auto-replacing harvesters
If their number drops below refinery count.
2019-01-06 08:39:45 +01:00
reaperrr
e36ef57e35 Increase default scan interval for idle bot harvesters
Every 2 seconds (at default speed) should be enough.
2019-01-06 08:39:45 +01:00
reaperrr
481e5e03d8 Make bots deploy MCV on first tick
And use a boolean instead of counting ticks.
2019-01-06 08:39:45 +01:00
Paul Chote
f5d788f4fc Prevent unit requests from stacking during production. 2019-01-04 21:14:20 +00:00
Paul Chote
5a8f7f1a5f Increase squad calculation intervals.
These were unnecessarily short, increasing the
AI performance overhead, and making it difficult
for units to escape concave terrain features.
2019-01-03 02:04:08 +01:00
Paul Chote
3d9e877eb2 Disable rush attacks against enemy aircraft. 2019-01-03 02:04:08 +01:00
Paul Chote
8a6a68feef Unify Squad enemy unit filtering. 2019-01-03 02:04:08 +01:00
Paul Chote
4d56ecb3a8 Remove unused MaximumDefenseRadius parameter. 2019-01-01 12:43:10 +01:00
reaperrr
54c2894b4e Split off last bot modules
And dissolve AI namespace.
There would have been so little left in Common.AI,
that keeping it made no sense anymore.
2018-12-31 10:56:01 +00:00
reaperrr
6db27b1839 Split off CaptureManagerBotModule
from HackyAI.

Note: This isn't used in any official mod right know,
and known to be bugged on bleed already.
2018-12-22 17:42:53 +01:00
reaperrr
04c34741c8 Extract BaseBuilderBotModule from HackyAI 2018-12-19 21:50:54 +13:00
Paul Chote
8eeb6d68e7 Tweak FrozenActorLayer queries:
- FrozenActorsInRegion now filters for valid and (optionally) visible FAs
- Add new FrozenActorsInCircle to mirror World.FindActorsInCircle.

The first change means that SupportPowerDecision now correctly ignores
FrozenActors that the AI has not discovered.
2018-12-17 22:19:26 +01:00
Paul Chote
3e490e5843 Cache FrozenActorLayer on the Player object.
This avoids unnecessary trait queries.
2018-12-17 22:19:26 +01:00
reaperrr
451a38338b Convert AISupportPowerManager to module 2018-11-25 19:00:44 +01:00
reaperrr
67cba65800 Fix bot module plumbing
Fixes the issues pointed out after the original harvester module was merged.
Also merges the update rules as discussed on IRC.
2018-11-24 11:05:37 +00:00
Andre Mohren
b1a44086a0 Removed unused using directives. 2018-11-17 17:23:22 +00:00
reaperrr
927b6cd561 Convert AIHarvesterManager into *Module 2018-11-04 01:11:00 +01:00