Paul Chote
2e9e4cff5c
Allow NormalizeSequence to remove existing damage prefixes. Fixes #5909 .
2014-07-10 17:16:46 +12:00
Paul Chote
2b91a2363b
Fix make animations.
2014-07-08 16:56:09 +12:00
Paul Chote
5650d5fc98
Revert "use TickRender() for RenderSprites and PaletteModifier"
...
This reverts commit 87fd576b26 .
2014-07-08 11:09:54 +12:00
Paul Chote
802b6a652c
Revert "new PauseState to differentiate game and editor pausing"
...
This reverts commit d1e18cad7a .
2014-07-08 10:42:00 +12:00
Paul Chote
18c9a25232
Revert "freeze animations during pause to visualize it better"
...
This reverts commit 960248fe44 .
2014-07-08 10:40:06 +12:00
Matthias Mailänder
960248fe44
freeze animations during pause to visualize it better
2014-07-06 08:24:08 +02:00
Matthias Mailänder
d1e18cad7a
new PauseState to differentiate game and editor pausing
2014-07-06 08:24:08 +02:00
Matthias Mailänder
87fd576b26
use TickRender() for RenderSprites and PaletteModifier
2014-07-06 08:24:08 +02:00
Matthias Mailänder
0feb5a7bdc
check for building influence when growing resources
...
closes #5556
2014-07-04 09:22:14 +02:00
Matthias Mailänder
362c86764f
document the buildable and country trait
2014-07-01 09:08:08 +02:00
Matthias Mailänder
7fa51712ec
Merge pull request #5758 from pchote/cell-world-conversions
...
Generalize cell/world coordinate conversions.
2014-06-28 08:27:18 +02:00
RoosterDragon
7030d8b2b6
Changed HardwarePalette.ApplyModifiers to be more efficient.
...
- Add separate ImmutablePalette and MutablePalette classes since the distinction is extremely important to HardwarePalette.
- Keep a cache of palettes in HardwarePalette to avoid reallocation them every time ApplyModifiers is called.
- Palettes that are not allowed to be modified are copied to the buffer once when added, rather than every time ApplyModifiers is called.
- The AdjustPalette method now takes a read-only dictionary to prevent the dictionary being messed with.
- Added a constant for the palette size to remove its usage as a magic number in several areas.
- The ColorPreviewManagerWidget is annoying in that it needs to actually permanently update a palette after it has been added. To allow this, HardwarePalette now allows a palette to be replaced after initialization. The WorldRenderer therefore now also updates the PaletteReference it created earlier with the new palette to prevent stale data being used elsewhere.
2014-06-28 01:11:48 +01:00
Paul Chote
d7f1b1c9e2
Remove CVec -> WVec conversion.
2014-06-27 23:30:41 +12:00
Paul Chote
9487f49cd5
Replace WPos.ToCPos -> Map.CellContaining.
2014-06-27 23:30:40 +12:00
Paul Chote
7b52fa52b6
Replace CPos.CenterPosition -> Map.CenterOfCell.
2014-06-27 23:30:40 +12:00
Paul Chote
b6d1d26eeb
Add World parameter to Util.BetweenCells.
2014-06-27 23:30:40 +12:00
Paul Chote
086ec07eb6
Add World parameter to Target.FromCell.
2014-06-27 23:30:40 +12:00
Paul Chote
e4ea012b9e
Add World parameter to Target.FromOrder.
2014-06-27 23:30:40 +12:00
Paul Chote
5560f276ca
Map: Rename IsInMap -> Contains.
2014-06-27 22:07:03 +12:00
Paul Chote
fd4d3b40d0
Simplify shroud range checks.
2014-06-27 22:07:03 +12:00
Paul Chote
2a466d08c3
Remove the now-unused ExploredBounds optimization.
2014-06-27 22:07:03 +12:00
Paul Chote
ad730a44c3
Use CellLayer for resources.
2014-06-27 22:07:02 +12:00
Paul Chote
ce331a28e8
Use CellLayer for custom terrain.
2014-06-27 22:07:02 +12:00
Paul Chote
8dc0967d2e
Use CellLayer for ActorMap.
2014-06-27 22:07:02 +12:00
Paul Chote
baf27bc4cd
Use CellLayers for shroud.
2014-06-27 22:07:02 +12:00
Paul Chote
295af5741f
Use CellLayers for ResourceLayer.
2014-06-27 22:07:01 +12:00
Paul Chote
bbd1331536
Clean up actor selection in WorldInteractionControllerWidget.
2014-06-27 19:20:44 +12:00
Paul Chote
d43acfe94b
Merge pull request #5679 from RoosterDragon/main-loop-alloc
...
Reduce memory allocation in the main loop
2014-06-26 23:10:56 +12:00
RoosterDragon
8a60880cf1
Tackle the last of the low hanging fruit for memory allocations in the main game loop.
...
- Avoid calling string.Split twice in SprintFont.Measure.
- Change ActorsInBox method of ActorMap and ScreenMap to avoid allocating and intermediate list. As a bonus this allows the sequence to be lazily consumed. Also avoid LINQ in these methods.
- In FrozenUnderFog.TickRender, the method exits early if no players are visible so the attempt at lazy generation was not needed.
- Unwrap a LINQ Any call in ClassicProductionQueue.Tick.
- Merge some successive Where calls in ProximityCapturable into single predicates.
2014-06-22 17:29:45 +01:00
Matthias Mailänder
05609399eb
don't try to spawn resources when the cell is already full
...
fixes #5699
2014-06-22 11:49:40 +02:00
Paul Chote
57280e3eab
Merge pull request #5660 from Mailaender/document-traits
...
Documented some order related traits
2014-06-21 01:27:11 +12:00
Matthias Mailänder
e607c04cce
let harvester splatter resources when exploding
...
closes #2346
2014-06-20 11:11:31 +02:00
Matthias Mailänder
3e627d2eba
rename ore to the more generic name resources everywhere
2014-06-20 11:11:31 +02:00
Matthias Mailänder
18805779a8
document RejectsOrders
2014-06-19 21:21:14 +02:00
RoosterDragon
22abf9b4c4
Remove and sort usings.
2014-06-18 21:43:35 +01:00
Paul Chote
887a515e14
Add MinRange plumbing to attack activities.
2014-06-15 22:48:43 +12:00
ScottNZ
dbffce81a6
Remove unused usings
2014-06-15 22:16:40 +12:00
Paul Chote
1169211893
Merge pull request #5579 from Mailaender/frozen-C4
...
Fixed C4 target inconsistencies with Fog of War and Husks
2014-06-15 22:01:04 +12:00
Matthias Mailänder
8f64835898
StyleCop
2014-06-15 10:51:57 +02:00
Matthias Mailänder
dac12839fd
Merge pull request #5630 from pavlos256/map-helpers
...
Move map helpers from WorldUtils to Map
2014-06-14 11:49:19 +02:00
Matthias Mailänder
fe0d7ab00e
Merge pull request #5627 from pchote/frozen-cloak-fix
...
Invalidate FrozenActors that don’t have any sprites.
2014-06-14 11:41:49 +02:00
Matthias Mailänder
1ebfc6bb06
Merge pull request #5631 from pavlos256/dev-iddqd
...
Add "/all" dev command
2014-06-14 10:27:58 +02:00
Matthias Mailänder
ee0df9c1cb
make C4 Demolition frozen actor aware
2014-06-14 09:35:38 +02:00
Paul Chote
5e986b3079
Merge pull request #5615 from RoosterDragon/minor-alloc
...
Minor allocation tweaks
2014-06-14 12:26:39 +12:00
Pavlos Touboulidis
ee4f3e5642
Always allow cheats on single player games
2014-06-13 17:18:12 +03:00
Pavlos Touboulidis
3f2425f1d6
StyleCop
2014-06-13 15:55:48 +03:00
Pavlos Touboulidis
c282fa1077
Move GetTerrainIndex/Info from WorldUtils to Map
2014-06-13 13:57:32 +03:00
Paul Chote
96477b7c1a
Invalidate FrozenActors that don’t have any sprites. Fixes #4809 .
2014-06-13 21:07:39 +12:00
Pavlos Touboulidis
092352729f
Change terrain type from string based dictionaries to arrays
2014-06-13 11:20:54 +03:00
RoosterDragon
b8b8b1e2df
Minor changes to reduce allocation.
...
- Cache a predicate in ActorMap.
- Use short circuiting to skip a call to HasTrait in AttackBase.
- In AutoTarget.ScanForTarget, move the check for the scan time above the calculations since we can skip them if it's not time yet.
- In AutoTarget.ChooseTarget, merge four Where calls into one.
2014-06-12 05:32:44 +01:00