android - AndEngine 与PhysicsFactory 错误

标签 android andengine

当我尝试运行 andengine 示例时,我遇到了这个问题:

The method createBoxBody(PhysicsWorld, IShape, BodyDef.BodyType, FixtureDef) from the type PhysicsFactory refers to the missing type IShape

在这一行:

PhysicsFactory.createBoxBody(this.mPhysicsWorld, ground, BodyType.StaticBody, wallFixtureDef);

这个错误:

The method registerUpdateHandler(IUpdateHandler) in the type Entity is not applicable for the arguments (PhysicsWorld)

在这一行:

this.mScene.registerUpdateHandler(this.mPhysicsWorld);

谢谢

最佳答案

我也遇到了同样的问题。

解决方案是让 AndEnginePhysicsBox2DExtension-GLES2 将 AndEngine-GLES2 作为 IntelliJ 中的模块依赖项。

关于android - AndEngine 与PhysicsFactory 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9518132/

相关文章:

java - 宽高比为 800x480

java - AndEngine 背景缩放

android - 在一个通用池 AndEngine 中使用不同的 Sprite 纹理

android - 我应该为发布版本删除泄漏的金丝雀代码/类吗?

android - Andengine导入错误

java - 在 json 中插入/显示/加载崩溃

java - Azure 移动服务 Android 错误

java - AndEngine:让 Sprite 同时移动和跳跃?

android - 如何在不上传新 APK 的情况下在 Android 上远程更新翻译 string.xml?

Android support-v7-appcompat 问题与 4.0 及更高版本