Move Facing and Altitude onto IMove impls, with associated pile of cleanups

This commit is contained in:
Paul Chote
2010-07-31 22:59:43 +12:00
parent 88cb942430
commit 207ee49da3
51 changed files with 186 additions and 184 deletions

View File

@@ -28,8 +28,10 @@ namespace OpenRA.Mods.RA
var info = self.Info.Traits.Get<LeavesHuskInfo>();
var husk = w.CreateActor(info.HuskActor, self.Location, self.Owner);
husk.CenterLocation = self.CenterLocation;
husk.traits.Get<Unit>().Altitude = self.traits.Get<Unit>().Altitude;
husk.traits.Get<Unit>().Facing = self.traits.Get<Unit>().Facing;
var move = self.traits.Get<IMove>();
var huskMove = husk.traits.Get<IMove>();
huskMove.Altitude = move.Altitude;
huskMove.Facing = move.Facing;
var turreted = self.traits.GetOrDefault<Turreted>();
if (turreted != null)