diff --git a/samples/Cpp/HelloCpp/proj.emscripten/main.cpp b/samples/Cpp/HelloCpp/proj.emscripten/main.cpp new file mode 100644 index 0000000000..be615ef301 --- /dev/null +++ b/samples/Cpp/HelloCpp/proj.emscripten/main.cpp @@ -0,0 +1,20 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(800, 480); + + return CCApplication::sharedApplication()->run(); +} diff --git a/samples/Cpp/SimpleGame/proj.emscripten/main.cpp b/samples/Cpp/SimpleGame/proj.emscripten/main.cpp new file mode 100644 index 0000000000..fbaeec114b --- /dev/null +++ b/samples/Cpp/SimpleGame/proj.emscripten/main.cpp @@ -0,0 +1,20 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(800, 480); + + return CCApplication::sharedApplication()->run(); +} diff --git a/samples/Cpp/TestCpp/proj.emscripten/main.cpp b/samples/Cpp/TestCpp/proj.emscripten/main.cpp new file mode 100644 index 0000000000..bbaa8a6d23 --- /dev/null +++ b/samples/Cpp/TestCpp/proj.emscripten/main.cpp @@ -0,0 +1,19 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" +#include "CCEGLView.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(800, 480); + return CCApplication::sharedApplication()->run(); +} diff --git a/samples/Lua/HelloLua/proj.emscripten/main.cpp b/samples/Lua/HelloLua/proj.emscripten/main.cpp new file mode 100644 index 0000000000..dd21672f23 --- /dev/null +++ b/samples/Lua/HelloLua/proj.emscripten/main.cpp @@ -0,0 +1,18 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(960, 640); + return CCApplication::sharedApplication()->run(); +} diff --git a/samples/Lua/TestLua/proj.emscripten/main.cpp b/samples/Lua/TestLua/proj.emscripten/main.cpp new file mode 100644 index 0000000000..bbaa8a6d23 --- /dev/null +++ b/samples/Lua/TestLua/proj.emscripten/main.cpp @@ -0,0 +1,19 @@ +#include "../Classes/AppDelegate.h" +#include "cocos2d.h" +#include "CCEGLView.h" + +#include +#include +#include +#include + +USING_NS_CC; + +int main(int argc, char **argv) +{ + // create the application instance + AppDelegate app; + CCEGLView* eglView = CCEGLView::sharedOpenGLView(); + eglView->setFrameSize(800, 480); + return CCApplication::sharedApplication()->run(); +}