Commit Graph

4460 Commits

Author SHA1 Message Date
RoosterDragon
662077a47e Merge pull request #9103 from reaperrr/water-rot
Refactored WaterPaletteRotation into RotationPaletteEffect
2015-09-06 20:19:09 +01:00
TheRaffy
1fc2158f2e Added a WeatherOverlay 2015-09-06 20:25:29 +02:00
reaperrr
ca055eb7bb Refactored WaterPaletteRotation
Moved RotationBase from tileset definition to WaterPaletteRotation effect.
Unhardcoded rotation range and rotation rate.
Added possibility to exclude Tilesets from effect.

Fixed RA water palette rotation for actors on desert maps (#8872).
2015-09-06 19:25:10 +02:00
Matthias Mailänder
c206bebb7f Merge pull request #9274 from pchote/fix-sound-engine
Don’t create multiple sound contexts.
2015-09-06 11:35:50 +02:00
atlimit8
8250f223c4 More HashSet trait fields & Lint support 2015-09-05 16:59:30 -05:00
Paul Chote
886d489766 Don’t create multiple sound contexts. 2015-09-05 18:29:14 +01:00
RoosterDragon
901e604cf3 Replace arrays with sets.
In places where arrays were being treated as a set, just create a set directly. This reveals the intention of such collections better, and also improves performance by allowing set based methods to be used.
2015-09-03 20:09:24 +01:00
atlimit8
fadfd179cb Cache FrozenActor ITargetable.TargetTypes union 2015-09-02 23:19:00 -05:00
atlimit8
23d0424437 Add ITargetablePositions seperating it from ITargetable 2015-09-02 23:14:40 -05:00
atlimit8
f5c3575c5a Support multiple ITargetable traits 2015-09-02 23:14:40 -05:00
Pavel Penev
c4bf92870b Merge pull request #9083 from Mailaender/lint-cleanup
Cleaned up the ILint boiler plate code
2015-09-02 15:49:43 +03:00
Pavel Penev
a3633671a9 Fix the build after a bad merge
Merging #9187 without rebasing it on post-#9182 bleed was a bad idea.
2015-09-02 15:22:14 +03:00
Pavel Penev
ba9abc9e0a Merge pull request #9187 from RoosterDragon/field-saver-culture
Fix culture in FieldSaver for collections
2015-09-02 15:14:42 +03:00
Pavel Penev
256929073c Clean up some trait info loading code
Remove some methods that traits define to load their YAML values on their own.
2015-09-01 22:52:22 +03:00
Pavel Penev
8ddbabbfde Add Dictionary<,> support to FieldSaver 2015-09-01 22:52:20 +03:00
Pavel Penev
341b3395c8 Add Dictionary<,> support to FieldLoader 2015-09-01 22:52:18 +03:00
Pavel Penev
821e09877d Remove an assumption from FieldLoader.TryGetValueFromYaml() about the current value not having subnodes.
FieldLoader assumed the YAML that is being loaded is a simple value with no subnodes and threw an exception otherwise. This explicitly excluded the possibility of trying to load a Dictionary or another more complex object.
2015-09-01 22:52:04 +03:00
RoosterDragon
d9dd96ca35 Speed up Map.ContainsAllProjectedCellsCovering on flat maps.
This method gets called often via Contains calls. We can significantly speed up the method for flat maps since we know the projection and it is trivial to perform. This avoids an expensive projection lookup.
2015-08-31 20:45:32 +01:00
RoosterDragon
dab53f403d Provide a hand-written enumerator for ActorMap.GetUnitsAt(CPos). 2015-08-31 20:43:19 +01:00
RoosterDragon
18478646d4 Avoid multiple ToMPos calls in ActorMap. 2015-08-31 20:43:18 +01:00
RoosterDragon
4eacb6e5c9 Transparently cache results of GetTerrainIndex in Map.
This method performs an expensive calculation and is called often during pathfinding. We create a cache of the terrain indicies for the map to vastly reduce the cost.
2015-08-31 20:43:17 +01:00
RoosterDragon
fa87befeff Add missing CellEntryChanged checks. 2015-08-31 20:43:16 +01:00
Matthias Mailänder
0b8d7708ef add more lint interfaces to reduce boiler plate 2015-08-30 13:12:25 +02:00
Matthias Mailänder
72dffe3391 dispose res properly 2015-08-29 18:47:10 +02:00
Matthias Mailänder
9c1eeafa08 Merge pull request #9004 from reaperrr/quanbo
Introduce QuantizeFacingsFromSequence
2015-08-28 22:46:29 +02:00
RoosterDragon
d11e60474a Ensure the elements of arrays and sets are formatted correctly in FormatValue.
We call FormatValue on each element to ensure correct culture and other formatting that would otherwise not be applied.
2015-08-28 19:39:25 +01:00
RoosterDragon
243763f570 Remove redundant invariant culture handling for float, decimal, double.
This is already handled by the type converter portion of the code.
2015-08-28 19:33:59 +01:00
RoosterDragon
2f9ca36506 Update WeaponInfo to use HashSets for some fields directly. 2015-08-27 21:48:12 +01:00
RoosterDragon
5a177a889c Add ability to load and save HashSets. 2015-08-27 21:48:09 +01:00
RoosterDragon
410b97823a Ensure our array handling only accepts single dimensional arrays. 2015-08-27 21:31:24 +01:00
reaperrr
18b8eb30a3 Merge pull request #9134 from clemty/docs
minor LUA and trait documentation fixes, whitespace fixes
2015-08-24 21:26:20 +02:00
abcdefg30
b9f4431ed0 Merge pull request #9151 from penev92/bleed_summaries
Add a bit of code documentation
2015-08-24 21:18:11 +02:00
clemty
2bbc1fcda4 LUA and trait documentation fixes
- Typo in documentation ("proximitry").
- Add spaces between sentences.
- Remove most occurrences of "  " (two spaces) unless clearly used as indendation
- Punctuation (although no fullstop after filenames like "notifications.yaml").
2015-08-24 19:41:15 +02:00
Matthias Mailänder
6132ec6558 Merge pull request #9150 from penev92/bleed_dedicatedSound
Make lower-level Sound not require the server state directly
2015-08-24 06:44:51 +02:00
Pavel Penev
02dd5afbd9 Merge pull request #9058 from RoosterDragon/reduce-alloc
Reduce allocations in the main game loop
2015-08-24 02:11:08 +03:00
reaperrr
006e66a3c3 Refactored IQuantizeBodyOrientation implementation
Moved BodyOrientation and related interfaces from Game to Mods.Common.
Introduced QuantizeFacingsFromSequence trait.
With*Body render traits no longer implement IQuantizeBodyOrientation
themselves.
2015-08-24 00:48:56 +02:00
Pavel Penev
09a41d8bde Add a bit of code documentation 2015-08-24 01:47:35 +03:00
Pavel Penev
49e9ad2c7c Make lower-level Sound not require the server state directly 2015-08-24 01:36:56 +03:00
Pavel Penev
1d3cfcf378 Merge pull request #8632 from Mailaender/openra-platform
Removed the OpenAL/OpenGL/SDL2 dependency from the game engine
2015-08-24 00:45:27 +03:00
Pavel Penev
535863ea83 Merge pull request #9147 from Mailaender/exception-log-map
Added the current map to the exception.log
2015-08-24 00:29:52 +03:00
Matthias Mailänder
001d2cde30 add the map to the exception.log 2015-08-23 22:27:00 +02:00
Matthias Mailänder
bec209085b Merge pull request #7873 from penev92/bleed_raceToFaction
Replace old "country" and "race" name in the code with the generic "faction"
2015-08-23 17:49:40 +02:00
Matthias Mailänder
f7b0454b9e avoid an unnecessary overload 2015-08-23 07:58:07 +02:00
Matthias Mailänder
17f3466451 untie the engine from SDL2 and MiniTK 2015-08-23 07:58:03 +02:00
Pavel Penev
09f67d18bb Some internal "race" to "faction" renaming 2015-08-22 23:34:36 +03:00
abcdefg30
87580d0aab Add a GpsRemoveFrozenActor trait 2015-08-22 21:36:30 +02:00
Matthias Mailänder
9a861bdfba Merge pull request #8700 from deniz1a/rename-disable-shroud
Renames "Disable Shroud & Fog" debug option to "Observer view".
2015-08-20 20:41:01 +02:00
RoosterDragon
d415d3ba4e Reduce allocations in the main game loop.
- Cache the shroud projection even for flat maps to avoid allocating single element arrays.
- Avoid LINQ in shroud and map projection queries to avoid enumerator allocations.
- Avoid LINQ in calculation of sync values.
- Cache enumerables in ProductionQueue.
- Cache delegate in HackyAI.
2015-08-18 21:17:28 +01:00
Matthias Mailänder
118782a85e check palette references 2015-08-17 21:36:45 +02:00
Matthias Mailänder
ba8e292b71 Merge pull request #9022 from RoosterDragon/less-sync
Sync only once per tick
2015-08-17 21:13:55 +02:00