Change Exit.SpawnOffsetVector to WVec.

This commit is contained in:
Paul Chote
2013-07-21 10:08:48 +12:00
parent ac3f63b59c
commit 36a45d1a3f
4 changed files with 9 additions and 10 deletions

View File

@@ -217,8 +217,7 @@ namespace OpenRA.Mods.RA.Missions
cargo.Load(chinook, world.CreateActor(false, ChinookCargo.Random(world.SharedRandom), allies, null, null));
var exit = lz.Info.Traits.WithInterface<ExitInfo>().FirstOrDefault();
var offset = (exit == null) ? WVec.Zero :
new WVec(exit.SpawnOffsetVector.X, exit.SpawnOffsetVector.Y, 0) * 1024 / Game.CellSize;
var offset = (exit != null) ? exit.SpawnOffsetVector : WVec.Zero;
chinook.QueueActivity(new HeliFly(lz.CenterPosition + offset)); // no reservation of hpad but it's not needed
chinook.QueueActivity(new Turn(0));