Commit Graph

423 Commits

Author SHA1 Message Date
reaperrr
ad4c0e6dee Remove HeliFlyCircle activity
FlyCircle actually works fine for D2k Carryalls,
and no other place used this.
2019-05-01 20:50:10 +01:00
reaperrr
543d46f47c Make ground actors leave resupplier if resupply is aborted 2019-04-29 01:40:52 +01: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
4a06c66dbd Fix resupply anim not always finishing properly 2019-04-29 01:40:52 +01:00
reaperrr
83934074a4 Merge INotifyRearm/Repair into INotifyResupply
And streamline its notify methods.
Also cache INotifyResupply traits at beginning
of Resupply activity.
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
Mustafa Alperen Seki
e63f52c43f Add RepairSound to EngineerRepair. 2019-04-22 20:25:52 +02:00
Mustafa Alperen Seki
2194584b25 Fix EngineerRepairable stance checks. 2019-04-22 20:25:52 +02:00
tovl
ffbee7e45b Temp fix for harvester getting stuck around resource spawn 2019-04-22 16:39:47 +02:00
tovl
2eaeb2097c Refactor resource harvesting logic. 2019-04-22 16:39:47 +02:00
tovl
560f8c26bc Add crushing logic to aircraft. 2019-04-22 02:56:57 +02:00
tovl
c633e07410 Make aircraft occupy cells when landed. 2019-04-22 02:56:57 +02:00
tovl
6aea91bd46 Replace pseudo-childactivities in WaitForTransport. 2019-04-20 16:14:59 +01:00
tovl
a000b173d8 Replace pseudo-childactivities in Enter and related. 2019-04-20 16:14:59 +01:00
Lars Beckers
e6750bf19c Fix attack behaviour of disabled units. 2019-04-20 02:28:27 +02:00
abcdefg30
1bb319425b Add Sound.Play overloads that play a random sound from a list 2019-04-20 01:22:30 +02:00
reaperrr
db68c6e264 Fix Mobile actors turning even if Mobile is paused 2019-04-14 21:58:28 +02:00
tovl
cc7e758b27 Replace pseudo-childactivities in carryall logic. 2019-04-14 19:05:06 +01:00
reaperrr
c7eee6ae5d Improve ReturnToBase Activity.cs adherance
And make it use child activities for queueability.
2019-04-13 18:47:08 +02:00
reaperrr
8edf5b56ea Exclude dead actors from ChooseResupplier 2019-04-13 18:47:08 +02:00
reaperrr
2cdae0b380 Merge HeliReturnToBase into ReturnToBase 2019-04-13 18:47:08 +02:00
tovl
2a942bd04a Fix crash in FindAndDeliverResources.GetSearchFromLocation. 2019-04-13 16:04:54 +02:00
tovl
ea4f24d0b7 Rework harvester automation. 2019-04-04 19:22:25 +02:00
tovl
1d590ac207 Sanitize harvester search behavior. 2019-04-04 19:22:25 +02:00
tovl
bc7516989e Rework harvester unblock and idle behavior. 2019-04-04 19:22:25 +02:00
tovl
3bfa32ca33 harvester Harvest order works with queues
fix for autocarryable harvesters

Make use of QueueActivity's own handling of order.Queued
2019-04-04 19:22:25 +02:00
tovl
307a87cd9e harvester Deliver order works with queues 2019-04-04 19:22:25 +02:00
tovl
8ee11028d7 Replace SequenceActivities with ChildActivity in several air activities. 2019-03-30 18:54:30 +00:00
reaperrr
a10af382b4 Add plumbing for notifying traits of movement
More precisely, about start and stop of movement.
2019-03-30 16:24:47 +00:00
reaperrr
3211119027 Simplify ResupplyAircraft
By moving part of the take-off prevention (when TakeOffOnResupply
is set to false) to Aircraft.

Main reason & advantage is that dropping the 'WaitFor' child
makes this activity always end when resupplies are done,
which makes it more compatible with being queued as ChildActivity
itself (for example by ReturnToBase).
2019-03-30 16:44:04 +01:00
Oliver Brakmann
b4fd7331b2 Simplify Activity class
After the removal of the CompositeActivity class, all the supporting
code that made it work can be removed as well.
2019-03-30 14:38:23 +00:00
tovl
30de4df749 Replace SequenceActivities with ChildActivity in several activities. 2019-03-25 20:22:35 +00:00
Oliver Brakmann
44ca01d36c Remove pretick argument from Activity.Queue()
Pre-ticking a next activity would break the assumption that activities
in a queue would be processed in sequence.
2019-03-24 15:53:13 +00:00
tovl
16f1750252 Remove ResupplyAircraft hack 2019-03-22 19:02:05 +01:00
tovl
64cec4a0ad Revise AttackMoveActivity. 2019-03-22 19:02:05 +01:00
tovl
9f419fca34 make cargo unload deploy action queueable
fix line spacing

remove unnecessary null check
2019-03-14 00:54:54 +01:00
tovl
6f213dddec Make Attack use ChildActivities 2019-03-10 20:51:47 +01:00
reaperrr
5ec47b47af Rename fields on Repairable traits
To bring them in line with RearmActors,
Repairable.RepairBuildings and
RepairableNear.Buildings have been renamed
to RepairActors.
Additionally, their RA-specific internal
defaults were removed and the FieldLoader
now requires them to be set explicitly.
2019-03-10 19:19:49 +01:00
tovl
705795abde Activity.Cancel returns void instead of bool. 2019-03-09 21:47:43 +00:00
tovl
a17cd0fa06 Replaced Canceled state with Canceling state. 2019-03-09 21:47:43 +00:00
tovl
8191a6566b Add missing self and optional pretick parameters to Queue, QueueChild and PrintActivity methods.
This means sequenceActivities needs to accept self as well.
2019-03-09 21:47:43 +00:00
tovl
6d51d3988c fix aircraft ResupplyActivity 2019-03-09 21:47:43 +00:00
reaperrr
a7702a8ecd Make HeliReturnToBase use RTB.ChooseResupplier
Small consistency fix and prep for merging HRTB into RTB.
2019-03-09 12:12:51 +00:00
tovl
2e5e7c22f4 Make Mobile a PausableConditionalTrait 2019-03-07 02:50:43 +01:00
Paul Chote
3e404f6ac2 Remove HSLColor. 2019-03-04 18:26:42 +00:00
Paul Chote
ab4a7e3558 Replace System.Drawing primitives with our own. 2019-03-04 18:26:42 +00:00
Paul Chote
666d2e7bac Work around harvester unloading activity queue issues. 2019-03-02 18:22:44 +01:00
reaperrr
117dde32ba Removed unused sanity checks from pathfinding
These haven't been active and used in years.
2019-02-22 19:59:41 +00:00
reaperrr
5166b8cd5d Add missing closing bracket in Move comment 2019-02-22 19:59:41 +00:00
portablestew
a49287cc97 Possible fix for #14102: Consider airfield available if already reserved for the same actor 2019-02-15 13:59:53 +01:00