public override void UpdatePrimitive(BillboardPrimitive Primitive, int CurrentFrame) { SpriteSheet = new SpriteSheet(Composite.GetTarget(CurrentOffset)); if (CurrentFrame >= CompositeFrames.Count) { return; } PushFrames(); CurrentOffset = Composite.PushFrame(CompositeFrames[CurrentFrame]); var rect = Composite.GetFrameRect(CurrentOffset); Primitive.SetFrame(SpriteSheet, rect, rect.Width / 32.0f, rect.Height / 32.0f, Color.White, Color.White, Flipped); }
public override ImageFrame GetAsImageFrame(int CurrentFrame) { return(new ImageFrame(Composite.GetTarget(CurrentOffset), Composite.GetFrameRect(CurrentOffset))); }