Commit Graph

6691 Commits

Author SHA1 Message Date
RoosterDragon
f794cf69f9 In TypeDictionary.TrimExcess, also TrimExcess on the internal data dictionary size.
As TypeDictionary instances tend to live a long time without edits after being initially populated, this will reduce their long term memory footprint.
2023-06-13 23:52:44 +02:00
Paul Chote
1f37728ecf Return proper sysinfo OS names for Linux/macOS. 2023-06-11 13:18:49 +02:00
penev92
c0cd7259b3 Updated native dependencies NuGet packages 2023-06-11 10:41:02 +02:00
RoosterDragon
06df75ffee Improve PNG parsing performance.
Switch on the filter once per row rather than once per byte. This allows each row to be processed with a much tighter loop.
2023-06-10 16:20:02 +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
94abd8a928 Revert "Revert "Replace legacy Evaluator with IntegerExpressions.""
This reverts commit 4f16b0d464.
2023-06-04 21:29:15 +03: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
5bcb1a678c Fix fluent plural forms. 2023-06-01 12:43:10 +02:00
Matthias Mailänder
8a9426a0d4 Add a test case for Fluent plural forms. 2023-06-01 12:43:10 +02:00
Matthias Mailänder
b58a8aaa0f Fix benchmark CSV export on non-US systems. 2023-05-28 23:11:25 +03:00
Matthias Mailänder
8433bc0948 Throw early when Lua function parameters are null. 2023-05-23 17:30:03 +03:00
abcdefg30
b5f5d5f9d5 Fix ScriptContext crashing without a WorldLoaded function 2023-05-21 13:11:17 +02:00
abcdefg30
f2b3a9f837 Fix ScriptContext crashing without a Tick function 2023-05-21 13:11:17 +02:00
Gustas
211f7160dc Remove \r
we use \n everywhere else in the engine
2023-05-20 20:47:56 +03:00
Matthias Mailänder
445b736885 Replace sandbox wrapper scripts. 2023-05-20 13:19:48 +02:00
RoosterDragon
6d288aba2f Track keys during MiniYaml Merge.
This improves performance by avoiding repeated linear scans over the nodes to match the keys.
2023-05-15 23:48:39 +02:00
Matthias Mailänder
65c0cf1065 Deprecate string format shorthand. 2023-05-05 19:03:09 +02:00
Matthias Mailänder
1c2ce0dcc0 Deprecate string format log shorthand. 2023-05-05 19:03:09 +02:00
Matthias Mailänder
e251126dd4 Remove unused log proxy. 2023-05-05 19:03:09 +02:00
Gustas
44f1af7059 Move TileScale to MapGrid 2023-05-02 16:37:30 +03:00
Nate Nichols
8f511a3bb6 Added ability to use Mouse 4 and Mouse 5 as hotkeys 2023-04-28 15:22:25 +03:00
Matthias Mailänder
4f7a01a291 Localize difficulty settings. 2023-04-25 21:33:02 +03:00
Matthias Mailänder
af6330b1bd Allow localisation of dictionary values. 2023-04-25 21:33:02 +03:00
Matthias Mailänder
55ff0ac1f4 Inline variables. 2023-04-25 21:33:02 +03:00
Gustas
a9a7777293 Report linguini parse errors
Reports duplicate keys
2023-04-22 19:23:41 +02:00
Matthias Mailänder
68eec52cef Add TranslationProvider 2023-04-22 19:23:41 +02:00
Gustas
a065e6a47c Fix map level lobby options not being translated 2023-04-22 19:23:41 +02:00
Gustas
efe135e38b Add Translations to MapPreview 2023-04-22 19:23:41 +02:00
Gustas
8f5d8de1c2 Allow empty translation keys 2023-04-22 19:23:41 +02:00
Matthias Mailänder
2867334c00 Less verbose logging for untranslated strings. 2023-04-22 19:23:41 +02:00
RoosterDragon
6362bbd176 Fix CA1846 2023-04-17 00:05:12 +02:00
RoosterDragon
25b8e7fefc Fix CA1834 2023-04-17 00:05:12 +02:00
RoosterDragon
ad4a443fc2 Fix CA1066 2023-04-17 00:05:12 +02:00
RoosterDragon
c442bd83f8 Fix CA1036 2023-04-17 00:05:12 +02:00
RoosterDragon
ff799303b0 Fix CA1018 2023-04-17 00:05:12 +02:00
RoosterDragon
f09241d263 Fix CA1010 2023-04-17 00:05:12 +02:00
RoosterDragon
0c3071b9c6 Adjust MiniYaml node merging when removals are present.
# Example Scenario
MockString:
	CollectionOfStrings:
		StringA: A

MockString:
	CollectionOfStrings:
		StringB: B

MockString:
	-CollectionOfStrings:

MockString:
	CollectionOfStrings:
		StringC: C

MockString:
	CollectionOfStrings:
		StringD: D

# Previous MergePartial result
# The CollectionOfStrings is merged into a single unit, so the C and D items are dragged upwards and jump ahead of the Removal
# When this is processed, the final result removes CollectionOfStrings entirely

MockString:
	CollectionOfStrings:
		StringA: A
		StringB: B
		StringC: C
		StringD: D
	-CollectionOfStrings:

# New MergePartial result
# When merging nodes, we no longer allow merges to jump an intervening removal node.
# This means we can have multiple of a certain key (CollectionOfStrings in this example) which was not the case previously.
# When this is processed, the final result includes C/D but not A/B.

MockString:
	CollectionOfStrings:
		StringA: A
		StringB: B
	-CollectionOfStrings:
	CollectionOfStrings:
		StringC: C
		StringD: D
2023-04-14 23:57:26 +03:00
RoosterDragon
595717fff0 Enable Code Quality Rules
Enforces a variety of CAxxxx rules that do not have existing violations.

For the benefit of dotnet_code_quality.CA2241.try_determine_additional_string_formatting_methods_automatically = true, rename parameters of methods that forward to string.Format so format issues will get detected automatically.
2023-04-08 23:15:40 +02:00
RoosterDragon
14c0d011ea Fix SA1414 2023-04-08 16:51:51 +03:00
RoosterDragon
a167f9680f Fix SA1316 2023-04-08 16:51:51 +03:00
RoosterDragon
062dc2bd40 Fix SA1141 2023-04-08 16:51:51 +03:00
RoosterDragon
1ce9acd442 Fix IDE0110 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
cbd0583289 Fix IDE0062 2023-04-08 16:51:51 +03:00
RoosterDragon
023d80b94d Fix IDE0057 2023-04-08 16:51:51 +03:00
RoosterDragon
5254348819 Fix IDE0056 2023-04-08 16:51:51 +03:00
Gustas
e4ba9733fe Add sequences linting to ingame lobby 2023-04-07 16:23:30 +01:00