Commit Graph

53 Commits

Author SHA1 Message Date
atlimit8
27ad5208fb Fixed Mobile.SetPosition & other FixUnloadCargo touch-ups
Fixed Mobile.SetPosition
Finally removed old SubCell enum
Folded MobileInfo.CanEnterCell overloads into one
Renamed IPositionable.{IsMovingFrom => IsLeaving}
Changed Crate.IsLeaving to use crate lifetime
2014-08-29 23:00:53 -05:00
atlimit8
b2c9064545 Refactored [sub-]cell availability logic in IPositionable & ActorMap
Moved the logic from IPositionable.CanEnterCell & integrated sub-cell selection.
Added IPositionable.IsMovingFrom(CPos location, int subCell = -1) - to detect transient actors
Renamed IPositionable.{GetDesiredSubcell => GetAvailableSubcell} - since it checks for available sub-cells
Reduced IPositionable.CanEnterCell to one method that usually uses IPositionable.GetAvailableSubcell
Added actor checking to ActorMap.{HasFreeSubCell, FreeSubCell, AnyUnitsAt} - used by [sub-]cell availability logic
2014-08-29 23:00:53 -05:00
atlimit8
ff7ad53dee Fixed UnloadCargo stacking using new subcell API exposure 2014-08-29 23:00:53 -05:00
atlimit8
fe57417aa8 Added int subCell = -1 to IMove.MoveIntoWorld & IPositionable.SetPosition(Actor self, CPos cell) 2014-08-29 23:00:53 -05:00
Alexander Fast
070d00c678 Fixes year numbers in license text in file headers. 2014-08-21 11:27:52 +02:00
atlimit8
43478dd500 enum SubCell => int & Dictionary<SubCell, WVec> => WVec[] 2014-08-04 18:09:26 -05: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
5560f276ca Map: Rename IsInMap -> Contains. 2014-06-27 22:07:03 +12:00
Paul Chote
2026747f2a Use Map.IsInMap(CPos) for things that are checking CPos. 2014-06-27 19:20:46 +12:00
ScottNZ
dbffce81a6 Remove unused usings 2014-06-15 22:16:40 +12:00
Pavlos Touboulidis
c282fa1077 Move GetTerrainIndex/Info from WorldUtils to Map 2014-06-13 13:57:32 +03:00
Pavlos Touboulidis
092352729f Change terrain type from string based dictionaries to arrays 2014-06-13 11:20:54 +03:00
Paul Chote
4935266945 Merge FileFormats dll into Game and reorganise namespaces. 2014-04-17 01:20:47 +12:00
Matthias Mailänder
56470b918b use the disabled palette to render husks
closes #4631
2014-03-05 23:18:14 +01:00
Taryn Hill
e3e7d0b38c Add ignoreActor and checkTransientActors to IPositionable.CanEnterCell
Improved 'return' checks
Removed unnecessary 'using'
Fixed defaults.yaml spelling error
2013-10-13 20:24:29 -04:00
Paul Chote
27e4bbf1cb Replace CenterLocationInit -> CenterPositionInit. 2013-09-27 15:41:32 +12:00
Paul Chote
e03ec690ff Track actor positions in ActorMap. 2013-09-27 15:36:51 +12:00
Paul Chote
b00cc6108d Make ActorMap addition explicit. 2013-09-27 15:36:51 +12:00
Paul Chote
dfd51c0caa Introduce ScreenMap trait for caching screen-coord queries. 2013-09-27 15:36:25 +12:00
Paul Chote
e08445f762 Remove obsolete functions from Traits.Util. 2013-08-01 20:18:44 +12:00
Paul Chote
c3f04cc32e Convert non-aircraft positioning to world coords.
This removes the incomplete and unused hover code
on Mobile, which would be more trouble that it is
currently worth to carry over.
2013-07-21 17:35:47 +12:00
Paul Chote
e23c1ad33e Rewrite husks using world coords. 2013-07-21 17:35:46 +12:00
Paul Chote
6a435752fd Remove *PxPosition from IOccupySpace/IPositionable. 2013-07-21 17:35:46 +12:00
Paul Chote
19165d259d Add world coord overloads to IOccupySpace and IPositionable. 2013-07-21 17:35:46 +12:00
Paul Chote
ecc119cb29 Combine IHasLocation -> IOccupySpace, IMove -> ITeleportable. 2013-07-21 17:33:32 +12:00
Paul Chote
55d5db0f02 Set produced unit position via an ActorInitializer. Fixes #3214. 2013-05-04 12:11:43 +12:00
Scott_NZ
43d0363a55 Formatting improvements from Husk/Allies01 2012-08-16 21:46:30 +12:00
Scott_NZ
48f934f188 Set up tran husks, and stop husk placement causing crashes 2012-07-31 09:12:22 +12:00
James Dunne
9c49143534 New types for cell and pixel coordinate position/vectors. 2012-06-21 15:36:59 -05:00
Chris Forbes
bc6af1841b fix indents everywhere 2011-10-18 15:10:17 +13:00
Chris Forbes
2bc260c833 move Activity from OpenRA.Traits.Activities namespace to OpenRA.Traits 2011-10-06 23:11:58 +13:00
Chris Forbes
55036cd58c fix trailing whitespace everywhere 2011-09-26 08:40:39 +13:00
Chris Forbes
2bf7cb1496 fix #1052; tidy up *Init; route initial turret facing for husks through new TurretFacingInit 2011-08-09 08:51:36 +12:00
Chris Forbes
ddc1311d87 Make RenderUnit require IFacing; RenderSimple can be used for crates, mines, etc; fix husk facing init 2011-08-09 08:51:35 +12:00
Paul Chote
cf9ac8d801 Fix a dumb crash & avoid a trait lookup in DragHusk 2011-07-26 10:01:32 +12:00
Paul Chote
0a5f81c39e Drag husks to their final location. Fixes #730. 2011-07-25 23:50:11 +12:00
Paul Chote
094907c1a9 Update copyright header. Normalize line endings to LF. 2011-02-13 10:38:57 +13:00
Paul Chote
4b3c6cc62a Add a SubCell field to UIM. Allow UIM to query for units by subcell. 2011-02-04 18:39:03 +13:00
Chris Forbes
f52620f6fc add ISync to all traits that have [Sync] members 2011-01-26 21:00:28 +13:00
Paul Chote
dba7335594 Fix a pile of compiler warnings. 2010-11-21 13:10:22 +13:00
Bob
8a96c5f7b5 fix infantry entering buildings 2010-11-06 22:27:28 +13:00
Bob
011a20e8b4 add IHasLocation 2010-10-12 07:59:40 +13:00
Chris Forbes
f402ec7898 Revert "add IHasLocation"
This reverts commit 699b4b1154.
2010-09-28 07:43:49 +13:00
Bob
699b4b1154 add IHasLocation 2010-09-26 18:17:23 +12:00
Bob
ae703d50b2 Actor.traits is implementation detail 2010-08-14 17:39:49 +12:00
alzeih
4ea66ea309 Added FacingInit and AltitudeInit. Used in Mobile/Aircraft/Husks. Refactored Production, SpyPlane, Paratroopers and LeavesHusk 2010-08-02 00:49:26 +12:00
Bob
10b7ece62e new mapactor init stuff 2010-08-01 19:38:39 +12:00
Paul Chote
d29e3f3f0e Split facing into its own interface; fix husks 2010-08-01 01:01:31 +12:00
Chris Forbes
d5f12dd8ee trim down license spam in all files 2010-07-18 16:48:21 +12:00