【发布时间】:2014-06-25 21:30:21
【问题描述】:
我需要知道播放器何时切换设备的方向。因此,我使用这个事件,但我总是这个错误信息。怎么了?
this.OrientationChanged += OrientationChanged();
方法 'OrientationChanged' 没有重载需要 0 个参数
如何在 MonoGame Windows Phone 8 游戏中使用此事件?
我在 Game1.cs 中使用如下代码:
this.OrientationChanged += OrientationChanged();
void OrientationChanged(object sender, OrientationChangedEventArgs e)
{
if (e.Orientation == PageOrientation.LandscapeLeft)
{
}
}
我的项目:https://www.dropbox.com/s/qa1ty2ydo1hqfwn/MonogameFarseerDemo.rar
【问题讨论】: