Pass pre-combined rotations into the rendering code.
This commit is contained in:
@@ -39,7 +39,7 @@ namespace OpenRA.Mods.Cnc.Traits.Render
|
||||
var frame = init.GetValue<BodyAnimationFrameInit, uint>(this, 0);
|
||||
|
||||
yield return new ModelAnimation(model, () => WVec.Zero,
|
||||
() => new[] { body.QuantizeOrientation(orientation(), facings) },
|
||||
() => body.QuantizeOrientation(orientation(), facings),
|
||||
() => false, () => frame, ShowShadow);
|
||||
}
|
||||
}
|
||||
@@ -64,7 +64,7 @@ namespace OpenRA.Mods.Cnc.Traits.Render
|
||||
var model = self.World.ModelCache.GetModelSequence(rv.Image, info.Sequence);
|
||||
frames = model.Frames;
|
||||
modelAnimation = new ModelAnimation(model, () => WVec.Zero,
|
||||
() => new[] { body.QuantizeOrientation(self, self.Orientation) },
|
||||
() => body.QuantizeOrientation(self, self.Orientation),
|
||||
() => false, () => frame, info.ShowShadow);
|
||||
|
||||
rv.Add(modelAnimation);
|
||||
|
||||
Reference in New Issue
Block a user