Commit Graph

143 Commits

Author SHA1 Message Date
Matthias Mailänder
394d635dae new trait WithMakeAnimation 2014-07-06 08:24:08 +02:00
Pavlos Touboulidis
daed053a57 Fix and optimize FindTilesInCircle 2014-07-03 18:11:28 +03:00
Paul Chote
7b52fa52b6 Replace CPos.CenterPosition -> Map.CenterOfCell. 2014-06-27 23:30:40 +12:00
Paul Chote
a9635e8c4a Refund the *old* player when a production structure is captured. 2014-06-26 23:14:14 +12:00
Paul Chote
4db2cf6b2b Propagate race to produced actors. 2014-06-26 23:14:14 +12:00
Paul Chote
4b2663015b Fix CanBuild not checking DeveloperMode.AllTech. 2014-06-26 23:14:14 +12:00
Paul Chote
749a947d3f Avoid repeated queries of DeveloperMode. 2014-06-26 23:14:14 +12:00
Paul Chote
ca082e3cec Allow ProductionQueue to filter by race. 2014-06-26 23:14:13 +12:00
Paul Chote
d9e0559c7a Remove some long-dead code. 2014-06-26 23:14:13 +12:00
Paul Chote
66d9629520 Fix remaining tech tree issues. 2014-06-26 23:14:12 +12:00
Paul Chote
7b3a0ebeb5 Tidy production traits. 2014-06-26 23:14:10 +12:00
Paul Chote
6536f92b12 Allow custom prerequisites to be restricted by race. 2014-06-26 23:12:23 +12:00
Paul Chote
a5cc68efee Allow production ownership test to be disabled. 2014-06-26 23:12:23 +12:00
Paul Chote
c5089db19c Allow actors to exist in multiple building queues. 2014-06-26 23:12:22 +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
RoosterDragon
22abf9b4c4 Remove and sort usings. 2014-06-18 21:43:35 +01:00
Paul Chote
1db1a1b324 Fix a typo in ITechTreeElement. 2014-06-15 22:49:52 +12:00
ScottNZ
90894aa03e Use var everywhere 2014-06-15 22:17:34 +12:00
ScottNZ
dbffce81a6 Remove unused usings 2014-06-15 22:16:40 +12: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
Pavlos Touboulidis
ee4f3e5642 Always allow cheats on single player games 2014-06-13 17:18:12 +03:00
Pavlos Touboulidis
060d5326ed Move FindTilesInCircle from WorldUtils to Map 2014-06-13 14:24:53 +03:00
RoosterDragon
e63f330717 Improved efficiency of startup methods.
- ShpReader will copy the input stream into memory just once rather than for every header.
- ShpReader.CopyImageData switched to use Array.Copy since that uses some unsafe magic for speed.
- In ActorInfo, cache a GetType call and prevent needless materialization in PrerequisitesOf.
- In ObjectCreator, cache type and ctor lookups since these are expensive and often repeated.
- Implement IReadOnlyDictionary<T, U> on Cache<T, U> to provide some supplementary functions.
- In TechTree.GatherOwnedPrerequisites, rearrange a Boolean 'and' expression to evaluate expensive functions later in the chain, and use ContainsKey to speed up name check.
2014-06-09 17:13:01 +01:00
Paul Chote
e1501d5b7c Add clock overlay to support power beacons. 2014-05-31 18:41:02 +12:00
WolfGaming
75e13592b2 Adding to the Authors file 2014-05-19 03:29:25 +00:00
WolfGaming
00698cefff Added in code for Tech Levels using prereqs
and fixed up some kinks of the old system
2014-05-19 03:29:25 +00:00
Pavlos Touboulidis
63ec6d60e7 Refactoring to remove static Rules & SequenceProvider 2014-05-17 14:32:03 +03:00
Matthias Mailänder
f68a6bbd76 split latency from Client into ClientPing
closes #4282
2014-05-15 10:04:21 +02:00
Matthias Mailänder
f365f9da2b split lobby SyncInfo order into smaller chunks
closes #4594
2014-05-15 10:04:03 +02:00
Paul Chote
b4298982a0 Merge pull request #5262 from Mailaender/parse-invariant-culture
Added checks for NumberFormatInfo.InvariantInfo everywhere
2014-05-14 00:20:35 +12:00
Squiggles211
ce69ea2237 Fix sold tech bug on build limited structures
Fixes where if a structure with a build limit was sold, it was not
properly removed from the buildables prerequisite list until next
update.
2014-05-12 08:42:44 -05:00
Matthias Mailänder
b19d286f56 parse with NumberFormatInfo.InvariantInfo everywhere
closes #5240
2014-05-06 18:31:48 +02:00
Squiggles211
a495d9d552 Rewrite for better efficiency
uses a single, more concise statement rather than an if statement, and
checks buildLimit before attempting to check if the buildables cache
contains the key.
2014-05-02 08:26:36 -05:00
Squiggles211
11c9bd7bc8 Fix TechTree prerequisite bug for buildings with a build limit.
Fixes where a building/unit whose prereq is a build limited structure
was always available to be built even when the prereq was not satisfied.
2014-05-01 18:28:21 -05:00
Oliver Brakmann
63f4a0646f Fix build palette showing too many queued items when BuildLimit is reached
When a BuildLimit on an actor type is set and nearly reached, you could
shift-click the build palette and it would show it had five more items
queued when really less are allowed to be built. This fixes it so that
only the allowed number of items is enqueued, and thus showing the
correct number on the build palette.
2014-04-26 16:27:02 +02:00
Matthias Mailänder
fcca5a7683 StyleCop 2014-04-20 15:05:43 +02:00
Matthias Mailänder
00ca5516fc add crane animation to Dune 2000 and Tiberian Sun
closes #3754
2014-04-19 13:12:32 +02:00
Matthias Mailänder
bf4f58b5c7 StyleCop 2014-04-18 15:38:42 +02:00
Paul Chote
4935266945 Merge FileFormats dll into Game and reorganise namespaces. 2014-04-17 01:20:47 +12:00
Paul Chote
94e30503a7 Allow support powers to define a poster image for beacons. 2014-03-20 22:13:11 +13:00
Paul Chote
9f31304743 Don't notify when the world attacks your base. 2014-03-18 15:28:49 +13:00
Paul Chote
20b88fd904 Remove World.FrameNumber. 2014-03-12 17:19:29 +13:00
Stephen Holdaway
bd077d337f Set ProductionItem build time when building starts
The build time for a unit/structure was previously set at the time that
item was added to a production queue. This meant modifiers of the
production time (multiple production facilities in ClassicProductionQueue
or "instant build" in debug) were not applied to items already in a queue.

This change modifies ProductionQueue so that build time is set at the
instant an item starts building (reaches the front of it's queue). This was
done primarily to make the production bonuses in ClassicProductionQueue
more apparent, though it also makes the "instant build" debug option more
responsive when items are queued prior to enabling.
2014-03-09 14:56:54 +13:00
Chicken man
cf3cc43a28 Changed things to do with Shroud to WRange. Updated Utility. 2014-03-05 17:30:33 -05:00
ScottNZ
0a9a959ecf Change spacebar key to move to the last visible radar ping location 2014-02-22 00:07:54 +13:00
ScottNZ
06caf7f156 Add radar pings to BaseAttackNotifier and HarvesterAttackNotifier 2014-02-22 00:07:54 +13:00
ScottNZ
2a8efde8e6 Add map beacons and radar pings 2014-02-22 00:07:53 +13:00
Kanar
aace7ca607 Disables "building"-speech when nothing more can be built 2014-01-18 22:42:05 +01:00
Paul Chote
bbc19df512 Fix StyleCop issues in TechTree. 2013-12-08 21:40:59 +13:00
Paul Chote
e76dbcd4bf Silently ignore bogus prerequisites instead of crashing. Fixes #4225. 2013-12-08 21:34:49 +13:00