Gustas
a148f30070
Simplify matrix utils
2023-09-03 22:58:04 +02:00
RoosterDragon
93a97d5d6f
Fix CA1851, assume_method_enumerates_parameters = true
2023-08-20 20:41:27 +02:00
RoosterDragon
3275875ae5
Fix CA1851
2023-08-20 20:41:27 +02:00
RoosterDragon
285443f10f
Fix CA1310, CA1311
2023-08-07 21:38:09 +02:00
RoosterDragon
d83e579dfe
Fix CA1305
2023-08-07 21:38:09 +02:00
michaeldgg2
1a2d43fc99
WorldRenderer: use string.IsNullOrEmpty for check in Palette method
...
Unified usage of WorldRenderer.Palette method when it comes to appending player name (in case of player palette)
2023-07-25 13:33:11 +03:00
RoosterDragon
58e8b123db
Avoid some allocations during loading.
...
- In FieldLoader, cache boxed bools and some boxed ints.
- In FieldLoader, presize collections when parsing a List, HashSet or Dictionary.
- In FieldLoader, don't allocate a list of missing items until required.
- In FieldLoader, when a string value is passed, avoid wrapping this in a MiniYaml object by allowing both strings and yaml to be passed in the GetValue overload that does the real work.
- In Animation, avoid allocating no-op actions.
- In VxlReader, use EnsureCapcity to better size the Dictionary.
- In VxlReader change VxlElement to a struct.
- In Locomotor, presize TerrainSpeeds dictionary.
2023-07-16 23:21:20 +02:00
RoosterDragon
231bf01f18
Fix CA1854
2023-06-20 17:57:40 +02:00
RoosterDragon
f752e04b03
Fix CA1816
2023-06-20 17:57:40 +02:00
RoosterDragon
f4af5c1764
Fix CA1852
2023-06-06 11:51:47 +03:00
RoosterDragon
277699cbd5
Fix CA1822
2023-06-06 11:51:47 +03:00
Matthias Mailänder
1c2ce0dcc0
Deprecate string format log shorthand.
2023-05-05 19:03:09 +02:00
Gustas
44f1af7059
Move TileScale to MapGrid
2023-05-02 16:37:30 +03:00
RoosterDragon
14c0d011ea
Fix SA1414
2023-04-08 16:51:51 +03:00
RoosterDragon
8a285f9b19
Fix IDE0090
2023-04-08 16:51:51 +03:00
RoosterDragon
164abfdae1
Fix IDE0083
2023-04-08 16:51:51 +03:00
RoosterDragon
bd2b3d9793
Fix IDE0074
2023-04-08 16:51:51 +03:00
RoosterDragon
5254348819
Fix IDE0056
2023-04-08 16:51:51 +03:00
RoosterDragon
bcfa0c9ae9
Review StyleCop rules.
...
- Enforce SA1604 ElementDocumentationShouldHaveSummary.
- Enforce SA1629 DocumentationTextShouldEndWithAPeriod.
- Turn off some rules covered by IDExxxx rules.
- Remaining rules are treated as part of OpenRA style.
2023-03-18 12:46:10 +02:00
RoosterDragon
98c4eaca83
Fix IDE0032
2023-03-14 13:41:25 +02:00
Paul Chote
c35ab081ff
Rewrite sequence loading logic.
...
Multiple layers of Lazy<T>ness are replaced with
an explicit two-part loading scheme.
Sequences are parsed immediately, without the need
for the sprite assets, and tell the SpriteCache
which frames they need. Use-cases that want the
actual sprites can then tell the SpriteCache to
load the frames and the sequences to resolve the
sprites.
2023-03-10 20:11:33 +02:00
Paul Chote
a6f3db0a45
Allow all sprites to use interpolated facings.
2023-03-10 20:11:33 +02:00
Paul Chote
b051211842
Remove internal state from ISpriteSequence API.
2023-03-10 20:11:33 +02:00
Paul Chote
7cd4272350
Access sequences from Map.
2023-03-10 20:11:33 +02:00
Gustas
dab3ca0025
Add support for dark player colors
2023-03-10 15:43:24 +02:00
RoosterDragon
52fd564eac
Fix some whitespace formatting issues: stray tabs or spaces.
...
Wrap some long lines on affected code.
2023-03-02 20:02:45 +02:00
Gustas
422a228cea
Fix PlayerColorRemap expecting colors in linear space
...
PlayerColorRemap expected colors in linear space yet we provided them in gamma. We fix this by instead expecting gamma space colors and then converting them into linear space ourselves.
2023-02-28 23:26:37 +02:00
RoosterDragon
0b01b73111
Fix IDE0060
2023-02-28 21:21:40 +02:00
Gustas
8d0fe52dd8
Remove unnecessary parentheses
2023-02-27 08:36:47 +02:00
Gustas
157d1b32dc
Use null propagation
2023-02-27 08:36:47 +02:00
RoosterDragon
2d4119e88d
Fix IDE0051
2023-02-24 22:00:25 +02:00
RoosterDragon
b0dca05e50
Fix IDE0002
2023-02-24 22:00:25 +02:00
abcdefg30
5bf7fe852c
Remove the copyright year numbers
2023-01-11 11:58:54 +02:00
Matthias Mailänder
56ff98a2a3
Throw specific cursor sequence errors
...
instead of dividing by zero because length is 0.
2023-01-03 13:25:50 +01:00
Paul Chote
6d438a9d61
Allow mods to customise the default rendering scale.
2022-12-31 17:11:03 +01:00
Matthias Mailänder
19ecddcd86
Enforce use of 'var' instead of explicit type.
2022-12-28 23:02:04 +01:00
Vapre
7005da3592
SpriteRenderer, do not copy vertex array data each flush.
2022-11-14 23:33:24 +01:00
Gustas
c041ea7d39
Crash on image/panel not found and add TryGet functions for searching
2022-10-20 19:28:02 +02:00
AspectInteractive2
a1a50d6c98
Added rotation logic to the renderer to enable the use of Interpolated Facings.
2022-07-17 17:03:53 +02:00
abcdefg30
6a31b1f9f3
Update the copyright header year
2022-05-28 00:35:10 -05:00
Eduardo Cáceres
2677e9c013
Use pattern matching
2022-05-18 11:42:36 -05:00
Eduardo Cáceres
7eb64ea6fc
Use read-only autoimplemented property when possible
2022-05-18 11:42:36 -05:00
Eduardo Cáceres
79f321cb44
.Any(), .Count() -> .Count or .Length
2022-05-18 11:42:36 -05:00
Matthias Mailänder
0e7ad43425
Remove unused parameters.
2022-04-01 23:30:26 +02:00
Vapre
83357af14c
WorldRenderer, replace foreach ActorsWithTraits with ApplyToActorsWithTrait. #18798 .
2022-03-13 10:45:01 +01:00
penev92
bf332b6619
Fixed fields missing the readonly modifier
2022-01-22 18:47:06 +00:00
penev92
0d24ccc47a
Fixed unnecessary zero-length array allocations
...
Changed all currently present zero-length array allocations in the codebase to use `Array.Empty` instead.
2022-01-20 22:10:28 +01:00
penev92
860ec642b8
Addressed review comments
...
- Renamed `IVideo.CurrentFrameNumber` to `CurrentFrameIndex`
- Improved logged error message in VideoPlayerWidget
- Renumbered fields in ThreadedGraphicsContext
2022-01-11 18:16:31 +01:00
penev92
6f0509d235
Removed now-unused ITexture.SetData() overload
2022-01-11 18:16:31 +01:00
penev92
c4ab7041b8
Updated VideoPlayerWidget to play new IVideo data
...
Added optional padding to video frames because that's what VideoPlayerWidget expects.
Keeping the option to not use padding for other use-cases like converting frames to PNG.
2022-01-11 18:16:31 +01:00