我2个场景…在一个导入另一个的头文件后一运行就一直吐槽关于其中一个场景未定义问题…
2>f:\cocos\code\plane\classes\gameoverscene.h(5): error C2011: “GameOverLayer”:“class”类型重定义
2> f:\cocos\code\plane\classes\gameoverscene.h(5) : 参见“GameOverLayer”的声明
2>f:\cocos\code\plane\classes\enemylayer.h(31): warning C4996: ‘cocos2d::LabelBMFont’: 被声明为已否决
2> f:\cocos\code\plane\cocos2d\cocos\2d\cclabelbmfont.h(81) : 参见“cocos2d::LabelBMFont”的声明
2>f:\cocos\code\plane\classes\gameoverscene.cpp(6): error C2027: 使用了未定义类型“GameOverLayer”
2> f:\cocos\code\plane\classes\gameoverscene.h(5) : 参见“GameOverLayer”的声明
2>f:\cocos\code\plane\classes\gameoverscene.cpp(8): error C2027: 使用了未定义类型“GameOverLayer”
2> f:\cocos\code\plane\classes\gameoverscene.h(5) : 参见“GameOverLayer”的声明
2>f:\cocos\code\plane\classes\gameoverscene.cpp(8): error C3861: “create”: 找不到标识符
2>f:\cocos\code\plane\classes\gameoverscene.cpp(13): error C2027: 使用了未定义类型“GameOverLayer”
2> f:\cocos\code\plane\classes\gameoverscene.h(5) : 参见“GameOverLayer”的声明
2>f:\cocos\code\plane\classes\gameoverscene.cpp(15): error C2248: “cocos2d::Layer::init”: 无法访问 protected 成员(在“cocos2d::Layer”类中声明)
这是什么问题…难道是因为不能同时相互导入头文件么?
