Commit Graph

191 Commits

Author SHA1 Message Date
Paul Chote
b29b685058 Rename Fluent-related code to be more precise. 2024-10-04 15:11:27 +03:00
Paul Chote
720b925fd5 Move file system mounting into mod code. 2024-10-02 18:37:46 +03:00
RoosterDragon
b58c1ea5bc Provide names and pools when creating MiniYaml.
- Rename the filename parameter to name and make it mandatory. Review all callers and ensure a useful string is provided as input, to ensure sufficient context is included for logging and debugging. This can be a filename, url, or any arbitrary text so include whatever context seems reasonable.
- When several MiniYamls are created that have similar content, provide a shared string pool. This allows strings that are common between all the yaml to be shared, reducing long term memory usage. We also change the pool from a dictionary to a set. Originally a Dictionary had to be used so we could call TryGetValue to get a reference to the pooled string. Now that more recent versions of dotnet provide a TryGetValue on HashSet, we can use a set directly without the memory wasted by having to store both keys and values in a dictionary.
2024-01-21 12:39:10 +02:00
Gustas
686040a316 Turn ModelRenderer and VoxelCache into traits 2023-09-23 19:12:51 +02:00
RoosterDragon
300281695a Deserialize mod rules only once when loading all maps.
This avoids loading, parsing and merging YAML rules for the mod during loading of each individual map. This saves significant time resolving custom rules on each map loaded.
2023-06-01 12:59:53 +02:00
Matthias Mailänder
68eec52cef Add TranslationProvider 2023-04-22 19:23:41 +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
Gustas
8d0fe52dd8 Remove unnecessary parentheses 2023-02-27 08:36:47 +02:00
abcdefg30
5bf7fe852c Remove the copyright year numbers 2023-01-11 11:58:54 +02:00
abcdefg30
6a31b1f9f3 Update the copyright header year 2022-05-28 00:35:10 -05:00
Eduardo Cáceres
7eb64ea6fc Use read-only autoimplemented property when possible 2022-05-18 11:42:36 -05:00
Matthias Mailänder
648c56bca1 Don't crash when joining a game after asset installation. 2022-04-17 00:27:36 +03:00
Matthias Mailänder
0e7ad43425 Remove unused parameters. 2022-04-01 23:30:26 +02:00
penev92
bf332b6619 Fixed fields missing the readonly modifier 2022-01-22 18:47:06 +00:00
Matthias Mailänder
07815143f1 Fix CA1825 warnings on empty array initialisation. 2021-12-06 13:19:28 +01:00
teinarss
fba4c5049c Replace Thread.CurrentThread.ManagedThreadId with Environment.CurrentManagedThreadId 2021-08-10 23:02:18 +02:00
Andre Mohren
6810469634 Updated copyright years. 2021-06-29 18:33:21 -05:00
teinarss
10676be377 Replace F extension with string interpolation 2021-05-08 22:20:59 +02:00
teinarss
e12ff2c59d Remove our own ReadOnlyDictionary and update usages 2021-04-03 11:33:31 +02:00
teinarss
4a1e4f3e16 Use expression body syntax 2021-03-07 13:00:52 +00:00
Paul Chote
207e09fea9 Add plumbing for mod-defined terrain loaders. 2021-01-11 21:57:55 +01:00
Paul Chote
995c33a942 Remove Ruleset.TileSet. 2021-01-11 21:57:55 +01:00
Matthias Mailänder
7bc17b59f5 Add a generic video player widget. 2021-01-10 10:21:17 +01:00
Paul Chote
6e7ad9df25 Remove vestigial translation plumbing.
This was never completed to the level required to
be properly used ingame.
2020-12-25 16:18:28 +01:00
Paul Chote
dd7b8b24af Use tileset ID in sequences instead of the TileSet object. 2020-10-11 01:23:15 +02:00
Paul Chote
7803686aec Rewrite sequence linting / missing file handling.
- Distinguish between missing sequences and missing sprites
- Lint default sequences as well as maps
- Improved performance
- Correctly handle null images
2020-09-12 17:52:46 +02:00
teinarss
9c4fd0e3d3 Use Null-Propagation Operator 2020-08-19 18:11:07 +01:00
teinarss
c2026dc254 Add Discord Rich Presence 2020-07-12 14:27:59 +02:00
abcdefg30
23b3c237b7 Update the year numbers in all license headers to 2020 2020-01-05 17:00: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
Paul Chote
91295f9c68 Add IReadOnlyFileSystem.IsExternalModFile. 2018-05-01 00:46:57 +02:00
Arular101
8a60918841 Update copyright notice year to 2018 2018-01-17 00:47:34 +01:00
Paul Chote
f98907f42e Add HotkeyManager class. 2017-12-08 01:29:15 +01:00
Paul Chote
34810756c2 Move Voxel code to Mods.Cnc. 2017-06-14 18:56:06 +02:00
Paul Chote
e1cd00c1dd Add backend plumbing for model loaders. 2017-06-14 18:56:06 +02:00
Paul Chote
0222ea675c Implement mod-defined package loaders. 2017-05-07 13:25:38 +01:00
Paul Chote
248c12827e Resolve assembly paths before loading the FileSystem. 2017-05-07 13:25:03 +01:00
Paul Chote
f0d7a6caca Move GetLoaders to ObjectCreator. 2017-05-07 13:25:03 +01:00
Paul Chote
8dd50c0421 Keep ObjectCreator ResolveAssembly override bound until disposal. 2017-04-25 21:49:37 +01:00
Paul Chote
9b6afd3c37 Unhardcode modchooser mod for content installation. 2017-02-12 13:21:11 +00:00
Taryn Hill
43317e0f5d Update copyright notice year to 2017 2016-12-31 23:46:13 -06:00
Paul Chote
cff8e949d8 Move ModContent out of the engine. 2016-08-08 22:36:07 +01:00
Paul Chote
3df9efb95d Rework mod enumeration / caching.
- Replaced ModMetadata.AllMods with Game.Mods.
- Store / reference mod Manifest instead of ModMetadata.
- Removes engine dependency on ModContent class.
2016-08-08 22:36:07 +01:00
Paul Chote
1e5065e06a Remove lazy loading of map rules. 2016-03-18 20:23:52 +00:00
Paul Chote
7993068c8f Remove Map.SequenceProvider. 2016-03-12 19:46:20 +00:00
Paul Chote
82a9d69a51 Remove RulesetCache and push rule parsing to background thread. 2016-03-11 21:18:32 +00:00
Paul Chote
a3b1baa654 Extract default TileSet/Sequence dictionaries to ModData. 2016-03-11 21:18:32 +00:00
Paul Chote
20e8bc249d Restore support for inline map rules. 2016-03-10 19:27:50 +00:00
Paul Chote
b969d61466 Move advanced map yaml to their own files. 2016-03-08 20:54:54 +00:00
Oliver Brakmann
4f1fa3acec Merge pull request #10786 from pchote/mappreview-packages
Remove internal use of map paths.
2016-02-23 22:52:54 +01:00