/// <summary>
        ///     Paint a representation of the simple filler (usually in designer).
        /// </summary>
        /// <param name="e">A <c>PaintValueEventArgs</c> that indicates what to paint and where to paint it.</param>
        public override void PaintValue(PaintValueEventArgs e)
        {
            //e.Graphics.FillRectangle(new SolidBrush(Color.Blue), e.Bounds /*r*/);

            ////if (e.Value is Filler)
            ////{
            ////    Brush br = ((Filler)e.Value).GetUITypeEditorBrush(e.Bounds);
            ////    if (br != null)
            ////    {
            ////        e.Graphics.FillRectangle(br, e.Bounds /*r*/);
            ////    }
            ////}

            e.Graphics.TextRenderingHint = System.Drawing.Text.TextRenderingHint.AntiAlias;

            if (e.Value is PeaceInput)
            {
                animationMode animationMode = ((PeaceInput)e.Value).AnimationMode;

                switch (animationMode)
                {
                case animationMode.OneD:
                    e.Graphics.DrawString("☺", new Font("Microsoft Sans Serif", 12), new SolidBrush(Color.Cyan),
                                          new Point(3, 1));
                    break;

                case animationMode.TwoD:
                    e.Graphics.DrawString("❁", new Font("Microsoft Sans Serif", 12), new SolidBrush(Color.Cyan),
                                          new Point(0, 1));
                    break;

                case animationMode.ThreeD:
                    e.Graphics.DrawString("⚜", new Font("Microsoft Sans Serif", 12), new SolidBrush(Color.Cyan),
                                          new Point(0, 0));
                    break;

                case animationMode.Default:
                    e.Graphics.DrawString("?", new Font("Microsoft Sans Serif", 12), new SolidBrush(Color.Cyan),
                                          new Point(3, 0));
                    break;
                }
            }
        }
    void Update()
    {
        if (Ember == null)
        {
            foreach (Transform child in transform)
            {
                if (child.name == "Ember")
                {
                    Ember = child.gameObject; break;
                }
            }
        }

        if (anim == null)
        {
            anim = Ember.GetComponent <SpriterDotNetBehaviour>().Animator;
            //This event is fired whenever an animation ends.
            anim.AnimationFinished += animationTransitions;
        }

        if (Input.anyKeyDown)
        {
            //Advance the animation.
            if (anim.CurrentAnimation.Name == "Statue")
            {
                anim.Play("Statue to Idle");
            }
            else if (anim.CurrentAnimation.Name == "Idle")
            {
                switch (mode)
                {
                case animationMode.move:
                    anim.Play("Idle to Walk");
                    mode = animationMode.straightJump;
                    break;

                case animationMode.straightJump:
                    anim.Play("Begin Straight Jump");
                    mode = animationMode.rollingJump;
                    break;

                case animationMode.rollingJump:
                    anim.Play("Begin Rolling Jump");
                    mode = animationMode.lookUp;
                    break;

                case animationMode.lookUp:
                    if (!slash)
                    {
                        anim.Play("Grounded Forward Slash");
                        slash = true;
                    }
                    else
                    {
                        slash = false;
                        anim.Play("Idle to Lookup");
                        mode = animationMode.lookDown;
                    }
                    break;

                case animationMode.lookDown:
                    anim.Play("Idle to Crouch");
                    mode = animationMode.move;
                    break;
                }
            }
            else if (anim.CurrentAnimation.Name == "Walk")
            {
                anim.Play("Run");
            }
            else if (anim.CurrentAnimation.Name == "Run")
            {
                anim.Play("Idle");
            }
            else if (anim.CurrentAnimation.Name == "Straight Jump Rising")
            {
                if (!slash)
                {
                    anim.Play("Airborn Upward Slash");
                    slash = true;
                }
                else
                {
                    anim.Play("Straight Jump Crest");
                    slash = false;
                }
            }
            else if (anim.CurrentAnimation.Name == "Straight Jump Falling" ||
                     anim.CurrentAnimation.Name == "Rolling Jump")
            {
                if (!slash)
                {
                    if (anim.CurrentAnimation.Name == "Straight Jump Falling")
                    {
                        anim.Play("Airborn Forward Slash");
                    }
                    else
                    {
                        anim.Play("Airborn Downward Slash");
                    }
                    slash = true;
                }
                else
                {
                    anim.Play("Straight Jump Landing");
                    slash = false;
                }
            }
            else if (anim.CurrentAnimation.Name == "Crouch")
            {
                anim.Play("Crouch to Idle");
            }
            else if (anim.CurrentAnimation.Name == "Lookup")
            {
                if (!slash)
                {
                    anim.Play("Grounded Upward Slash");
                    slash = true;
                }
                else
                {
                    anim.Play("Lookup to Idle");
                    slash = false;
                }
            }
        }
    }