works *without* aftermath again.
This commit is contained in:
@@ -63,6 +63,7 @@ namespace OpenRa.Game
|
||||
controller = new Controller();
|
||||
worldRenderer = new WorldRenderer( renderer );
|
||||
|
||||
SequenceProvider.Initialize(useAftermath);
|
||||
viewport = new Viewport( clientSize, Rules.Map.Offset, Rules.Map.Offset + Rules.Map.Size, renderer );
|
||||
|
||||
world = new World();
|
||||
|
||||
@@ -12,10 +12,17 @@ namespace OpenRa.Game.Graphics
|
||||
|
||||
static Dictionary<string, CursorSequence> cursors = new Dictionary<string, CursorSequence>();
|
||||
|
||||
static SequenceProvider()
|
||||
public static void Initialize( bool useAftermath )
|
||||
{
|
||||
LoadSequenceSource("sequences.xml");
|
||||
if (useAftermath)
|
||||
LoadSequenceSource("sequences-aftermath.xml");
|
||||
}
|
||||
|
||||
static void LoadSequenceSource(string filename)
|
||||
{
|
||||
XmlDocument document = new XmlDocument();
|
||||
document.Load(FileSystem.Open("sequences.xml"));
|
||||
document.Load(FileSystem.Open(filename));
|
||||
|
||||
foreach (XmlElement eUnit in document.SelectNodes("/sequences/unit"))
|
||||
LoadSequencesForUnit(eUnit);
|
||||
|
||||
@@ -45,8 +45,8 @@ namespace OpenRa.Game.Traits.Activities
|
||||
umt = mobile.GetMovementType(),
|
||||
checkForBlocked = false,
|
||||
};
|
||||
var refineries = Game.world.Actors.Where( x => x.unitInfo != null
|
||||
&& x.unitInfo.Name == "proc" && x.Owner == self.Owner ).ToList();
|
||||
var refineries = Game.world.Actors.Where( x => x.traits.Contains<AcceptsOre>()
|
||||
&& x.Owner == self.Owner ).ToList();
|
||||
if( refinery != null )
|
||||
search.AddInitialCell( refinery.Location + refineryDeliverOffset );
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user