如何创建使用C#Windows窗体一个流畅的动画效果? [英] How to create a smooth animation using C# Windows forms?

查看:681
本文介绍了如何创建使用C#Windows窗体一个流畅的动画效果?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

由于我的学校项目,我必须创建一个使用Windows窗体个游戏而已。

due my school project I must create a game using Windows forms only..

我决定创建一个2D的赛车游戏。所以现在我需要动车的形象。
要移动它,我试图动画车KeyDown事件,但动画真的..蹒跚
那么,有没有其他的方式来创建动画?或者是它可能以某种方式soomth呢?
(对于汽车我用停靠的形式,并在其绘制事件IM重绘汽车在右边的窗口位置的图片框)。

I have decided to create a 2D racing game. So now I need to move the car image. To move it I tried to animate the car with the KeyDown event, however the animation is really Faltering.. So is there any other way to create animation? or is it possible to soomth it somehow? (For the car I use a PictureBox that Docked to the form and in its paint event im redrawing the car in the right window positions.)

推荐答案

这个职位应该解决您的问题:
简单使用 - 动画 - -C-Windows的形式

This post should solve your issues: simple-animation-using-c-windows-forms

他详细介绍他是如何绕到在Windows窗体中的编码动画和介绍了一些您的问题。

He details how he went around coding animation in a windows form and covers some of your questions.

如果不解决这个问题,查找使用一些XNA库,弗里曼说。

If that doesn't solve it, look up using some XNA libraries as Freeman said.

这篇关于如何创建使用C#Windows窗体一个流畅的动画效果?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