Commit Graph

41 Commits

Author SHA1 Message Date
Paul Chote
ab6a9597bb Remove Map usage from LobbyLogic. 2016-03-16 21:03:31 +00:00
Paul Chote
be5eee0227 Allow rules to be constructed from a MapPreview. 2016-03-12 20:01:39 +00:00
Paul Chote
9c4dd54fa3 Generate map previews on save. 2016-03-08 21:13:38 +00:00
Paul Chote
21d19e65a5 Unhardcode map installation directory. 2016-02-28 19:34:56 +00:00
Paul Chote
be52c1cb72 Properly use the virtual filesystem for map loading and saving. 2016-02-28 19:27:33 +00:00
Paul Chote
bee3eb2c0a Dispose MapPreviews and map packages. 2016-02-28 10:18:49 +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
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
Paul Chote
d492c23a6d Store map packages in MapPreview. 2016-02-21 16:11:36 +00:00
Paul Chote
02ab54c9bc Load MapPreview data without initialising a full Map. 2016-02-18 20:19:44 +00:00
Paul Chote
7b00da04ca Remove MapPreview.Map. 2016-02-06 22:30:50 +00:00
Paul Chote
3708a7649d Remove MapPreview.CacheRules. 2016-02-06 22:30:49 +00:00
Paul Chote
d5e3fbf452 Store map path in MapPreview. 2016-02-06 22:30:49 +00:00
Paul Chote
7a5678ec39 Move MapVisibility to MapPreview. 2016-02-06 22:28:35 +00:00
RoosterDragon
8e89a6a696 Simplify names, remove unused usings, remove redundant casts. 2016-01-17 21:35:36 +00:00
Pavel Penev
bb3aea338a Rename enum TileShape to MapGridType 2015-10-26 00:41:21 +02:00
Paul Chote
be37717e6d Account for cross-mod tile shapes in map previews. 2015-10-24 22:02:46 +01:00
Matthias Mailänder
72dffe3391 dispose res properly 2015-08-29 18:47:10 +02:00
Oliver Brakmann
dc08b7a90a Add buttons for map file management to map chooser 2015-05-24 01:49:30 +02:00
Paul Chote
4b1f541f34 Reorganize actor and smudge loading.
The actor and smudge definitions are now stored
as raw MiniYamlNodes in the map.  It is now the
responsibility of the consumers to parse these
into real objects.
2015-04-30 07:06:14 +12:00
penev92
2402b56da7 Reorganize PlayerReference loading to enable upgrade rules for them.
The PlayerReference definitions are now stored
as raw MiniYamlNodes in the map.
2015-04-26 23:16:20 +03: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
84dffce7c1 Added an extension method to clone bitmaps with a 32bbpArgb pixel format. 2015-04-11 21:05:46 +01:00
RoosterDragon
5dfcc3e9d0 Convert custom map previews that are not using PixelFormat.Format32bppArgb. 2015-04-10 19:54:02 +01:00
RoosterDragon
1515ac54f6 Enforce a line length limit. 2015-03-19 17:20:34 +00:00
RoosterDragon
82bea961ba Checked LINQ queries and collections for inefficiencies.
- Made Array.IndexOf available via extension method.
- Made ToHashSet extension method.
- Change collections queried often via Contains into sets.
- Avoid Count() extension if Count or Length property exist.
- Made Count() > 0 checks and variations calls to Any() instead.
- Don't call ToList/ToArray if there is no benefit to materializing the sequence.
- If the sequence does benefit from materialization, follow this general pattern:
  - Collection queried often via Contains use ToHashSet to speed up lookups.
  - Short lived variables use ToList. This is because ToArray requires an extra copy to output the final size.
  - Collections persisted into fields or for a long time use ToArray to minimize memory overhead.
2015-01-29 19:20:11 +00:00
abcdefg30
8ca61aa917 Updated all year numbers 2015-01-09 21:18:05 +01:00
Matthias Mailänder
bc3acfeee7 StyleCop clean OpenRA.Game 2015-01-04 15:38:54 +01:00
Matthias Mailänder
44cd174a8d StyleCop clean OpenRA.Game 2015-01-03 19:00:48 +01:00
Hellhake
5a97a4b63b Fix StyleCop warnings in OpenRA.Game 2015-01-02 12:11:01 +01:00
Paul Chote
50643b0cfe Fix the handling of maps with invalid rules. Fixes #6787. 2014-10-19 15:52:13 +13:00
Paul Chote
4f44cc1969 Load assets using absolute paths. Fixes #6717. 2014-10-11 11:02:30 +13:00
ihptru
305f76e300 depend on proper status in auto-downloading 2014-07-06 19:17:38 +04:00
ScottNZ
dbffce81a6 Remove unused usings 2014-06-15 22:16:40 +12:00
RoosterDragon
9dbbc23967 Make map preview generation fast.
- Change Map.LoadMapTiles and Map.LoadResourceTiles to read the whole stream into memory before processing individual bytes. This removes the cost of significant overhead from repeated calls to ReadUInt8/16.
- Remove significant UI jank caused by the map chooser by not including the placeholder widget. The maps render fast enough that it is no longer worthwhile and it was causing a lot of flushes which were the source of the jank.
- Trigger async generation for all maps when the chooser is loaded. This means in practice all previews will be ready by the time the user begins to scroll the selection. Since generation is fast, there is no issue with scrolling straight to the bottom and having to wait for the backlog to clear.
2014-06-10 11:46:39 +01:00
Matthias Mailänder
00662fe391 also do a local rule check after map download 2014-06-01 06:01:41 +02:00
Matthias Mailänder
bb57ccd5bb update MapRuleStatus after download
fixes #5479
2014-05-31 13:14:53 +02:00
Paul Chote
69e87b0057 Disable maps with broken rules in the lobby. Fixes #4334. 2014-05-18 17:41:36 +12:00
Paul Chote
657ade7221 Add map folder types. Fixes #4635. 2014-05-18 17:29:42 +12:00
Paul Chote
4935266945 Merge FileFormats dll into Game and reorganise namespaces. 2014-04-17 01:20:47 +12:00