Example #1
0
        public override SKSurface Draw(GameState currentState, long frame)
        {
            Clear();

            DrawBackground();

            foreach (Character c in currentState.AllCharacters)
            {
                Point renderPoint = CharacterRenderLocation.GetRenderPoint(c);
                RenderCache [c].Render(Canvas, c, renderPoint.X, renderPoint.Y, frame);
            }

            Canvas.DrawSurface(TargetView.Draw(currentState, frame), 0, 0);
            Canvas.DrawSurface(SkillBar.Draw(currentState, frame), SkillBarOffset.X, SkillBarOffset.Y);
            Canvas.DrawSurface(LogView.Draw(currentState, frame), LogOffset.X, LogOffset.Y);

            return(Surface);
        }
Example #2
0
        public override SKSurface Draw(GameState currentState, long frame)
        {
            Clear();

            DrawBackground();

            foreach (Character c in currentState.AllCharacters)
            {
                Point renderPoint = CharacterRenderLocation.GetRenderPoint(currentState, c);
                RenderCache [c].Render(Canvas, currentState, c, renderPoint.X, renderPoint.Y, frame);
            }

            Canvas.DrawSurface(TargetView.Draw(currentState, frame), 0, 0);
            Canvas.DrawSurface(LogView.Draw(currentState, frame), LogOffset.X, LogOffset.Y);

            // We must do this from outside since DrawSurface doesn't do transparency the way we need
            if (SkillSelectionView.IsEnabled(currentState))
            {
                Canvas.DrawRect(SkillSelectionView.ScreenRect, Styles.SkillSelectionBackground);
            }
            Canvas.DrawSurface(SkillSelectionView.Draw(currentState, frame), SkillSelectionOffset.X, SkillSelectionOffset.Y);

            return(Surface);
        }