Commit Graph

66 Commits

Author SHA1 Message Date
RoosterDragon
c63788b686 Fix RCS1099 2023-10-30 23:31:33 +02:00
RoosterDragon
f69e6289b5 Handle re-entrant RunUnsynced correctly.
If nested calls to RunUnsynced are running, then using a bool would cause the flag to be reset once the inner function completes, but an outer function may still be running and not yet ready for the flag to be reset. To correctly handle nested calls, we track a count and only reset the flag once all functions have completed.
2023-08-23 20:56:20 +03:00
RoosterDragon
231bf01f18 Fix CA1854 2023-06-20 17:57:40 +02:00
RoosterDragon
8a285f9b19 Fix IDE0090 2023-04-08 16:51:51 +03: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
Vapre
d53601daa6 World, SyncHash, cache per tick. 2021-11-13 21:46:40 +01:00
abcdefg30
e8e0e155e5 Explain the try-finally clause in Sync.cs in a comment 2021-10-14 19:45:29 +02:00
abcdefg30
b366db7175 Revert "Directly run unsynced functions if we don't check sync hashes"
This reverts commit 1dc0a603c7.
2021-10-14 19:45:29 +02:00
abcdefg30
69248132ad Don't desync while the world is disposing 2021-10-09 21:13:35 +02:00
abcdefg30
1dc0a603c7 Directly run unsynced functions if we don't check sync hashes 2021-10-09 21:13:35 +02:00
Vapre
5ae4662f08 RunUnsynced, do not recalculate sync hash on reentry. Cache debug settings. 2021-09-12 10:06:44 +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
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
83e44bee66 Rework and rename Sync.CheckSyncUnchanged 2018-12-26 17:33:55 +01:00
Mustafa Alperen Seki
4987d45f23 Fix a crash when protected properties are [Sync]ed. 2018-11-10 12:14:14 +01:00
Arular101
8a60918841 Update copyright notice year to 2018 2018-01-17 00:47:34 +01:00
Taryn Hill
43317e0f5d Update copyright notice year to 2017 2016-12-31 23:46:13 -06:00
Paul Chote
e71225496b Clarify GPL version. 2016-02-21 16:30:48 +00:00
Paul Chote
b396965fd9 Update licence header year. 2016-02-21 16:27:31 +00:00
RoosterDragon
dc37574494 Cache sync hash functions per actor for faster sync calculations.
Caching the result of the function lookup allows the actor to calculate all the sync hashes for its syncable traits faster as it does not need to repeat the lookup each time.
2016-01-31 00:44:43 +00:00
RoosterDragon
eb3be990a6 Remove dead code and encapsulate more in Sync.cs. 2016-01-31 00:42:00 +00:00
RoosterDragon
8e89a6a696 Simplify names, remove unused usings, remove redundant casts. 2016-01-17 21:35:36 +00:00
abcdefg30
3ec874db31 Revert "Sync inherited members."
This reverts commit cfd2f265d5.
2015-08-04 17:24:59 +02:00
RoosterDragon
cfd2f265d5 Sync inherited members. 2015-07-31 22:04:43 +01:00
Matthias Mailänder
7447e0bf93 rename WRange to WDist 2015-07-09 10:55:38 +02:00
Matthias Mailänder
47a92c4511 fix a NullReferenceException 2015-06-07 13:41:29 +02:00
abcdefg30
8ca61aa917 Updated all year numbers 2015-01-09 21:18:05 +01:00
Matthias Mailänder
44cd174a8d StyleCop clean OpenRA.Game 2015-01-03 19:00:48 +01:00
Oliver Brakmann
30e42cdc62 Merge pull request #7247 from Hellhake/stylecop-game
Fix StyleCop warnings in OpenRA.Game
2015-01-02 12:58:04 +01:00
Hellhake
5a97a4b63b Fix StyleCop warnings in OpenRA.Game 2015-01-02 12:11:01 +01:00
Hellhake
fa72e04042 Remove BOM 2015-01-01 22:51:12 +01:00
Alexander Fast
070d00c678 Fixes year numbers in license text in file headers. 2014-08-21 11:27:52 +02:00
RoosterDragon
22abf9b4c4 Remove and sort usings. 2014-06-18 21:43:35 +01:00
ScottNZ
90894aa03e Use var everywhere 2014-06-15 22:17:34 +12:00
Matthias Mailänder
8f64835898 StyleCop 2014-06-15 10:51:57 +02:00
RoosterDragon
0c8bdff5be Formatting fixes.
Spaces to tabs, indents, etc.
2014-05-26 18:10:59 +01:00
RoosterDragon
b733465f33 General uncontroversial cleanup:
- Made private methods static where possible (runtime can elide checking the object for null).
- Declared attribute classes as sealed (allows reflection on attributes to complete faster).
- Moved some static cctor's into field initializers (static cctor's are slower than static field initializers).
- Made classes static if they contained only static methods (can't create instances of useless objects).
- Use inferable Exts.Lazy and not new Lazy<T>().
- Added required STAThread attribute to CrashDialog.
- Removed unused parameters in private methods.
- Added Serializable attribute to exceptions.
- Added parameter name in calls to ArgumentNullException.
- Use of as operator instead of is + cast.
- Changed (x as Foo).Bar anti-pattern into ((Foo)x).Bar. Results in sensible cast exceptions on error rather than null dereferences.
- Removed unused method in NullShader.
2014-05-23 15:50:54 +01:00
Paul Chote
4935266945 Merge FileFormats dll into Game and reorganise namespaces. 2014-04-17 01:20:47 +12:00
Paul Chote
19e0c2a83f Remove PPos and PVecInt. 2013-09-27 15:58:56 +12:00
Matthias Mailänder
aa86eb47aa hash Target 2013-08-29 17:40:20 +02:00
Paul Chote
3fd01cfac2 Remove obsolete PSubPos and PSubVec. 2013-08-01 20:18:43 +12:00
Paul Chote
a49cc78c57 Tidy Sync. 2013-07-11 19:44:15 +12:00
Paul Chote
60f49b39d4 Fix #3546. 2013-07-11 18:45:12 +12:00
Paul Chote
e765fb6439 Make world-coordinates [Sync]able 2013-07-06 18:43:06 +12:00
James Dunne
b127ae8027 Added sub-pixel position/vector types.
Updated Sync code to handle new sub-pixel types.
2012-06-21 19:41:12 -05:00
James Dunne
9c49143534 New types for cell and pixel coordinate position/vectors. 2012-06-21 15:36:59 -05:00
Chris Forbes
bc6af1841b fix indents everywhere 2011-10-18 15:10:17 +13:00