Commit Graph

4058 Commits

Author SHA1 Message Date
Oliver Brakmann
a48a878a71 Merge pull request #7983 from pchote/radar-colors
Adjust IRadarSignature to support per-cell colors.
2015-04-25 16:38:28 +02:00
Oliver Brakmann
bc7fd81297 Merge pull request #7840 from sinf/fix7838
Fixed parsing of hotkeys with no name (such as tilde)
2015-04-25 14:19:25 +02:00
sinf
5e86e63b37 Fixed parsing of hotkeys with no name (such as tilde) 2015-04-25 15:01:00 +03:00
Matthias Mailänder
175e9a14b7 Merge pull request #8000 from pchote/bogus-yaml-removals
Fix yaml merging
2015-04-25 13:42:18 +02:00
Matthias Mailänder
1476a0eb70 Merge pull request #7847 from RoosterDragon/screen-map-refactor-perf
Refactored ScreenMap & improved perf of updates, removals and region lookups
2015-04-25 10:12:52 +02:00
Paul Chote
d8f24adcc7 Merge pull request #7853 from Mailaender/alpha-experiments
Added AlphaImage support
2015-04-25 19:03:25 +12:00
Pavel Penev
479e81d7f5 Merge pull request #7944 from LunaticEdit/bleed
EndOfStream first chance exceptions on server
2015-04-25 07:17:24 +03:00
Pavel Penev
c9e89cc7f5 Merge pull request #7832 from Phrohdoh/cleanup
Another cleanup.
2015-04-25 06:53:16 +03:00
RoosterDragon
09dc1db651 Refactored ScreenMap & improved perf of updates, removals and region lookups.
Reduce code duplication by extracting a common class to deal with spatial partitioning of actors, and use some (cached) delegates to reduce duplication further without affecting performance too much.

Speed up updates and removal of actors by caching their location so we only need to update or remove them from bins they are actually in (typically very few), compared to having to check every bin for removals which is much more work in comparison.

