reaperrr
441e18b898
Remove PathHash
...
This is 9(!) years old and we haven't had
pathfinding-related desyncs in quite a while.
We can still bring this back later if we ever
need it again.
2021-03-27 22:29:13 +00:00
Matthias Mailänder
bbbed49f82
Add a lint check for cursor definitions.
2021-03-20 17:37:16 +01:00
reaperrr
65c796dec7
Use Mobile.Pathfinder to reduce trait look-ups
2021-03-14 12:28:54 +00:00
Paul Chote
d52ba83f96
Replace terniary null checks with coalescing.
2021-03-08 18:11:25 +01:00
reaperrr
2473b8763b
Rename methods/activities with Visual in them
...
While they may be only 'visual' in terms of influence/cell grid,
they all do update CenterPosition, which is essentially the
actual world position of the actor.
'Visual' would imply that it only affects the position where the
actor is drawn, which is inaccurate.
Furthermore, using the term 'Visual' here would make
naming future methods/properties related to visual interpolation
unnecessarily complicated, because that's where we might
need a real 'Visual(Only)Position'.
2021-03-08 11:19:11 +01:00
teinarss
4a1e4f3e16
Use expression body syntax
2021-03-07 13:00:52 +00:00
Paul Chote
8ded6dafd4
Add AvoidTerrainTypes to ScaredyCat.
2020-12-12 12:54:46 +01:00
Paul Chote
942f1e2d9e
Fix infantry ignoring the default subcell when produced.
...
They were being created with the correct subcell, but was rejecting it
as invalid because it was already occupied (by the unit itself).
2020-12-01 22:39:11 +01:00
tovl
84eb3c54ef
Expose targetline colors to yaml.
...
All targetlines can now be set to a custom color in yaml or set to be invisible.
All automated behaviours including scripted activities now have no visible target lines.
2020-11-14 12:04:19 +00:00
teinarss
13581c030d
Use in parameter for Target
2020-11-06 22:02:24 +01:00
Paul Chote
5a7dc385a3
Remove obsolete LocomotorInfo caching.
2020-10-18 18:19:56 +02:00
RoosterDragon
2adee1e374
Use HasMovementType to avoid Enum.HasFlag allocations.
2020-10-17 23:48:48 +02:00
teinarss
27f1a7ab27
Use out var syntax
2020-08-19 18:11:07 +01:00
teinarss
19b02875c7
Use Tuple syntax
2020-08-15 10:37:10 +01:00
Paul Chote
ac975f4139
Convert yaml-exposed facings to WAngle.
2020-07-19 10:41:05 +02:00
Paul Chote
a2269e7ee7
Convert (Dynamic)FacingInit, (Dynamic)TurretFacingInit to WAngle.
2020-07-08 20:38:30 +02:00
Paul Chote
e8f443f4a9
Remove TurretFacingsInit and PlugsInit.
2020-07-08 20:38:30 +02:00
abcdefg30
5e92915095
Fix the cargo unload regression with scripted transports
...
The activity is not interruptible, so we'd continue after the Move regardless
2020-07-02 21:14:35 +02:00
tovl
b79aa7eb6a
Add AlwaysTurnInPlace option to Mobile.
2020-06-28 00:11:26 +02:00
Paul Chote
43717a89b5
Add Orientation getter to IFacing.
2020-06-21 18:05:40 +02:00
Paul Chote
c6c3a8c60d
Make ActorPreview and EditorActorPreview wrap ActorReference.
2020-06-19 17:57:56 +02:00
Paul Chote
ae7cfa56b7
Restrict IActorPreviewInitInfo to ActorInit.
2020-06-19 17:57:56 +02:00
Paul Chote
b856613194
Add ISingleInstanceInit interface.
...
Inits that are logically singletons (e.g. actor
location or owner) should implement this interface
to avoid runtime inconsistencies.
Duplicate instances are rejected at init-time,
allowing simpler queries when they are used.
2020-06-19 17:57:56 +02:00
Paul Chote
803b930405
Change IFacing.TurnSpeed to WAngle.
2020-06-12 18:35:41 +02:00
Paul Chote
6adf45bcb4
Convert IFacing.Facing and TurnSpeed to WAngle.
2020-06-12 18:35:41 +02:00
Paul Chote
b38018af9c
Replace IActorInit with an abstract class.
...
A shared ValueActorInit<T> is introduced to reduce duplication
in the most common init cases, and an ActorInitActorReference
allow actors to be referenced by map.yaml name.
2020-06-08 19:18:38 +02:00
Ivaylo Draganov
b8a9f41892
Add missing trait descriptions for cursors and unify the language
2020-05-31 00:12:04 +02:00
Paul Chote
7c6ec577dc
Rewrite ActorInit queries.
2020-05-28 19:04:53 +02:00
Adam Mitchell
0a9eb1ff83
Fix units stuck on transit-only when resupplying
2020-04-17 11:13:46 +02:00
reaperrr
da4ed24064
Mobile ResolveOrder optimization
...
When the order is "Move", the other two 'if' checks
are redundant, so 'else if' makes more sense here.
2020-02-22 17:56:47 +00:00
Paul Chote
9dc4ea8541
Fix production door not closing if the actor stays on the exit cell.
2020-02-09 16:52:22 +01:00
Paul Chote
85a5b6cc17
Fix subcell crusher logic.
2020-02-09 13:18:57 +01:00
abcdefg30
23b3c237b7
Update the year numbers in all license headers to 2020
2020-01-05 17:00:34 +00:00
tovl
2094142b7d
Include tunnel check in CanStayInCell.
2020-01-04 16:04:27 +00:00
tovl
434c46058f
Disallow units idling on service depot.
2020-01-04 16:04:27 +00:00
tovl
3236499fb7
Increase IMove.MoveTo call flexibility.
2019-12-13 23:51:03 +01:00
abcdefg30
142f823e6f
Explain that CanEnterCell ignores 'subCell' if there is a free subcell
2019-11-21 14:13:17 +01:00
abcdefg30
25b7386f0d
Let Mobile's CanEnterCell consider ToSubCell
2019-11-21 14:13:17 +01:00
abcdefg30
4717e98c48
Add a subCell parameter to IPositionableInfo.CanEnterCell
2019-11-21 14:13:17 +01:00
reaperrr
2de51ae73c
Cache IPathFinder in Mobile at creation
...
Avoiding look-ups on every move order,
as well as reducing line lengths.
2019-11-03 20:53:29 +01:00
teinarss
c94cf61069
Fix OccupiedCells for units sharing cells
2019-10-31 21:49:07 +00:00
Paul Chote
5315f8603f
Override selection if the mouse is over an already selected actor.
2019-10-30 14:53:23 +01:00
Paul Chote
0e4cb53ada
Pass contextual information to TargetOverridesSelection.
2019-10-30 14:53:23 +01:00
tovl
d2991247a3
Add separate condition to mobile for disabling nudging only.
2019-10-28 19:35:32 +01:00
tovl
38caadfdf0
Clean up nudging code.
2019-10-28 19:35:32 +01:00
tovl
c4d1468f62
Make locomotor cache and nudging logic aware of mobile trait status.
2019-10-28 19:35:32 +01:00
Paul Chote
c15a0a54bb
Don't consider unit creation as movement.
2019-10-20 16:38:25 +02:00
Paul Chote
69970d42f3
Prevent movement pausing at invalid position.
2019-10-19 13:11:00 +02:00
Paul Chote
ae34410c80
Replace MoveIntoWorld with ReturnToCell/AssociateWithAirfield.
2019-10-17 23:31:15 +02:00
Paul Chote
9b4d149a06
Revert "Suppress MoveIntoWorldInit for map-placed Mobile actors."
...
This reverts commit f0c28cc15334c7224630c375d669274f8da8fb31.
2019-10-17 23:31:15 +02:00