Commit Graph

615 Commits

Author SHA1 Message Date
Matthias Mailänder
6581fcb6a7 Add a random interval to idle animations. 2020-06-28 13:43:33 +02:00
abcdefg30
f75afc6ee4 Fix a compilation error in WithInfantryBody.cs 2020-06-19 20:01:04 +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
23561cd76b Add custom palette support to WithInfantryBody. 2020-06-19 17:09:13 +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
Paul Chote
c999b2d778 Convert QuantizeFacing to WAngle facings. 2020-05-28 21:23:51 +02:00
Paul Chote
bfb6c671fb Change QuantizeFacing to return a facing instead of an index. 2020-05-28 21:23:51 +02:00
Paul Chote
7c6ec577dc Rewrite ActorInit queries. 2020-05-28 19:04:53 +02:00
Paul Chote
86f61298e6 Replace ITraitInfo interface with TraitInfo class. 2020-05-21 13:01:04 +02:00
atlimit8
1ef27d18c1 check name for Actor.GrantCondition() 2020-05-17 12:33:29 +02:00
Paul Chote
fe58ed1283 Animation facing -> WAngle. 2020-05-09 10:20:23 -05:00
atlimit8
259c8d2c98 Merge ConditionManager trait directly into Actor 2020-05-09 15:46:11 +02:00
Paul Chote
f03841c4e4 Hide selection decorations when spectators zoom too far out. 2020-05-02 14:30:04 -05:00
Matthias Mailänder
0103c38c13 Don't change the animation when it's not your turn. 2020-05-02 20:07:09 +01:00
Matthias Mailänder
bd1760682f Rename WithNukeLaunch* traits to WithSupportPower*. 2020-04-30 01:37:05 -05:00
Matthias Mailänder
52d0490f95 Supersede INotifyNuke 2020-04-30 01:37:05 -05:00
Paul Chote
e42d177920 Include selection decorations when calculating ScreenMap bounds. 2020-04-30 00:09:57 +02:00
Matthias Mailänder
86a7a0bd6c Move Render*Circle traits to their base traits. 2020-04-26 10:30:50 +02:00
Matthias Mailänder
fc84cd9204 Add an is in world check to fix a crash. 2020-04-21 01:15:43 -05:00
Matthias Mailänder
331b854e4e Add a lint check for production bar types. 2020-04-10 21:00:26 +02:00
Matthias Mailänder
274bc9cbba Add missing sequence reference. 2020-04-10 20:56:54 +02:00
Matthias Mailänder
827f8d95b4 Remove unused using. 2020-04-10 20:56:54 +02:00
Matthias Mailänder
2946dd35d5 Spaces to tabs. 2020-04-10 20:14:39 +02:00
Paul Chote
2c4e6c4188 Remove special-case rollover rendering. 2020-03-24 00:07:10 -05:00
Paul Chote
9f3254dbd1 Implement isometric selection boxes for TS structures. 2020-03-24 00:07:10 -05:00
Paul Chote
ac200f6173 Rework decoration renderable traits:
- Removed implicit pip definitions and IPips interface.
  New decoration traits have been added to render them.
  Pip types are no longer hardcoded in OpenRA.Game.

- Decoration rendering is now managed by SelectionDecorations(Base),
  which allows us to remove assumptions about the selection box
  geometry from the decoration traits.

- RenderNameTag has been replaced by WithNameTagDecoration, which is
  an otherwise normal decoration trait.

- Unify the configuration and reduce duplication between traits.

- Removed hardcoded references to specific selection box renderables.

- Remove legacy cruft.
2020-03-24 00:07:10 -05:00
Paul Chote
ce91c5a76f Fix WithDisguisingInfantryBody idle animation crash. 2020-03-01 14:43:12 +01: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
abcdefg30
6cc27eaa76 Fix the description of VeteranProductionIconOverlay 2020-01-31 13:55:56 +01:00
reaperrr
b839204c7f Minor WithInfantryBody reorganisation
Move PlayStandAnimation to a more suitable position
inside the file.
2020-01-25 13:26:25 +01:00
reaperrr
595b6c8923 Greatly simplified WithInfantryBody TickIdle code
There was a lot of redundancy and unnecessary
complexity in several checks.

This now also prevents infantry from randomly
restarting and potentially switching between stand
sequences if there are no idle sequences.
Old behavior can still be replicated by listing
stand sequences as IdleSequences.
2020-01-25 13:26:25 +01:00
abcdefg30
deffc2dd15 Add support for defining the palette of WithResourceLevelOverlay 2020-01-12 00:47:20 +00:00
abcdefg30
23b3c237b7 Update the year numbers in all license headers to 2020 2020-01-05 17:00:34 +00:00
reaperrr
7a57f0e6ef Expose delay of WithDeathAnimation
Allows to show it a few ticks after death if the modder
wishes so.
2019-12-30 18:01:09 +00:00
Paul Chote
032c412e09 Fix WithTextDecoration rendering. 2019-12-28 21:44:26 +01:00
reaperrr
efc06a020b Move WithDeliveryAnimation to Mods.Common 2019-12-08 16:03:14 +00:00
reaperrr
c4597b5c6b Fix RA desert tree fire palette
By default WithDamageOverlay uses the actors'
palette, but RA's desert terrain uses the TD desert.pal
which isn't compatible with RA's fire animation shps.
2019-11-23 18:40:27 +01:00
Paul Chote
70b020205d Rename *Time to *Ticks and increase internal resolution. 2019-11-17 17:06:29 +01:00
Paul Chote
1599eac66c Rename SelectionBoxRenderable to SelectionBoxAnnotationRenderable. 2019-10-20 23:46:33 +02:00
Paul Chote
43e84c89ef Rename SelectionBarsRenderable to SelectionBarsAnnotationRenderable. 2019-10-20 23:46:33 +02:00
Paul Chote
8e280ef0a7 Rename RangeCircleRenderable to RangeCircleAnnotationRenderable. 2019-10-20 23:46:33 +02:00
Paul Chote
81d9b705a6 Rename DetectionCircleRenderable to DetectionCircleAnnotationRenderable. 2019-10-20 23:46:33 +02:00
Paul Chote
4ec0fa299d Rename TextRenderable to TextAnnotationRenderable. 2019-10-20 23:46:33 +02:00
Paul Chote
7937383bf4 Replace scaleSizeWithZoom with SpriteAnnotation. 2019-10-20 23:46:33 +02:00
Paul Chote
0ff078968d Change IPlaceBuildingDecorationInfo to use annotations. 2019-10-20 23:46:33 +02:00
Paul Chote
1dc84f48de Migrate traits to IRenderAnnotations. 2019-10-20 23:46:33 +02:00
Paul Chote
060ea80ca4 Fix infantry idle animations playing immediately after creation. 2019-10-20 16:38:25 +02:00
Paul Chote
999ad0e18a Convert CustomTerrainDebugOverlay to IRenderAboveShroud. 2019-09-14 18:49:44 +02:00
Paul Chote
a9a43d54f7 Convert WithRangeCircle to IRenderAboveShroud. 2019-09-14 18:49:44 +02:00