Exemple #1
0
        public static void FillWithMetadata(ClickEfect clickEfect, ClickEffectMetadata metadata, ContentManager contentManager)
        {
            clickEfect.Content = AnimatedObject.FromMetadata(contentManager.Load<AnimatedObjectMetadata>(metadata.ContentPath), contentManager);
            clickEfect.Content.AddAnimationRule("Default", () => true);

            clickEfect.EndSize = metadata.EndSize;
            clickEfect.StartSize = metadata.StartSize;
            clickEfect.TimeAlive = metadata.TimeAlive;
        }
Exemple #2
0
 public static ClickEfect FromMetadata(ClickEffectMetadata metadata, ContentManager contentManager)
 {
     var clickEfect = new ClickEfect();
     FillWithMetadata(clickEfect, metadata, contentManager);
     return clickEfect;
 }