Speed up checking for actors inside a region by checking if items are located entirely within the bin they are located in. If so, we don't need to add them to the hash-set for de-duplication purposes which is fairly expensive.
2015-04-23 21:06:09 +01:00
Paul Chote
8a1f9261c3 Convert hidden [Desc] to a <summary>. 2015-04-22 21:24:48 +12:00
Paul Chote
2cbe269c1e Support multiple inheritance for actor rules. 2015-04-22 21:24:47 +12:00
Paul Chote
0a43b3da72 Rewrite yaml merging block removal.
Fixes #2922, #6818.
2015-04-22 19:58:10 +12:00
Paul Chote
4b22436d14 Fix a regression from #7987. 2015-04-20 04:55:31 +12:00
Oliver Brakmann
322801247f Merge pull request #7987 from pchote/fix-player-bogosity
Fix random country display.
2015-04-19 18:13:04 +02:00
Paul Chote
3cfa96e7a6 Fix random country display. 2015-04-20 03:33:46 +12:00
Paul Chote
145f7b28f5 Adjust IRadarSignature to support per-cell colors. 2015-04-19 22:27:47 +12:00
Paul Chote
ab7706073b Don’t crash when asking for the offset of an invalid subcell. 2015-04-19 15:20:45 +12:00
Matthias Mailänder
868e404b22 add 2 new blend modes: Multiplicative, DoubleMultiplicative 2015-04-18 13:41:53 +02:00
Oliver Brakmann
b363c2c51e Don't unnecessarily discard 24bpp map previews
Those images now get converted on-the-fly by the game.
2015-04-18 11:27:23 +02:00
RoosterDragon
9c93001c84 Convert to 32bbp internally in FastCopyIntoSprite.
This avoids the need for callers to ensure the pixel format is correct, but ensures that the copying succeeds when the format is different.
2015-04-17 18:50:49 +01:00
RoosterDragon
106816a547 Cache the IRenderModifier and IRender traits in Actor.
Previously we just cached the query object, but now we cache the full results. This avoids having to re-evaluate them every render.
2015-04-14 20:15:45 +01:00
LunaticEdit
575b568c6a EndOfStream first chance exceptions on server
The server class reads the memory stream in a forever loop until an
EndOfStreamException occurs. This causes repeated first chance
exceptions due to EndOfStreamException. This change verifies that the
memory stream's reader position is not past the length of the memory
stream.
2015-04-13 19:09:32 -04:00
penev92
cc73ba09ab Fix flag-related crash for scripted "players" 2015-04-13 23:36:29 +03:00
Oliver Brakmann
7b1b17df4a Allow non-selectable factions for players if LockRace is set 2015-04-12 15:27:25 +02:00
RoosterDragon
84dffce7c1 Added an extension method to clone bitmaps with a 32bbpArgb pixel format. 2015-04-11 21:05:46 +01:00
RoosterDragon
c1787a8368 Don't process images with the wrong pixel format in MapCache. 2015-04-11 15:20:16 +01:00
RoosterDragon
7883355481 Validate PixelFormat of source bitmap argument in FastCopyIntoSprite. 2015-04-10 19:54:03 +01:00
RoosterDragon
5dfcc3e9d0 Convert custom map previews that are not using PixelFormat.Format32bppArgb. 2015-04-10 19:54:02 +01:00
Taryn Hill
96d6ea79ce Remove explicit private.
Remove unnecessary delegate.
Use extension method syntax.
Fix HealthInfo.NotifyAppliedDamage’s desc.
Remove unused using directives.
Remove explicit type declaration in Manifest.
2015-04-09 13:59:20 -05:00
Oliver Brakmann
a992318208 Fix "ally" suffix being wrongly assigned to enemy players
Fixes #7890
2015-04-07 17:34:54 +02:00
Matthias Mailänder
3f48c649f0 Merge pull request #7722 from penev92/bleed_diplomacyWindow
Closes #7391
2015-04-05 08:34:38 +02:00
penev92
2c108a1845 Use proper names and flags for unknown players 2015-04-04 17:24:19 +03:00
Oliver Brakmann
4ca27234e6 Merge pull request #7686 from reaperrr/custom-visibility-update
Skip visibility updates when fog & shroud are disabled via lobby
2015-04-03 20:58:56 +02:00
Matthias Mailänder
a8bf90f8b2 Merge pull request #7746 from RoosterDragon/shroud-vis-perf
Speed up frozen actor visibility updates.
2015-04-03 15:20:10 +02:00
Matthias Mailänder
8494ad0a38 Merge pull request #7834 from RoosterDragon/avoid-preventable-allocations
Avoid preventable allocations
2015-04-03 13:52:46 +02:00
RoosterDragon
3885ca3f14 Speed up frozen actor visibility updates.
Cache the isVisibleTest function in the ctor for FrozenActor. The footprint never changes so the test will always be valid.
2015-04-03 12:21:03 +01:00
Pavel Penev
cedfe5c0b5 Merge pull request #7734 from RoosterDragon/frozen-lazy-render
Lazily generate frozen actor renderables.
2015-04-03 04:16:19 -07:00
Paul Chote
98b8078f7d Merge pull request #7573 from bvandenbogaard/bleed
Added audio.bag/audio.idx support used in RA2
2015-04-03 11:35:54 +01:00
Matthias Mailänder
5733c049e1 Merge pull request #7715 from RoosterDragon/random-prevent-crash
Only evaluate input sequence once in RandomOrDefault.
2015-04-03 12:27:20 +02:00
Paul Chote
070d8ea6a2 Merge pull request #7811 from reaperrr/new-blendmodes1
Added two new BlendModes
2015-04-03 10:57:12 +01:00
Matthias Mailänder
39b42a35a0 Merge pull request #7823 from RoosterDragon/celllayer-enumerator
Fix CellLayer.GetEnumerator
2015-04-03 10:13:16 +02:00
RoosterDragon
b66db23adf Only evaluate input sequence once in RandomOrDefault.
This ensures non-deterministic sequences cannot crash by returning an empty sequence on the second evaluation.
2015-04-03 01:08:30 +01:00
RoosterDragon
ab2ef0ba03 Improve performance of target validation.
The Warhead and WeaponInfo classes now maintain preconstructed sets of valid and invalid targets to speed up validation checks since LINQ Intersect no longer has to be called (which recreates the sets internally each time).

Fixed minor bugs in the AI where it was repeating the validation logic but failing to account for invalid targets.
2015-04-02 21:11:12 +01:00
Oliver Brakmann
92e0dbd864 Merge pull request #7822 from RoosterDragon/map-cache-dispose-fix
Ensure MapCache disposes cleanly.
2015-04-02 20:26:02 +02:00
reaperrr
4fc58b4491 Skip shroud/fog calculations when both are disabled via lobby option. 2015-04-02 00:42:51 +02:00
RoosterDragon
9c0d3d737d Fix CellLayer.GetEnumerator. 2015-04-01 22:52:36 +01:00
RoosterDragon
47e2c48068 Ensure MapCache disposes cleanly.
This prevents the map loading thread writing to disposed objects which can have unintended side effects.
2015-04-01 20:58:09 +01:00
reaperrr
c0448fce3e Adds two new BlendModes. 2015-04-01 21:16:01 +02:00
Taryn Hill
4ed53c5952 Simplify return statements.
Remove redundant ‘this’.
Remove unused using directives.
Simplify LINQ chains.
Add some trait property descriptions.
Add readonly where viable.
Add fullstops to some yaml descriptions.
2015-04-01 12:33:17 -05:00
Paul Chote
57a6fff6ce Don’t crash if the click location is outside the map. 2015-03-31 20:59:53 +01:00