diff --git a/AUTHORS b/AUTHORS index aa9402cb1c..c68d82da64 100644 --- a/AUTHORS +++ b/AUTHORS @@ -828,6 +828,7 @@ Developers: Added missing Text Font and Placeholder feature of EditBox for Mac platform HttpRequest uses std::function as callback EditBox: mac secure input + Fix a bug that can not get/set text in password mode on Mac OS X iSevenDays Fixed a bug that the result of 'malloc' is incompatible with type 'unsigned char *' in Image::saveImageToPNG @@ -887,6 +888,7 @@ Developers: Added TextField::getStringLength() Add shadow, outline, glow filter support for UIText Fix UITextField IME can't auto detach + Add getChildByName method for get a node that can be cast to Type T QiuleiWang Fix the bug that calculated height of multi-line string was incorrect on iOS @@ -896,7 +898,8 @@ Developers: kyokomi Fix the bug that UIButton doesn't support TTF font - Fix a but of TextReader + Fix a bug of TextReader + Fix a bug that UITextField doesn't support TTF font gin0606 Add a new line at the end of a file @@ -910,6 +913,12 @@ Developers: chareice Make `setup.py` work on zsh + + taug + Could add seach path and resolution order path in front. + + CaiCQ + Fix a but that LabelTTF may lost chinese characters on linux Retired Core Developers: WenSheng Yang diff --git a/CHANGELOG b/CHANGELOG index ad5c3e1d42..ced3fc6798 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,19 +1,32 @@ -cocos2d-x-3.2 ?? +cocos2d-x-3.2 Jul.17 2014 + [NEW] Node: added getChildByName method for get a node that can be cast to Type T + [NEW] FileUtils: could add seach path and resolution order path in front + [FIX] Animation3D: getOrCreate is deprecated and replaced with Animation3D::create [FIX] Animate3D: setSpeed() accept negtive value, which means play reverse, getPlayback and setPlayBack are deprecated + [FIX] EditBox: can not set/get text in password mode on Mac OS X + [FIX] Game Controller: joystick y value inversed on iOS [FIX] GLView: cursor position is not correct if design resolution is different from device resolution - [FIX] Label: color can not be set correctly if using system font + [FIX] Label: color can not be set correctly if using system font on iOS + [FIX] LabelTTF: may lost chinese characters on linux [FIX] Lua-binding: support UIVideoPlayer [FIX] Node: setRotation3D not work based on anchor point [FIX] Node: modify regular of enumerateChildren, now it just searchs its children - [FIX] Setup.py: not work if using zsh + [FIX] Physics integration: body shape will be wrong when using negative value to scale + [FIX] ScrollViewDelegate: make the scrollView delegate methods optional + [FIX] Setup.py: will crash on windows because of checking `zsh` [FIX] SpriteBatchNode: opacity can not work [FIX] Sprite3D: may crash on Android if playing animation and replace Scene after come from background - [FIX] UIdget: opacity is wrong when replace texture + [FIX] UIwidget: opacity is wrong when replace texture + [FIX] UIRichText: will crash when using utf8 string and the length exceed specified length + [FIX] UIText: can not wrap words automatically [FIX] UITextField: keyboard can not hide if touching space outside of keyboard + [FIX] UITextField: can not wrap words automatically + [FIX] UIVideoPlayer: can not exit full screen mode on Android [FIX] Others: don't release singleton objects correctly that are needed in the whole game, which will be treated as memory leak when using VLD. + [FIX] Others: compiling error when building for iOS 64-bit devices with Xcode6 beta3 cocos2d-x-3.2rc0 Jul.7 2014 diff --git a/build/cocos2d_libs.xcodeproj/project.pbxproj b/build/cocos2d_libs.xcodeproj/project.pbxproj index afffa6f339..08b4c96517 100644 --- a/build/cocos2d_libs.xcodeproj/project.pbxproj +++ b/build/cocos2d_libs.xcodeproj/project.pbxproj @@ -7475,15 +7475,6 @@ "\"$(SRCROOT)/../external/websockets/prebuilt/ios\"", "\"$(SRCROOT)/../external/curl/prebuilt/ios\"", ); - "OTHER_LDFLAGS[arch=arm64]" = ( - "-lcurl_arm64", - "-ljpeg_arm64", - "-lpng_arm64", - "-ltiff_arm64", - "-lwebp_arm64", - "-lwebsockets_arm64", - "-lfreetype_arm64", - ); SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = "1,2"; USER_HEADER_SEARCH_PATHS = "$(inherited) $(SRCROOT)/../external/websockets/include/ios $(SRCROOT)/../external/freetype2/include/ios $(SRCROOT)/../external/curl/include/ios $(SRCROOT)/../external/webp/include/ios $(SRCROOT)/../external/tiff/include/ios $(SRCROOT)/../external/jpeg/include/ios $(SRCROOT)/../external/png/include/ios"; @@ -7515,15 +7506,6 @@ "\"$(SRCROOT)/../external/websockets/prebuilt/ios\"", "\"$(SRCROOT)/../external/curl/prebuilt/ios\"", ); - "OTHER_LDFLAGS[arch=arm64]" = ( - "-lcurl_arm64", - "-ljpeg_arm64", - "-lpng_arm64", - "-ltiff_arm64", - "-lwebp_arm64", - "-lwebsockets_arm64", - "-lfreetype_arm64", - ); SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = "1,2"; USER_HEADER_SEARCH_PATHS = "$(inherited) $(SRCROOT)/../external/websockets/include/ios $(SRCROOT)/../external/freetype2/include/ios $(SRCROOT)/../external/curl/include/ios $(SRCROOT)/../external/webp/include/ios $(SRCROOT)/../external/tiff/include/ios $(SRCROOT)/../external/jpeg/include/ios $(SRCROOT)/../external/png/include/ios"; diff --git a/build/cocos2d_tests.xcodeproj/project.pbxproj b/build/cocos2d_tests.xcodeproj/project.pbxproj index a76759dc2b..0db024a45a 100644 --- a/build/cocos2d_tests.xcodeproj/project.pbxproj +++ b/build/cocos2d_tests.xcodeproj/project.pbxproj @@ -58,6 +58,9 @@ 1503FAC418DA8B6C00F6518C /* tp.lua in Resources */ = {isa = PBXBuildFile; fileRef = 1503FAB118DA8B6C00F6518C /* tp.lua */; }; 1503FAC518DA8B6C00F6518C /* url.lua in Resources */ = {isa = PBXBuildFile; fileRef = 1503FAB218DA8B6C00F6518C /* url.lua */; }; 1503FAC618DA8B6C00F6518C /* url.lua in Resources */ = {isa = PBXBuildFile; fileRef = 1503FAB218DA8B6C00F6518C /* url.lua */; }; + 156229331973D400009C9067 /* bitExtend.lua in Resources */ = {isa = PBXBuildFile; fileRef = 156229321973D400009C9067 /* bitExtend.lua */; }; + 156229341973D400009C9067 /* bitExtend.lua in Resources */ = {isa = PBXBuildFile; fileRef = 156229321973D400009C9067 /* bitExtend.lua */; }; + 156EAE071977D0BD00F53709 /* ActionTimeline in Resources */ = {isa = PBXBuildFile; fileRef = 38FA2E75194AECF800FF2BE4 /* ActionTimeline */; }; 15AECE0B195C0F8A00907DB0 /* MediaPlayer.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3EA0FB65191B933000B170C8 /* MediaPlayer.framework */; }; 15AECE0F195C1FDD00907DB0 /* cocosvideo.mp4 in Resources */ = {isa = PBXBuildFile; fileRef = 3EA0FB5D191B92F100B170C8 /* cocosvideo.mp4 */; }; 15AECE1F195D0EC500907DB0 /* experimentalConstants.lua in Resources */ = {isa = PBXBuildFile; fileRef = 15AECE1E195D0EC500907DB0 /* experimentalConstants.lua */; }; @@ -1393,6 +1396,7 @@ 1503FAB018DA8B6C00F6518C /* socket.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = socket.lua; path = ../external/lua/luasocket/socket.lua; sourceTree = ""; }; 1503FAB118DA8B6C00F6518C /* tp.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = tp.lua; path = ../external/lua/luasocket/tp.lua; sourceTree = ""; }; 1503FAB218DA8B6C00F6518C /* url.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = url.lua; path = ../external/lua/luasocket/url.lua; sourceTree = ""; }; + 156229321973D400009C9067 /* bitExtend.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = bitExtend.lua; path = "../cocos/scripting/lua-bindings/script/bitExtend.lua"; sourceTree = ""; }; 15AECE1E195D0EC500907DB0 /* experimentalConstants.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = experimentalConstants.lua; path = "../cocos/scripting/lua-bindings/script/experimentalConstants.lua"; sourceTree = ""; }; 15C64822165F391E007D4F18 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/Cocoa.framework; sourceTree = DEVELOPER_DIR; }; 15C64824165F3934007D4F18 /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/OpenGL.framework; sourceTree = DEVELOPER_DIR; }; @@ -5531,6 +5535,7 @@ 1ABCA36418CD9E060087CE3A /* Lua Common */ = { isa = PBXGroup; children = ( + 156229321973D400009C9067 /* bitExtend.lua */, 15AECE1E195D0EC500907DB0 /* experimentalConstants.lua */, 1503FAA918DA8B6C00F6518C /* ftp.lua */, 1503FAAA18DA8B6C00F6518C /* headers.lua */, @@ -7866,6 +7871,7 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + 156EAE071977D0BD00F53709 /* ActionTimeline in Resources */, 15E66FD6192DC8C700C20A52 /* Sprite3DTest in Resources */, 1AC35DC318CEE65100F37B72 /* Misc in Resources */, 1AC35DC618CEE65100F37B72 /* Shaders in Resources */, @@ -7897,6 +7903,7 @@ 15C90B4918E66C2A00D69802 /* tp.lua in Resources */, 1AC35DE918CEE65900F37B72 /* effect1.wav in Resources */, 1ABCA38E18CD9E180087CE3A /* GuiConstants.lua in Resources */, + 156229331973D400009C9067 /* bitExtend.lua in Resources */, 15C90B3F18E66C0C00D69802 /* ltn12.lua in Resources */, 15C90B4718E66C2400D69802 /* socket.lua in Resources */, 15C90B3A18E66BE200D69802 /* ftp.lua in Resources */, @@ -7939,6 +7946,7 @@ 15B0870D195AD52000D6F62B /* ActionTimeline in Resources */, 15E66FC8192D957100C20A52 /* Sprite3DTest in Resources */, 15C90B4418E66C1800D69802 /* mime.lua in Resources */, + 156229341973D400009C9067 /* bitExtend.lua in Resources */, 15C90B4C18E66C3100D69802 /* url.lua in Resources */, 1AC35DD618CEE65200F37B72 /* Misc in Resources */, 1ABCA37B18CD9E180087CE3A /* CCBReaderLoad.lua in Resources */, diff --git a/cocos/2d/CCFastTMXLayer.cpp b/cocos/2d/CCFastTMXLayer.cpp index 15d5717330..7b422e766a 100644 --- a/cocos/2d/CCFastTMXLayer.cpp +++ b/cocos/2d/CCFastTMXLayer.cpp @@ -49,15 +49,16 @@ THE SOFTWARE. #include NS_CC_BEGIN +namespace experimental { -const int FastTMXLayer::FAST_TMX_ORIENTATION_ORTHO = 0; -const int FastTMXLayer::FAST_TMX_ORIENTATION_HEX = 1; -const int FastTMXLayer::FAST_TMX_ORIENTATION_ISO = 2; +const int TMXLayer::FAST_TMX_ORIENTATION_ORTHO = 0; +const int TMXLayer::FAST_TMX_ORIENTATION_HEX = 1; +const int TMXLayer::FAST_TMX_ORIENTATION_ISO = 2; // FastTMXLayer - init & alloc & dealloc -FastTMXLayer * FastTMXLayer::create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) +TMXLayer * TMXLayer::create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) { - FastTMXLayer *ret = new FastTMXLayer(); + TMXLayer *ret = new TMXLayer(); if (ret->initWithTilesetInfo(tilesetInfo, layerInfo, mapInfo)) { ret->autorelease(); @@ -66,7 +67,7 @@ FastTMXLayer * FastTMXLayer::create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *l return nullptr; } -bool FastTMXLayer::initWithTilesetInfo(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) +bool TMXLayer::initWithTilesetInfo(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) { if( tilesetInfo ) @@ -108,7 +109,7 @@ bool FastTMXLayer::initWithTilesetInfo(TMXTilesetInfo *tilesetInfo, TMXLayerInfo return true; } -FastTMXLayer::FastTMXLayer() +TMXLayer::TMXLayer() : _layerName("") , _layerSize(Size::ZERO) , _mapTileSize(Size::ZERO) @@ -124,7 +125,7 @@ FastTMXLayer::FastTMXLayer() _buffersVBO[0] = _buffersVBO[1] = 0; } -FastTMXLayer::~FastTMXLayer() +TMXLayer::~TMXLayer() { CC_SAFE_RELEASE(_tileSet); CC_SAFE_RELEASE(_texture); @@ -140,7 +141,7 @@ FastTMXLayer::~FastTMXLayer() } } -void FastTMXLayer::draw(Renderer *renderer, const Mat4& transform, uint32_t flags) +void TMXLayer::draw(Renderer *renderer, const Mat4& transform, uint32_t flags) { updateTotalQuads(); @@ -169,13 +170,13 @@ void FastTMXLayer::draw(Renderer *renderer, const Mat4& transform, uint32_t flag auto& cmd = _renderCommands[index++]; cmd.init(iter.first); - cmd.func = CC_CALLBACK_0(FastTMXLayer::onDraw, this, _indicesVertexZOffsets[iter.first], iter.second); + cmd.func = CC_CALLBACK_0(TMXLayer::onDraw, this, _indicesVertexZOffsets[iter.first], iter.second); renderer->addCommand(&cmd); } } -void FastTMXLayer::onDraw(int offset, int count) +void TMXLayer::onDraw(int offset, int count) { GL::bindTexture2D(_texture->getName()); getGLProgramState()->apply(_modelViewTransform); @@ -194,7 +195,7 @@ void FastTMXLayer::onDraw(int offset, int count) CC_INCREMENT_GL_DRAWN_BATCHES_AND_VERTICES(1, count * 4); } -void FastTMXLayer::updateTiles(const Rect& culledRect) +void TMXLayer::updateTiles(const Rect& culledRect) { Rect visibleTiles = culledRect; Size mapTileSize = CC_SIZE_PIXELS_TO_POINTS(_mapTileSize); @@ -287,7 +288,7 @@ void FastTMXLayer::updateTiles(const Rect& culledRect) } -void FastTMXLayer::updateVertexBuffer() +void TMXLayer::updateVertexBuffer() { GL::bindVAO(0); if(!glIsBuffer(_buffersVBO[0])) @@ -300,7 +301,7 @@ void FastTMXLayer::updateVertexBuffer() glBindBuffer(GL_ARRAY_BUFFER, 0); } -void FastTMXLayer::updateIndexBuffer() +void TMXLayer::updateIndexBuffer() { if(!glIsBuffer(_buffersVBO[1])) { @@ -312,7 +313,7 @@ void FastTMXLayer::updateIndexBuffer() } // FastTMXLayer - setup Tiles -void FastTMXLayer::setupTiles() +void TMXLayer::setupTiles() { // Optimization: quick hack that sets the image size on the tileset _tileSet->_imageSize = _texture->getContentSizeInPixels(); @@ -352,7 +353,7 @@ void FastTMXLayer::setupTiles() } -Mat4 FastTMXLayer::tileToNodeTransform() +Mat4 TMXLayer::tileToNodeTransform() { float w = _mapTileSize.width / CC_CONTENT_SCALE_FACTOR(); float h = _mapTileSize.height / CC_CONTENT_SCALE_FACTOR(); @@ -404,7 +405,7 @@ Mat4 FastTMXLayer::tileToNodeTransform() } -void FastTMXLayer::updateTotalQuads() +void TMXLayer::updateTotalQuads() { if(_quadsDirty) { @@ -536,7 +537,7 @@ void FastTMXLayer::updateTotalQuads() } // removing / getting tiles -Sprite* FastTMXLayer::getTileAt(const Vec2& tileCoordinate) +Sprite* TMXLayer::getTileAt(const Vec2& tileCoordinate) { CCASSERT( tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); CCASSERT( _tiles, "TMXLayer: the tiles map has been released"); @@ -576,7 +577,7 @@ Sprite* FastTMXLayer::getTileAt(const Vec2& tileCoordinate) return tile; } -int FastTMXLayer::getTileGIDAt(const Vec2& tileCoordinate, TMXTileFlags* flags/* = nullptr*/) +int TMXLayer::getTileGIDAt(const Vec2& tileCoordinate, TMXTileFlags* flags/* = nullptr*/) { CCASSERT(tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); CCASSERT(_tiles, "TMXLayer: the tiles map has been released"); @@ -602,12 +603,12 @@ int FastTMXLayer::getTileGIDAt(const Vec2& tileCoordinate, TMXTileFlags* flags/* return (tile & kTMXFlippedMask); } -Vec2 FastTMXLayer::getPositionAt(const Vec2& pos) +Vec2 TMXLayer::getPositionAt(const Vec2& pos) { return PointApplyTransform(pos, _tileToNodeTransform); } -int FastTMXLayer::getVertexZForPos(const Vec2& pos) +int TMXLayer::getVertexZForPos(const Vec2& pos) { int ret = 0; int maxVal = 0; @@ -638,7 +639,7 @@ int FastTMXLayer::getVertexZForPos(const Vec2& pos) return ret; } -void FastTMXLayer::removeTileAt(const Vec2& tileCoordinate) +void TMXLayer::removeTileAt(const Vec2& tileCoordinate) { CCASSERT( tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); @@ -661,7 +662,7 @@ void FastTMXLayer::removeTileAt(const Vec2& tileCoordinate) } } -void FastTMXLayer::setFlaggedTileGIDByIndex(int index, int gid) +void TMXLayer::setFlaggedTileGIDByIndex(int index, int gid) { if(gid == _tiles[index]) return; _tiles[index] = gid; @@ -669,7 +670,7 @@ void FastTMXLayer::setFlaggedTileGIDByIndex(int index, int gid) _dirty = true; } -void FastTMXLayer::removeChild(Node* node, bool cleanup) +void TMXLayer::removeChild(Node* node, bool cleanup) { int tag = node->getTag(); auto it = _spriteContainer.find(tag); @@ -680,8 +681,8 @@ void FastTMXLayer::removeChild(Node* node, bool cleanup) Node::removeChild(node, cleanup); } -// FastTMXLayer - Properties -Value FastTMXLayer::getProperty(const std::string& propertyName) const +// TMXLayer - Properties +Value TMXLayer::getProperty(const std::string& propertyName) const { if (_properties.find(propertyName) != _properties.end()) return _properties.at(propertyName); @@ -689,7 +690,7 @@ Value FastTMXLayer::getProperty(const std::string& propertyName) const return Value(); } -void FastTMXLayer::parseInternalProperties() +void TMXLayer::parseInternalProperties() { auto vertexz = getProperty("cc_vertexz"); if (vertexz.isNull()) return; @@ -719,7 +720,7 @@ void FastTMXLayer::parseInternalProperties() } //CCTMXLayer2 - obtaining positions, offset -Vec2 FastTMXLayer::calculateLayerOffset(const Vec2& pos) +Vec2 TMXLayer::calculateLayerOffset(const Vec2& pos) { Vec2 ret = Vec2::ZERO; switch (_layerOrientation) @@ -740,12 +741,12 @@ Vec2 FastTMXLayer::calculateLayerOffset(const Vec2& pos) } // TMXLayer - adding / remove tiles -void FastTMXLayer::setTileGID(int gid, const Vec2& tileCoordinate) +void TMXLayer::setTileGID(int gid, const Vec2& tileCoordinate) { setTileGID(gid, tileCoordinate, (TMXTileFlags)0); } -void FastTMXLayer::setTileGID(int gid, const Vec2& tileCoordinate, TMXTileFlags flags) +void TMXLayer::setTileGID(int gid, const Vec2& tileCoordinate, TMXTileFlags flags) { CCASSERT(tileCoordinate.x < _layerSize.width && tileCoordinate.y < _layerSize.height && tileCoordinate.x >=0 && tileCoordinate.y >=0, "TMXLayer: invalid position"); CCASSERT(_tiles, "TMXLayer: the tiles map has been released"); @@ -796,7 +797,7 @@ void FastTMXLayer::setTileGID(int gid, const Vec2& tileCoordinate, TMXTileFlags } } -void FastTMXLayer::setupTileSprite(Sprite* sprite, Vec2 pos, int gid) +void TMXLayer::setupTileSprite(Sprite* sprite, Vec2 pos, int gid) { sprite->setPosition(getPositionAt(pos)); sprite->setPositionZ((float)getVertexZForPos(pos)); @@ -852,9 +853,11 @@ void FastTMXLayer::setupTileSprite(Sprite* sprite, Vec2 pos, int gid) } } -std::string FastTMXLayer::getDescription() const +std::string TMXLayer::getDescription() const { return StringUtils::format("", _tag, (int)_mapTileSize.width, (int)_mapTileSize.height); } +} //end of namespace experimental + NS_CC_END diff --git a/cocos/2d/CCFastTMXLayer.h b/cocos/2d/CCFastTMXLayer.h index fa377bb0d0..f148eccc19 100644 --- a/cocos/2d/CCFastTMXLayer.h +++ b/cocos/2d/CCFastTMXLayer.h @@ -45,6 +45,8 @@ class Texture2D; class Sprite; struct _ccCArray; +namespace experimental{ + /** * @addtogroup tilemap_parallax_nodes * @{ @@ -76,20 +78,20 @@ http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:tiled_maps @since v3.2 */ -class CC_DLL FastTMXLayer : public Node +class CC_DLL TMXLayer : public Node { public: /** creates a FastTMXLayer with an tileset info, a layer info and a map info */ - static FastTMXLayer * create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); + static TMXLayer * create(TMXTilesetInfo *tilesetInfo, TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); /** * @js ctor */ - FastTMXLayer(); + TMXLayer(); /** * @js NA * @lua NA */ - virtual ~FastTMXLayer(); + virtual ~TMXLayer(); /** returns the tile gid at a given tile coordinate. It also returns the tile flags. */ @@ -256,7 +258,7 @@ public: // end of tilemap_parallax_nodes group /// @} - +} //end of namespace experimental NS_CC_END #endif //__CCTMX_LAYER2_H__ diff --git a/cocos/2d/CCFastTMXTiledMap.cpp b/cocos/2d/CCFastTMXTiledMap.cpp index af81acc6e1..89bec47562 100644 --- a/cocos/2d/CCFastTMXTiledMap.cpp +++ b/cocos/2d/CCFastTMXTiledMap.cpp @@ -34,12 +34,13 @@ THE SOFTWARE. #include "deprecated/CCString.h" NS_CC_BEGIN +namespace experimental { // implementation FastTMXTiledMap -FastTMXTiledMap * FastTMXTiledMap::create(const std::string& tmxFile) +TMXTiledMap * TMXTiledMap::create(const std::string& tmxFile) { - FastTMXTiledMap *ret = new FastTMXTiledMap(); + TMXTiledMap *ret = new TMXTiledMap(); if (ret->initWithTMXFile(tmxFile)) { ret->autorelease(); @@ -49,9 +50,9 @@ FastTMXTiledMap * FastTMXTiledMap::create(const std::string& tmxFile) return nullptr; } -FastTMXTiledMap* FastTMXTiledMap::createWithXML(const std::string& tmxString, const std::string& resourcePath) +TMXTiledMap* TMXTiledMap::createWithXML(const std::string& tmxString, const std::string& resourcePath) { - FastTMXTiledMap *ret = new FastTMXTiledMap(); + TMXTiledMap *ret = new TMXTiledMap(); if (ret->initWithXML(tmxString, resourcePath)) { ret->autorelease(); @@ -61,7 +62,7 @@ FastTMXTiledMap* FastTMXTiledMap::createWithXML(const std::string& tmxString, co return nullptr; } -bool FastTMXTiledMap::initWithTMXFile(const std::string& tmxFile) +bool TMXTiledMap::initWithTMXFile(const std::string& tmxFile) { CCASSERT(tmxFile.size()>0, "FastTMXTiledMap: tmx file should not be empty"); @@ -79,7 +80,7 @@ bool FastTMXTiledMap::initWithTMXFile(const std::string& tmxFile) return true; } -bool FastTMXTiledMap::initWithXML(const std::string& tmxString, const std::string& resourcePath) +bool TMXTiledMap::initWithXML(const std::string& tmxString, const std::string& resourcePath) { setContentSize(Size::ZERO); @@ -91,21 +92,21 @@ bool FastTMXTiledMap::initWithXML(const std::string& tmxString, const std::strin return true; } -FastTMXTiledMap::FastTMXTiledMap() +TMXTiledMap::TMXTiledMap() :_mapSize(Size::ZERO) ,_tileSize(Size::ZERO) { } -FastTMXTiledMap::~FastTMXTiledMap() +TMXTiledMap::~TMXTiledMap() { } // private -FastTMXLayer * FastTMXTiledMap::parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) +TMXLayer * TMXTiledMap::parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) { TMXTilesetInfo *tileset = tilesetForLayer(layerInfo, mapInfo); - FastTMXLayer *layer = FastTMXLayer::create(tileset, layerInfo, mapInfo); + TMXLayer *layer = TMXLayer::create(tileset, layerInfo, mapInfo); // tell the layerinfo to release the ownership of the tiles map. layerInfo->_ownTiles = false; @@ -114,7 +115,7 @@ FastTMXLayer * FastTMXTiledMap::parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo * return layer; } -TMXTilesetInfo * FastTMXTiledMap::tilesetForLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) +TMXTilesetInfo * TMXTiledMap::tilesetForLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo) { Size size = layerInfo->_layerSize; auto& tilesets = mapInfo->getTilesets(); @@ -155,7 +156,7 @@ TMXTilesetInfo * FastTMXTiledMap::tilesetForLayer(TMXLayerInfo *layerInfo, TMXMa return nullptr; } -void FastTMXTiledMap::buildWithMapInfo(TMXMapInfo* mapInfo) +void TMXTiledMap::buildWithMapInfo(TMXMapInfo* mapInfo) { _mapSize = mapInfo->getMapSize(); _tileSize = mapInfo->getTileSize(); @@ -173,7 +174,7 @@ void FastTMXTiledMap::buildWithMapInfo(TMXMapInfo* mapInfo) for(const auto &layerInfo : layers) { if (layerInfo->_visible) { - FastTMXLayer *child = parseLayer(layerInfo, mapInfo); + TMXLayer *child = parseLayer(layerInfo, mapInfo); addChild(child, idx, idx); // update content size with the max size @@ -189,13 +190,13 @@ void FastTMXTiledMap::buildWithMapInfo(TMXMapInfo* mapInfo) } // public -FastTMXLayer * FastTMXTiledMap::getLayer(const std::string& layerName) const +TMXLayer * TMXTiledMap::getLayer(const std::string& layerName) const { CCASSERT(layerName.size() > 0, "Invalid layer name!"); for (auto& child : _children) { - FastTMXLayer* layer = dynamic_cast(child); + TMXLayer* layer = dynamic_cast(child); if(layer) { if(layerName.compare( layer->getLayerName()) == 0) @@ -209,7 +210,7 @@ FastTMXLayer * FastTMXTiledMap::getLayer(const std::string& layerName) const return nullptr; } -TMXObjectGroup * FastTMXTiledMap::getObjectGroup(const std::string& groupName) const +TMXObjectGroup * TMXTiledMap::getObjectGroup(const std::string& groupName) const { CCASSERT(groupName.size() > 0, "Invalid group name!"); @@ -230,7 +231,7 @@ TMXObjectGroup * FastTMXTiledMap::getObjectGroup(const std::string& groupName) c return nullptr; } -Value FastTMXTiledMap::getProperty(const std::string& propertyName) const +Value TMXTiledMap::getProperty(const std::string& propertyName) const { if (_properties.find(propertyName) != _properties.end()) return _properties.at(propertyName); @@ -238,7 +239,7 @@ Value FastTMXTiledMap::getProperty(const std::string& propertyName) const return Value(); } -Value FastTMXTiledMap::getPropertiesForGID(int GID) const +Value TMXTiledMap::getPropertiesForGID(int GID) const { if (_tileProperties.find(GID) != _tileProperties.end()) return _tileProperties.at(GID); @@ -246,11 +247,12 @@ Value FastTMXTiledMap::getPropertiesForGID(int GID) const return Value(); } -std::string FastTMXTiledMap::getDescription() const +std::string TMXTiledMap::getDescription() const { return StringUtils::format("(_children.size())); } +} //end of namespace experimental NS_CC_END diff --git a/cocos/2d/CCFastTMXTiledMap.h b/cocos/2d/CCFastTMXTiledMap.h index 9dfc098552..07a544a775 100644 --- a/cocos/2d/CCFastTMXTiledMap.h +++ b/cocos/2d/CCFastTMXTiledMap.h @@ -33,11 +33,14 @@ THE SOFTWARE. NS_CC_BEGIN class TMXObjectGroup; -class FastTMXLayer; class TMXLayerInfo; class TMXTilesetInfo; class TMXMapInfo; +namespace experimental { + +class TMXLayer; + /** @brief FastTMXTiledMap knows how to parse and render a TMX map. It adds support for the TMX tiled map format used by http://www.mapeditor.org @@ -89,17 +92,17 @@ object->getProperty(name_of_the_property); @since v3.2 */ -class CC_DLL FastTMXTiledMap : public Node +class CC_DLL TMXTiledMap : public Node { public: /** creates a TMX Tiled Map with a TMX file.*/ - static FastTMXTiledMap* create(const std::string& tmxFile); + static TMXTiledMap* create(const std::string& tmxFile); /** initializes a TMX Tiled Map with a TMX formatted XML string and a path to TMX resources */ - static FastTMXTiledMap* createWithXML(const std::string& tmxString, const std::string& resourcePath); + static TMXTiledMap* createWithXML(const std::string& tmxString, const std::string& resourcePath); /** return the FastTMXLayer for the specific layer */ - FastTMXLayer* getLayer(const std::string& layerName) const; + TMXLayer* getLayer(const std::string& layerName) const; /** return the TMXObjectGroup for the specific group */ TMXObjectGroup* getObjectGroup(const std::string& groupName) const; @@ -141,12 +144,12 @@ protected: /** * @js ctor */ - FastTMXTiledMap(); + TMXTiledMap(); /** * @js NA * @lua NA */ - virtual ~FastTMXTiledMap(); + virtual ~TMXTiledMap(); /** initializes a TMX Tiled Map with a TMX file */ bool initWithTMXFile(const std::string& tmxFile); @@ -154,7 +157,7 @@ protected: /** initializes a TMX Tiled Map with a TMX formatted XML string and a path to TMX resources */ bool initWithXML(const std::string& tmxString, const std::string& resourcePath); - FastTMXLayer * parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); + TMXLayer * parseLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); TMXTilesetInfo * tilesetForLayer(TMXLayerInfo *layerInfo, TMXMapInfo *mapInfo); void buildWithMapInfo(TMXMapInfo* mapInfo); @@ -173,12 +176,14 @@ protected: ValueMapIntKey _tileProperties; private: - CC_DISALLOW_COPY_AND_ASSIGN(FastTMXTiledMap); + CC_DISALLOW_COPY_AND_ASSIGN(TMXTiledMap); }; // end of tilemap_parallax_nodes group /// @} + +} //end of namespace experimental NS_CC_END diff --git a/cocos/2d/CCFontAtlasCache.cpp b/cocos/2d/CCFontAtlasCache.cpp index bad6c9f733..f088da6319 100644 --- a/cocos/2d/CCFontAtlasCache.cpp +++ b/cocos/2d/CCFontAtlasCache.cpp @@ -22,11 +22,11 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ - -#include - #include "2d/CCFontAtlasCache.h" +#include +#include + #include "2d/CCFontFNT.h" #include "2d/CCFontFreeType.h" #include "CCFontCharMap.h" diff --git a/cocos/2d/CCFontAtlasCache.h b/cocos/2d/CCFontAtlasCache.h index 800948ba44..4e2c17c687 100644 --- a/cocos/2d/CCFontAtlasCache.h +++ b/cocos/2d/CCFontAtlasCache.h @@ -26,7 +26,6 @@ #ifndef _CCFontAtlasCache_h_ #define _CCFontAtlasCache_h_ -#include #include #include "2d/CCFontAtlas.h" diff --git a/cocos/2d/CCLabelTextFormatter.cpp b/cocos/2d/CCLabelTextFormatter.cpp index a9658489dd..c1c0c8d386 100644 --- a/cocos/2d/CCLabelTextFormatter.cpp +++ b/cocos/2d/CCLabelTextFormatter.cpp @@ -186,7 +186,7 @@ bool LabelTextFormatter::alignText(Label *theLabel) int i = 0; int lineNumber = 0; - int strLen = static_cast(theLabel->_currentUTF16String.length()); + int strLen = theLabel->_limitShowCount; std::vector lastLine; auto strWhole = theLabel->_currentUTF16String; diff --git a/cocos/2d/CCNode.h b/cocos/2d/CCNode.h index 7b26969cea..e0b881e464 100644 --- a/cocos/2d/CCNode.h +++ b/cocos/2d/CCNode.h @@ -712,6 +712,15 @@ public: * @since v3.2 */ virtual Node* getChildByName(const std::string& name) const; + /** + * Gets a child from the container with its name that can be cast to Type T + * + * @param name An identifier to find the child node. + * + * @return a Node with the given name that can be cast to Type T + */ + template + inline T getChildByName(const std::string& name) const { return static_cast(getChildByName(name)); } /** Search the children of the receiving node to perform processing for nodes which share a name. * * @param name The name to search for, supports c++11 regular expression. diff --git a/cocos/2d/CCRenderTexture.cpp b/cocos/2d/CCRenderTexture.cpp index 7738341537..b5f16595b6 100644 --- a/cocos/2d/CCRenderTexture.cpp +++ b/cocos/2d/CCRenderTexture.cpp @@ -94,6 +94,9 @@ RenderTexture::~RenderTexture() void RenderTexture::listenToBackground(EventCustom *event) { + // We have not found a way to dispatch the enter background message before the texture data are destroyed. + // So we disable this pair of message handler at present. +#if 0 #if CC_ENABLE_CACHE_TEXTURE_DATA CC_SAFE_DELETE(_UITextureImage); @@ -118,10 +121,12 @@ void RenderTexture::listenToBackground(EventCustom *event) glDeleteFramebuffers(1, &_FBO); _FBO = 0; #endif +#endif } void RenderTexture::listenToForeground(EventCustom *event) { +#if 0 #if CC_ENABLE_CACHE_TEXTURE_DATA // -- regenerate frame buffer object and attach the texture glGetIntegerv(GL_FRAMEBUFFER_BINDING, &_oldFBO); @@ -139,6 +144,7 @@ void RenderTexture::listenToForeground(EventCustom *event) glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, _texture->getName(), 0); glBindFramebuffer(GL_FRAMEBUFFER, _oldFBO); #endif +#endif } RenderTexture * RenderTexture::create(int w, int h, Texture2D::PixelFormat eFormat) @@ -564,6 +570,14 @@ void RenderTexture::onBegin() Mat4::createOrthographicOffCenter((float)-1.0 / widthRatio, (float)1.0 / widthRatio, (float)-1.0 / heightRatio, (float)1.0 / heightRatio, -1, 1, &orthoMatrix); director->multiplyMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_PROJECTION, orthoMatrix); } + else + { +#if CC_TARGET_PLATFORM == CC_PLATFORM_WP8 + Mat4 modifiedProjection = director->getMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_PROJECTION); + modifiedProjection = CCEGLView::sharedOpenGLView()->getReverseOrientationMatrix() * modifiedProjection; + director->loadMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_PROJECTION, modifiedProjection); +#endif + } //calculate viewport { diff --git a/cocos/2d/CCTransition.h b/cocos/2d/CCTransition.h index a065dfc419..e86aa06394 100644 --- a/cocos/2d/CCTransition.h +++ b/cocos/2d/CCTransition.h @@ -153,7 +153,7 @@ public: // virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionRotoZoom(); virtual ~TransitionRotoZoom(); @@ -175,7 +175,7 @@ public: // virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionJumpZoom(); virtual ~TransitionJumpZoom(); @@ -201,10 +201,11 @@ public: // virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionMoveInL(); virtual ~TransitionMoveInL(); +protected: /** initializes the scenes */ virtual void initScenes(); @@ -220,10 +221,11 @@ class CC_DLL TransitionMoveInR : public TransitionMoveInL public: static TransitionMoveInR* create(float t, Scene* scene); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionMoveInR(); virtual ~TransitionMoveInR(); +protected: virtual void initScenes(); private: @@ -238,10 +240,11 @@ class CC_DLL TransitionMoveInT : public TransitionMoveInL public: static TransitionMoveInT* create(float t, Scene* scene); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionMoveInT(); virtual ~TransitionMoveInT(); +protected: virtual void initScenes(); private: @@ -256,10 +259,11 @@ class CC_DLL TransitionMoveInB : public TransitionMoveInL public: static TransitionMoveInB* create(float t, Scene* scene); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionMoveInB(); virtual ~TransitionMoveInB(); +protected: virtual void initScenes(); private: @@ -284,10 +288,11 @@ public: // virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionSlideInL(); virtual ~TransitionSlideInL(); +protected: /** initializes the scenes */ virtual void initScenes(void); @@ -308,10 +313,11 @@ public: /** returns the action that will be performed by the incoming and outgoing scene */ virtual ActionInterval* action(void); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionSlideInR(); virtual ~TransitionSlideInR(); +protected: /** initializes the scenes */ virtual void initScenes(void); @@ -332,10 +338,11 @@ public: /** returns the action that will be performed by the incoming and outgoing scene */ virtual ActionInterval* action(void); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionSlideInB(); virtual ~TransitionSlideInB(); +protected: /** initializes the scenes */ virtual void initScenes(); @@ -356,10 +363,11 @@ public: /** returns the action that will be performed by the incoming and outgoing scene */ virtual ActionInterval* action(void); -protected: +CC_CONSTRUCTOR_ACCESS: TransitionSlideInT(); virtual ~TransitionSlideInT(); +protected: /** initializes the scenes */ virtual void initScenes(void); @@ -387,7 +395,7 @@ public: virtual void onEnter() override; virtual ActionInterval* easeActionWithAction(ActionInterval * action) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionShrinkGrow(); virtual ~TransitionShrinkGrow(); @@ -414,7 +422,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFlipX(); virtual ~TransitionFlipX(); @@ -441,7 +449,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFlipY(); virtual ~TransitionFlipY(); @@ -468,7 +476,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFlipAngular(); virtual ~TransitionFlipAngular(); @@ -495,7 +503,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionZoomFlipX(); virtual ~TransitionZoomFlipX(); @@ -522,7 +530,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionZoomFlipY(); virtual ~TransitionZoomFlipY(); @@ -549,7 +557,7 @@ public: */ virtual void onEnter() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionZoomFlipAngular(); virtual ~TransitionZoomFlipAngular(); @@ -625,7 +633,7 @@ public : */ virtual void onExit() override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionCrossFade(); virtual ~TransitionCrossFade(); @@ -653,10 +661,11 @@ public : virtual ActionInterval * easeActionWithAction(ActionInterval * action) override; virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionTurnOffTiles(); virtual ~TransitionTurnOffTiles(); +protected: virtual void sceneOrder() override; NodeGrid* _outSceneProxy; @@ -685,9 +694,12 @@ public: virtual ActionInterval * easeActionWithAction(ActionInterval * action) override; virtual void onExit() override; virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override; -protected: + +CC_CONSTRUCTOR_ACCESS: TransitionSplitCols(); virtual ~TransitionSplitCols(); + +protected: void switchTargetToInscene(); NodeGrid* _gridProxy; private: @@ -707,7 +719,7 @@ public: // virtual ActionInterval* action(void) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionSplitRows(); virtual ~TransitionSplitRows(); @@ -736,10 +748,12 @@ public: virtual ActionInterval* easeActionWithAction(ActionInterval * action) override; virtual void onExit() override; virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override; -protected: + +CC_CONSTRUCTOR_ACCESS: TransitionFadeTR(); virtual ~TransitionFadeTR(); +protected: virtual void sceneOrder(); NodeGrid* _outSceneProxy; @@ -761,7 +775,7 @@ public: // virtual ActionInterval* actionWithSize(const Size& size) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFadeBL(); virtual ~TransitionFadeBL(); @@ -782,7 +796,7 @@ public: // virtual ActionInterval* actionWithSize(const Size& size) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFadeUp(); virtual ~TransitionFadeUp(); @@ -803,7 +817,7 @@ public: // virtual ActionInterval* actionWithSize(const Size& size) override; -protected: +CC_CONSTRUCTOR_ACCESS: TransitionFadeDown(); virtual ~TransitionFadeDown(); diff --git a/cocos/2d/CCTransitionPageTurn.h b/cocos/2d/CCTransitionPageTurn.h index a34fc19946..3291566d33 100644 --- a/cocos/2d/CCTransitionPageTurn.h +++ b/cocos/2d/CCTransitionPageTurn.h @@ -59,15 +59,6 @@ public: * scene is being turned from left over the outgoing scene. */ static TransitionPageTurn* create(float t,Scene* scene,bool backwards); - /** - * @js ctor - */ - TransitionPageTurn(); - /** - * @js NA - * @lua NA - */ - virtual ~TransitionPageTurn(); // // Overrides @@ -89,6 +80,17 @@ public: virtual void onEnter() override; virtual void onExit() override; +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionPageTurn(); + /** + * @js NA + * @lua NA + */ + virtual ~TransitionPageTurn(); + protected: virtual void sceneOrder() override; diff --git a/cocos/2d/CCTransitionProgress.h b/cocos/2d/CCTransitionProgress.h index 0f5f01a856..d4cfbe8deb 100644 --- a/cocos/2d/CCTransitionProgress.h +++ b/cocos/2d/CCTransitionProgress.h @@ -44,14 +44,16 @@ class CC_DLL TransitionProgress : public TransitionScene public: static TransitionProgress* create(float t, Scene* scene); - TransitionProgress(); - // // Overrides // virtual void onEnter() override; virtual void onExit() override; +CC_CONSTRUCTOR_ACCESS: + TransitionProgress(); + virtual ~TransitionProgress(){} + protected: virtual void sceneOrder() override; @@ -74,6 +76,13 @@ class CC_DLL TransitionProgressRadialCCW : public TransitionProgress public: static TransitionProgressRadialCCW* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressRadialCCW(){} + virtual ~TransitionProgressRadialCCW(){} + protected: // // Overrides @@ -91,6 +100,13 @@ class CC_DLL TransitionProgressRadialCW : public TransitionProgress public: static TransitionProgressRadialCW* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressRadialCW(){} + virtual ~TransitionProgressRadialCW(){} + protected: // // Overrides @@ -107,6 +123,13 @@ class CC_DLL TransitionProgressHorizontal : public TransitionProgress public: static TransitionProgressHorizontal* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressHorizontal(){} + virtual ~TransitionProgressHorizontal(){} + protected: // // Overrides @@ -119,6 +142,13 @@ class CC_DLL TransitionProgressVertical : public TransitionProgress public: static TransitionProgressVertical* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressVertical(){} + virtual ~TransitionProgressVertical(){} + protected: // // Overrides @@ -131,6 +161,13 @@ class CC_DLL TransitionProgressInOut : public TransitionProgress public: static TransitionProgressInOut* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressInOut(){} + virtual ~TransitionProgressInOut(){} + protected: // // Overrides @@ -145,6 +182,13 @@ class CC_DLL TransitionProgressOutIn : public TransitionProgress public: static TransitionProgressOutIn* create(float t, Scene* scene); +CC_CONSTRUCTOR_ACCESS: + /** + * @js ctor + */ + TransitionProgressOutIn(){} + virtual ~TransitionProgressOutIn(){} + protected: // // Overrides diff --git a/cocos/3d/CCObjLoader.cpp b/cocos/3d/CCObjLoader.cpp index 4c5da0d89e..1ad3e446eb 100644 --- a/cocos/3d/CCObjLoader.cpp +++ b/cocos/3d/CCObjLoader.cpp @@ -28,6 +28,7 @@ #include "CCObjLoader.h" #include "platform/CCFileUtils.h" +#include "base/ccUtils.h" NS_CC_BEGIN @@ -102,7 +103,7 @@ static inline int parseInt(const char*& token) static inline float parseFloat(const char*& token) { token += strspn(token, " \t"); - float f = (float)atof(token); + float f = (float)utils::atof(token); token += strcspn(token, " \t\r"); return f; } diff --git a/cocos/Android.mk b/cocos/Android.mk index 219098f275..92ff9a8b65 100644 --- a/cocos/Android.mk +++ b/cocos/Android.mk @@ -223,9 +223,9 @@ LOCAL_WHOLE_STATIC_LIBRARIES += cocos2dxandroid_static # define the macro to compile through support/zip_support/ioapi.c LOCAL_CFLAGS := -DUSE_FILE32API -LOCAL_CPPFLAGS := -Wno-deprecated-declarations +LOCAL_CPPFLAGS := -Wno-deprecated-declarations -Wno-extern-c-compat LOCAL_EXPORT_CFLAGS := -DUSE_FILE32API -LOCAL_EXPORT_CPPFLAGS := -Wno-deprecated-declarations +LOCAL_EXPORT_CPPFLAGS := -Wno-deprecated-declarations -Wno-extern-c-compat include $(BUILD_STATIC_LIBRARY) diff --git a/cocos/base/CCConsole.cpp b/cocos/base/CCConsole.cpp index e06185654c..8e149e76c1 100644 --- a/cocos/base/CCConsole.cpp +++ b/cocos/base/CCConsole.cpp @@ -63,6 +63,7 @@ #include "renderer/CCTextureCache.h" #include "CCGLView.h" #include "base/base64.h" +#include "base/ccUtils.h" NS_CC_BEGIN extern const char* cocos2dVersion(void); @@ -660,8 +661,8 @@ void Console::commandTouch(int fd, const std::string& args) if((argv.size() == 3) && (isFloat(argv[1]) && isFloat(argv[2]))) { - float x = std::atof(argv[1].c_str()); - float y = std::atof(argv[2].c_str()); + float x = utils::atof(argv[1].c_str()); + float y = utils::atof(argv[2].c_str()); srand ((unsigned)time(nullptr)); _touchId = rand(); @@ -686,10 +687,10 @@ void Console::commandTouch(int fd, const std::string& args) && (isFloat(argv[3])) && (isFloat(argv[4]))) { - float x1 = std::atof(argv[1].c_str()); - float y1 = std::atof(argv[2].c_str()); - float x2 = std::atof(argv[3].c_str()); - float y2 = std::atof(argv[4].c_str()); + float x1 = utils::atof(argv[1].c_str()); + float y1 = utils::atof(argv[2].c_str()); + float x2 = utils::atof(argv[3].c_str()); + float y2 = utils::atof(argv[4].c_str()); srand ((unsigned)time(nullptr)); _touchId = rand(); diff --git a/cocos/base/CCController-iOS.mm b/cocos/base/CCController-iOS.mm index e53f85bccf..2349224900 100644 --- a/cocos/base/CCController-iOS.mm +++ b/cocos/base/CCController-iOS.mm @@ -196,7 +196,7 @@ void Controller::registerListeners() }; _impl->_gcController.extendedGamepad.leftThumbstick.yAxis.valueChangedHandler = ^(GCControllerAxisInput *axis, float value){ - onAxisEvent(Key::JOYSTICK_LEFT_Y, value, axis.isAnalog); + onAxisEvent(Key::JOYSTICK_LEFT_Y, -value, axis.isAnalog); }; _impl->_gcController.extendedGamepad.rightThumbstick.xAxis.valueChangedHandler = ^(GCControllerAxisInput *axis, float value){ @@ -204,7 +204,7 @@ void Controller::registerListeners() }; _impl->_gcController.extendedGamepad.rightThumbstick.yAxis.valueChangedHandler = ^(GCControllerAxisInput *axis, float value){ - onAxisEvent(Key::JOYSTICK_RIGHT_Y, value, axis.isAnalog); + onAxisEvent(Key::JOYSTICK_RIGHT_Y, -value, axis.isAnalog); }; _impl->_gcController.extendedGamepad.valueChangedHandler = ^(GCExtendedGamepad *gamepad, GCControllerElement *element){ diff --git a/cocos/base/CCData.cpp b/cocos/base/CCData.cpp index fda70d44b7..3092202337 100644 --- a/cocos/base/CCData.cpp +++ b/cocos/base/CCData.cpp @@ -100,7 +100,7 @@ ssize_t Data::getSize() const return _size; } -void Data::copy(unsigned char* bytes, const ssize_t size) +void Data::copy(const unsigned char* bytes, const ssize_t size) { clear(); diff --git a/cocos/base/CCData.h b/cocos/base/CCData.h index 8a9ec870e2..7532093bae 100644 --- a/cocos/base/CCData.h +++ b/cocos/base/CCData.h @@ -63,7 +63,7 @@ public: * Developer should free the pointer after invoking this method. * @see Data::fastSet */ - void copy(unsigned char* bytes, const ssize_t size); + void copy(const unsigned char* bytes, const ssize_t size); /** Fast set the buffer pointer and its size. Please use it carefully. * @param bytes The buffer pointer, note that it have to be allocated by 'malloc' or 'calloc', diff --git a/cocos/base/CCNS.cpp b/cocos/base/CCNS.cpp index 452e3a7458..0073a740f4 100644 --- a/cocos/base/CCNS.cpp +++ b/cocos/base/CCNS.cpp @@ -28,6 +28,8 @@ THE SOFTWARE. #include #include +#include "base/ccUtils.h" + using namespace std; NS_CC_BEGIN @@ -133,10 +135,10 @@ Rect RectFromString(const std::string& str) strArray sizeInfo; CC_BREAK_IF(!splitWithForm(sizeStr.c_str(), sizeInfo)); - float x = (float) atof(pointInfo[0].c_str()); - float y = (float) atof(pointInfo[1].c_str()); - float width = (float) atof(sizeInfo[0].c_str()); - float height = (float) atof(sizeInfo[1].c_str()); + float x = (float) utils::atof(pointInfo[0].c_str()); + float y = (float) utils::atof(pointInfo[1].c_str()); + float width = (float) utils::atof(sizeInfo[0].c_str()); + float height = (float) utils::atof(sizeInfo[1].c_str()); result = Rect(x, y, width, height); } while (0); @@ -153,8 +155,8 @@ Vec2 PointFromString(const std::string& str) strArray strs; CC_BREAK_IF(!splitWithForm(str, strs)); - float x = (float) atof(strs[0].c_str()); - float y = (float) atof(strs[1].c_str()); + float x = (float) utils::atof(strs[0].c_str()); + float y = (float) utils::atof(strs[1].c_str()); ret = Vec2(x, y); } while (0); @@ -171,8 +173,8 @@ Size SizeFromString(const std::string& pszContent) strArray strs; CC_BREAK_IF(!splitWithForm(pszContent, strs)); - float width = (float) atof(strs[0].c_str()); - float height = (float) atof(strs[1].c_str()); + float width = (float) utils::atof(strs[0].c_str()); + float height = (float) utils::atof(strs[1].c_str()); ret = Size(width, height); } while (0); diff --git a/cocos/base/CCUserDefault.cpp b/cocos/base/CCUserDefault.cpp index 2c19feb45c..ef52f03c0d 100644 --- a/cocos/base/CCUserDefault.cpp +++ b/cocos/base/CCUserDefault.cpp @@ -27,6 +27,7 @@ THE SOFTWARE. #include "platform/CCFileUtils.h" #include "tinyxml2.h" #include "base/base64.h" +#include "base/ccUtils.h" #if (CC_TARGET_PLATFORM != CC_PLATFORM_IOS && CC_TARGET_PLATFORM != CC_PLATFORM_MAC && CC_TARGET_PLATFORM != CC_PLATFORM_ANDROID) @@ -250,7 +251,7 @@ double UserDefault::getDoubleForKey(const char* pKey, double defaultValue) if (value) { - ret = atof(value); + ret = utils::atof(value); } if (doc) delete doc; diff --git a/cocos/base/CCUserDefaultAndroid.cpp b/cocos/base/CCUserDefaultAndroid.cpp index 63ee9182db..c6c3a166d1 100644 --- a/cocos/base/CCUserDefaultAndroid.cpp +++ b/cocos/base/CCUserDefaultAndroid.cpp @@ -24,6 +24,7 @@ THE SOFTWARE. ****************************************************************************/ #include "base/CCUserDefault.h" #include "base/CCPlatformConfig.h" +#include "base/ccUtils.h" #include "platform/CCCommon.h" #include "base/base64.h" @@ -243,7 +244,7 @@ float UserDefault::getFloatForKey(const char* pKey, float defaultValue) { if (node->FirstChild()) { - float ret = atof((const char*)node->FirstChild()->Value()); + float ret = utils::atof((const char*)node->FirstChild()->Value()); // set value in NSUserDefaults setFloatForKey(pKey, ret); @@ -279,7 +280,7 @@ double UserDefault::getDoubleForKey(const char* pKey, double defaultValue) { if (node->FirstChild()) { - double ret = atof((const char*)node->FirstChild()->Value()); + double ret = utils::atof((const char*)node->FirstChild()->Value()); // set value in NSUserDefaults setDoubleForKey(pKey, ret); diff --git a/cocos/base/CCValue.cpp b/cocos/base/CCValue.cpp index 00b4904810..d5e0e06a4e 100644 --- a/cocos/base/CCValue.cpp +++ b/cocos/base/CCValue.cpp @@ -25,6 +25,7 @@ #include "base/CCValue.h" #include #include +#include "base/ccUtils.h" NS_CC_BEGIN @@ -504,7 +505,7 @@ float Value::asFloat() const if (_type == Type::STRING) { - return atof(_field.strVal->c_str()); + return utils::atof(_field.strVal->c_str()); } if (_type == Type::INTEGER) @@ -540,7 +541,7 @@ double Value::asDouble() const if (_type == Type::STRING) { - return static_cast(atof(_field.strVal->c_str())); + return static_cast(utils::atof(_field.strVal->c_str())); } if (_type == Type::INTEGER) diff --git a/cocos/base/ccUtils.cpp b/cocos/base/ccUtils.cpp index 5a025b25ec..36cafb1c20 100644 --- a/cocos/base/ccUtils.cpp +++ b/cocos/base/ccUtils.cpp @@ -24,6 +24,9 @@ THE SOFTWARE. ****************************************************************************/ #include "base/ccUtils.h" + +#include + #include "base/CCDirector.h" #include "renderer/CCCustomCommand.h" #include "renderer/CCRenderer.h" @@ -160,6 +163,27 @@ std::vector findChildren(const Node &node, const std::string &name) return vec; } + +#define MAX_ITOA_BUFFER_SIZE 256 +double atof(const char* str) +{ + if (str == nullptr) + { + return 0.0; + } + + char buf[MAX_ITOA_BUFFER_SIZE]; + strncpy(buf, str, MAX_ITOA_BUFFER_SIZE); + + // strip string, only remain 7 numbers after '.' + char* dot = strchr(buf, '.'); + if (dot != nullptr && dot - buf + 8 < MAX_ITOA_BUFFER_SIZE) + { + dot[8] = '\0'; + } + + return ::atof(buf); +} } diff --git a/cocos/base/ccUtils.h b/cocos/base/ccUtils.h index 939d71b854..1fba5b1b40 100644 --- a/cocos/base/ccUtils.h +++ b/cocos/base/ccUtils.h @@ -73,6 +73,11 @@ namespace utils * @since v3.2 */ std::vector findChildren(const Node &node, const std::string &name); + + /** Same to ::atof, but strip the string, remain 7 numbers after '.' before call atof。 + * Why we need this? Because in android c++_static, atof ( and std::atof ) is unsupported for numbers have long decimal part and contain several numbers can approximate to 1 ( like 90.099998474121094 ), it will return inf. this function is used to fix this bug. + */ + double atof(const char* str); } NS_CC_END diff --git a/cocos/cocos2d.cpp b/cocos/cocos2d.cpp index 34b671cd8e..d96b55ce20 100644 --- a/cocos/cocos2d.cpp +++ b/cocos/cocos2d.cpp @@ -31,7 +31,7 @@ NS_CC_BEGIN const char* cocos2dVersion() { - return "cocos2d-x 3.2beta0"; + return "cocos2d-x 3.2"; } NS_CC_END diff --git a/cocos/deprecated/CCString.cpp b/cocos/deprecated/CCString.cpp index 06bf28d7de..38d153b95f 100644 --- a/cocos/deprecated/CCString.cpp +++ b/cocos/deprecated/CCString.cpp @@ -29,6 +29,7 @@ Copyright (c) 2013-2014 Chukong Technologies #include #include #include "CCArray.h" +#include "base/ccUtils.h" NS_CC_BEGIN @@ -118,7 +119,7 @@ float __String::floatValue() const { return 0.0f; } - return (float)atof(_string.c_str()); + return (float)utils::atof(_string.c_str()); } double __String::doubleValue() const @@ -127,7 +128,7 @@ double __String::doubleValue() const { return 0.0; } - return atof(_string.c_str()); + return utils::atof(_string.c_str()); } bool __String::boolValue() const diff --git a/cocos/editor-support/cocostudio/ActionTimeline/CCTimeLine.cpp b/cocos/editor-support/cocostudio/ActionTimeline/CCTimeLine.cpp index c9f04cc985..10f09ceb5d 100644 --- a/cocos/editor-support/cocostudio/ActionTimeline/CCTimeLine.cpp +++ b/cocos/editor-support/cocostudio/ActionTimeline/CCTimeLine.cpp @@ -157,8 +157,8 @@ void Timeline::binarySearchKeyFrame(int frameIndex) break; } - int target = -1; - int low=0,high=length-1,mid; + long target = -1; + long low=0,high=length-1,mid=0; while(low<=high){ mid=(low+high)/2; if(frameIndex >= _frames.at(mid)->getFrameIndex() && frameIndex < _frames.at(mid+1)->getFrameIndex()) diff --git a/cocos/editor-support/cocostudio/CCActionManagerEx.cpp b/cocos/editor-support/cocostudio/CCActionManagerEx.cpp index cf650bc7e2..76a15e0bba 100644 --- a/cocos/editor-support/cocostudio/CCActionManagerEx.cpp +++ b/cocos/editor-support/cocostudio/CCActionManagerEx.cpp @@ -42,7 +42,12 @@ ActionManagerEx* ActionManagerEx::getInstance() void ActionManagerEx::destroyInstance() { - CC_SAFE_DELETE(sharedActionManager); + if(sharedActionManager != nullptr) + { + sharedActionManager->releaseActions(); + CC_SAFE_DELETE(sharedActionManager); + } + } ActionManagerEx::ActionManagerEx() @@ -154,6 +159,13 @@ void ActionManagerEx::releaseActions() for (iter = _actionDic.begin(); iter != _actionDic.end(); iter++) { cocos2d::Vector objList = iter->second; + int listCount = objList.size(); + for (int i = 0; i < listCount; i++) { + ActionObject* action = objList.at(i); + if (action != nullptr) { + action->stop(); + } + } objList.clear(); } diff --git a/cocos/editor-support/cocostudio/CCActionNode.cpp b/cocos/editor-support/cocostudio/CCActionNode.cpp index f0c6ee782e..116eeb1592 100644 --- a/cocos/editor-support/cocostudio/CCActionNode.cpp +++ b/cocos/editor-support/cocostudio/CCActionNode.cpp @@ -28,6 +28,7 @@ THE SOFTWARE. #include "ui/UIWidget.h" #include "ui/UIHelper.h" #include "cocostudio/CocoLoader.h" +#include "base/ccUtils.h" using namespace cocos2d; using namespace ui; @@ -184,7 +185,7 @@ void ActionNode::initWithDictionary(const rapidjson::Value& dic, Ref* root) } float ActionNode::valueToFloat(const std::string& value) { - return atof(value.c_str()); + return utils::atof(value.c_str()); } void ActionNode::initWithBinary(CocoLoader *cocoLoader, diff --git a/cocos/editor-support/cocostudio/CCActionObject.cpp b/cocos/editor-support/cocostudio/CCActionObject.cpp index b064cb2fc2..67d6c25fb7 100644 --- a/cocos/editor-support/cocostudio/CCActionObject.cpp +++ b/cocos/editor-support/cocostudio/CCActionObject.cpp @@ -29,6 +29,7 @@ THE SOFTWARE. #include "base/CCDirector.h" #include "base/CCScheduler.h" #include "2d/CCActionInstant.h" +#include "base/ccUtils.h" using namespace cocos2d; @@ -189,7 +190,7 @@ bool ActionObject::valueToBool(const std::string& value) } float ActionObject::valueToFloat(const std::string& value) { - return atof(value.c_str()); + return utils::atof(value.c_str()); } void ActionObject::addActionNode(ActionNode* node) diff --git a/cocos/editor-support/cocostudio/CCDataReaderHelper.cpp b/cocos/editor-support/cocostudio/CCDataReaderHelper.cpp index 88be54e2cb..22b076371c 100644 --- a/cocos/editor-support/cocostudio/CCDataReaderHelper.cpp +++ b/cocos/editor-support/cocostudio/CCDataReaderHelper.cpp @@ -25,6 +25,7 @@ THE SOFTWARE. #include "platform/CCFileUtils.h" #include "base/CCDirector.h" #include "base/CCScheduler.h" +#include "base/ccUtils.h" #include "tinyxml2.h" @@ -1763,7 +1764,7 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, if (key.compare(CONTENT_SCALE) == 0) { std::string value = tpChildArray[i].GetValue(&tCocoLoader); - dataInfo->contentScale = atof(value.c_str()); + dataInfo->contentScale = utils::atof(value.c_str()); } else if ( 0 == key.compare(ARMATURE_DATA)) { @@ -1879,7 +1880,7 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, armatureData->name = name; } - float version = atof(pAramtureDataArray[1].GetValue(cocoLoader)); + float version = utils::atof(pAramtureDataArray[1].GetValue(cocoLoader)); dataInfo->cocoStudioVersion = armatureData->dataVersion = version; //DICTOOL->getFloatValue_json(json, VERSION, 0.1f); int length = pAramtureDataArray[3].GetChildNum(); //DICTOOL->getArrayCount_json(json, BONE_DATA, 0); @@ -1989,27 +1990,27 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, str = SkinDataValue[i].GetValue(cocoLoader); if (key.compare(A_X) == 0) { - sdd->skinData.x = atof(str) * s_PositionReadScale; + sdd->skinData.x = utils::atof(str) * s_PositionReadScale; } else if (key.compare(A_Y) == 0) { - sdd->skinData.y = atof(str) * s_PositionReadScale; + sdd->skinData.y = utils::atof(str) * s_PositionReadScale; } else if (key.compare(A_SCALE_X) == 0) { - sdd->skinData.scaleX = atof(str); + sdd->skinData.scaleX = utils::atof(str); } else if (key.compare(A_SCALE_Y) == 0) { - sdd->skinData.scaleY = atof(str); + sdd->skinData.scaleY = utils::atof(str); } else if (key.compare(A_SKEW_X) == 0) { - sdd->skinData.skewX = atof(str); + sdd->skinData.skewX = utils::atof(str); } else if (key.compare(A_SKEW_Y) == 0) { - sdd->skinData.skewY = atof(str); + sdd->skinData.skewY = utils::atof(str); } } @@ -2168,7 +2169,7 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, movementData->scale = 1.0; if(str != nullptr) { - movementData->scale = atof(str); + movementData->scale = utils::atof(str); } } else if (key.compare(A_TWEEN_EASING) == 0) @@ -2220,7 +2221,7 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, { if(str != nullptr) { - movementBoneData->delay = atof(str); + movementBoneData->delay = utils::atof(str); } } else if (key.compare(FRAME_DATA) == 0) @@ -2382,7 +2383,7 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, str = pFrameData[ii].GetValue(cocoLoader); if (str != nullptr) { - frameData->easingParams[ii] = atof(str); + frameData->easingParams[ii] = utils::atof(str); } } } @@ -2421,28 +2422,28 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, { if(str != nullptr) { - textureData->width = atof(str); + textureData->width = utils::atof(str); } } else if (key.compare(A_HEIGHT) == 0) { if(str != nullptr) { - textureData->height = atof(str); + textureData->height = utils::atof(str); } } else if (key.compare(A_PIVOT_X) == 0) { if(str != nullptr) { - textureData->pivotX = atof(str); + textureData->pivotX = utils::atof(str); } } else if (key.compare(A_PIVOT_Y) == 0) { if(str != nullptr) { - textureData->pivotY = atof(str); + textureData->pivotY = utils::atof(str); } } else if (key.compare(CONTOUR_DATA) == 0) @@ -2481,8 +2482,8 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, { pVerTexPoint = pVerTexPointArray[ii].GetChildArray(cocoLoader); Vec2 vertex; - vertex.x = atof(pVerTexPoint[0].GetValue(cocoLoader)); - vertex.y = atof(pVerTexPoint[1].GetValue(cocoLoader)); + vertex.x = utils::atof(pVerTexPoint[0].GetValue(cocoLoader)); + vertex.y = utils::atof(pVerTexPoint[1].GetValue(cocoLoader)); contourData->vertexList.push_back(vertex); } break; } @@ -2505,11 +2506,11 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, str = child->GetValue(cocoLoader); if (key.compare(A_X) == 0) { - node->x = atof(str) * dataInfo->contentScale; + node->x = utils::atof(str) * dataInfo->contentScale; } else if (key.compare(A_Y) == 0) { - node->y = atof(str) * dataInfo->contentScale; + node->y = utils::atof(str) * dataInfo->contentScale; } else if (key.compare(A_Z) == 0) { @@ -2517,19 +2518,19 @@ void DataReaderHelper::decodeNode(BaseData *node, const rapidjson::Value& json, } else if (key.compare(A_SKEW_X) == 0) { - node->skewX = atof(str); + node->skewX = utils::atof(str); } else if (key.compare(A_SKEW_Y) == 0) { - node->skewY = atof(str); + node->skewY = utils::atof(str); } else if (key.compare(A_SCALE_X) == 0) { - node->scaleX = atof(str); + node->scaleX = utils::atof(str); } else if (key.compare(A_SCALE_Y) == 0) { - node->scaleY = atof(str); + node->scaleY = utils::atof(str); } else if (key.compare(COLOR_INFO) == 0) { diff --git a/cocos/editor-support/cocostudio/CCSGUIReader.cpp b/cocos/editor-support/cocostudio/CCSGUIReader.cpp index 7e706e4455..d86f04c166 100644 --- a/cocos/editor-support/cocostudio/CCSGUIReader.cpp +++ b/cocos/editor-support/cocostudio/CCSGUIReader.cpp @@ -1241,9 +1241,9 @@ Widget* WidgetPropertiesReader0300::createWidget(const rapidjson::Value& data, c SpriteFrameCache::getInstance()->addSpriteFramesWithFile(file); } }else if (key == "designWidth"){ - fileDesignWidth = atof(tpChildArray[i].GetValue(cocoLoader)); + fileDesignWidth = utils::atof(tpChildArray[i].GetValue(cocoLoader)); }else if (key == "designHeight"){ - fileDesignHeight = atof(tpChildArray[i].GetValue(cocoLoader)); + fileDesignHeight = utils::atof(tpChildArray[i].GetValue(cocoLoader)); }else if (key == "widgetTree"){ if (fileDesignWidth <= 0 || fileDesignHeight <= 0) { diff --git a/cocos/editor-support/cocostudio/CCSSceneReader.cpp b/cocos/editor-support/cocostudio/CCSSceneReader.cpp index 92177e9284..ab855a30cc 100644 --- a/cocos/editor-support/cocostudio/CCSSceneReader.cpp +++ b/cocos/editor-support/cocostudio/CCSSceneReader.cpp @@ -510,12 +510,12 @@ void SceneReader::setPropertyFromJsonDict(CocoLoader *cocoLoader, stExpCocoNode if (key == "x") { - x = atof(value.c_str()); + x = utils::atof(value.c_str()); node->setPositionX(x); } else if (key == "y") { - y = atof(value.c_str()); + y = utils::atof(value.c_str()); node->setPositionY(y); } else if (key == "visible") @@ -535,7 +535,7 @@ void SceneReader::setPropertyFromJsonDict(CocoLoader *cocoLoader, stExpCocoNode } else if(key == "scalex") { - fScaleX = atof(value.c_str()); + fScaleX = utils::atof(value.c_str()); node->setScaleX(fScaleX); } else if(key == "scaley") @@ -545,7 +545,7 @@ void SceneReader::setPropertyFromJsonDict(CocoLoader *cocoLoader, stExpCocoNode } else if(key == "rotation") { - fRotationZ = atof(value.c_str()); + fRotationZ = utils::atof(value.c_str()); node->setRotation(fRotationZ); } } diff --git a/cocos/editor-support/cocostudio/CCSkin.cpp b/cocos/editor-support/cocostudio/CCSkin.cpp index d7d7a3feab..ac61c1a104 100644 --- a/cocos/editor-support/cocostudio/CCSkin.cpp +++ b/cocos/editor-support/cocostudio/CCSkin.cpp @@ -160,6 +160,7 @@ void Skin::updateTransform() // // calculate the Quad based on the Affine Matrix // + Mat4 transform = getNodeToParentTransform(); Size &size = _rect.size; @@ -169,13 +170,13 @@ void Skin::updateTransform() float x2 = x1 + size.width; float y2 = y1 + size.height; - float x = _transform.m[12]; - float y = _transform.m[13]; + float x = transform.m[12]; + float y = transform.m[13]; - float cr = _transform.m[0]; - float sr = _transform.m[1]; - float cr2 = _transform.m[5]; - float sr2 = -_transform.m[4]; + float cr = transform.m[0]; + float sr = transform.m[1]; + float cr2 = transform.m[5]; + float sr2 = -transform.m[4]; float ax = x1 * cr - y1 * sr2 + x; float ay = x1 * sr + y1 * cr2 + y; diff --git a/cocos/editor-support/cocostudio/CocoLoader.cpp b/cocos/editor-support/cocostudio/CocoLoader.cpp index da84bd9200..41bafa1392 100644 --- a/cocos/editor-support/cocostudio/CocoLoader.cpp +++ b/cocos/editor-support/cocostudio/CocoLoader.cpp @@ -195,27 +195,6 @@ bool CocoLoader::ReadCocoBinBuff(char* pBinBuff) return true; } -stExpCocoObjectDesc* CocoLoader::GetCocoObjectDesc(const char* szObjDesc) -{ - for(int i = 0 ; i < m_pFileHeader->m_ObjectCount ; i++) - { - if(0 == strcmp((char*)m_pObjectDescArray[i].m_szName,szObjDesc)) - { - return &m_pObjectDescArray[i]; - } - } - return nullptr; -} - -stExpCocoObjectDesc* CocoLoader::GetCocoObjectDesc(int vIndex) -{ - if(vIndex >= 0 && vIndex < m_pFileHeader->m_ObjectCount) - { - return &m_pObjectDescArray[vIndex]; - } - return nullptr; -} - char* CocoLoader::GetMemoryAddr_AttribDesc() { return m_pMemoryBuff + m_pFileHeader->m_lAttribMemAddr ; diff --git a/cocos/editor-support/cocostudio/CocoLoader.h b/cocos/editor-support/cocostudio/CocoLoader.h index 4ead7b84b7..b54681aaa6 100644 --- a/cocos/editor-support/cocostudio/CocoLoader.h +++ b/cocos/editor-support/cocostudio/CocoLoader.h @@ -104,8 +104,6 @@ public: stCocoFileHeader* GetFileHeader(){return m_pFileHeader;} stExpCocoNode* GetRootCocoNode(){return m_pRootNode;} stExpCocoObjectDesc* GetCocoObjectDescArray(){return m_pObjectDescArray;} - stExpCocoObjectDesc* GetCocoObjectDesc(const char* szObjDesc); - stExpCocoObjectDesc* GetCocoObjectDesc(int vIndex); char* GetMemoryAddr_AttribDesc(); char* GetMemoryAddr_CocoNode(); char* GetMemoryAddr_String(); diff --git a/cocos/editor-support/cocostudio/TriggerMng.cpp b/cocos/editor-support/cocostudio/TriggerMng.cpp index 779b5dca86..6b76be239b 100755 --- a/cocos/editor-support/cocostudio/TriggerMng.cpp +++ b/cocos/editor-support/cocostudio/TriggerMng.cpp @@ -191,7 +191,7 @@ bool TriggerMng::isEmpty(void) const } - void TriggerMng::buildJson(rapidjson::Document &document, cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCocoNode *pCocoNode) +void TriggerMng::buildJson(rapidjson::Document &document, cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCocoNode *pCocoNode) { int count = pCocoNode[13].GetChildNum(); int length = 0; @@ -262,15 +262,15 @@ bool TriggerMng::isEmpty(void) const } else { - rapidjson::Type type = pDataItemArray[i4].GetType(pCocoLoader); + rapidjson::Type type = pDataItemArray[i5].GetType(pCocoLoader); if (type == rapidjson::kStringType) { dataitem.AddMember("value", str3, allocator); } - else if(type == rapidjson::kNumberType) + else { int nV = atoi(str3); - float fV = atof(str3); + float fV = utils::atof(str3); if (fabs(nV - fV) < 0.0000001) { dataitem.AddMember("value", nV, allocator); @@ -343,10 +343,10 @@ bool TriggerMng::isEmpty(void) const { dataitem.AddMember("value", str5, allocator); } - else if(type == rapidjson::kNumberType) + else { int nV = atoi(str5); - float fV = atof(str5); + float fV = utils::atof(str5); if (fabs(nV - fV) < 0.0000001) { dataitem.AddMember("value", nV, allocator); diff --git a/cocos/editor-support/cocostudio/TriggerObj.cpp b/cocos/editor-support/cocostudio/TriggerObj.cpp index 7fec68a848..06cd96986e 100755 --- a/cocos/editor-support/cocostudio/TriggerObj.cpp +++ b/cocos/editor-support/cocostudio/TriggerObj.cpp @@ -241,98 +241,98 @@ void TriggerObj::serialize(const rapidjson::Value &val) } - void TriggerObj::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCocoNode *pCocoNode) +void TriggerObj::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCocoNode *pCocoNode) +{ + int length = pCocoNode->GetChildNum(); + int count = 0; + int num = 0; + stExpCocoNode *pTriggerObjArray = pCocoNode->GetChildArray(pCocoLoader); + for (int i0 = 0; i0 < length; ++i0) { - int length = pCocoNode->GetChildNum(); - int count = 0; - int num = 0; - stExpCocoNode *pTriggerObjArray = pCocoNode->GetChildArray(pCocoLoader); - for (int i0 = 0; i0 < length; ++i0) + std::string key = pTriggerObjArray[i0].GetName(pCocoLoader); + const char* str0 = pTriggerObjArray[i0].GetValue(pCocoLoader); + if (key.compare("id") == 0) { - std::string key = pTriggerObjArray[i0].GetName(pCocoLoader); - const char* str0 = pTriggerObjArray[i0].GetValue(pCocoLoader); - if (key.compare("id") == 0) + if (str0 != nullptr) { - if (str0 != nullptr) - { - _id = atoi(str0); //(unsigned int)(DICTOOL->getIntValue_json(val, "id")); - } + _id = atoi(str0); } - else if (key.compare("conditions") == 0) + } + else if (key.compare("conditions") == 0) + { + count = pTriggerObjArray[i0].GetChildNum(); + stExpCocoNode *pConditionsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); + for (int i1 = 0; i1 < count; ++i1) { - count = pTriggerObjArray[i0].GetChildNum(); - stExpCocoNode *pConditionsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); - for (int i1 = 0; i1 < count; ++i1) + num = pConditionsArray[i1].GetChildNum(); + stExpCocoNode *pConditionArray = pConditionsArray[i1].GetChildArray(pCocoLoader); + const char *classname = pConditionArray[0].GetValue(pCocoLoader); + if (classname == nullptr) { - num = pConditionsArray[i1].GetChildNum(); - stExpCocoNode *pConditionArray = pConditionsArray[i1].GetChildArray(pCocoLoader); - const char *classname = pConditionArray[0].GetValue(pCocoLoader); - if (classname == nullptr) - { - continue; - } - BaseTriggerCondition *con = dynamic_cast(ObjectFactory::getInstance()->createObject(classname)); - CCAssert(con != nullptr, "class named classname can not implement!"); - con->serialize(pCocoLoader, &pConditionArray[1]); - con->init(); - _cons.pushBack(con); + continue; } + BaseTriggerCondition *con = dynamic_cast(ObjectFactory::getInstance()->createObject(classname)); + CCAssert(con != nullptr, "class named classname can not implement!"); + con->serialize(pCocoLoader, &pConditionArray[1]); + con->init(); + _cons.pushBack(con); } - else if (key.compare("actions") == 0) + } + else if (key.compare("actions") == 0) + { + count = pTriggerObjArray[i0].GetChildNum(); + stExpCocoNode *pActionsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); + for (int i2 = 0; i2 < count; ++i2) { - count = pTriggerObjArray[i0].GetChildNum(); - stExpCocoNode *pActionsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); - for (int i2 = 0; i2 < count; ++i2) + num = pActionsArray[i2].GetChildNum(); + stExpCocoNode *pActionArray = pActionsArray[i2].GetChildArray(pCocoLoader); + const char *classname = pActionArray[0].GetValue(pCocoLoader); + if (classname == nullptr) { - num = pActionsArray[i2].GetChildNum(); - stExpCocoNode *pActionArray = pActionsArray[i2].GetChildArray(pCocoLoader); - const char *classname = pActionArray[0].GetValue(pCocoLoader); - if (classname == nullptr) - { - continue; - } - BaseTriggerAction *act = dynamic_cast(ObjectFactory::getInstance()->createObject(classname)); - CCAssert(act != nullptr, "class named classname can not implement!"); - act->serialize(pCocoLoader, &pActionArray[1]); - act->init(); - _acts.pushBack(act); + continue; } + BaseTriggerAction *act = dynamic_cast(ObjectFactory::getInstance()->createObject(classname)); + CCAssert(act != nullptr, "class named classname can not implement!"); + act->serialize(pCocoLoader, &pActionArray[1]); + act->init(); + _acts.pushBack(act); } - else if (key.compare("events") == 0) + } + else if (key.compare("events") == 0) + { + count = pTriggerObjArray[i0].GetChildNum(); + stExpCocoNode *pEventsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); + for (int i3 = 0; i3 < count; ++i3) { - count = pTriggerObjArray[i0].GetChildNum(); - stExpCocoNode *pEventsArray = pTriggerObjArray[i0].GetChildArray(pCocoLoader); - for (int i3 = 0; i3 < count; ++i3) + num = pEventsArray[i3].GetChildNum(); + stExpCocoNode *pEventArray = pEventsArray[i3].GetChildArray(pCocoLoader); + const char *str1 = pEventArray[0].GetValue(pCocoLoader); + if (str1 == nullptr) { - num = pEventsArray[i3].GetChildNum(); - stExpCocoNode *pEventArray = pEventsArray[i3].GetChildArray(pCocoLoader); - const char *str1 = pEventArray[0].GetValue(pCocoLoader); - if (str1 == nullptr) - { - continue; - } - int event = atoi(str1); - if (event < 0) - { - continue; - } - char* buf = new char[10]; - sprintf(buf, "%d", event); - std::string custom_event_name(buf); - CC_SAFE_DELETE_ARRAY(buf); - - EventListenerCustom* listener = EventListenerCustom::create(custom_event_name, [=](EventCustom* evt){ - if (detect()) - { - done(); - } - }); - _listeners.pushBack(listener); - TriggerMng::getInstance()->addEventListenerWithFixedPriority(listener, 1); + continue; } + int event = atoi(str1); + if (event < 0) + { + continue; + } + char* buf = new char[10]; + sprintf(buf, "%d", event); + std::string custom_event_name(buf); + CC_SAFE_DELETE_ARRAY(buf); + + EventListenerCustom* listener = EventListenerCustom::create(custom_event_name, [=](EventCustom* evt){ + if (detect()) + { + done(); + } + }); + _listeners.pushBack(listener); + TriggerMng::getInstance()->addEventListenerWithFixedPriority(listener, 1); } } } +} diff --git a/cocos/editor-support/cocostudio/WidgetReader/WidgetReader.cpp b/cocos/editor-support/cocostudio/WidgetReader/WidgetReader.cpp index f68f2af107..69eda57774 100644 --- a/cocos/editor-support/cocostudio/WidgetReader/WidgetReader.cpp +++ b/cocos/editor-support/cocostudio/WidgetReader/WidgetReader.cpp @@ -87,7 +87,7 @@ namespace cocostudio }; valueToFloat = [=](const std::string& str) -> float{ - return atof(str.c_str()); + return utils::atof(str.c_str()); }; } diff --git a/cocos/physics/CCPhysicsShape.cpp b/cocos/physics/CCPhysicsShape.cpp index 0fcfcfd820..c40caccd4a 100644 --- a/cocos/physics/CCPhysicsShape.cpp +++ b/cocos/physics/CCPhysicsShape.cpp @@ -453,7 +453,7 @@ void PhysicsShapeCircle::update(float delta) if (_dirty) { - cpFloat factor = PhysicsHelper::float2cpfloat( _newScaleX / _scaleX ); + cpFloat factor = std::abs(PhysicsHelper::float2cpfloat( _newScaleX / _scaleX )); cpShape* shape = _info->getShapes().front(); cpVect v = cpCircleShapeGetOffset(shape); @@ -710,6 +710,17 @@ void PhysicsShapePolygon::update(float delta) vects[i].y *= factorY; } + // convert hole to clockwise + if ( factorX * factorY < 0 ) + { + for (int i = 0; i < count / 2; ++i) + { + cpVect v = vects[i]; + vects[i] = vects[count - i - 1]; + vects[count - i - 1] = v; + } + } + for (int i = 0; i < count; ++i) { cpVect n = cpvnormalize(cpvperp(cpvsub(vects[i], vects[(i + 1) % count]))); diff --git a/cocos/platform/CCFileUtils.cpp b/cocos/platform/CCFileUtils.cpp index c655dbba03..5079035ce7 100644 --- a/cocos/platform/CCFileUtils.cpp +++ b/cocos/platform/CCFileUtils.cpp @@ -31,6 +31,7 @@ THE SOFTWARE. #include "base/ccMacros.h" #include "base/CCDirector.h" #include "platform/CCSAXParser.h" +#include "base/ccUtils.h" #include "tinyxml2.h" #include "unzip.h" @@ -257,7 +258,7 @@ public: else if (sName == "integer") _curArray->push_back(Value(atoi(_curValue.c_str()))); else - _curArray->push_back(Value(atof(_curValue.c_str()))); + _curArray->push_back(Value(utils::atof(_curValue.c_str()))); } else if (SAX_DICT == curState) { @@ -266,7 +267,7 @@ public: else if (sName == "integer") (*_curDict)[_curKey] = Value(atoi(_curValue.c_str())); else - (*_curDict)[_curKey] = Value(atof(_curValue.c_str())); + (*_curDict)[_curKey] = Value(utils::atof(_curValue.c_str())); } _curValue.clear(); @@ -765,13 +766,16 @@ void FileUtils::setSearchResolutionsOrder(const std::vector& search } } -void FileUtils::addSearchResolutionsOrder(const std::string &order) +void FileUtils::addSearchResolutionsOrder(const std::string &order,const bool front) { std::string resOrder = order; if (!resOrder.empty() && resOrder[resOrder.length()-1] != '/') resOrder.append("/"); - - _searchResolutionsOrderArray.push_back(resOrder); + if (front) { + _searchResolutionsOrderArray.insert(_searchResolutionsOrderArray.begin(), resOrder); + } else { + _searchResolutionsOrderArray.push_back(resOrder); + } } const std::vector& FileUtils::getSearchResolutionsOrder() @@ -818,7 +822,7 @@ void FileUtils::setSearchPaths(const std::vector& searchPaths) } } -void FileUtils::addSearchPath(const std::string &searchpath) +void FileUtils::addSearchPath(const std::string &searchpath,const bool front) { std::string prefix; if (!isAbsolutePath(searchpath)) @@ -829,7 +833,11 @@ void FileUtils::addSearchPath(const std::string &searchpath) { path += "/"; } - _searchPathArray.push_back(path); + if (front) { + _searchPathArray.insert(_searchPathArray.begin(), path); + } else { + _searchPathArray.push_back(path); + } } void FileUtils::setFilenameLookupDictionary(const ValueMap& filenameLookupDict) diff --git a/cocos/platform/CCFileUtils.h b/cocos/platform/CCFileUtils.h index 60e899ed35..570b02fc50 100644 --- a/cocos/platform/CCFileUtils.h +++ b/cocos/platform/CCFileUtils.h @@ -229,7 +229,7 @@ public: * @see setSearchResolutionsOrder(), fullPathForFilename(). * @since v2.1 */ - virtual void addSearchResolutionsOrder(const std::string &order); + virtual void addSearchResolutionsOrder(const std::string &order,const bool front=false); /** * Gets the array that contains the search order of the resources. @@ -266,7 +266,7 @@ public: * * @since v2.1 */ - void addSearchPath(const std::string & path); + void addSearchPath(const std::string & path, const bool front=false); /** * Gets the array of search paths. diff --git a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerActivity.java b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerActivity.java index f5bc665c2b..b527751778 100644 --- a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerActivity.java +++ b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerActivity.java @@ -270,7 +270,7 @@ public abstract class GameControllerActivity extends Cocos2dxActivity implements mControllerOuya.onResume(); } - mControllerHelper.gatherControllers(); + GameControllerHelper.gatherControllers(mControllerHelper.mGameController); } @Override diff --git a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerHelper.java b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerHelper.java index e4c756e074..f1cec07d11 100644 --- a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerHelper.java +++ b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerHelper.java @@ -80,6 +80,7 @@ public class GameControllerHelper { int deviceId = event.getDeviceId(); String deviceName = event.getDevice().getName(); if(mGameController.get(deviceId) == null){ + gatherControllers(mGameController); mGameController.append(deviceId, deviceName); } @@ -167,6 +168,7 @@ public class GameControllerHelper { String deviceName = event.getDevice().getName(); if(mGameController.get(deviceId) == null){ + gatherControllers(mGameController); mGameController.append(deviceId, deviceName); } @@ -224,7 +226,7 @@ public class GameControllerHelper { } void onInputDeviceChanged(int deviceId){ - gatherControllers(); + gatherControllers(mGameController); } void onInputDeviceRemoved(int deviceId) { @@ -234,20 +236,20 @@ public class GameControllerHelper { } } - void gatherControllers(){ - int controllerCount = mGameController.size(); + static void gatherControllers(SparseArray controllers){ + int controllerCount = controllers.size(); for (int i = 0; i < controllerCount; i++) { try { - int controllerDeveceId = mGameController.keyAt(i); + int controllerDeveceId = controllers.keyAt(i); InputDevice device = InputDevice.getDevice(controllerDeveceId); if (device == null) { - GameControllerAdapter.onDisconnected(mGameController.get(controllerDeveceId), controllerDeveceId); - mGameController.delete(controllerDeveceId); + GameControllerAdapter.onDisconnected(controllers.get(controllerDeveceId), controllerDeveceId); + controllers.delete(controllerDeveceId); } } catch (Exception e) { - int controllerDeveceId = mGameController.keyAt(i); - GameControllerAdapter.onDisconnected(mGameController.get(controllerDeveceId), controllerDeveceId); - mGameController.delete(controllerDeveceId); + int controllerDeveceId = controllers.keyAt(i); + GameControllerAdapter.onDisconnected(controllers.get(controllerDeveceId), controllerDeveceId); + controllers.delete(controllerDeveceId); e.printStackTrace(); } } diff --git a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerNibiru.java b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerNibiru.java index 142a19f671..ec3aeb9723 100644 --- a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerNibiru.java +++ b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerNibiru.java @@ -113,7 +113,7 @@ OnSimpleStickListener, OnAccListener, OnGyroListener, OnStateListener, GameContr { if( !mControllerService.hasDeviceConnected() ){ Bundle bun = new Bundle(); - bun.putBoolean(ControllerService.FLAG_IS_SHOW_GAMEPAD_TIP, true); + bun.putBoolean(ControllerService.FLAG_IS_SHOW_GAMEPAD_TIP, false); try { mControllerService.showDeviceManagerUI(mContext, bun); } catch (ControllerServiceException e) { diff --git a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerOuya.java b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerOuya.java index ca6ccede4f..fab0fdc80a 100644 --- a/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerOuya.java +++ b/cocos/platform/android/ControllerManualAdapter/src/org/cocos2dx/lib/GameControllerOuya.java @@ -5,6 +5,7 @@ import org.cocos2dx.lib.GameControllerDelegate; import tv.ouya.console.api.OuyaController; import android.content.Context; +import android.util.SparseArray; import android.util.SparseIntArray; import android.view.KeyEvent; import android.view.MotionEvent; @@ -13,6 +14,8 @@ public class GameControllerOuya implements GameControllerDelegate{ private SparseIntArray mKeyMap; + private SparseArray mGameController = new SparseArray(); + public GameControllerOuya(){ mKeyMap = new SparseIntArray(20); mKeyMap.put(OuyaController.BUTTON_A, GameControllerDelegate.BUTTON_B); @@ -25,13 +28,9 @@ public class GameControllerOuya implements GameControllerDelegate{ mKeyMap.put(OuyaController.BUTTON_DPAD_UP, GameControllerDelegate.BUTTON_DPAD_UP); mKeyMap.put(OuyaController.BUTTON_L1, GameControllerDelegate.BUTTON_LEFT_SHOULDER); mKeyMap.put(OuyaController.BUTTON_R1, GameControllerDelegate.BUTTON_RIGHT_SHOULDER); - mKeyMap.put(OuyaController.AXIS_L2, GameControllerDelegate.BUTTON_LEFT_TRIGGER); - mKeyMap.put(OuyaController.AXIS_R2, GameControllerDelegate.BUTTON_RIGHT_TRIGGER); - mKeyMap.put(OuyaController.AXIS_LS_X, GameControllerDelegate.BUTTON_LEFT_THUMBSTICK); - mKeyMap.put(OuyaController.AXIS_LS_Y, GameControllerDelegate.BUTTON_LEFT_THUMBSTICK); - mKeyMap.put(OuyaController.AXIS_RS_X, GameControllerDelegate.BUTTON_RIGHT_THUMBSTICK); - mKeyMap.put(OuyaController.AXIS_RS_Y, GameControllerDelegate.BUTTON_RIGHT_THUMBSTICK); + mKeyMap.put(OuyaController.BUTTON_L3, GameControllerDelegate.BUTTON_LEFT_THUMBSTICK); + mKeyMap.put(OuyaController.BUTTON_R3, GameControllerDelegate.BUTTON_RIGHT_THUMBSTICK); } public void onCreate(Context context) { @@ -61,7 +60,11 @@ public class GameControllerOuya implements GameControllerDelegate{ { int deviceId = event.getDeviceId(); String deviceName = event.getDevice().getName(); - OuyaController c = OuyaController.getControllerByDeviceId(deviceId); + OuyaController c = OuyaController.getControllerByDeviceId(deviceId); + if (mGameController.get(deviceId) == null) { + GameControllerHelper.gatherControllers(mGameController); + mGameController.append(deviceId, deviceName); + } float newLeftTrigger = c.getAxisValue(OuyaController.AXIS_L2); if (Float.compare(newLeftTrigger, mOldLeftTrigger) != 0) { @@ -125,10 +128,6 @@ public class GameControllerOuya implements GameControllerDelegate{ int action = event.getAction(); int keyCode = event.getKeyCode(); - if (keyCode == KeyEvent.KEYCODE_BUTTON_L2 || keyCode == KeyEvent.KEYCODE_BUTTON_R2) { - return true; - } - if (action == KeyEvent.ACTION_DOWN) { handled = OuyaController.onKeyDown(keyCode, event); } @@ -143,10 +142,17 @@ public class GameControllerOuya implements GameControllerDelegate{ isAnalog = true; } + int deviceId = event.getDeviceId(); + String deviceName = event.getDevice().getName(); + + if (mGameController.get(deviceId) == null) { + GameControllerHelper.gatherControllers(mGameController); + mGameController.append(deviceId, deviceName); + } if (action == KeyEvent.ACTION_DOWN) { - mControllerEventListener.onButtonEvent(event.getDevice().getName(), event.getDeviceId(), mKeyMap.get(keyCode), true, 1.0f, isAnalog); + mControllerEventListener.onButtonEvent(deviceName, deviceId, mKeyMap.get(keyCode), true, 1.0f, isAnalog); }else { - mControllerEventListener.onButtonEvent(event.getDevice().getName(), event.getDeviceId(), mKeyMap.get(keyCode), false, 0.0f, isAnalog); + mControllerEventListener.onButtonEvent(deviceName, deviceId, mKeyMap.get(keyCode), false, 0.0f, isAnalog); } } diff --git a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxGLSurfaceView.java b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxGLSurfaceView.java index a710f8a711..58ecf41465 100644 --- a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxGLSurfaceView.java +++ b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxGLSurfaceView.java @@ -292,6 +292,7 @@ public class Cocos2dxGLSurfaceView extends GLSurfaceView { public boolean onKeyDown(final int pKeyCode, final KeyEvent pKeyEvent) { switch (pKeyCode) { case KeyEvent.KEYCODE_BACK: + Cocos2dxVideoHelper.mVideoHandler.sendEmptyMessage(Cocos2dxVideoHelper.KeyEventBack); case KeyEvent.KEYCODE_MENU: case KeyEvent.KEYCODE_DPAD_LEFT: case KeyEvent.KEYCODE_DPAD_RIGHT: diff --git a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoHelper.java b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoHelper.java index 64d1cc0adf..5bd3910eac 100644 --- a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoHelper.java +++ b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoHelper.java @@ -40,7 +40,7 @@ public class Cocos2dxVideoHelper { private FrameLayout mLayout = null; private Cocos2dxActivity mActivity = null; private SparseArray sVideoViews = null; - private static VideoHandler mVideoHandler = null; + static VideoHandler mVideoHandler = null; Cocos2dxVideoHelper(Cocos2dxActivity activity,FrameLayout layout) { @@ -64,6 +64,8 @@ public class Cocos2dxVideoHelper { private final static int VideoTaskSetVisible = 9; private final static int VideoTaskRestart = 10; private final static int VideoTaskKeepRatio = 11; + private final static int VideoTaskFullScreen = 12; + final static int KeyEventBack = 1000; static class VideoHandler extends Handler{ WeakReference mReference; @@ -101,6 +103,16 @@ public class Cocos2dxVideoHelper { helper._setVideoRect(msg.arg1, rect.left, rect.top, rect.right, rect.bottom); break; } + case VideoTaskFullScreen:{ + Cocos2dxVideoHelper helper = mReference.get(); + Rect rect = (Rect)msg.obj; + if (msg.arg2 == 1) { + helper._setFullScreenEnabled(msg.arg1, true, rect.right, rect.bottom); + } else { + helper._setFullScreenEnabled(msg.arg1, false, rect.right, rect.bottom); + } + break; + } case VideoTaskPause: { Cocos2dxVideoHelper helper = mReference.get(); helper._pauseVideo(msg.arg1); @@ -144,6 +156,11 @@ public class Cocos2dxVideoHelper { } break; } + case KeyEventBack: { + Cocos2dxVideoHelper helper = mReference.get(); + helper.onBackKeyEvent(); + break; + } default: break; } @@ -255,6 +272,38 @@ public class Cocos2dxVideoHelper { } } + public static void setFullScreenEnabled(int index,boolean enabled, int width,int height) { + Message msg = new Message(); + msg.what = VideoTaskFullScreen; + msg.arg1 = index; + if (enabled) { + msg.arg2 = 1; + } else { + msg.arg2 = 0; + } + msg.obj = new Rect(0, 0, width, height); + mVideoHandler.sendMessage(msg); + } + + private void _setFullScreenEnabled(int index, boolean enabled, int width,int height) { + Cocos2dxVideoView videoView = sVideoViews.get(index); + if (videoView != null) { + videoView.setFullScreenEnabled(enabled, width, height); + } + } + + private void onBackKeyEvent() { + int viewCount = sVideoViews.size(); + for (int i = 0; i < viewCount; i++) { + int key = sVideoViews.keyAt(i); + Cocos2dxVideoView videoView = sVideoViews.get(key); + if (videoView != null) { + videoView.setFullScreenEnabled(false, 0, 0); + mActivity.runOnGLThread(new VideoEventRunnable(key, KeyEventBack)); + } + } + } + public static void startVideo(int index) { Message msg = new Message(); msg.what = VideoTaskStart; diff --git a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoView.java b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoView.java index f701f7b375..11ca29a137 100644 --- a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoView.java +++ b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxVideoView.java @@ -18,7 +18,6 @@ package org.cocos2dx.lib; import android.app.AlertDialog; -import android.content.Context; import android.content.DialogInterface; import android.content.Intent; import android.content.res.AssetFileDescriptor; @@ -27,7 +26,6 @@ import android.media.AudioManager; import android.media.MediaPlayer; import android.media.MediaPlayer.OnErrorListener; import android.net.Uri; -import android.util.AttributeSet; import android.util.Log; import android.view.MotionEvent; import android.view.SurfaceHolder; @@ -75,7 +73,7 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl // recording the seek position while preparing private int mSeekWhenPrepared; - protected Context mContext = null; + protected Cocos2dxActivity mCocos2dxActivity = null; protected int mViewLeft = 0; protected int mViewTop = 0; @@ -87,27 +85,17 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl protected int mVisibleWidth = 0; protected int mVisibleHeight = 0; + protected boolean mFullScreenEnabled = false; + protected int mFullScreenWidth = 0; + protected int mFullScreenHeight = 0; + private int mViewTag = 0; - public Cocos2dxVideoView(Context context,int tag) { - super(context); + public Cocos2dxVideoView(Cocos2dxActivity activity,int tag) { + super(activity); mViewTag = tag; - mContext = context; - initVideoView(); - } - - public Cocos2dxVideoView(Context context, AttributeSet attrs) { - this(context, attrs, 0); - - mContext = context; - initVideoView(); - } - - public Cocos2dxVideoView(Context context, AttributeSet attrs, int defStyle) { - super(context, attrs, defStyle); - - mContext = context; + mCocos2dxActivity = activity; initVideoView(); } @@ -115,11 +103,11 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { if (mVideoWidth == 0 || mVideoHeight == 0) { setMeasuredDimension(mViewWidth, mViewHeight); - Log.e(TAG, ""+mViewWidth+ ":" +mViewHeight); + Log.i(TAG, ""+mViewWidth+ ":" +mViewHeight); } else { setMeasuredDimension(mVisibleWidth, mVisibleHeight); - Log.e(TAG, ""+mVisibleWidth+ ":" +mVisibleHeight); + Log.i(TAG, ""+mVisibleWidth+ ":" +mVisibleHeight); } } @@ -131,6 +119,18 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl mViewHeight = maxHeight; if (mVideoWidth != 0 && mVideoHeight != 0) { + fixSize(mViewLeft, mViewTop, mViewWidth, mVideoHeight); + } + } + + public void setFullScreenEnabled(boolean enabled, int width, int height) { + if (mFullScreenEnabled != enabled) { + mFullScreenEnabled = enabled; + if (width != 0 && height != 0) { + mFullScreenWidth = width; + mFullScreenHeight = height; + } + fixSize(); } } @@ -265,7 +265,7 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl // TODO: these constants need to be published somewhere in the framework. Intent i = new Intent("com.android.music.musicservicecommand"); i.putExtra("command", "pause"); - mContext.sendBroadcast(i); + mCocos2dxActivity.sendBroadcast(i); // we shouldn't clear the target state, because somebody might have // called start() previously @@ -288,10 +288,10 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl mDuration = -1; mCurrentBufferPercentage = 0; if (isAssetRouse) { - AssetFileDescriptor afd = mContext.getAssets().openFd(fileName); + AssetFileDescriptor afd = mCocos2dxActivity.getAssets().openFd(fileName); mMediaPlayer.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); } else { - mMediaPlayer.setDataSource(mContext, mUri); + mMediaPlayer.setDataSource(mCocos2dxActivity, mUri); } mMediaPlayer.prepareAsync(); @@ -321,27 +321,35 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl } public void fixSize() { - if (mViewWidth != 0 && mViewHeight != 0) { + if (mFullScreenEnabled) { + fixSize(0, 0, mFullScreenWidth, mFullScreenHeight); + } else { + fixSize(mViewLeft, mViewTop, mViewWidth, mVideoHeight); + } + } + + public void fixSize(int left,int top,int width,int height) { + if (width != 0 && height != 0) { if (mKeepRatio) { - if ( mVideoWidth * mViewHeight > mViewWidth * mVideoHeight ) { - mVisibleWidth = mViewWidth; - mVisibleHeight = mViewWidth * mVideoHeight / mVideoWidth; - } else if ( mVideoWidth * mViewHeight < mViewWidth * mVideoHeight ) { - mVisibleWidth = mViewHeight * mVideoWidth / mVideoHeight; - mVisibleHeight = mViewHeight; + if ( mVideoWidth * height > width * mVideoHeight ) { + mVisibleWidth = width; + mVisibleHeight = width * mVideoHeight / mVideoWidth; + } else if ( mVideoWidth * height < width * mVideoHeight ) { + mVisibleWidth = height * mVideoWidth / mVideoHeight; + mVisibleHeight = height; } - mVisibleLeft = mViewLeft + (mViewWidth - mVisibleWidth) / 2; - mVisibleTop = mViewTop + (mViewHeight - mVisibleHeight) / 2; + mVisibleLeft = left + (width - mVisibleWidth) / 2; + mVisibleTop = top + (height - mVisibleHeight) / 2; } else { - mVisibleLeft = mViewLeft; - mVisibleTop = mViewTop; - mVisibleWidth = mViewWidth; - mVisibleHeight = mViewHeight; + mVisibleLeft = left; + mVisibleTop = top; + mVisibleWidth = width; + mVisibleHeight = height; } } else { - mVisibleLeft = mViewLeft; - mVisibleTop = mViewTop; + mVisibleLeft = left; + mVisibleTop = top; mVisibleWidth = mVideoWidth; mVisibleHeight = mVideoHeight; } @@ -437,7 +445,7 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl * longer have a window, don't bother showing the user an error. */ if (getWindowToken() != null) { - Resources r = mContext.getResources(); + Resources r = mCocos2dxActivity.getResources(); int messageId; if (framework_err == MediaPlayer.MEDIA_ERROR_NOT_VALID_FOR_PROGRESSIVE_PLAYBACK) { @@ -451,7 +459,7 @@ public class Cocos2dxVideoView extends SurfaceView implements MediaPlayerControl int titleId = r.getIdentifier("VideoView_error_title", "string", "android"); int buttonStringId = r.getIdentifier("VideoView_error_button", "string", "android"); - new AlertDialog.Builder(mContext) + new AlertDialog.Builder(mCocos2dxActivity) .setTitle(r.getString(titleId)) .setMessage(messageId) .setPositiveButton(r.getString(buttonStringId), diff --git a/cocos/platform/desktop/CCGLView.cpp b/cocos/platform/desktop/CCGLView.cpp index a934875204..4c4fbd7072 100644 --- a/cocos/platform/desktop/CCGLView.cpp +++ b/cocos/platform/desktop/CCGLView.cpp @@ -30,6 +30,7 @@ THE SOFTWARE. #include "base/CCEventKeyboard.h" #include "base/CCEventMouse.h" #include "base/CCIMEDispatcher.h" +#include "base/ccUtils.h" #include @@ -356,7 +357,7 @@ bool GLView::initWithRect(const std::string& viewName, Rect rect, float frameZoo // check OpenGL version at first const GLubyte* glVersion = glGetString(GL_VERSION); - if ( atof((const char*)glVersion) < 1.5 ) + if ( utils::atof((const char*)glVersion) < 1.5 ) { char strComplain[256] = {0}; sprintf(strComplain, diff --git a/cocos/platform/linux/CCDevice.cpp b/cocos/platform/linux/CCDevice.cpp index 5e007f7d28..5536c87d81 100644 --- a/cocos/platform/linux/CCDevice.cpp +++ b/cocos/platform/linux/CCDevice.cpp @@ -215,7 +215,7 @@ public: return false; } - if (isspace(unicode)) { + if (iswspace(unicode)) { currentPaintPosition += face->glyph->metrics.horiAdvance >> 6; prevGlyphIndex = glyphIndex; prevCharacter = unicode; diff --git a/cocos/platform/wp8/shaders/precompiledshaders.h b/cocos/platform/wp8/shaders/precompiledshaders.h index 5a5a3e0450..3a23edfe5d 100644 --- a/cocos/platform/wp8/shaders/precompiledshaders.h +++ b/cocos/platform/wp8/shaders/precompiledshaders.h @@ -86,7 +86,7 @@ const unsigned char s_133478C5A874C1E6F59B418CE6C7C39F1AE0F873[] = { 120, 116, 117, 114, 101, 48, 0, 0, 0, 0, 1, 0, 0, 0, 248, 3, 0, 0, 4, 5, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 11, 95, 74, 206, 145, 124, 32, 219, 67, 19, @@ -456,7 +456,7 @@ const unsigned char s_13E33F532157A58EC77EDE3B3112560A89D272B2[] = { 116, 114, 105, 120, 0, 0, 0, 0, 0, 0, 0, 0, 204, 2, 0, 0, 164, 4, 0, 0, 0, 0, 0, 0, -173, 144, 0, 0, 0, 0, 0, 0, +221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 127, 145, 81, 72, 216, 190, 16, 61, 245, 231, 235, 249, @@ -800,7 +800,7 @@ const unsigned char s_1A69A7CC77C7C8FC62799B0513816EA41FBF3BFE[] = { 116, 67, 111, 108, 111, 114, 0, 0, 0, 0, 3, 0, 0, 0, 208, 7, 0, 0, 4, 5, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 65, 106, 69, 173, 111, 248, 97, 165, 186, 90, @@ -1301,7 +1301,7 @@ const unsigned char s_53938AB67AD93ABA0DDB87F3C9889304284E011E[] = { 120, 116, 117, 114, 101, 48, 0, 0, 0, 0, 1, 0, 0, 0, 24, 4, 0, 0, 4, 5, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 200, 5, 103, 205, 248, 30, 69, 65, 32, 117, @@ -1675,7 +1675,7 @@ const unsigned char s_67837675F2BB48C0E926316F505FC1538228E0FA[] = { 86, 80, 77, 97, 116, 114, 105, 120, 0, 0, 0, 0, 0, 0, 0, 0, 16, 4, 0, 0, 48, 5, 0, 0, - 0, 0, 0, 0, 173, 144, 0, 0, + 0, 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 79, 226, 72, 124, 94, 252, 37, 157, @@ -2070,7 +2070,7 @@ const unsigned char s_78250E25D1929D4A842050738140787BE42541C6[] = { 108, 112, 104, 97, 95, 118, 97, 108, 117, 101, 0, 0, 0, 0, 2, 0, 0, 0, 36, 5, 0, 0, 4, 5, - 0, 0, 0, 0, 0, 0, 173, 144, + 0, 0, 0, 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 100, 113, 175, 29, 164, 71, @@ -2485,7 +2485,7 @@ const unsigned char s_7B67DD242152D35ACC079265FAD9D03DC98182DE[] = { 67, 95, 84, 101, 120, 116, 117, 114, 101, 48, 0, 0, 0, 0, 1, 0, 0, 0, 248, 3, 0, 0, 0, 5, - 0, 0, 0, 0, 0, 0, 173, 144, + 0, 0, 0, 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 11, 95, 74, 206, 145, 124, @@ -2869,7 +2869,7 @@ const unsigned char s_7CE5EE84ACB6110F7FA29152ECE3344CB6D6620D[] = { 99, 111, 108, 111, 114, 0, 0, 0, 0, 2, 0, 0, 0, 96, 4, 0, 0, 192, 4, 0, 0, 0, 0, 0, - 0, 173, 144, 0, 0, 0, 0, 0, + 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 157, 116, 105, 89, 118, 135, 249, 239, 42, 226, 184, @@ -3250,7 +3250,7 @@ const unsigned char s_7E1EEF397305D0BC2DCDBA4F2DAFBCBA1534E45C[] = { 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 1, 0, 0, 0, 52, 3, 0, 0, 40, 4, 0, 0, 0, - 0, 0, 0, 173, 144, 0, 0, 0, + 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 153, 8, 62, 201, 202, 170, 111, 182, 149, @@ -3584,7 +3584,7 @@ const unsigned char s_847DBFDDA6EC09C57E4ED43012AE2FB5CAC7D8D5[] = { 111, 108, 111, 114, 0, 0, 0, 0, 2, 0, 0, 0, 240, 4, 0, 0, 4, 5, 0, 0, 0, 0, 0, 0, -173, 144, 0, 0, 0, 0, 0, 0, +221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 134, 66, 128, 226, 107, 172, 247, 161, 241, 207, 89, 240, @@ -4001,7 +4001,7 @@ const unsigned char s_92BE325B516F887D2C928EDE20ADF428DB01C038[] = { 95, 118, 97, 108, 117, 101, 0, 0, 0, 0, 2, 0, 0, 0, 36, 5, 0, 0, 0, 5, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 100, 113, 175, 29, 164, 71, 177, 78, 120, 99, @@ -4330,842 +4330,10 @@ const unsigned char s_92BE325B516F887D2C928EDE20ADF428DB01C038[] = { 111, 110, 0, 171, 171, 171, }; -const unsigned char s_A2377A827972A5466DA8637681045D32DA8A817D[] = { +const unsigned char s_976D0E98457C40DFC2F0FBD00E30607C9E4CFDAE[] = { 166, 147, 0, 0, 142, 9, 2, 1, - 0, 128, 0, 0, 82, 139, 0, 0, - 10, 0, 0, 0, 97, 95, 112, 111, -115, 105, 116, 105, 111, 110, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 255, 255, 255, 255, 80, 139, - 0, 0, 10, 0, 0, 0, 97, 95, -116, 101, 120, 67, 111, 111, 114, 100, - 1, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 0, 0, 0, 0, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 1, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 0, 3, 0, 0, 0, 92, 139, 0, - 0, 242, 141, 0, 0, 12, 0, 0, - 0, 67, 67, 95, 77, 86, 80, 77, - 97, 116, 114, 105, 120, 0, 0, 0, - 0, 255, 255, 255, 255, 0, 0, 0, - 0, 4, 0, 0, 0, 94, 139, 0, - 0, 0, 0, 0, 0, 11, 0, 0, - 0, 67, 67, 95, 84, 101, 120, 116, -117, 114, 101, 48, 0, 0, 0, 0, - 0, 0, 0, 0, 255, 255, 255, 255, - 1, 0, 0, 0, 82, 139, 0, 0, -240, 141, 0, 0, 7, 0, 0, 0, -117, 95, 99, 111, 108, 111, 114, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 1, 0, 0, 0, 3, - 0, 0, 0, 12, 0, 0, 0, 67, - 67, 95, 77, 86, 80, 77, 97, 116, -114, 105, 120, 0, 0, 0, 0, 0, - 0, 0, 0, 11, 0, 0, 0, 67, - 67, 95, 84, 101, 120, 116, 117, 114, -101, 48, 0, 0, 0, 0, 1, 0, - 0, 0, 7, 0, 0, 0, 117, 95, - 99, 111, 108, 111, 114, 0, 0, 0, - 0, 2, 0, 0, 0, 96, 4, 0, - 0, 144, 4, 0, 0, 0, 0, 0, - 0, 173, 144, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 68, 88, 66, 67, 157, 116, 105, - 89, 118, 135, 249, 239, 42, 226, 184, - 78, 220, 105, 236, 28, 1, 0, 0, - 0, 96, 4, 0, 0, 6, 0, 0, - 0, 56, 0, 0, 0, 228, 0, 0, - 0, 252, 1, 0, 0, 120, 2, 0, - 0, 176, 3, 0, 0, 228, 3, 0, - 0, 65, 111, 110, 57, 164, 0, 0, - 0, 164, 0, 0, 0, 0, 2, 255, -255, 112, 0, 0, 0, 52, 0, 0, - 0, 1, 0, 40, 0, 0, 0, 52, - 0, 0, 0, 52, 0, 1, 0, 36, - 0, 0, 0, 52, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 1, 2, 255, -255, 31, 0, 0, 2, 0, 0, 0, -128, 0, 0, 3, 176, 31, 0, 0, - 2, 0, 0, 0, 144, 0, 8, 15, -160, 66, 0, 0, 3, 0, 0, 15, -128, 0, 0, 228, 176, 0, 8, 228, -160, 5, 0, 0, 3, 0, 0, 15, -128, 0, 0, 228, 128, 0, 0, 228, -160, 1, 0, 0, 2, 0, 8, 15, -128, 0, 0, 228, 128, 1, 0, 0, - 2, 1, 8, 15, 128, 0, 0, 228, -128, 1, 0, 0, 2, 2, 8, 15, -128, 0, 0, 228, 128, 1, 0, 0, - 2, 3, 8, 15, 128, 0, 0, 228, -128, 255, 255, 0, 0, 83, 72, 68, - 82, 16, 1, 0, 0, 64, 0, 0, - 0, 68, 0, 0, 0, 89, 0, 0, - 4, 70, 142, 32, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 90, 0, 0, - 3, 0, 96, 16, 0, 0, 0, 0, - 0, 88, 24, 0, 4, 0, 112, 16, - 0, 0, 0, 0, 0, 85, 85, 0, - 0, 98, 16, 0, 3, 50, 16, 16, - 0, 0, 0, 0, 0, 101, 0, 0, - 3, 242, 32, 16, 0, 0, 0, 0, - 0, 101, 0, 0, 3, 242, 32, 16, - 0, 1, 0, 0, 0, 101, 0, 0, - 3, 242, 32, 16, 0, 2, 0, 0, - 0, 101, 0, 0, 3, 242, 32, 16, - 0, 3, 0, 0, 0, 104, 0, 0, - 2, 1, 0, 0, 0, 69, 0, 0, - 9, 242, 0, 16, 0, 0, 0, 0, - 0, 70, 16, 16, 0, 0, 0, 0, - 0, 70, 126, 16, 0, 0, 0, 0, - 0, 0, 96, 16, 0, 0, 0, 0, - 0, 56, 0, 0, 8, 242, 0, 16, - 0, 0, 0, 0, 0, 70, 14, 16, - 0, 0, 0, 0, 0, 70, 142, 32, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 54, 0, 0, 5, 242, 32, 16, - 0, 0, 0, 0, 0, 70, 14, 16, - 0, 0, 0, 0, 0, 54, 0, 0, - 5, 242, 32, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 0, 0, 0, - 0, 54, 0, 0, 5, 242, 32, 16, - 0, 2, 0, 0, 0, 70, 14, 16, - 0, 0, 0, 0, 0, 54, 0, 0, - 5, 242, 32, 16, 0, 3, 0, 0, - 0, 70, 14, 16, 0, 0, 0, 0, - 0, 62, 0, 0, 1, 83, 84, 65, - 84, 116, 0, 0, 0, 7, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 5, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 4, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 82, 68, 69, 70, 48, 1, 0, - 0, 1, 0, 0, 0, 176, 0, 0, - 0, 3, 0, 0, 0, 28, 0, 0, - 0, 0, 4, 255, 255, 0, 65, 0, - 0, 252, 0, 0, 0, 124, 0, 0, - 0, 3, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 1, 0, 0, 0, 145, 0, 0, - 0, 2, 0, 0, 0, 5, 0, 0, - 0, 4, 0, 0, 0, 255, 255, 255, -255, 0, 0, 0, 0, 1, 0, 0, - 0, 13, 0, 0, 0, 166, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 115, 97, 109, -112, 108, 101, 114, 95, 95, 67, 67, - 95, 84, 101, 120, 116, 117, 114, 101, - 48, 0, 116, 101, 120, 116, 117, 114, -101, 95, 95, 67, 67, 95, 84, 101, -120, 116, 117, 114, 101, 48, 0, 36, - 71, 108, 111, 98, 97, 108, 115, 0, -171, 166, 0, 0, 0, 1, 0, 0, - 0, 200, 0, 0, 0, 16, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 224, 0, 0, 0, 0, 0, 0, - 0, 16, 0, 0, 0, 2, 0, 0, - 0, 236, 0, 0, 0, 0, 0, 0, - 0, 95, 117, 95, 99, 111, 108, 111, -114, 0, 171, 171, 171, 1, 0, 3, - 0, 1, 0, 4, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 77, 105, 99, -114, 111, 115, 111, 102, 116, 32, 40, - 82, 41, 32, 72, 76, 83, 76, 32, - 83, 104, 97, 100, 101, 114, 32, 67, -111, 109, 112, 105, 108, 101, 114, 32, - 54, 46, 51, 46, 57, 54, 48, 48, - 46, 49, 54, 51, 56, 52, 0, 171, -171, 73, 83, 71, 78, 44, 0, 0, - 0, 1, 0, 0, 0, 8, 0, 0, - 0, 32, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 3, 0, 0, - 0, 0, 0, 0, 0, 3, 3, 0, - 0, 84, 69, 88, 67, 79, 79, 82, - 68, 0, 171, 171, 171, 79, 83, 71, - 78, 116, 0, 0, 0, 4, 0, 0, - 0, 8, 0, 0, 0, 104, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 0, 0, 0, - 0, 15, 0, 0, 0, 104, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 1, 0, 0, - 0, 15, 0, 0, 0, 104, 0, 0, - 0, 2, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 2, 0, 0, - 0, 15, 0, 0, 0, 104, 0, 0, - 0, 3, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 15, 0, 0, 0, 83, 86, 95, - 84, 97, 114, 103, 101, 116, 0, 171, -171, 68, 88, 66, 67, 110, 14, 140, -120, 239, 110, 56, 78, 103, 37, 245, -162, 140, 151, 93, 223, 1, 0, 0, - 0, 144, 4, 0, 0, 6, 0, 0, - 0, 56, 0, 0, 0, 68, 1, 0, - 0, 156, 2, 0, 0, 24, 3, 0, - 0, 236, 3, 0, 0, 56, 4, 0, - 0, 65, 111, 110, 57, 4, 1, 0, - 0, 4, 1, 0, 0, 0, 2, 254, -255, 208, 0, 0, 0, 52, 0, 0, - 0, 1, 0, 36, 0, 0, 0, 48, - 0, 0, 0, 48, 0, 0, 0, 36, - 0, 1, 0, 48, 0, 0, 0, 0, - 0, 4, 0, 1, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 2, 254, -255, 81, 0, 0, 5, 5, 0, 15, -160, 0, 0, 0, 63, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 31, 0, 0, 2, 5, 0, 0, -128, 0, 0, 15, 144, 31, 0, 0, - 2, 5, 0, 1, 128, 1, 0, 15, -144, 9, 0, 0, 3, 0, 0, 1, -128, 3, 0, 228, 160, 0, 0, 228, -144, 9, 0, 0, 3, 0, 0, 2, -128, 4, 0, 228, 160, 0, 0, 228, -144, 2, 0, 0, 3, 0, 0, 1, -128, 0, 0, 85, 128, 0, 0, 0, -128, 5, 0, 0, 3, 0, 0, 4, -192, 0, 0, 0, 128, 5, 0, 0, -160, 9, 0, 0, 3, 0, 0, 1, -128, 2, 0, 228, 160, 0, 0, 228, -144, 1, 0, 0, 2, 1, 0, 2, -128, 0, 0, 0, 129, 9, 0, 0, - 3, 1, 0, 1, 128, 1, 0, 228, -160, 0, 0, 228, 144, 4, 0, 0, - 4, 0, 0, 3, 192, 0, 0, 85, -128, 0, 0, 228, 160, 1, 0, 228, -128, 1, 0, 0, 2, 0, 0, 8, -192, 0, 0, 85, 128, 1, 0, 0, - 2, 0, 0, 3, 224, 1, 0, 228, -144, 255, 255, 0, 0, 83, 72, 68, - 82, 80, 1, 0, 0, 64, 0, 1, - 0, 84, 0, 0, 0, 89, 0, 0, - 4, 70, 142, 32, 0, 0, 0, 0, - 0, 4, 0, 0, 0, 95, 0, 0, - 3, 242, 16, 16, 0, 0, 0, 0, - 0, 95, 0, 0, 3, 50, 16, 16, - 0, 1, 0, 0, 0, 101, 0, 0, - 3, 50, 32, 16, 0, 0, 0, 0, - 0, 103, 0, 0, 4, 242, 32, 16, - 0, 1, 0, 0, 0, 1, 0, 0, - 0, 104, 0, 0, 2, 1, 0, 0, - 0, 54, 0, 0, 5, 50, 32, 16, - 0, 0, 0, 0, 0, 70, 16, 16, - 0, 1, 0, 0, 0, 17, 0, 0, - 8, 18, 0, 16, 0, 0, 0, 0, - 0, 70, 142, 32, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 70, 30, 16, - 0, 0, 0, 0, 0, 54, 0, 0, - 6, 34, 32, 16, 0, 1, 0, 0, - 0, 10, 0, 16, 128, 65, 0, 0, - 0, 0, 0, 0, 0, 17, 0, 0, - 8, 18, 0, 16, 0, 0, 0, 0, - 0, 70, 142, 32, 0, 0, 0, 0, - 0, 2, 0, 0, 0, 70, 30, 16, - 0, 0, 0, 0, 0, 17, 0, 0, - 8, 34, 0, 16, 0, 0, 0, 0, - 0, 70, 142, 32, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 70, 30, 16, - 0, 0, 0, 0, 0, 0, 0, 0, - 7, 18, 0, 16, 0, 0, 0, 0, - 0, 26, 0, 16, 0, 0, 0, 0, - 0, 10, 0, 16, 0, 0, 0, 0, - 0, 54, 0, 0, 5, 130, 32, 16, - 0, 1, 0, 0, 0, 26, 0, 16, - 0, 0, 0, 0, 0, 56, 0, 0, - 7, 66, 32, 16, 0, 1, 0, 0, - 0, 10, 0, 16, 0, 0, 0, 0, - 0, 1, 64, 0, 0, 0, 0, 0, - 63, 17, 0, 0, 8, 18, 32, 16, - 0, 1, 0, 0, 0, 70, 142, 32, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 70, 30, 16, 0, 0, 0, 0, - 0, 62, 0, 0, 1, 83, 84, 65, - 84, 116, 0, 0, 0, 10, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 4, 0, 0, 0, 7, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 2, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 82, 68, 69, 70, 204, 0, 0, - 0, 1, 0, 0, 0, 72, 0, 0, - 0, 1, 0, 0, 0, 28, 0, 0, - 0, 0, 4, 254, 255, 0, 65, 0, - 0, 152, 0, 0, 0, 60, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 36, 71, 108, -111, 98, 97, 108, 115, 0, 171, 171, -171, 60, 0, 0, 0, 1, 0, 0, - 0, 96, 0, 0, 0, 64, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 120, 0, 0, 0, 0, 0, 0, - 0, 64, 0, 0, 0, 2, 0, 0, - 0, 136, 0, 0, 0, 0, 0, 0, - 0, 95, 67, 67, 95, 77, 86, 80, - 77, 97, 116, 114, 105, 120, 0, 171, -171, 3, 0, 3, 0, 4, 0, 4, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 77, 105, 99, 114, 111, 115, 111, -102, 116, 32, 40, 82, 41, 32, 72, - 76, 83, 76, 32, 83, 104, 97, 100, -101, 114, 32, 67, 111, 109, 112, 105, -108, 101, 114, 32, 54, 46, 51, 46, - 57, 54, 48, 48, 46, 49, 54, 51, - 56, 52, 0, 171, 171, 73, 83, 71, - 78, 68, 0, 0, 0, 2, 0, 0, - 0, 8, 0, 0, 0, 56, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 0, 0, 0, - 0, 15, 15, 0, 0, 56, 0, 0, - 0, 1, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 1, 0, 0, - 0, 3, 3, 0, 0, 84, 69, 88, - 67, 79, 79, 82, 68, 0, 171, 171, -171, 79, 83, 71, 78, 80, 0, 0, - 0, 2, 0, 0, 0, 8, 0, 0, - 0, 56, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 3, 0, 0, - 0, 0, 0, 0, 0, 3, 12, 0, - 0, 65, 0, 0, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 3, 0, 0, - 0, 1, 0, 0, 0, 15, 0, 0, - 0, 84, 69, 88, 67, 79, 79, 82, - 68, 0, 83, 86, 95, 80, 111, 115, -105, 116, 105, 111, 110, 0, 171, 171, -171, -}; - -const unsigned char s_B5E27B4F3CF7236633255B28CBA530D6EE5CED86[] = { - -166, 147, 0, 0, 142, 9, 2, 1, - 0, 128, 0, 0, 82, 139, 0, 0, - 10, 0, 0, 0, 97, 95, 112, 111, -115, 105, 116, 105, 111, 110, 1, 0, - 0, 0, 82, 139, 0, 0, 7, 0, - 0, 0, 97, 95, 99, 111, 108, 111, -114, 0, 0, 0, 0, 80, 139, 0, - 0, 10, 0, 0, 0, 97, 95, 116, -101, 120, 67, 111, 111, 114, 100, 2, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 0, - 0, 0, 0, 0, 0, 0, 0, 255, -255, 255, 255, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 1, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 1, 0, 0, 0, 0, - 3, 0, 0, 0, 92, 139, 0, 0, -242, 141, 0, 0, 12, 0, 0, 0, - 67, 67, 95, 77, 86, 80, 77, 97, -116, 114, 105, 120, 0, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 4, 0, 0, 0, 94, 139, 0, 0, - 0, 0, 0, 0, 11, 0, 0, 0, - 67, 67, 95, 84, 101, 120, 116, 117, -114, 101, 48, 0, 0, 0, 0, 0, - 0, 0, 0, 255, 255, 255, 255, 1, - 0, 0, 0, 82, 139, 0, 0, 240, -141, 0, 0, 11, 0, 0, 0, 117, - 95, 116, 101, 120, 116, 67, 111, 108, -111, 114, 0, 0, 0, 0, 0, 0, - 0, 0, 255, 255, 255, 255, 1, 0, - 0, 0, 3, 0, 0, 0, 12, 0, - 0, 0, 67, 67, 95, 77, 86, 80, - 77, 97, 116, 114, 105, 120, 0, 0, - 0, 0, 0, 0, 0, 0, 11, 0, - 0, 0, 67, 67, 95, 84, 101, 120, -116, 117, 114, 101, 48, 0, 0, 0, - 0, 1, 0, 0, 0, 11, 0, 0, - 0, 117, 95, 116, 101, 120, 116, 67, -111, 108, 111, 114, 0, 0, 0, 0, - 2, 0, 0, 0, 240, 5, 0, 0, - 4, 5, 0, 0, 0, 0, 0, 0, -173, 144, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 68, 88, 66, 67, 223, 173, 203, 80, -172, 13, 170, 215, 168, 128, 228, 5, - 62, 250, 21, 248, 1, 0, 0, 0, -240, 5, 0, 0, 6, 0, 0, 0, - 56, 0, 0, 0, 124, 1, 0, 0, -112, 3, 0, 0, 236, 3, 0, 0, - 40, 5, 0, 0, 116, 5, 0, 0, - 65, 111, 110, 57, 60, 1, 0, 0, - 60, 1, 0, 0, 0, 2, 255, 255, - 8, 1, 0, 0, 52, 0, 0, 0, - 1, 0, 40, 0, 0, 0, 52, 0, - 0, 0, 52, 0, 1, 0, 36, 0, - 0, 0, 52, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 1, 2, 255, 255, - 81, 0, 0, 5, 1, 0, 15, 160, - 31, 133, 235, 190, 254, 255, 71, 65, - 0, 0, 0, 192, 0, 0, 64, 64, - 31, 0, 0, 2, 0, 0, 0, 128, - 0, 0, 15, 176, 31, 0, 0, 2, - 0, 0, 0, 128, 1, 0, 3, 176, - 31, 0, 0, 2, 0, 0, 0, 144, - 0, 8, 15, 160, 66, 0, 0, 3, - 0, 0, 15, 128, 1, 0, 228, 176, - 0, 8, 228, 160, 2, 0, 0, 3, - 0, 0, 1, 128, 0, 0, 255, 128, - 1, 0, 0, 160, 5, 0, 0, 3, - 0, 0, 17, 128, 0, 0, 0, 128, - 1, 0, 85, 160, 4, 0, 0, 4, - 0, 0, 2, 128, 0, 0, 0, 128, - 1, 0, 170, 160, 1, 0, 255, 160, - 5, 0, 0, 3, 0, 0, 1, 128, - 0, 0, 0, 128, 0, 0, 0, 128, - 5, 0, 0, 3, 0, 0, 1, 128, - 0, 0, 0, 128, 0, 0, 85, 128, - 5, 0, 0, 3, 0, 0, 1, 128, - 0, 0, 0, 128, 0, 0, 255, 160, - 5, 0, 0, 3, 0, 0, 8, 128, - 0, 0, 0, 128, 0, 0, 255, 176, - 5, 0, 0, 3, 0, 0, 7, 128, - 0, 0, 228, 176, 0, 0, 228, 160, - 1, 0, 0, 2, 0, 8, 15, 128, - 0, 0, 228, 128, 1, 0, 0, 2, - 1, 8, 15, 128, 0, 0, 228, 128, - 1, 0, 0, 2, 2, 8, 15, 128, - 0, 0, 228, 128, 1, 0, 0, 2, - 3, 8, 15, 128, 0, 0, 228, 128, -255, 255, 0, 0, 83, 72, 68, 82, -236, 1, 0, 0, 64, 0, 0, 0, -123, 0, 0, 0, 89, 0, 0, 4, - 70, 142, 32, 0, 0, 0, 0, 0, - 1, 0, 0, 0, 90, 0, 0, 3, - 0, 96, 16, 0, 0, 0, 0, 0, - 88, 24, 0, 4, 0, 112, 16, 0, - 0, 0, 0, 0, 85, 85, 0, 0, - 98, 16, 0, 3, 242, 16, 16, 0, - 0, 0, 0, 0, 98, 16, 0, 3, - 50, 16, 16, 0, 1, 0, 0, 0, -101, 0, 0, 3, 242, 32, 16, 0, - 0, 0, 0, 0, 101, 0, 0, 3, -242, 32, 16, 0, 1, 0, 0, 0, -101, 0, 0, 3, 242, 32, 16, 0, - 2, 0, 0, 0, 101, 0, 0, 3, -242, 32, 16, 0, 3, 0, 0, 0, -104, 0, 0, 2, 1, 0, 0, 0, - 69, 0, 0, 9, 242, 0, 16, 0, - 0, 0, 0, 0, 70, 16, 16, 0, - 1, 0, 0, 0, 70, 126, 16, 0, - 0, 0, 0, 0, 0, 96, 16, 0, - 0, 0, 0, 0, 0, 0, 0, 7, - 18, 0, 16, 0, 0, 0, 0, 0, - 58, 0, 16, 0, 0, 0, 0, 0, - 1, 64, 0, 0, 31, 133, 235, 190, - 56, 32, 0, 7, 18, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 1, 64, 0, 0, -254, 255, 71, 65, 50, 0, 0, 9, - 34, 0, 16, 0, 0, 0, 0, 0, - 10, 0, 16, 0, 0, 0, 0, 0, - 1, 64, 0, 0, 0, 0, 0, 192, - 1, 64, 0, 0, 0, 0, 64, 64, - 56, 0, 0, 7, 18, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 56, 0, 0, 7, - 18, 0, 16, 0, 0, 0, 0, 0, - 10, 0, 16, 0, 0, 0, 0, 0, - 26, 0, 16, 0, 0, 0, 0, 0, - 56, 0, 0, 8, 18, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 58, 128, 32, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 56, 0, 0, 7, 130, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 58, 16, 16, 0, - 0, 0, 0, 0, 56, 0, 0, 8, -114, 0, 16, 0, 0, 0, 0, 0, - 70, 18, 16, 0, 0, 0, 0, 0, - 70, 130, 32, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 54, 0, 0, 5, -242, 32, 16, 0, 0, 0, 0, 0, - 70, 14, 16, 0, 0, 0, 0, 0, - 54, 0, 0, 5, 242, 32, 16, 0, - 1, 0, 0, 0, 70, 14, 16, 0, - 0, 0, 0, 0, 54, 0, 0, 5, -242, 32, 16, 0, 2, 0, 0, 0, - 70, 14, 16, 0, 0, 0, 0, 0, - 54, 0, 0, 5, 242, 32, 16, 0, - 3, 0, 0, 0, 70, 14, 16, 0, - 0, 0, 0, 0, 62, 0, 0, 1, - 83, 84, 65, 84, 116, 0, 0, 0, - 14, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 6, 0, 0, 0, - 8, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 1, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 4, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 82, 68, 69, 70, - 52, 1, 0, 0, 1, 0, 0, 0, -176, 0, 0, 0, 3, 0, 0, 0, - 28, 0, 0, 0, 0, 4, 255, 255, - 0, 65, 0, 0, 0, 1, 0, 0, -124, 0, 0, 0, 3, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 1, 0, 0, 0, 1, 0, 0, 0, -145, 0, 0, 0, 2, 0, 0, 0, - 5, 0, 0, 0, 4, 0, 0, 0, -255, 255, 255, 255, 0, 0, 0, 0, - 1, 0, 0, 0, 13, 0, 0, 0, -166, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 1, 0, 0, 0, 0, 0, 0, 0, -115, 97, 109, 112, 108, 101, 114, 95, - 95, 67, 67, 95, 84, 101, 120, 116, -117, 114, 101, 48, 0, 116, 101, 120, -116, 117, 114, 101, 95, 95, 67, 67, - 95, 84, 101, 120, 116, 117, 114, 101, - 48, 0, 36, 71, 108, 111, 98, 97, -108, 115, 0, 171, 166, 0, 0, 0, - 1, 0, 0, 0, 200, 0, 0, 0, - 16, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 224, 0, 0, 0, - 0, 0, 0, 0, 16, 0, 0, 0, - 2, 0, 0, 0, 240, 0, 0, 0, - 0, 0, 0, 0, 95, 117, 95, 116, -101, 120, 116, 67, 111, 108, 111, 114, - 0, 171, 171, 171, 1, 0, 3, 0, - 1, 0, 4, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 77, 105, 99, 114, -111, 115, 111, 102, 116, 32, 40, 82, - 41, 32, 72, 76, 83, 76, 32, 83, -104, 97, 100, 101, 114, 32, 67, 111, -109, 112, 105, 108, 101, 114, 32, 54, - 46, 51, 46, 57, 54, 48, 48, 46, - 49, 54, 51, 56, 52, 0, 171, 171, - 73, 83, 71, 78, 68, 0, 0, 0, - 2, 0, 0, 0, 8, 0, 0, 0, - 56, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 0, 0, 0, 0, 15, 15, 0, 0, - 56, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 1, 0, 0, 0, 3, 3, 0, 0, - 84, 69, 88, 67, 79, 79, 82, 68, - 0, 171, 171, 171, 79, 83, 71, 78, -116, 0, 0, 0, 4, 0, 0, 0, - 8, 0, 0, 0, 104, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 0, 0, 0, 0, - 15, 0, 0, 0, 104, 0, 0, 0, - 1, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 1, 0, 0, 0, - 15, 0, 0, 0, 104, 0, 0, 0, - 2, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 2, 0, 0, 0, - 15, 0, 0, 0, 104, 0, 0, 0, - 3, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 3, 0, 0, 0, - 15, 0, 0, 0, 83, 86, 95, 84, - 97, 114, 103, 101, 116, 0, 171, 171, - 68, 88, 66, 67, 235, 56, 180, 223, -125, 231, 231, 218, 70, 75, 12, 63, -200, 233, 69, 121, 1, 0, 0, 0, - 4, 5, 0, 0, 6, 0, 0, 0, - 56, 0, 0, 0, 92, 1, 0, 0, -224, 2, 0, 0, 92, 3, 0, 0, - 48, 4, 0, 0, 148, 4, 0, 0, - 65, 111, 110, 57, 28, 1, 0, 0, - 28, 1, 0, 0, 0, 2, 254, 255, -232, 0, 0, 0, 52, 0, 0, 0, - 1, 0, 36, 0, 0, 0, 48, 0, - 0, 0, 48, 0, 0, 0, 36, 0, - 1, 0, 48, 0, 0, 0, 0, 0, - 4, 0, 1, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1, 2, 254, 255, - 81, 0, 0, 5, 5, 0, 15, 160, - 0, 0, 0, 63, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 31, 0, 0, 2, 5, 0, 0, 128, - 0, 0, 15, 144, 31, 0, 0, 2, - 5, 0, 1, 128, 1, 0, 15, 144, - 31, 0, 0, 2, 5, 0, 2, 128, - 2, 0, 15, 144, 9, 0, 0, 3, - 0, 0, 1, 128, 3, 0, 228, 160, - 1, 0, 228, 144, 9, 0, 0, 3, - 0, 0, 2, 128, 4, 0, 228, 160, - 1, 0, 228, 144, 2, 0, 0, 3, - 0, 0, 1, 128, 0, 0, 85, 128, - 0, 0, 0, 128, 5, 0, 0, 3, - 0, 0, 4, 192, 0, 0, 0, 128, - 5, 0, 0, 160, 9, 0, 0, 3, - 0, 0, 1, 128, 2, 0, 228, 160, - 1, 0, 228, 144, 1, 0, 0, 2, - 1, 0, 2, 128, 0, 0, 0, 129, - 9, 0, 0, 3, 1, 0, 1, 128, - 1, 0, 228, 160, 1, 0, 228, 144, - 4, 0, 0, 4, 0, 0, 3, 192, - 0, 0, 85, 128, 0, 0, 228, 160, - 1, 0, 228, 128, 1, 0, 0, 2, - 0, 0, 8, 192, 0, 0, 85, 128, - 1, 0, 0, 2, 0, 0, 15, 224, - 0, 0, 228, 144, 1, 0, 0, 2, - 1, 0, 3, 224, 2, 0, 228, 144, -255, 255, 0, 0, 83, 72, 68, 82, -124, 1, 0, 0, 64, 0, 1, 0, - 95, 0, 0, 0, 89, 0, 0, 4, - 70, 142, 32, 0, 0, 0, 0, 0, - 4, 0, 0, 0, 95, 0, 0, 3, -242, 16, 16, 0, 0, 0, 0, 0, - 95, 0, 0, 3, 242, 16, 16, 0, - 1, 0, 0, 0, 95, 0, 0, 3, - 50, 16, 16, 0, 2, 0, 0, 0, -101, 0, 0, 3, 242, 32, 16, 0, - 0, 0, 0, 0, 101, 0, 0, 3, - 50, 32, 16, 0, 1, 0, 0, 0, -103, 0, 0, 4, 242, 32, 16, 0, - 2, 0, 0, 0, 1, 0, 0, 0, -104, 0, 0, 2, 1, 0, 0, 0, - 54, 0, 0, 5, 242, 32, 16, 0, - 0, 0, 0, 0, 70, 30, 16, 0, - 0, 0, 0, 0, 54, 0, 0, 5, - 50, 32, 16, 0, 1, 0, 0, 0, - 70, 16, 16, 0, 2, 0, 0, 0, - 17, 0, 0, 8, 18, 0, 16, 0, - 0, 0, 0, 0, 70, 142, 32, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 70, 30, 16, 0, 1, 0, 0, 0, - 54, 0, 0, 6, 34, 32, 16, 0, - 2, 0, 0, 0, 10, 0, 16, 128, - 65, 0, 0, 0, 0, 0, 0, 0, - 17, 0, 0, 8, 18, 0, 16, 0, - 0, 0, 0, 0, 70, 142, 32, 0, - 0, 0, 0, 0, 2, 0, 0, 0, - 70, 30, 16, 0, 1, 0, 0, 0, - 17, 0, 0, 8, 34, 0, 16, 0, - 0, 0, 0, 0, 70, 142, 32, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 70, 30, 16, 0, 1, 0, 0, 0, - 0, 0, 0, 7, 18, 0, 16, 0, - 0, 0, 0, 0, 26, 0, 16, 0, - 0, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 54, 0, 0, 5, -130, 32, 16, 0, 2, 0, 0, 0, - 26, 0, 16, 0, 0, 0, 0, 0, - 56, 0, 0, 7, 66, 32, 16, 0, - 2, 0, 0, 0, 10, 0, 16, 0, - 0, 0, 0, 0, 1, 64, 0, 0, - 0, 0, 0, 63, 17, 0, 0, 8, - 18, 32, 16, 0, 2, 0, 0, 0, - 70, 142, 32, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 70, 30, 16, 0, - 1, 0, 0, 0, 62, 0, 0, 1, - 83, 84, 65, 84, 116, 0, 0, 0, - 11, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 6, 0, 0, 0, - 7, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 82, 68, 69, 70, -204, 0, 0, 0, 1, 0, 0, 0, - 72, 0, 0, 0, 1, 0, 0, 0, - 28, 0, 0, 0, 0, 4, 254, 255, - 0, 65, 0, 0, 152, 0, 0, 0, - 60, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 1, 0, 0, 0, 0, 0, 0, 0, - 36, 71, 108, 111, 98, 97, 108, 115, - 0, 171, 171, 171, 60, 0, 0, 0, - 1, 0, 0, 0, 96, 0, 0, 0, - 64, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 120, 0, 0, 0, - 0, 0, 0, 0, 64, 0, 0, 0, - 2, 0, 0, 0, 136, 0, 0, 0, - 0, 0, 0, 0, 95, 67, 67, 95, - 77, 86, 80, 77, 97, 116, 114, 105, -120, 0, 171, 171, 3, 0, 3, 0, - 4, 0, 4, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 77, 105, 99, 114, -111, 115, 111, 102, 116, 32, 40, 82, - 41, 32, 72, 76, 83, 76, 32, 83, -104, 97, 100, 101, 114, 32, 67, 111, -109, 112, 105, 108, 101, 114, 32, 54, - 46, 51, 46, 57, 54, 48, 48, 46, - 49, 54, 51, 56, 52, 0, 171, 171, - 73, 83, 71, 78, 92, 0, 0, 0, - 3, 0, 0, 0, 8, 0, 0, 0, - 80, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 0, 0, 0, 0, 15, 15, 0, 0, - 80, 0, 0, 0, 1, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 1, 0, 0, 0, 15, 15, 0, 0, - 80, 0, 0, 0, 2, 0, 0, 0, - 0, 0, 0, 0, 3, 0, 0, 0, - 2, 0, 0, 0, 3, 3, 0, 0, - 84, 69, 88, 67, 79, 79, 82, 68, - 0, 171, 171, 171, 79, 83, 71, 78, -104, 0, 0, 0, 3, 0, 0, 0, - 8, 0, 0, 0, 80, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 0, 0, 0, 0, - 15, 0, 0, 0, 80, 0, 0, 0, - 1, 0, 0, 0, 0, 0, 0, 0, - 3, 0, 0, 0, 1, 0, 0, 0, - 3, 12, 0, 0, 89, 0, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, - 3, 0, 0, 0, 2, 0, 0, 0, - 15, 0, 0, 0, 84, 69, 88, 67, - 79, 79, 82, 68, 0, 83, 86, 95, - 80, 111, 115, 105, 116, 105, 111, 110, - 0, 171, 171, 171, -}; - -const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { - -166, 147, 0, 0, 142, 9, 2, 1, - 0, 128, 0, 0, 82, 139, 0, 0, + 0, 128, 0, 0, 81, 139, 0, 0, 10, 0, 0, 0, 97, 95, 112, 111, 115, 105, 116, 105, 111, 110, 2, 0, 0, 0, 82, 139, 0, 0, 12, 0, @@ -5869,8 +5037,8 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 0, 0, 7, 0, 0, 0, 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 3, 0, 0, 0, 96, 4, 0, - 0, 120, 10, 0, 0, 0, 0, 0, - 0, 173, 144, 0, 0, 0, 0, 0, + 0, 148, 13, 0, 0, 0, 0, 0, + 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 157, 116, 105, 89, 118, 135, 249, 239, 42, 226, 184, @@ -6012,16 +5180,16 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 0, 3, 0, 0, 0, 3, 0, 0, 0, 15, 0, 0, 0, 83, 86, 95, 84, 97, 114, 103, 101, 116, 0, 171, -171, 68, 88, 66, 67, 107, 238, 81, -172, 139, 110, 118, 99, 56, 54, 8, -248, 83, 176, 136, 78, 1, 0, 0, - 0, 120, 10, 0, 0, 6, 0, 0, - 0, 56, 0, 0, 0, 56, 3, 0, - 0, 24, 8, 0, 0, 148, 8, 0, - 0, 164, 9, 0, 0, 32, 10, 0, - 0, 65, 111, 110, 57, 248, 2, 0, - 0, 248, 2, 0, 0, 0, 2, 254, -255, 196, 2, 0, 0, 52, 0, 0, +171, 68, 88, 66, 67, 32, 233, 161, + 94, 234, 31, 215, 162, 44, 12, 38, +161, 61, 0, 59, 104, 1, 0, 0, + 0, 148, 13, 0, 0, 6, 0, 0, + 0, 56, 0, 0, 0, 204, 4, 0, + 0, 52, 11, 0, 0, 176, 11, 0, + 0, 192, 12, 0, 0, 60, 13, 0, + 0, 65, 111, 110, 57, 140, 4, 0, + 0, 140, 4, 0, 0, 0, 2, 254, +255, 88, 4, 0, 0, 52, 0, 0, 0, 1, 0, 36, 0, 0, 0, 48, 0, 0, 0, 48, 0, 0, 0, 36, 0, 1, 0, 48, 0, 0, 0, 0, @@ -6029,8 +5197,8 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 0, 0, 0, 184, 0, 1, 2, 254, 255, 81, 0, 0, 5, 185, 0, 15, 160, 0, 0, 64, 64, 0, 0, 0, - 63, 0, 0, 0, 0, 0, 0, 0, - 0, 81, 0, 0, 5, 186, 0, 15, + 0, 0, 0, 128, 63, 0, 0, 0, + 63, 81, 0, 0, 5, 186, 0, 15, 160, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 0, 0, 0, 0, 0, 0, 31, 0, 0, 2, 5, 0, 0, @@ -6039,97 +5207,330 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 144, 31, 0, 0, 2, 5, 0, 2, 128, 2, 0, 15, 144, 31, 0, 0, 2, 5, 0, 3, 128, 3, 0, 15, -144, 12, 0, 0, 3, 0, 0, 15, -128, 0, 0, 228, 144, 0, 0, 228, -145, 19, 0, 0, 2, 1, 0, 15, -128, 0, 0, 228, 144, 2, 0, 0, - 3, 2, 0, 15, 128, 1, 0, 228, -129, 0, 0, 228, 144, 12, 0, 0, - 3, 1, 0, 15, 128, 1, 0, 228, -129, 1, 0, 228, 128, 4, 0, 0, - 4, 0, 0, 15, 128, 0, 0, 228, -128, 1, 0, 228, 128, 2, 0, 228, -128, 5, 0, 0, 3, 0, 0, 15, -128, 0, 0, 228, 128, 185, 0, 0, -160, 46, 0, 0, 2, 0, 0, 15, -176, 0, 0, 225, 128, 5, 0, 0, - 4, 1, 0, 15, 128, 1, 0, 85, +144, 19, 0, 0, 2, 0, 0, 1, +128, 0, 0, 0, 144, 2, 0, 0, + 3, 0, 0, 2, 128, 0, 0, 0, +129, 0, 0, 0, 144, 12, 0, 0, + 3, 0, 0, 4, 128, 0, 0, 0, +144, 0, 0, 0, 145, 12, 0, 0, + 3, 0, 0, 1, 128, 0, 0, 0, +129, 0, 0, 0, 128, 4, 0, 0, + 4, 0, 0, 1, 128, 0, 0, 170, +128, 0, 0, 0, 128, 0, 0, 85, +128, 5, 0, 0, 3, 0, 0, 1, +128, 0, 0, 0, 128, 185, 0, 0, +160, 46, 0, 0, 2, 0, 0, 1, +176, 0, 0, 0, 128, 5, 0, 0, + 4, 0, 0, 15, 128, 1, 0, 0, 144, 4, 32, 228, 160, 0, 0, 0, -176, 4, 0, 0, 5, 1, 0, 15, -128, 4, 32, 228, 160, 0, 0, 85, -176, 1, 0, 0, 144, 1, 0, 228, -128, 4, 0, 0, 5, 0, 0, 15, -128, 4, 32, 228, 160, 0, 0, 170, -176, 1, 0, 170, 144, 1, 0, 228, -128, 4, 0, 0, 5, 0, 0, 15, -128, 4, 32, 228, 160, 0, 0, 255, -176, 1, 0, 255, 144, 0, 0, 228, -128, 9, 0, 0, 3, 0, 0, 1, -128, 2, 0, 228, 144, 0, 0, 228, -128, 5, 0, 0, 4, 1, 0, 15, -128, 1, 0, 85, 144, 5, 32, 228, +176, 5, 0, 0, 4, 1, 0, 15, +128, 1, 0, 0, 144, 5, 32, 228, 160, 0, 0, 0, 176, 5, 0, 0, - 4, 2, 0, 15, 128, 1, 0, 85, + 4, 2, 0, 15, 128, 1, 0, 0, 144, 6, 32, 228, 160, 0, 0, 0, -176, 4, 0, 0, 5, 2, 0, 15, -128, 6, 32, 228, 160, 0, 0, 85, -176, 1, 0, 0, 144, 2, 0, 228, +176, 41, 0, 4, 2, 185, 0, 85, +160, 1, 0, 85, 144, 19, 0, 0, + 2, 3, 0, 1, 128, 0, 0, 85, +144, 2, 0, 0, 3, 3, 0, 2, +128, 3, 0, 0, 129, 0, 0, 85, +144, 12, 0, 0, 3, 3, 0, 4, +128, 0, 0, 85, 144, 0, 0, 85, +145, 12, 0, 0, 3, 3, 0, 1, +128, 3, 0, 0, 129, 3, 0, 0, +128, 4, 0, 0, 4, 3, 0, 1, +128, 3, 0, 170, 128, 3, 0, 0, +128, 3, 0, 85, 128, 5, 0, 0, + 3, 3, 0, 1, 128, 3, 0, 0, +128, 185, 0, 0, 160, 46, 0, 0, + 2, 0, 0, 1, 176, 3, 0, 0, +128, 4, 0, 0, 5, 0, 0, 15, +128, 4, 32, 228, 160, 0, 0, 0, +176, 1, 0, 85, 144, 0, 0, 228, 128, 4, 0, 0, 5, 1, 0, 15, -128, 5, 32, 228, 160, 0, 0, 85, -176, 1, 0, 0, 144, 1, 0, 228, +128, 5, 32, 228, 160, 0, 0, 0, +176, 1, 0, 85, 144, 1, 0, 228, +128, 4, 0, 0, 5, 2, 0, 15, +128, 6, 32, 228, 160, 0, 0, 0, +176, 1, 0, 85, 144, 2, 0, 228, +128, 42, 0, 0, 0, 43, 0, 0, + 0, 41, 0, 4, 2, 185, 0, 85, +160, 1, 0, 170, 144, 19, 0, 0, + 2, 3, 0, 1, 128, 0, 0, 170, +144, 2, 0, 0, 3, 3, 0, 2, +128, 3, 0, 0, 129, 0, 0, 170, +144, 12, 0, 0, 3, 3, 0, 4, +128, 0, 0, 170, 144, 0, 0, 170, +145, 12, 0, 0, 3, 3, 0, 1, +128, 3, 0, 0, 129, 3, 0, 0, +128, 4, 0, 0, 4, 3, 0, 1, +128, 3, 0, 170, 128, 3, 0, 0, +128, 3, 0, 85, 128, 5, 0, 0, + 3, 3, 0, 1, 128, 3, 0, 0, +128, 185, 0, 0, 160, 46, 0, 0, + 2, 0, 0, 1, 176, 3, 0, 0, +128, 4, 0, 0, 5, 0, 0, 15, +128, 4, 32, 228, 160, 0, 0, 0, +176, 1, 0, 170, 144, 0, 0, 228, 128, 4, 0, 0, 5, 1, 0, 15, -128, 5, 32, 228, 160, 0, 0, 170, +128, 5, 32, 228, 160, 0, 0, 0, 176, 1, 0, 170, 144, 1, 0, 228, 128, 4, 0, 0, 5, 2, 0, 15, -128, 6, 32, 228, 160, 0, 0, 170, +128, 6, 32, 228, 160, 0, 0, 0, 176, 1, 0, 170, 144, 2, 0, 228, -128, 4, 0, 0, 5, 2, 0, 15, -128, 6, 32, 228, 160, 0, 0, 255, -176, 1, 0, 255, 144, 2, 0, 228, +128, 42, 0, 0, 0, 43, 0, 0, + 0, 41, 0, 4, 2, 185, 0, 85, +160, 1, 0, 255, 144, 19, 0, 0, + 2, 3, 0, 1, 128, 0, 0, 255, +144, 2, 0, 0, 3, 3, 0, 2, +128, 3, 0, 0, 129, 0, 0, 255, +144, 12, 0, 0, 3, 3, 0, 4, +128, 0, 0, 255, 144, 0, 0, 255, +145, 12, 0, 0, 3, 3, 0, 1, +128, 3, 0, 0, 129, 3, 0, 0, +128, 4, 0, 0, 4, 3, 0, 1, +128, 3, 0, 170, 128, 3, 0, 0, +128, 3, 0, 85, 128, 5, 0, 0, + 3, 3, 0, 1, 128, 3, 0, 0, +128, 185, 0, 0, 160, 46, 0, 0, + 2, 0, 0, 1, 176, 3, 0, 0, +128, 4, 0, 0, 5, 0, 0, 15, +128, 4, 32, 228, 160, 0, 0, 0, +176, 1, 0, 255, 144, 0, 0, 228, 128, 4, 0, 0, 5, 1, 0, 15, -128, 5, 32, 228, 160, 0, 0, 255, +128, 5, 32, 228, 160, 0, 0, 0, 176, 1, 0, 255, 144, 1, 0, 228, -128, 9, 0, 0, 3, 0, 0, 2, -128, 2, 0, 228, 144, 1, 0, 228, -128, 9, 0, 0, 3, 0, 0, 4, -128, 2, 0, 228, 144, 2, 0, 228, -128, 1, 0, 0, 2, 0, 0, 8, -128, 2, 0, 255, 144, 9, 0, 0, - 3, 1, 0, 1, 128, 2, 0, 228, -160, 0, 0, 228, 128, 9, 0, 0, - 3, 1, 0, 2, 128, 3, 0, 228, -160, 0, 0, 228, 128, 2, 0, 0, - 3, 1, 0, 1, 128, 1, 0, 85, -128, 1, 0, 0, 128, 5, 0, 0, - 3, 0, 0, 4, 192, 1, 0, 0, -128, 185, 0, 85, 160, 9, 0, 0, - 3, 1, 0, 1, 128, 1, 0, 228, -160, 0, 0, 228, 128, 9, 0, 0, - 3, 0, 0, 1, 128, 0, 0, 228, -160, 0, 0, 228, 128, 1, 0, 0, - 2, 0, 0, 2, 128, 1, 0, 0, -129, 4, 0, 0, 4, 0, 0, 3, -192, 1, 0, 85, 128, 184, 0, 228, -160, 0, 0, 228, 128, 1, 0, 0, - 2, 0, 0, 8, 192, 1, 0, 85, +128, 4, 0, 0, 5, 2, 0, 15, +128, 6, 32, 228, 160, 0, 0, 0, +176, 1, 0, 255, 144, 2, 0, 228, +128, 42, 0, 0, 0, 43, 0, 0, + 0, 4, 0, 0, 4, 3, 0, 15, +128, 2, 0, 36, 144, 185, 0, 106, +160, 185, 0, 149, 160, 9, 0, 0, + 3, 0, 0, 1, 128, 3, 0, 228, +128, 0, 0, 228, 128, 9, 0, 0, + 3, 0, 0, 2, 128, 3, 0, 228, +128, 1, 0, 228, 128, 9, 0, 0, + 3, 0, 0, 4, 128, 3, 0, 228, +128, 2, 0, 228, 128, 1, 0, 0, + 2, 0, 0, 8, 128, 185, 0, 170, +160, 9, 0, 0, 3, 1, 0, 1, +128, 0, 0, 228, 160, 0, 0, 228, +128, 9, 0, 0, 3, 1, 0, 4, +128, 1, 0, 228, 160, 0, 0, 228, +128, 9, 0, 0, 3, 1, 0, 8, +128, 2, 0, 228, 160, 0, 0, 228, +128, 9, 0, 0, 3, 0, 0, 1, +128, 3, 0, 228, 160, 0, 0, 228, +128, 1, 0, 0, 2, 1, 0, 2, +128, 1, 0, 170, 129, 2, 0, 0, + 3, 0, 0, 2, 128, 0, 0, 0, +128, 1, 0, 255, 128, 5, 0, 0, + 3, 0, 0, 4, 192, 0, 0, 85, +128, 185, 0, 255, 160, 4, 0, 0, + 4, 0, 0, 3, 192, 0, 0, 0, +128, 184, 0, 228, 160, 1, 0, 228, 128, 4, 0, 0, 4, 0, 0, 3, 224, 3, 0, 228, 144, 186, 0, 228, -160, 186, 0, 226, 160, 255, 255, 0, - 0, 83, 72, 68, 82, 216, 4, 0, - 0, 64, 0, 1, 0, 54, 1, 0, - 0, 89, 8, 0, 4, 70, 142, 32, - 0, 0, 0, 0, 0, 184, 0, 0, +160, 186, 0, 226, 160, 1, 0, 0, + 2, 0, 0, 8, 192, 0, 0, 0, +128, 255, 255, 0, 0, 83, 72, 68, + 82, 96, 6, 0, 0, 64, 0, 1, + 0, 152, 1, 0, 0, 89, 8, 0, + 4, 70, 142, 32, 0, 0, 0, 0, + 0, 184, 0, 0, 0, 95, 0, 0, + 3, 242, 16, 16, 0, 0, 0, 0, 0, 95, 0, 0, 3, 242, 16, 16, - 0, 0, 0, 0, 0, 95, 0, 0, - 3, 242, 16, 16, 0, 1, 0, 0, - 0, 95, 0, 0, 3, 242, 16, 16, - 0, 2, 0, 0, 0, 95, 0, 0, - 3, 50, 16, 16, 0, 3, 0, 0, - 0, 101, 0, 0, 3, 50, 32, 16, - 0, 0, 0, 0, 0, 103, 0, 0, - 4, 242, 32, 16, 0, 1, 0, 0, - 0, 1, 0, 0, 0, 104, 0, 0, - 2, 4, 0, 0, 0, 50, 0, 0, + 0, 1, 0, 0, 0, 95, 0, 0, + 3, 114, 16, 16, 0, 2, 0, 0, + 0, 95, 0, 0, 3, 50, 16, 16, + 0, 3, 0, 0, 0, 101, 0, 0, + 3, 50, 32, 16, 0, 0, 0, 0, + 0, 103, 0, 0, 4, 242, 32, 16, + 0, 1, 0, 0, 0, 1, 0, 0, + 0, 104, 0, 0, 2, 4, 0, 0, + 0, 27, 0, 0, 5, 18, 0, 16, + 0, 0, 0, 0, 0, 10, 16, 16, + 0, 0, 0, 0, 0, 38, 0, 0, + 8, 0, 208, 0, 0, 34, 0, 16, + 0, 0, 0, 0, 0, 10, 0, 16, + 0, 0, 0, 0, 0, 1, 64, 0, + 0, 3, 0, 0, 0, 56, 0, 0, + 10, 242, 0, 16, 0, 1, 0, 0, + 0, 6, 16, 16, 0, 1, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 26, 0, 16, + 0, 0, 0, 0, 0, 35, 0, 0, + 15, 50, 0, 16, 0, 0, 0, 0, + 0, 6, 0, 16, 0, 0, 0, 0, + 0, 2, 64, 0, 0, 3, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2, 64, 0, + 0, 1, 0, 0, 0, 2, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 56, 0, 0, 10, 242, 0, 16, + 0, 2, 0, 0, 0, 6, 16, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 6, 0, 0, 0, 0, 4, 0, 0, + 0, 10, 0, 16, 0, 0, 0, 0, + 0, 56, 0, 0, 10, 242, 0, 16, + 0, 0, 0, 0, 0, 6, 16, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 6, 0, 0, 0, 0, 4, 0, 0, + 0, 26, 0, 16, 0, 0, 0, 0, + 0, 49, 0, 0, 10, 114, 0, 16, + 0, 3, 0, 0, 0, 2, 64, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 150, 23, 16, 0, 1, 0, 0, + 0, 31, 0, 4, 3, 10, 0, 16, + 0, 3, 0, 0, 0, 27, 0, 0, + 5, 18, 0, 16, 0, 3, 0, 0, + 0, 26, 16, 16, 0, 0, 0, 0, + 0, 38, 0, 0, 8, 0, 208, 0, + 0, 130, 0, 16, 0, 3, 0, 0, + 0, 10, 0, 16, 0, 3, 0, 0, + 0, 1, 64, 0, 0, 3, 0, 0, + 0, 50, 0, 0, 12, 242, 0, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 6, 0, 0, 0, 0, 4, 0, 0, + 0, 58, 0, 16, 0, 3, 0, 0, + 0, 86, 21, 16, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 35, 0, 0, 15, 146, 0, 16, + 0, 3, 0, 0, 0, 6, 0, 16, + 0, 3, 0, 0, 0, 2, 64, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 2, 64, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 2, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 10, 0, 16, + 0, 3, 0, 0, 0, 86, 21, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 2, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 58, 0, 16, + 0, 3, 0, 0, 0, 86, 21, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 21, 0, 0, + 1, 31, 0, 4, 3, 26, 0, 16, + 0, 3, 0, 0, 0, 27, 0, 0, + 5, 18, 0, 16, 0, 3, 0, 0, + 0, 42, 16, 16, 0, 0, 0, 0, + 0, 38, 0, 0, 8, 0, 208, 0, + 0, 34, 0, 16, 0, 3, 0, 0, + 0, 10, 0, 16, 0, 3, 0, 0, + 0, 1, 64, 0, 0, 3, 0, 0, + 0, 50, 0, 0, 12, 242, 0, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 6, 0, 0, 0, 0, 4, 0, 0, + 0, 26, 0, 16, 0, 3, 0, 0, + 0, 166, 26, 16, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 35, 0, 0, 15, 50, 0, 16, + 0, 3, 0, 0, 0, 6, 0, 16, + 0, 3, 0, 0, 0, 2, 64, 0, + 0, 3, 0, 0, 0, 3, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2, 64, 0, 0, 1, 0, 0, + 0, 2, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 2, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 10, 0, 16, + 0, 3, 0, 0, 0, 166, 26, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 2, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 26, 0, 16, + 0, 3, 0, 0, 0, 166, 26, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 21, 0, 0, + 1, 31, 0, 4, 3, 42, 0, 16, + 0, 3, 0, 0, 0, 27, 0, 0, + 5, 18, 0, 16, 0, 3, 0, 0, + 0, 58, 16, 16, 0, 0, 0, 0, + 0, 38, 0, 0, 8, 0, 208, 0, + 0, 34, 0, 16, 0, 3, 0, 0, + 0, 10, 0, 16, 0, 3, 0, 0, + 0, 1, 64, 0, 0, 3, 0, 0, + 0, 50, 0, 0, 12, 242, 0, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 6, 0, 0, 0, 0, 4, 0, 0, + 0, 26, 0, 16, 0, 3, 0, 0, + 0, 246, 31, 16, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 35, 0, 0, 15, 50, 0, 16, + 0, 3, 0, 0, 0, 6, 0, 16, + 0, 3, 0, 0, 0, 2, 64, 0, + 0, 3, 0, 0, 0, 3, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2, 64, 0, 0, 1, 0, 0, + 0, 2, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 2, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 10, 0, 16, + 0, 3, 0, 0, 0, 246, 31, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 2, 0, 0, 0, 50, 0, 0, + 12, 242, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 6, 0, 0, 0, + 0, 4, 0, 0, 0, 26, 0, 16, + 0, 3, 0, 0, 0, 246, 31, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 21, 0, 0, + 1, 54, 0, 0, 5, 114, 0, 16, + 0, 3, 0, 0, 0, 70, 18, 16, + 0, 2, 0, 0, 0, 54, 0, 0, + 5, 130, 0, 16, 0, 3, 0, 0, + 0, 1, 64, 0, 0, 0, 0, 128, + 63, 17, 0, 0, 7, 18, 0, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 3, 0, 0, 0, 70, 14, 16, + 0, 1, 0, 0, 0, 17, 0, 0, + 7, 34, 0, 16, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 3, 0, 0, + 0, 70, 14, 16, 0, 2, 0, 0, + 0, 17, 0, 0, 7, 66, 0, 16, + 0, 1, 0, 0, 0, 70, 14, 16, + 0, 3, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 54, 0, 0, + 5, 130, 0, 16, 0, 1, 0, 0, + 0, 1, 64, 0, 0, 0, 0, 128, + 63, 17, 0, 0, 8, 18, 32, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 17, 0, 0, 8, 18, 0, 16, + 0, 0, 0, 0, 0, 70, 142, 32, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 17, 0, 0, 8, 34, 0, 16, + 0, 0, 0, 0, 0, 70, 142, 32, + 0, 0, 0, 0, 0, 2, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 17, 0, 0, 8, 66, 0, 16, + 0, 0, 0, 0, 0, 70, 142, 32, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 70, 14, 16, 0, 1, 0, 0, + 0, 54, 0, 0, 6, 34, 32, 16, + 0, 1, 0, 0, 0, 10, 0, 16, +128, 65, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 7, 18, 0, 16, + 0, 0, 0, 0, 0, 42, 0, 16, + 0, 0, 0, 0, 0, 26, 0, 16, + 0, 0, 0, 0, 0, 56, 0, 0, + 7, 66, 32, 16, 0, 1, 0, 0, + 0, 10, 0, 16, 0, 0, 0, 0, + 0, 1, 64, 0, 0, 0, 0, 0, + 63, 54, 0, 0, 5, 130, 32, 16, + 0, 1, 0, 0, 0, 42, 0, 16, + 0, 0, 0, 0, 0, 50, 0, 0, 15, 50, 32, 16, 0, 0, 0, 0, 0, 70, 16, 16, 0, 3, 0, 0, 0, 2, 64, 0, 0, 0, 0, 128, @@ -6137,183 +5538,438 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 128, 63, 0, 0, 0, 0, 0, 0, 0, - 0, 27, 0, 0, 5, 242, 0, 16, - 0, 0, 0, 0, 0, 70, 30, 16, - 0, 0, 0, 0, 0, 38, 0, 0, - 11, 0, 208, 0, 0, 242, 0, 16, - 0, 1, 0, 0, 0, 70, 14, 16, - 0, 0, 0, 0, 0, 2, 64, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 56, 0, 0, 10, 242, 0, 16, - 0, 2, 0, 0, 0, 86, 21, 16, - 0, 1, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 26, 0, 16, 0, 1, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 2, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 10, 0, 16, 0, 1, 0, 0, - 0, 6, 16, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 2, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 2, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 42, 0, 16, 0, 1, 0, 0, - 0, 166, 26, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 2, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 1, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 58, 0, 16, 0, 1, 0, 0, - 0, 246, 31, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 2, 0, 0, - 0, 17, 0, 0, 7, 18, 0, 16, - 0, 1, 0, 0, 0, 70, 30, 16, - 0, 2, 0, 0, 0, 70, 14, 16, - 0, 1, 0, 0, 0, 35, 0, 0, - 15, 242, 0, 16, 0, 2, 0, 0, - 0, 6, 5, 16, 0, 0, 0, 0, - 0, 2, 64, 0, 0, 3, 0, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 3, 0, 0, 0, 2, 64, 0, - 0, 1, 0, 0, 0, 2, 0, 0, - 0, 1, 0, 0, 0, 2, 0, 0, - 0, 35, 0, 0, 15, 242, 0, 16, - 0, 0, 0, 0, 0, 166, 15, 16, - 0, 0, 0, 0, 0, 2, 64, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 3, 0, 0, 0, 3, 0, 0, - 0, 2, 64, 0, 0, 1, 0, 0, - 0, 2, 0, 0, 0, 1, 0, 0, - 0, 2, 0, 0, 0, 56, 0, 0, - 10, 242, 0, 16, 0, 3, 0, 0, - 0, 86, 21, 16, 0, 1, 0, 0, - 0, 70, 142, 32, 6, 0, 0, 0, - 0, 4, 0, 0, 0, 42, 0, 16, - 0, 2, 0, 0, 0, 50, 0, 0, - 12, 242, 0, 16, 0, 3, 0, 0, - 0, 70, 142, 32, 6, 0, 0, 0, - 0, 4, 0, 0, 0, 10, 0, 16, - 0, 2, 0, 0, 0, 6, 16, 16, - 0, 1, 0, 0, 0, 70, 14, 16, - 0, 3, 0, 0, 0, 50, 0, 0, - 12, 242, 0, 16, 0, 3, 0, 0, - 0, 70, 142, 32, 6, 0, 0, 0, - 0, 4, 0, 0, 0, 10, 0, 16, - 0, 0, 0, 0, 0, 166, 26, 16, - 0, 1, 0, 0, 0, 70, 14, 16, - 0, 3, 0, 0, 0, 50, 0, 0, - 12, 242, 0, 16, 0, 3, 0, 0, - 0, 70, 142, 32, 6, 0, 0, 0, - 0, 4, 0, 0, 0, 42, 0, 16, - 0, 0, 0, 0, 0, 246, 31, 16, - 0, 1, 0, 0, 0, 70, 14, 16, - 0, 3, 0, 0, 0, 17, 0, 0, - 7, 34, 0, 16, 0, 1, 0, 0, - 0, 70, 30, 16, 0, 2, 0, 0, - 0, 70, 14, 16, 0, 3, 0, 0, - 0, 56, 0, 0, 10, 242, 0, 16, - 0, 3, 0, 0, 0, 86, 21, 16, - 0, 1, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 58, 0, 16, 0, 2, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 2, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 26, 0, 16, 0, 2, 0, 0, - 0, 6, 16, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 3, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 2, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 26, 0, 16, 0, 0, 0, 0, - 0, 166, 26, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 2, 0, 0, - 0, 50, 0, 0, 12, 242, 0, 16, - 0, 0, 0, 0, 0, 70, 142, 32, - 6, 0, 0, 0, 0, 4, 0, 0, - 0, 58, 0, 16, 0, 0, 0, 0, - 0, 246, 31, 16, 0, 1, 0, 0, - 0, 70, 14, 16, 0, 2, 0, 0, - 0, 17, 0, 0, 7, 66, 0, 16, - 0, 1, 0, 0, 0, 70, 30, 16, - 0, 2, 0, 0, 0, 70, 14, 16, - 0, 0, 0, 0, 0, 54, 0, 0, - 5, 130, 0, 16, 0, 1, 0, 0, - 0, 58, 16, 16, 0, 2, 0, 0, - 0, 17, 0, 0, 8, 18, 0, 16, - 0, 0, 0, 0, 0, 70, 142, 32, - 0, 0, 0, 0, 0, 2, 0, 0, - 0, 70, 14, 16, 0, 1, 0, 0, - 0, 17, 0, 0, 8, 34, 0, 16, - 0, 0, 0, 0, 0, 70, 142, 32, + 0, 62, 0, 0, 1, 83, 84, 65, + 84, 116, 0, 0, 0, 47, 0, 0, + 0, 4, 0, 0, 0, 0, 0, 0, + 0, 6, 0, 0, 0, 24, 0, 0, + 0, 8, 0, 0, 0, 0, 0, 0, + 0, 1, 0, 0, 0, 3, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 82, 68, 69, 70, 8, 1, 0, + 0, 1, 0, 0, 0, 72, 0, 0, + 0, 1, 0, 0, 0, 28, 0, 0, + 0, 0, 4, 254, 255, 0, 65, 0, + 0, 212, 0, 0, 0, 60, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 36, 71, 108, +111, 98, 97, 108, 115, 0, 171, 171, +171, 60, 0, 0, 0, 2, 0, 0, + 0, 96, 0, 0, 0, 128, 11, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 144, 0, 0, 0, 0, 0, 0, + 0, 64, 0, 0, 0, 2, 0, 0, + 0, 160, 0, 0, 0, 0, 0, 0, + 0, 176, 0, 0, 0, 64, 0, 0, + 0, 64, 11, 0, 0, 2, 0, 0, + 0, 196, 0, 0, 0, 0, 0, 0, + 0, 95, 67, 67, 95, 77, 86, 80, + 77, 97, 116, 114, 105, 120, 0, 171, +171, 3, 0, 3, 0, 4, 0, 4, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 95, 117, 95, 109, 97, 116, 114, +105, 120, 80, 97, 108, 101, 116, 116, +101, 0, 171, 171, 171, 1, 0, 3, + 0, 1, 0, 4, 0, 180, 0, 0, + 0, 0, 0, 0, 0, 77, 105, 99, +114, 111, 115, 111, 102, 116, 32, 40, + 82, 41, 32, 72, 76, 83, 76, 32, + 83, 104, 97, 100, 101, 114, 32, 67, +111, 109, 112, 105, 108, 101, 114, 32, + 54, 46, 51, 46, 57, 54, 48, 48, + 46, 49, 54, 51, 56, 52, 0, 171, +171, 73, 83, 71, 78, 116, 0, 0, + 0, 4, 0, 0, 0, 8, 0, 0, + 0, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, - 0, 70, 14, 16, 0, 1, 0, 0, - 0, 0, 0, 0, 7, 18, 0, 16, - 0, 0, 0, 0, 0, 26, 0, 16, - 0, 0, 0, 0, 0, 10, 0, 16, - 0, 0, 0, 0, 0, 54, 0, 0, - 5, 130, 32, 16, 0, 1, 0, 0, - 0, 26, 0, 16, 0, 0, 0, 0, - 0, 56, 0, 0, 7, 66, 32, 16, - 0, 1, 0, 0, 0, 10, 0, 16, - 0, 0, 0, 0, 0, 1, 64, 0, - 0, 0, 0, 0, 63, 17, 0, 0, - 8, 18, 0, 16, 0, 0, 0, 0, - 0, 70, 142, 32, 0, 0, 0, 0, - 0, 1, 0, 0, 0, 70, 14, 16, - 0, 1, 0, 0, 0, 17, 0, 0, - 8, 18, 32, 16, 0, 1, 0, 0, - 0, 70, 142, 32, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 15, 15, 0, + 0, 104, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 1, 0, 0, 0, 15, 15, 0, + 0, 104, 0, 0, 0, 2, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 2, 0, 0, 0, 7, 7, 0, + 0, 104, 0, 0, 0, 3, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 3, 0, 0, 0, 3, 3, 0, + 0, 84, 69, 88, 67, 79, 79, 82, + 68, 0, 171, 171, 171, 79, 83, 71, + 78, 80, 0, 0, 0, 2, 0, 0, + 0, 8, 0, 0, 0, 56, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 3, 12, 0, 0, 65, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 3, 0, 0, 0, 1, 0, 0, + 0, 15, 0, 0, 0, 84, 69, 88, + 67, 79, 79, 82, 68, 0, 83, 86, + 95, 80, 111, 115, 105, 116, 105, 111, +110, 0, 171, 171, 171, +}; + +const unsigned char s_A2377A827972A5466DA8637681045D32DA8A817D[] = { + +166, 147, 0, 0, 142, 9, 2, 1, + 0, 128, 0, 0, 82, 139, 0, 0, + 10, 0, 0, 0, 97, 95, 112, 111, +115, 105, 116, 105, 111, 110, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 255, 255, 255, 255, 80, 139, + 0, 0, 10, 0, 0, 0, 97, 95, +116, 101, 120, 67, 111, 111, 114, 100, + 1, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 0, 0, 0, 0, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 1, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 0, 3, 0, 0, 0, 92, 139, 0, + 0, 242, 141, 0, 0, 12, 0, 0, + 0, 67, 67, 95, 77, 86, 80, 77, + 97, 116, 114, 105, 120, 0, 0, 0, + 0, 255, 255, 255, 255, 0, 0, 0, + 0, 4, 0, 0, 0, 94, 139, 0, + 0, 0, 0, 0, 0, 11, 0, 0, + 0, 67, 67, 95, 84, 101, 120, 116, +117, 114, 101, 48, 0, 0, 0, 0, + 0, 0, 0, 0, 255, 255, 255, 255, + 1, 0, 0, 0, 82, 139, 0, 0, +240, 141, 0, 0, 7, 0, 0, 0, +117, 95, 99, 111, 108, 111, 114, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 1, 0, 0, 0, 3, + 0, 0, 0, 12, 0, 0, 0, 67, + 67, 95, 77, 86, 80, 77, 97, 116, +114, 105, 120, 0, 0, 0, 0, 0, + 0, 0, 0, 11, 0, 0, 0, 67, + 67, 95, 84, 101, 120, 116, 117, 114, +101, 48, 0, 0, 0, 0, 1, 0, + 0, 0, 7, 0, 0, 0, 117, 95, + 99, 111, 108, 111, 114, 0, 0, 0, + 0, 2, 0, 0, 0, 96, 4, 0, + 0, 144, 4, 0, 0, 0, 0, 0, + 0, 221, 144, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 68, 88, 66, 67, 157, 116, 105, + 89, 118, 135, 249, 239, 42, 226, 184, + 78, 220, 105, 236, 28, 1, 0, 0, + 0, 96, 4, 0, 0, 6, 0, 0, + 0, 56, 0, 0, 0, 228, 0, 0, + 0, 252, 1, 0, 0, 120, 2, 0, + 0, 176, 3, 0, 0, 228, 3, 0, + 0, 65, 111, 110, 57, 164, 0, 0, + 0, 164, 0, 0, 0, 0, 2, 255, +255, 112, 0, 0, 0, 52, 0, 0, + 0, 1, 0, 40, 0, 0, 0, 52, + 0, 0, 0, 52, 0, 1, 0, 36, + 0, 0, 0, 52, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 1, 2, 255, +255, 31, 0, 0, 2, 0, 0, 0, +128, 0, 0, 3, 176, 31, 0, 0, + 2, 0, 0, 0, 144, 0, 8, 15, +160, 66, 0, 0, 3, 0, 0, 15, +128, 0, 0, 228, 176, 0, 8, 228, +160, 5, 0, 0, 3, 0, 0, 15, +128, 0, 0, 228, 128, 0, 0, 228, +160, 1, 0, 0, 2, 0, 8, 15, +128, 0, 0, 228, 128, 1, 0, 0, + 2, 1, 8, 15, 128, 0, 0, 228, +128, 1, 0, 0, 2, 2, 8, 15, +128, 0, 0, 228, 128, 1, 0, 0, + 2, 3, 8, 15, 128, 0, 0, 228, +128, 255, 255, 0, 0, 83, 72, 68, + 82, 16, 1, 0, 0, 64, 0, 0, + 0, 68, 0, 0, 0, 89, 0, 0, + 4, 70, 142, 32, 0, 0, 0, 0, + 0, 1, 0, 0, 0, 90, 0, 0, + 3, 0, 96, 16, 0, 0, 0, 0, + 0, 88, 24, 0, 4, 0, 112, 16, + 0, 0, 0, 0, 0, 85, 85, 0, + 0, 98, 16, 0, 3, 50, 16, 16, + 0, 0, 0, 0, 0, 101, 0, 0, + 3, 242, 32, 16, 0, 0, 0, 0, + 0, 101, 0, 0, 3, 242, 32, 16, + 0, 1, 0, 0, 0, 101, 0, 0, + 3, 242, 32, 16, 0, 2, 0, 0, + 0, 101, 0, 0, 3, 242, 32, 16, + 0, 3, 0, 0, 0, 104, 0, 0, + 2, 1, 0, 0, 0, 69, 0, 0, + 9, 242, 0, 16, 0, 0, 0, 0, + 0, 70, 16, 16, 0, 0, 0, 0, + 0, 70, 126, 16, 0, 0, 0, 0, + 0, 0, 96, 16, 0, 0, 0, 0, + 0, 56, 0, 0, 8, 242, 0, 16, 0, 0, 0, 0, 0, 70, 14, 16, - 0, 1, 0, 0, 0, 54, 0, 0, - 6, 34, 32, 16, 0, 1, 0, 0, - 0, 10, 0, 16, 128, 65, 0, 0, - 0, 0, 0, 0, 0, 62, 0, 0, - 1, 83, 84, 65, 84, 116, 0, 0, - 0, 30, 0, 0, 0, 4, 0, 0, - 0, 0, 0, 0, 0, 6, 0, 0, - 0, 23, 0, 0, 0, 3, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 2, 0, 0, - 0, 0, 0, 0, 0, 1, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 82, 68, 69, - 70, 8, 1, 0, 0, 1, 0, 0, - 0, 72, 0, 0, 0, 1, 0, 0, - 0, 28, 0, 0, 0, 0, 4, 254, -255, 0, 65, 0, 0, 212, 0, 0, - 0, 60, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 70, 142, 32, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 54, 0, 0, 5, 242, 32, 16, + 0, 0, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 54, 0, 0, + 5, 242, 32, 16, 0, 1, 0, 0, + 0, 70, 14, 16, 0, 0, 0, 0, + 0, 54, 0, 0, 5, 242, 32, 16, + 0, 2, 0, 0, 0, 70, 14, 16, + 0, 0, 0, 0, 0, 54, 0, 0, + 5, 242, 32, 16, 0, 3, 0, 0, + 0, 70, 14, 16, 0, 0, 0, 0, + 0, 62, 0, 0, 1, 83, 84, 65, + 84, 116, 0, 0, 0, 7, 0, 0, + 0, 1, 0, 0, 0, 0, 0, 0, + 0, 5, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, - 0, 36, 71, 108, 111, 98, 97, 108, -115, 0, 171, 171, 171, 60, 0, 0, - 0, 2, 0, 0, 0, 96, 0, 0, - 0, 128, 11, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 144, 0, 0, - 0, 0, 0, 0, 0, 64, 0, 0, - 0, 2, 0, 0, 0, 160, 0, 0, - 0, 0, 0, 0, 0, 176, 0, 0, - 0, 64, 0, 0, 0, 64, 11, 0, - 0, 2, 0, 0, 0, 196, 0, 0, - 0, 0, 0, 0, 0, 95, 67, 67, - 95, 77, 86, 80, 77, 97, 116, 114, -105, 120, 0, 171, 171, 3, 0, 3, - 0, 4, 0, 4, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 95, 117, 95, -109, 97, 116, 114, 105, 120, 80, 97, -108, 101, 116, 116, 101, 0, 171, 171, -171, 1, 0, 3, 0, 1, 0, 4, - 0, 180, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 82, 68, 69, 70, 48, 1, 0, + 0, 1, 0, 0, 0, 176, 0, 0, + 0, 3, 0, 0, 0, 28, 0, 0, + 0, 0, 4, 255, 255, 0, 65, 0, + 0, 252, 0, 0, 0, 124, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 1, 0, 0, 0, 145, 0, 0, + 0, 2, 0, 0, 0, 5, 0, 0, + 0, 4, 0, 0, 0, 255, 255, 255, +255, 0, 0, 0, 0, 1, 0, 0, + 0, 13, 0, 0, 0, 166, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 115, 97, 109, +112, 108, 101, 114, 95, 95, 67, 67, + 95, 84, 101, 120, 116, 117, 114, 101, + 48, 0, 116, 101, 120, 116, 117, 114, +101, 95, 95, 67, 67, 95, 84, 101, +120, 116, 117, 114, 101, 48, 0, 36, + 71, 108, 111, 98, 97, 108, 115, 0, +171, 166, 0, 0, 0, 1, 0, 0, + 0, 200, 0, 0, 0, 16, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 224, 0, 0, 0, 0, 0, 0, + 0, 16, 0, 0, 0, 2, 0, 0, + 0, 236, 0, 0, 0, 0, 0, 0, + 0, 95, 117, 95, 99, 111, 108, 111, +114, 0, 171, 171, 171, 1, 0, 3, + 0, 1, 0, 4, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 77, 105, 99, +114, 111, 115, 111, 102, 116, 32, 40, + 82, 41, 32, 72, 76, 83, 76, 32, + 83, 104, 97, 100, 101, 114, 32, 67, +111, 109, 112, 105, 108, 101, 114, 32, + 54, 46, 51, 46, 57, 54, 48, 48, + 46, 49, 54, 51, 56, 52, 0, 171, +171, 73, 83, 71, 78, 44, 0, 0, + 0, 1, 0, 0, 0, 8, 0, 0, + 0, 32, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, + 0, 0, 0, 0, 0, 3, 3, 0, + 0, 84, 69, 88, 67, 79, 79, 82, + 68, 0, 171, 171, 171, 79, 83, 71, + 78, 116, 0, 0, 0, 4, 0, 0, + 0, 8, 0, 0, 0, 104, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 15, 0, 0, 0, 104, 0, 0, + 0, 1, 0, 0, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 1, 0, 0, + 0, 15, 0, 0, 0, 104, 0, 0, + 0, 2, 0, 0, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 2, 0, 0, + 0, 15, 0, 0, 0, 104, 0, 0, + 0, 3, 0, 0, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 3, 0, 0, + 0, 15, 0, 0, 0, 83, 86, 95, + 84, 97, 114, 103, 101, 116, 0, 171, +171, 68, 88, 66, 67, 110, 14, 140, +120, 239, 110, 56, 78, 103, 37, 245, +162, 140, 151, 93, 223, 1, 0, 0, + 0, 144, 4, 0, 0, 6, 0, 0, + 0, 56, 0, 0, 0, 68, 1, 0, + 0, 156, 2, 0, 0, 24, 3, 0, + 0, 236, 3, 0, 0, 56, 4, 0, + 0, 65, 111, 110, 57, 4, 1, 0, + 0, 4, 1, 0, 0, 0, 2, 254, +255, 208, 0, 0, 0, 52, 0, 0, + 0, 1, 0, 36, 0, 0, 0, 48, + 0, 0, 0, 48, 0, 0, 0, 36, + 0, 1, 0, 48, 0, 0, 0, 0, + 0, 4, 0, 1, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 2, 254, +255, 81, 0, 0, 5, 5, 0, 15, +160, 0, 0, 0, 63, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 31, 0, 0, 2, 5, 0, 0, +128, 0, 0, 15, 144, 31, 0, 0, + 2, 5, 0, 1, 128, 1, 0, 15, +144, 9, 0, 0, 3, 0, 0, 1, +128, 3, 0, 228, 160, 0, 0, 228, +144, 9, 0, 0, 3, 0, 0, 2, +128, 4, 0, 228, 160, 0, 0, 228, +144, 2, 0, 0, 3, 0, 0, 1, +128, 0, 0, 85, 128, 0, 0, 0, +128, 5, 0, 0, 3, 0, 0, 4, +192, 0, 0, 0, 128, 5, 0, 0, +160, 9, 0, 0, 3, 0, 0, 1, +128, 2, 0, 228, 160, 0, 0, 228, +144, 1, 0, 0, 2, 1, 0, 2, +128, 0, 0, 0, 129, 9, 0, 0, + 3, 1, 0, 1, 128, 1, 0, 228, +160, 0, 0, 228, 144, 4, 0, 0, + 4, 0, 0, 3, 192, 0, 0, 85, +128, 0, 0, 228, 160, 1, 0, 228, +128, 1, 0, 0, 2, 0, 0, 8, +192, 0, 0, 85, 128, 1, 0, 0, + 2, 0, 0, 3, 224, 1, 0, 228, +144, 255, 255, 0, 0, 83, 72, 68, + 82, 80, 1, 0, 0, 64, 0, 1, + 0, 84, 0, 0, 0, 89, 0, 0, + 4, 70, 142, 32, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 95, 0, 0, + 3, 242, 16, 16, 0, 0, 0, 0, + 0, 95, 0, 0, 3, 50, 16, 16, + 0, 1, 0, 0, 0, 101, 0, 0, + 3, 50, 32, 16, 0, 0, 0, 0, + 0, 103, 0, 0, 4, 242, 32, 16, + 0, 1, 0, 0, 0, 1, 0, 0, + 0, 104, 0, 0, 2, 1, 0, 0, + 0, 54, 0, 0, 5, 50, 32, 16, + 0, 0, 0, 0, 0, 70, 16, 16, + 0, 1, 0, 0, 0, 17, 0, 0, + 8, 18, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 0, 0, 0, 0, + 0, 1, 0, 0, 0, 70, 30, 16, + 0, 0, 0, 0, 0, 54, 0, 0, + 6, 34, 32, 16, 0, 1, 0, 0, + 0, 10, 0, 16, 128, 65, 0, 0, + 0, 0, 0, 0, 0, 17, 0, 0, + 8, 18, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 0, 0, 0, 0, + 0, 2, 0, 0, 0, 70, 30, 16, + 0, 0, 0, 0, 0, 17, 0, 0, + 8, 34, 0, 16, 0, 0, 0, 0, + 0, 70, 142, 32, 0, 0, 0, 0, + 0, 3, 0, 0, 0, 70, 30, 16, + 0, 0, 0, 0, 0, 0, 0, 0, + 7, 18, 0, 16, 0, 0, 0, 0, + 0, 26, 0, 16, 0, 0, 0, 0, + 0, 10, 0, 16, 0, 0, 0, 0, + 0, 54, 0, 0, 5, 130, 32, 16, + 0, 1, 0, 0, 0, 26, 0, 16, + 0, 0, 0, 0, 0, 56, 0, 0, + 7, 66, 32, 16, 0, 1, 0, 0, + 0, 10, 0, 16, 0, 0, 0, 0, + 0, 1, 64, 0, 0, 0, 0, 0, + 63, 17, 0, 0, 8, 18, 32, 16, + 0, 1, 0, 0, 0, 70, 142, 32, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 70, 30, 16, 0, 0, 0, 0, + 0, 62, 0, 0, 1, 83, 84, 65, + 84, 116, 0, 0, 0, 10, 0, 0, + 0, 1, 0, 0, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 7, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 82, 68, 69, 70, 204, 0, 0, + 0, 1, 0, 0, 0, 72, 0, 0, + 0, 1, 0, 0, 0, 28, 0, 0, + 0, 0, 4, 254, 255, 0, 65, 0, + 0, 152, 0, 0, 0, 60, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 36, 71, 108, +111, 98, 97, 108, 115, 0, 171, 171, +171, 60, 0, 0, 0, 1, 0, 0, + 0, 96, 0, 0, 0, 64, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 120, 0, 0, 0, 0, 0, 0, + 0, 64, 0, 0, 0, 2, 0, 0, + 0, 136, 0, 0, 0, 0, 0, 0, + 0, 95, 67, 67, 95, 77, 86, 80, + 77, 97, 116, 114, 105, 120, 0, 171, +171, 3, 0, 3, 0, 4, 0, 4, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 77, 105, 99, 114, 111, 115, 111, 102, 116, 32, 40, 82, 41, 32, 72, 76, 83, 76, 32, 83, 104, 97, 100, @@ -6321,19 +5977,13 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 108, 101, 114, 32, 54, 46, 51, 46, 57, 54, 48, 48, 46, 49, 54, 51, 56, 52, 0, 171, 171, 73, 83, 71, - 78, 116, 0, 0, 0, 4, 0, 0, - 0, 8, 0, 0, 0, 104, 0, 0, + 78, 68, 0, 0, 0, 2, 0, 0, + 0, 8, 0, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, - 0, 15, 15, 0, 0, 104, 0, 0, + 0, 15, 15, 0, 0, 56, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1, 0, 0, - 0, 15, 15, 0, 0, 104, 0, 0, - 0, 2, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 2, 0, 0, - 0, 15, 15, 0, 0, 104, 0, 0, - 0, 3, 0, 0, 0, 0, 0, 0, - 0, 3, 0, 0, 0, 3, 0, 0, 0, 3, 3, 0, 0, 84, 69, 88, 67, 79, 79, 82, 68, 0, 171, 171, 171, 79, 83, 71, 78, 80, 0, 0, @@ -6350,6 +6000,455 @@ const unsigned char s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749[] = { 171, }; +const unsigned char s_B5E27B4F3CF7236633255B28CBA530D6EE5CED86[] = { + +166, 147, 0, 0, 142, 9, 2, 1, + 0, 128, 0, 0, 82, 139, 0, 0, + 10, 0, 0, 0, 97, 95, 112, 111, +115, 105, 116, 105, 111, 110, 1, 0, + 0, 0, 82, 139, 0, 0, 7, 0, + 0, 0, 97, 95, 99, 111, 108, 111, +114, 0, 0, 0, 0, 80, 139, 0, + 0, 10, 0, 0, 0, 97, 95, 116, +101, 120, 67, 111, 111, 114, 100, 2, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 0, + 0, 0, 0, 0, 0, 0, 0, 255, +255, 255, 255, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 1, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1, 0, 0, 0, 0, + 3, 0, 0, 0, 92, 139, 0, 0, +242, 141, 0, 0, 12, 0, 0, 0, + 67, 67, 95, 77, 86, 80, 77, 97, +116, 114, 105, 120, 0, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 4, 0, 0, 0, 94, 139, 0, 0, + 0, 0, 0, 0, 11, 0, 0, 0, + 67, 67, 95, 84, 101, 120, 116, 117, +114, 101, 48, 0, 0, 0, 0, 0, + 0, 0, 0, 255, 255, 255, 255, 1, + 0, 0, 0, 82, 139, 0, 0, 240, +141, 0, 0, 11, 0, 0, 0, 117, + 95, 116, 101, 120, 116, 67, 111, 108, +111, 114, 0, 0, 0, 0, 0, 0, + 0, 0, 255, 255, 255, 255, 1, 0, + 0, 0, 3, 0, 0, 0, 12, 0, + 0, 0, 67, 67, 95, 77, 86, 80, + 77, 97, 116, 114, 105, 120, 0, 0, + 0, 0, 0, 0, 0, 0, 11, 0, + 0, 0, 67, 67, 95, 84, 101, 120, +116, 117, 114, 101, 48, 0, 0, 0, + 0, 1, 0, 0, 0, 11, 0, 0, + 0, 117, 95, 116, 101, 120, 116, 67, +111, 108, 111, 114, 0, 0, 0, 0, + 2, 0, 0, 0, 240, 5, 0, 0, + 4, 5, 0, 0, 0, 0, 0, 0, +221, 144, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 68, 88, 66, 67, 223, 173, 203, 80, +172, 13, 170, 215, 168, 128, 228, 5, + 62, 250, 21, 248, 1, 0, 0, 0, +240, 5, 0, 0, 6, 0, 0, 0, + 56, 0, 0, 0, 124, 1, 0, 0, +112, 3, 0, 0, 236, 3, 0, 0, + 40, 5, 0, 0, 116, 5, 0, 0, + 65, 111, 110, 57, 60, 1, 0, 0, + 60, 1, 0, 0, 0, 2, 255, 255, + 8, 1, 0, 0, 52, 0, 0, 0, + 1, 0, 40, 0, 0, 0, 52, 0, + 0, 0, 52, 0, 1, 0, 36, 0, + 0, 0, 52, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 1, 2, 255, 255, + 81, 0, 0, 5, 1, 0, 15, 160, + 31, 133, 235, 190, 254, 255, 71, 65, + 0, 0, 0, 192, 0, 0, 64, 64, + 31, 0, 0, 2, 0, 0, 0, 128, + 0, 0, 15, 176, 31, 0, 0, 2, + 0, 0, 0, 128, 1, 0, 3, 176, + 31, 0, 0, 2, 0, 0, 0, 144, + 0, 8, 15, 160, 66, 0, 0, 3, + 0, 0, 15, 128, 1, 0, 228, 176, + 0, 8, 228, 160, 2, 0, 0, 3, + 0, 0, 1, 128, 0, 0, 255, 128, + 1, 0, 0, 160, 5, 0, 0, 3, + 0, 0, 17, 128, 0, 0, 0, 128, + 1, 0, 85, 160, 4, 0, 0, 4, + 0, 0, 2, 128, 0, 0, 0, 128, + 1, 0, 170, 160, 1, 0, 255, 160, + 5, 0, 0, 3, 0, 0, 1, 128, + 0, 0, 0, 128, 0, 0, 0, 128, + 5, 0, 0, 3, 0, 0, 1, 128, + 0, 0, 0, 128, 0, 0, 85, 128, + 5, 0, 0, 3, 0, 0, 1, 128, + 0, 0, 0, 128, 0, 0, 255, 160, + 5, 0, 0, 3, 0, 0, 8, 128, + 0, 0, 0, 128, 0, 0, 255, 176, + 5, 0, 0, 3, 0, 0, 7, 128, + 0, 0, 228, 176, 0, 0, 228, 160, + 1, 0, 0, 2, 0, 8, 15, 128, + 0, 0, 228, 128, 1, 0, 0, 2, + 1, 8, 15, 128, 0, 0, 228, 128, + 1, 0, 0, 2, 2, 8, 15, 128, + 0, 0, 228, 128, 1, 0, 0, 2, + 3, 8, 15, 128, 0, 0, 228, 128, +255, 255, 0, 0, 83, 72, 68, 82, +236, 1, 0, 0, 64, 0, 0, 0, +123, 0, 0, 0, 89, 0, 0, 4, + 70, 142, 32, 0, 0, 0, 0, 0, + 1, 0, 0, 0, 90, 0, 0, 3, + 0, 96, 16, 0, 0, 0, 0, 0, + 88, 24, 0, 4, 0, 112, 16, 0, + 0, 0, 0, 0, 85, 85, 0, 0, + 98, 16, 0, 3, 242, 16, 16, 0, + 0, 0, 0, 0, 98, 16, 0, 3, + 50, 16, 16, 0, 1, 0, 0, 0, +101, 0, 0, 3, 242, 32, 16, 0, + 0, 0, 0, 0, 101, 0, 0, 3, +242, 32, 16, 0, 1, 0, 0, 0, +101, 0, 0, 3, 242, 32, 16, 0, + 2, 0, 0, 0, 101, 0, 0, 3, +242, 32, 16, 0, 3, 0, 0, 0, +104, 0, 0, 2, 1, 0, 0, 0, + 69, 0, 0, 9, 242, 0, 16, 0, + 0, 0, 0, 0, 70, 16, 16, 0, + 1, 0, 0, 0, 70, 126, 16, 0, + 0, 0, 0, 0, 0, 96, 16, 0, + 0, 0, 0, 0, 0, 0, 0, 7, + 18, 0, 16, 0, 0, 0, 0, 0, + 58, 0, 16, 0, 0, 0, 0, 0, + 1, 64, 0, 0, 31, 133, 235, 190, + 56, 32, 0, 7, 18, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 1, 64, 0, 0, +254, 255, 71, 65, 50, 0, 0, 9, + 34, 0, 16, 0, 0, 0, 0, 0, + 10, 0, 16, 0, 0, 0, 0, 0, + 1, 64, 0, 0, 0, 0, 0, 192, + 1, 64, 0, 0, 0, 0, 64, 64, + 56, 0, 0, 7, 18, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 56, 0, 0, 7, + 18, 0, 16, 0, 0, 0, 0, 0, + 10, 0, 16, 0, 0, 0, 0, 0, + 26, 0, 16, 0, 0, 0, 0, 0, + 56, 0, 0, 8, 18, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 58, 128, 32, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 56, 0, 0, 7, 130, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 58, 16, 16, 0, + 0, 0, 0, 0, 56, 0, 0, 8, +114, 0, 16, 0, 0, 0, 0, 0, + 70, 18, 16, 0, 0, 0, 0, 0, + 70, 130, 32, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 54, 0, 0, 5, +242, 32, 16, 0, 0, 0, 0, 0, + 70, 14, 16, 0, 0, 0, 0, 0, + 54, 0, 0, 5, 242, 32, 16, 0, + 1, 0, 0, 0, 70, 14, 16, 0, + 0, 0, 0, 0, 54, 0, 0, 5, +242, 32, 16, 0, 2, 0, 0, 0, + 70, 14, 16, 0, 0, 0, 0, 0, + 54, 0, 0, 5, 242, 32, 16, 0, + 3, 0, 0, 0, 70, 14, 16, 0, + 0, 0, 0, 0, 62, 0, 0, 1, + 83, 84, 65, 84, 116, 0, 0, 0, + 14, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 6, 0, 0, 0, + 8, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 4, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 82, 68, 69, 70, + 52, 1, 0, 0, 1, 0, 0, 0, +176, 0, 0, 0, 3, 0, 0, 0, + 28, 0, 0, 0, 0, 4, 255, 255, + 0, 65, 0, 0, 0, 1, 0, 0, +124, 0, 0, 0, 3, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 1, 0, 0, 0, 1, 0, 0, 0, +145, 0, 0, 0, 2, 0, 0, 0, + 5, 0, 0, 0, 4, 0, 0, 0, +255, 255, 255, 255, 0, 0, 0, 0, + 1, 0, 0, 0, 13, 0, 0, 0, +166, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 0, +115, 97, 109, 112, 108, 101, 114, 95, + 95, 67, 67, 95, 84, 101, 120, 116, +117, 114, 101, 48, 0, 116, 101, 120, +116, 117, 114, 101, 95, 95, 67, 67, + 95, 84, 101, 120, 116, 117, 114, 101, + 48, 0, 36, 71, 108, 111, 98, 97, +108, 115, 0, 171, 166, 0, 0, 0, + 1, 0, 0, 0, 200, 0, 0, 0, + 16, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 224, 0, 0, 0, + 0, 0, 0, 0, 16, 0, 0, 0, + 2, 0, 0, 0, 240, 0, 0, 0, + 0, 0, 0, 0, 95, 117, 95, 116, +101, 120, 116, 67, 111, 108, 111, 114, + 0, 171, 171, 171, 1, 0, 3, 0, + 1, 0, 4, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 77, 105, 99, 114, +111, 115, 111, 102, 116, 32, 40, 82, + 41, 32, 72, 76, 83, 76, 32, 83, +104, 97, 100, 101, 114, 32, 67, 111, +109, 112, 105, 108, 101, 114, 32, 54, + 46, 51, 46, 57, 54, 48, 48, 46, + 49, 54, 51, 56, 52, 0, 171, 171, + 73, 83, 71, 78, 68, 0, 0, 0, + 2, 0, 0, 0, 8, 0, 0, 0, + 56, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 0, 0, 0, 0, 15, 15, 0, 0, + 56, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 1, 0, 0, 0, 3, 3, 0, 0, + 84, 69, 88, 67, 79, 79, 82, 68, + 0, 171, 171, 171, 79, 83, 71, 78, +116, 0, 0, 0, 4, 0, 0, 0, + 8, 0, 0, 0, 104, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 0, 0, 0, 0, + 15, 0, 0, 0, 104, 0, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 1, 0, 0, 0, + 15, 0, 0, 0, 104, 0, 0, 0, + 2, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 2, 0, 0, 0, + 15, 0, 0, 0, 104, 0, 0, 0, + 3, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 3, 0, 0, 0, + 15, 0, 0, 0, 83, 86, 95, 84, + 97, 114, 103, 101, 116, 0, 171, 171, + 68, 88, 66, 67, 235, 56, 180, 223, +125, 231, 231, 218, 70, 75, 12, 63, +200, 233, 69, 121, 1, 0, 0, 0, + 4, 5, 0, 0, 6, 0, 0, 0, + 56, 0, 0, 0, 92, 1, 0, 0, +224, 2, 0, 0, 92, 3, 0, 0, + 48, 4, 0, 0, 148, 4, 0, 0, + 65, 111, 110, 57, 28, 1, 0, 0, + 28, 1, 0, 0, 0, 2, 254, 255, +232, 0, 0, 0, 52, 0, 0, 0, + 1, 0, 36, 0, 0, 0, 48, 0, + 0, 0, 48, 0, 0, 0, 36, 0, + 1, 0, 48, 0, 0, 0, 0, 0, + 4, 0, 1, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1, 2, 254, 255, + 81, 0, 0, 5, 5, 0, 15, 160, + 0, 0, 0, 63, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 31, 0, 0, 2, 5, 0, 0, 128, + 0, 0, 15, 144, 31, 0, 0, 2, + 5, 0, 1, 128, 1, 0, 15, 144, + 31, 0, 0, 2, 5, 0, 2, 128, + 2, 0, 15, 144, 9, 0, 0, 3, + 0, 0, 1, 128, 3, 0, 228, 160, + 1, 0, 228, 144, 9, 0, 0, 3, + 0, 0, 2, 128, 4, 0, 228, 160, + 1, 0, 228, 144, 2, 0, 0, 3, + 0, 0, 1, 128, 0, 0, 85, 128, + 0, 0, 0, 128, 5, 0, 0, 3, + 0, 0, 4, 192, 0, 0, 0, 128, + 5, 0, 0, 160, 9, 0, 0, 3, + 0, 0, 1, 128, 2, 0, 228, 160, + 1, 0, 228, 144, 1, 0, 0, 2, + 1, 0, 2, 128, 0, 0, 0, 129, + 9, 0, 0, 3, 1, 0, 1, 128, + 1, 0, 228, 160, 1, 0, 228, 144, + 4, 0, 0, 4, 0, 0, 3, 192, + 0, 0, 85, 128, 0, 0, 228, 160, + 1, 0, 228, 128, 1, 0, 0, 2, + 0, 0, 8, 192, 0, 0, 85, 128, + 1, 0, 0, 2, 0, 0, 15, 224, + 0, 0, 228, 144, 1, 0, 0, 2, + 1, 0, 3, 224, 2, 0, 228, 144, +255, 255, 0, 0, 83, 72, 68, 82, +124, 1, 0, 0, 64, 0, 1, 0, + 95, 0, 0, 0, 89, 0, 0, 4, + 70, 142, 32, 0, 0, 0, 0, 0, + 4, 0, 0, 0, 95, 0, 0, 3, +242, 16, 16, 0, 0, 0, 0, 0, + 95, 0, 0, 3, 242, 16, 16, 0, + 1, 0, 0, 0, 95, 0, 0, 3, + 50, 16, 16, 0, 2, 0, 0, 0, +101, 0, 0, 3, 242, 32, 16, 0, + 0, 0, 0, 0, 101, 0, 0, 3, + 50, 32, 16, 0, 1, 0, 0, 0, +103, 0, 0, 4, 242, 32, 16, 0, + 2, 0, 0, 0, 1, 0, 0, 0, +104, 0, 0, 2, 1, 0, 0, 0, + 54, 0, 0, 5, 242, 32, 16, 0, + 0, 0, 0, 0, 70, 30, 16, 0, + 0, 0, 0, 0, 54, 0, 0, 5, + 50, 32, 16, 0, 1, 0, 0, 0, + 70, 16, 16, 0, 2, 0, 0, 0, + 17, 0, 0, 8, 18, 0, 16, 0, + 0, 0, 0, 0, 70, 142, 32, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 70, 30, 16, 0, 1, 0, 0, 0, + 54, 0, 0, 6, 34, 32, 16, 0, + 2, 0, 0, 0, 10, 0, 16, 128, + 65, 0, 0, 0, 0, 0, 0, 0, + 17, 0, 0, 8, 18, 0, 16, 0, + 0, 0, 0, 0, 70, 142, 32, 0, + 0, 0, 0, 0, 2, 0, 0, 0, + 70, 30, 16, 0, 1, 0, 0, 0, + 17, 0, 0, 8, 34, 0, 16, 0, + 0, 0, 0, 0, 70, 142, 32, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 70, 30, 16, 0, 1, 0, 0, 0, + 0, 0, 0, 7, 18, 0, 16, 0, + 0, 0, 0, 0, 26, 0, 16, 0, + 0, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 54, 0, 0, 5, +130, 32, 16, 0, 2, 0, 0, 0, + 26, 0, 16, 0, 0, 0, 0, 0, + 56, 0, 0, 7, 66, 32, 16, 0, + 2, 0, 0, 0, 10, 0, 16, 0, + 0, 0, 0, 0, 1, 64, 0, 0, + 0, 0, 0, 63, 17, 0, 0, 8, + 18, 32, 16, 0, 2, 0, 0, 0, + 70, 142, 32, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 70, 30, 16, 0, + 1, 0, 0, 0, 62, 0, 0, 1, + 83, 84, 65, 84, 116, 0, 0, 0, + 11, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 6, 0, 0, 0, + 7, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 82, 68, 69, 70, +204, 0, 0, 0, 1, 0, 0, 0, + 72, 0, 0, 0, 1, 0, 0, 0, + 28, 0, 0, 0, 0, 4, 254, 255, + 0, 65, 0, 0, 152, 0, 0, 0, + 60, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 0, + 36, 71, 108, 111, 98, 97, 108, 115, + 0, 171, 171, 171, 60, 0, 0, 0, + 1, 0, 0, 0, 96, 0, 0, 0, + 64, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 120, 0, 0, 0, + 0, 0, 0, 0, 64, 0, 0, 0, + 2, 0, 0, 0, 136, 0, 0, 0, + 0, 0, 0, 0, 95, 67, 67, 95, + 77, 86, 80, 77, 97, 116, 114, 105, +120, 0, 171, 171, 3, 0, 3, 0, + 4, 0, 4, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 77, 105, 99, 114, +111, 115, 111, 102, 116, 32, 40, 82, + 41, 32, 72, 76, 83, 76, 32, 83, +104, 97, 100, 101, 114, 32, 67, 111, +109, 112, 105, 108, 101, 114, 32, 54, + 46, 51, 46, 57, 54, 48, 48, 46, + 49, 54, 51, 56, 52, 0, 171, 171, + 73, 83, 71, 78, 92, 0, 0, 0, + 3, 0, 0, 0, 8, 0, 0, 0, + 80, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 0, 0, 0, 0, 15, 15, 0, 0, + 80, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 1, 0, 0, 0, 15, 15, 0, 0, + 80, 0, 0, 0, 2, 0, 0, 0, + 0, 0, 0, 0, 3, 0, 0, 0, + 2, 0, 0, 0, 3, 3, 0, 0, + 84, 69, 88, 67, 79, 79, 82, 68, + 0, 171, 171, 171, 79, 83, 71, 78, +104, 0, 0, 0, 3, 0, 0, 0, + 8, 0, 0, 0, 80, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 0, 0, 0, 0, + 15, 0, 0, 0, 80, 0, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 0, + 3, 0, 0, 0, 1, 0, 0, 0, + 3, 12, 0, 0, 89, 0, 0, 0, + 0, 0, 0, 0, 1, 0, 0, 0, + 3, 0, 0, 0, 2, 0, 0, 0, + 15, 0, 0, 0, 84, 69, 88, 67, + 79, 79, 82, 68, 0, 83, 86, 95, + 80, 111, 115, 105, 116, 105, 111, 110, + 0, 171, 171, 171, +}; + const unsigned char s_E2C7CE1244DE9C76688EFA9463B2A130B6A08893[] = { 166, 147, 0, 0, 142, 9, 2, 1, @@ -6427,7 +6526,7 @@ const unsigned char s_E2C7CE1244DE9C76688EFA9463B2A130B6A08893[] = { 77, 97, 116, 114, 105, 120, 0, 0, 0, 0, 0, 0, 0, 0, 204, 2, 0, 0, 144, 4, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 127, 145, 81, 72, 216, 190, 16, 61, 245, 231, @@ -6757,7 +6856,7 @@ const unsigned char s_E2D56227712263272BD5218FEA117CD06180F81B[] = { 117, 95, 112, 111, 105, 110, 116, 83, 105, 122, 101, 0, 0, 0, 0, 2, 0, 0, 0, 204, 2, 0, 0, 208, - 4, 0, 0, 0, 0, 0, 0, 173, + 4, 0, 0, 0, 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 127, 145, 81, 72, 216, @@ -7108,7 +7207,7 @@ const unsigned char s_F46558C274182079784898CF4968CF431593D5E2[] = { 116, 67, 111, 108, 111, 114, 0, 0, 0, 0, 3, 0, 0, 0, 108, 6, 0, 0, 4, 5, 0, 0, 0, 0, - 0, 0, 173, 144, 0, 0, 0, 0, + 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 47, 220, 115, 183, 137, 174, 141, 96, 204, 60, @@ -7564,7 +7663,7 @@ const unsigned char s_F6BA4519AF2653A53D57FB5D5508F0D8617105D6[] = { 101, 120, 116, 117, 114, 101, 48, 0, 0, 0, 0, 1, 0, 0, 0, 156, 3, 0, 0, 144, 4, 0, 0, 0, - 0, 0, 0, 173, 144, 0, 0, 0, + 0, 0, 0, 221, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 88, 66, 67, 203, 117, 183, 110, 154, 52, 220, 70, 125, @@ -7831,6 +7930,6 @@ const unsigned char s_F6BA4519AF2653A53D57FB5D5508F0D8617105D6[] = { }; const int s_numPrograms = 18; -const int s_programLengths[] = {2990,2528,4102,3022,2996,3358,2982,3073,2559,3300,3350,3025,3556,9465,2502,2675,3746,2775}; -const unsigned char* s_programs[] = {s_133478C5A874C1E6F59B418CE6C7C39F1AE0F873,s_13E33F532157A58EC77EDE3B3112560A89D272B2,s_1A69A7CC77C7C8FC62799B0513816EA41FBF3BFE,s_53938AB67AD93ABA0DDB87F3C9889304284E011E,s_67837675F2BB48C0E926316F505FC1538228E0FA,s_78250E25D1929D4A842050738140787BE42541C6,s_7B67DD242152D35ACC079265FAD9D03DC98182DE,s_7CE5EE84ACB6110F7FA29152ECE3344CB6D6620D,s_7E1EEF397305D0BC2DCDBA4F2DAFBCBA1534E45C,s_847DBFDDA6EC09C57E4ED43012AE2FB5CAC7D8D5,s_92BE325B516F887D2C928EDE20ADF428DB01C038,s_A2377A827972A5466DA8637681045D32DA8A817D,s_B5E27B4F3CF7236633255B28CBA530D6EE5CED86,s_BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749,s_E2C7CE1244DE9C76688EFA9463B2A130B6A08893,s_E2D56227712263272BD5218FEA117CD06180F81B,s_F46558C274182079784898CF4968CF431593D5E2,s_F6BA4519AF2653A53D57FB5D5508F0D8617105D6}; -const char* s_programKeys[] = {"133478C5A874C1E6F59B418CE6C7C39F1AE0F873","13E33F532157A58EC77EDE3B3112560A89D272B2","1A69A7CC77C7C8FC62799B0513816EA41FBF3BFE","53938AB67AD93ABA0DDB87F3C9889304284E011E","67837675F2BB48C0E926316F505FC1538228E0FA","78250E25D1929D4A842050738140787BE42541C6","7B67DD242152D35ACC079265FAD9D03DC98182DE","7CE5EE84ACB6110F7FA29152ECE3344CB6D6620D","7E1EEF397305D0BC2DCDBA4F2DAFBCBA1534E45C","847DBFDDA6EC09C57E4ED43012AE2FB5CAC7D8D5","92BE325B516F887D2C928EDE20ADF428DB01C038","A2377A827972A5466DA8637681045D32DA8A817D","B5E27B4F3CF7236633255B28CBA530D6EE5CED86","BF29CAEBBDC45A5100A66F92B9FD1F54BF3E6749","E2C7CE1244DE9C76688EFA9463B2A130B6A08893","E2D56227712263272BD5218FEA117CD06180F81B","F46558C274182079784898CF4968CF431593D5E2","F6BA4519AF2653A53D57FB5D5508F0D8617105D6"}; +const int s_programLengths[] = {2990,2528,4102,3022,2996,3358,2982,3073,2559,3300,3350,10261,3025,3556,2502,2675,3746,2775}; +const unsigned char* s_programs[] = {s_133478C5A874C1E6F59B418CE6C7C39F1AE0F873,s_13E33F532157A58EC77EDE3B3112560A89D272B2,s_1A69A7CC77C7C8FC62799B0513816EA41FBF3BFE,s_53938AB67AD93ABA0DDB87F3C9889304284E011E,s_67837675F2BB48C0E926316F505FC1538228E0FA,s_78250E25D1929D4A842050738140787BE42541C6,s_7B67DD242152D35ACC079265FAD9D03DC98182DE,s_7CE5EE84ACB6110F7FA29152ECE3344CB6D6620D,s_7E1EEF397305D0BC2DCDBA4F2DAFBCBA1534E45C,s_847DBFDDA6EC09C57E4ED43012AE2FB5CAC7D8D5,s_92BE325B516F887D2C928EDE20ADF428DB01C038,s_976D0E98457C40DFC2F0FBD00E30607C9E4CFDAE,s_A2377A827972A5466DA8637681045D32DA8A817D,s_B5E27B4F3CF7236633255B28CBA530D6EE5CED86,s_E2C7CE1244DE9C76688EFA9463B2A130B6A08893,s_E2D56227712263272BD5218FEA117CD06180F81B,s_F46558C274182079784898CF4968CF431593D5E2,s_F6BA4519AF2653A53D57FB5D5508F0D8617105D6}; +const char* s_programKeys[] = {"133478C5A874C1E6F59B418CE6C7C39F1AE0F873","13E33F532157A58EC77EDE3B3112560A89D272B2","1A69A7CC77C7C8FC62799B0513816EA41FBF3BFE","53938AB67AD93ABA0DDB87F3C9889304284E011E","67837675F2BB48C0E926316F505FC1538228E0FA","78250E25D1929D4A842050738140787BE42541C6","7B67DD242152D35ACC079265FAD9D03DC98182DE","7CE5EE84ACB6110F7FA29152ECE3344CB6D6620D","7E1EEF397305D0BC2DCDBA4F2DAFBCBA1534E45C","847DBFDDA6EC09C57E4ED43012AE2FB5CAC7D8D5","92BE325B516F887D2C928EDE20ADF428DB01C038","976D0E98457C40DFC2F0FBD00E30607C9E4CFDAE","A2377A827972A5466DA8637681045D32DA8A817D","B5E27B4F3CF7236633255B28CBA530D6EE5CED86","E2C7CE1244DE9C76688EFA9463B2A130B6A08893","E2D56227712263272BD5218FEA117CD06180F81B","F46558C274182079784898CF4968CF431593D5E2","F6BA4519AF2653A53D57FB5D5508F0D8617105D6"}; diff --git a/cocos/scripting/lua-bindings/Android.mk b/cocos/scripting/lua-bindings/Android.mk index c926b1d11c..aa2c13f5e3 100644 --- a/cocos/scripting/lua-bindings/Android.mk +++ b/cocos/scripting/lua-bindings/Android.mk @@ -23,6 +23,7 @@ LOCAL_SRC_FILES := manual/CCLuaBridge.cpp \ manual/lua_cocos2dx_ui_manual.cpp \ manual/lua_cocos2dx_spine_manual.cpp \ manual/lua_cocos2dx_physics_manual.cpp \ + manual/lua_cocos2dx_experimental_manual.cpp \ manual/lua_cocos2dx_experimental_video_manual.cpp \ manual/lua_cocos2dx_deprecated.cpp \ manual/lua_xml_http_request.cpp \ @@ -36,6 +37,7 @@ LOCAL_SRC_FILES := manual/CCLuaBridge.cpp \ auto/lua_cocos2dx_ui_auto.cpp \ auto/lua_cocos2dx_spine_auto.cpp \ auto/lua_cocos2dx_physics_auto.cpp \ + auto/lua_cocos2dx_experimental_auto.cpp \ auto/lua_cocos2dx_experimental_video_auto.cpp \ ../../../external/lua/tolua/tolua_event.c \ ../../../external/lua/tolua/tolua_is.c \ diff --git a/cocos/scripting/lua-bindings/CMakeLists.txt b/cocos/scripting/lua-bindings/CMakeLists.txt index 9ac8d5f1ff..1f414b9005 100644 --- a/cocos/scripting/lua-bindings/CMakeLists.txt +++ b/cocos/scripting/lua-bindings/CMakeLists.txt @@ -5,6 +5,7 @@ set(LUABINDING_SRC auto/lua_cocos2dx_ui_auto.cpp auto/lua_cocos2dx_spine_auto.cpp auto/lua_cocos2dx_physics_auto.cpp + auto/lua_cocos2dx_experimental_auto.cpp manual/tolua_fix.cpp manual/CCLuaBridge.cpp manual/CCLuaEngine.cpp @@ -24,6 +25,7 @@ set(LUABINDING_SRC manual/lua_cocos2dx_deprecated.cpp manual/lua_xml_http_request.cpp manual/LuaSkeletonAnimation.cpp + manual/lua_cocos2dx_experimental_manual.cpp ) include_directories( diff --git a/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua b/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua index 5b2004def4..00beabfed2 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: setEye(float, float, float) --- --- overload function: setEye(vec3_table) --- +-- @overload self, float, float, float +-- @overload self, vec3_table -- @function [parent=#ActionCamera] setEye -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua index ae69470263..1be2073a67 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua @@ -5,10 +5,8 @@ -- @parent_module ccs -------------------------------- --- overload function: getAction(float, ccs.ActionFrame) --- --- overload function: getAction(float) --- +-- @overload self, float, ccs.ActionFrame +-- @overload self, float -- @function [parent=#ActionFrame] getAction -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua b/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua index 5b32f95601..9d6a8e14b4 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua @@ -5,10 +5,8 @@ -- @parent_module ccs -------------------------------- --- overload function: playActionByName(char, char, cc.CallFunc) --- --- overload function: playActionByName(char, char) --- +-- @overload self, char, char, cc.CallFunc +-- @overload self, char, char -- @function [parent=#ActionManagerEx] playActionByName -- @param self -- @param #char char @@ -23,14 +21,6 @@ -- @param #char char -- @return ActionObject#ActionObject ret (return value: ccs.ActionObject) --------------------------------- --- @function [parent=#ActionManagerEx] initWithBinary --- @param self --- @param #char char --- @param #cc.Ref ref --- @param #ccs.CocoLoader cocoloader --- @param #ccs.stExpCocoNode stexpcoconode - -------------------------------- -- @function [parent=#ActionManagerEx] releaseActions -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionObject.lua b/cocos/scripting/lua-bindings/auto/api/ActionObject.lua index bc1d74c131..93f6dec2ec 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionObject.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionObject.lua @@ -38,10 +38,8 @@ -- @param self -------------------------------- --- overload function: play(cc.CallFunc) --- --- overload function: play() --- +-- @overload self, cc.CallFunc +-- @overload self -- @function [parent=#ActionObject] play -- @param self -- @param #cc.CallFunc callfunc @@ -61,13 +59,6 @@ -- @param self -- @return bool#bool ret (return value: bool) --------------------------------- --- @function [parent=#ActionObject] initWithBinary --- @param self --- @param #ccs.CocoLoader cocoloader --- @param #ccs.stExpCocoNode stexpcoconode --- @param #cc.Ref ref - -------------------------------- -- @function [parent=#ActionObject] addActionNode -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua index 685d82d1f3..267c36c133 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua @@ -10,10 +10,8 @@ -- @param #float float -------------------------------- --- overload function: getAction(float, ccs.ActionFrame) --- --- overload function: getAction(float) --- +-- @overload self, float, ccs.ActionFrame +-- @overload self, float -- @function [parent=#ActionRotationFrame] getAction -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua b/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua index 5a22f5c635..5cc4299820 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua @@ -83,14 +83,10 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: gotoFrameAndPlay(int, bool) --- --- overload function: gotoFrameAndPlay(int) --- --- overload function: gotoFrameAndPlay(int, int, bool) --- --- overload function: gotoFrameAndPlay(int, int, int, bool) --- +-- @overload self, int, bool +-- @overload self, int +-- @overload self, int, int, bool +-- @overload self, int, int, int, bool -- @function [parent=#ActionTimeline] gotoFrameAndPlay -- @param self -- @param #int int diff --git a/cocos/scripting/lua-bindings/auto/api/Animate.lua b/cocos/scripting/lua-bindings/auto/api/Animate.lua index 88cddd28ac..de15070b65 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animate.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animate.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: getAnimation() --- --- overload function: getAnimation() --- +-- @overload self +-- @overload self -- @function [parent=#Animate] getAnimation -- @param self -- @return Animation#Animation ret (retunr value: cc.Animation) diff --git a/cocos/scripting/lua-bindings/auto/api/Animate3D.lua b/cocos/scripting/lua-bindings/auto/api/Animate3D.lua index 4657cc4cb8..f49ae32b24 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animate3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animate3D.lua @@ -25,10 +25,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: create(cc.Animation3D, float, float) --- --- overload function: create(cc.Animation3D) --- +-- @overload self, cc.Animation3D, float, float +-- @overload self, cc.Animation3D -- @function [parent=#Animate3D] create -- @param self -- @param #cc.Animation3D animation3d diff --git a/cocos/scripting/lua-bindings/auto/api/Animation.lua b/cocos/scripting/lua-bindings/auto/api/Animation.lua index faf6075804..43b1d28a90 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animation.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animation.lua @@ -76,10 +76,8 @@ -- @param #rect_table rect -------------------------------- --- overload function: create(array_table, float, unsigned int) --- --- overload function: create() --- +-- @overload self, array_table, float, unsigned int +-- @overload self -- @function [parent=#Animation] create -- @param self -- @param #array_table array diff --git a/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua b/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua index 949e62a474..9bdd79a93c 100644 --- a/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua @@ -10,10 +10,8 @@ -- @param #cc.SpriteFrame spriteframe -------------------------------- --- overload function: getUserInfo() --- --- overload function: getUserInfo() --- +-- @overload self +-- @overload self -- @function [parent=#AnimationFrame] getUserInfo -- @param self -- @return map_table#map_table ret (retunr value: map_table) diff --git a/cocos/scripting/lua-bindings/auto/api/Application.lua b/cocos/scripting/lua-bindings/auto/api/Application.lua index 898e3301c4..ed1bc8e3e4 100644 --- a/cocos/scripting/lua-bindings/auto/api/Application.lua +++ b/cocos/scripting/lua-bindings/auto/api/Application.lua @@ -6,7 +6,7 @@ -------------------------------- -- @function [parent=#Application] getTargetPlatform -- @param self --- @return ApplicationProtocol::Platform#ApplicationProtocol::Platform ret (return value: cc.ApplicationProtocol::Platform) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Application] getCurrentLanguageCode @@ -16,7 +16,7 @@ -------------------------------- -- @function [parent=#Application] getCurrentLanguage -- @param self --- @return LanguageType#LanguageType ret (return value: cc.LanguageType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Application] setAnimationInterval diff --git a/cocos/scripting/lua-bindings/auto/api/Armature.lua b/cocos/scripting/lua-bindings/auto/api/Armature.lua index 1d9edfe029..3a64f91aad 100644 --- a/cocos/scripting/lua-bindings/auto/api/Armature.lua +++ b/cocos/scripting/lua-bindings/auto/api/Armature.lua @@ -59,12 +59,9 @@ -- @return BatchNode#BatchNode ret (return value: ccs.BatchNode) -------------------------------- --- overload function: init(string) --- --- overload function: init() --- --- overload function: init(string, ccs.Bone) --- +-- @overload self, string +-- @overload self +-- @overload self, string, ccs.Bone -- @function [parent=#Armature] init -- @param self -- @param #string str @@ -117,12 +114,9 @@ -- @return map_table#map_table ret (return value: map_table) -------------------------------- --- overload function: create(string) --- --- overload function: create() --- --- overload function: create(string, ccs.Bone) --- +-- @overload self, string +-- @overload self +-- @overload self, string, ccs.Bone -- @function [parent=#Armature] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua b/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua index 67cf95040a..8afaf2f804 100644 --- a/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua @@ -22,10 +22,8 @@ -- @param #string str -------------------------------- --- overload function: addArmatureFileInfo(string, string, string) --- --- overload function: addArmatureFileInfo(string) --- +-- @overload self, string, string, string +-- @overload self, string -- @function [parent=#ArmatureDataManager] addArmatureFileInfo -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/BatchNode.lua b/cocos/scripting/lua-bindings/auto/api/BatchNode.lua index 9f3dd96554..dfb42d2e5e 100644 --- a/cocos/scripting/lua-bindings/auto/api/BatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/BatchNode.lua @@ -15,10 +15,8 @@ -- @return BatchNode#BatchNode ret (return value: ccs.BatchNode) -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#BatchNode] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/Bone.lua b/cocos/scripting/lua-bindings/auto/api/Bone.lua index 3d6e41ff59..9b646e61db 100644 --- a/cocos/scripting/lua-bindings/auto/api/Bone.lua +++ b/cocos/scripting/lua-bindings/auto/api/Bone.lua @@ -60,7 +60,7 @@ -------------------------------- -- @function [parent=#Bone] getDisplayRenderNodeType -- @param self --- @return DisplayType#DisplayType ret (return value: ccs.DisplayType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Bone] removeDisplay @@ -73,10 +73,8 @@ -- @param #ccs.BoneData bonedata -------------------------------- --- overload function: init(string) --- --- overload function: init() --- +-- @overload self, string +-- @overload self -- @function [parent=#Bone] init -- @param self -- @param #string str @@ -88,10 +86,8 @@ -- @param #ccs.Bone bone -------------------------------- --- overload function: addDisplay(cc.Node, int) --- --- overload function: addDisplay(ccs.DisplayData, int) --- +-- @overload self, cc.Node, int +-- @overload self, ccs.DisplayData, int -- @function [parent=#Bone] addDisplay -- @param self -- @param #ccs.DisplayData displaydata @@ -171,10 +167,8 @@ -- @return BoneData#BoneData ret (return value: ccs.BoneData) -------------------------------- --- overload function: create(string) --- --- overload function: create() --- +-- @overload self, string +-- @overload self -- @function [parent=#Bone] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/Button.lua b/cocos/scripting/lua-bindings/auto/api/Button.lua index 68617b166f..01e2a2990d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Button.lua +++ b/cocos/scripting/lua-bindings/auto/api/Button.lua @@ -43,7 +43,7 @@ -- @function [parent=#Button] loadTextureDisabled -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Button] setTitleText @@ -59,7 +59,7 @@ -- @function [parent=#Button] loadTexturePressed -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Button] setTitleFontName @@ -82,7 +82,7 @@ -- @param #string str -- @param #string str -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Button] isScale9Enabled @@ -93,7 +93,7 @@ -- @function [parent=#Button] loadTextureNormal -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Button] setCapInsetsPressedRenderer @@ -121,16 +121,14 @@ -- @param #bool bool -------------------------------- --- overload function: create(string, string, string, ccui.Widget::TextureResType) --- --- overload function: create() --- +-- @overload self, string, string, string, int +-- @overload self -- @function [parent=#Button] create -- @param self -- @param #string str -- @param #string str -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -- @return Button#Button ret (retunr value: ccui.Button) -------------------------------- diff --git a/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua b/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua index d84aabd278..1238d0c551 100644 --- a/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua @@ -101,7 +101,7 @@ -------------------------------- -- @function [parent=#CCBAnimationManager] addDocumentCallbackControlEvents -- @param self --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#CCBAnimationManager] init diff --git a/cocos/scripting/lua-bindings/auto/api/CCBReader.lua b/cocos/scripting/lua-bindings/auto/api/CCBReader.lua index dc6a1e4d0d..b6fe92d042 100644 --- a/cocos/scripting/lua-bindings/auto/api/CCBReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/CCBReader.lua @@ -17,7 +17,7 @@ -------------------------------- -- @function [parent=#CCBReader] addDocumentCallbackControlEvents -- @param self --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#CCBReader] setCCBRootPath @@ -63,7 +63,7 @@ -------------------------------- -- @function [parent=#CCBReader] addOwnerCallbackControlEvents -- @param self --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#CCBReader] getOwnerOutletNames @@ -102,12 +102,9 @@ -- @param #float float -------------------------------- --- overload function: CCBReader(cc.CCBReader) --- --- overload function: CCBReader(cc.NodeLoaderLibrary, cc.CCBMemberVariableAssigner, cc.CCBSelectorResolver, cc.NodeLoaderListener) --- --- overload function: CCBReader() --- +-- @overload self, cc.CCBReader +-- @overload self, cc.NodeLoaderLibrary, cc.CCBMemberVariableAssigner, cc.CCBSelectorResolver, cc.NodeLoaderListener +-- @overload self -- @function [parent=#CCBReader] CCBReader -- @param self -- @param #cc.NodeLoaderLibrary nodeloaderlibrary diff --git a/cocos/scripting/lua-bindings/auto/api/CheckBox.lua b/cocos/scripting/lua-bindings/auto/api/CheckBox.lua index 3768859a61..fe0f55b6f8 100644 --- a/cocos/scripting/lua-bindings/auto/api/CheckBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/CheckBox.lua @@ -13,13 +13,13 @@ -- @function [parent=#CheckBox] loadTextureBackGroundSelected -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#CheckBox] loadTextureBackGroundDisabled -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#CheckBox] addEventListener @@ -30,7 +30,7 @@ -- @function [parent=#CheckBox] loadTextureFrontCross -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#CheckBox] loadTextures @@ -40,13 +40,13 @@ -- @param #string str -- @param #string str -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#CheckBox] loadTextureBackGround -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#CheckBox] setSelectedState @@ -57,13 +57,11 @@ -- @function [parent=#CheckBox] loadTextureFrontCrossDisabled -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- --- overload function: create(string, string, string, string, string, ccui.Widget::TextureResType) --- --- overload function: create() --- +-- @overload self, string, string, string, string, string, int +-- @overload self -- @function [parent=#CheckBox] create -- @param self -- @param #string str @@ -71,7 +69,7 @@ -- @param #string str -- @param #string str -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -- @return CheckBox#CheckBox ret (retunr value: ccui.CheckBox) -------------------------------- diff --git a/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua b/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua index d02fa5c3b4..f9ac0622a2 100644 --- a/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua @@ -35,10 +35,8 @@ -- @param #float float -------------------------------- --- overload function: create(cc.Node) --- --- overload function: create() --- +-- @overload self, cc.Node +-- @overload self -- @function [parent=#ClippingNode] create -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/ComAudio.lua b/cocos/scripting/lua-bindings/auto/api/ComAudio.lua index 09482e2d34..b7d19dbb4b 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComAudio.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComAudio.lua @@ -38,10 +38,8 @@ -- @param self -------------------------------- --- overload function: stopBackgroundMusic() --- --- overload function: stopBackgroundMusic(bool) --- +-- @overload self +-- @overload self, bool -- @function [parent=#ComAudio] stopBackgroundMusic -- @param self -- @param #bool bool @@ -74,24 +72,18 @@ -- @param #char char -------------------------------- --- overload function: playBackgroundMusic(char) --- --- overload function: playBackgroundMusic(char, bool) --- --- overload function: playBackgroundMusic() --- +-- @overload self, char +-- @overload self, char, bool +-- @overload self -- @function [parent=#ComAudio] playBackgroundMusic -- @param self -- @param #char char -- @param #bool bool -------------------------------- --- overload function: playEffect(char) --- --- overload function: playEffect(char, bool) --- --- overload function: playEffect() --- +-- @overload self, char +-- @overload self, char, bool +-- @overload self -- @function [parent=#ComAudio] playEffect -- @param self -- @param #char char diff --git a/cocos/scripting/lua-bindings/auto/api/ComRender.lua b/cocos/scripting/lua-bindings/auto/api/ComRender.lua index 014cb4e1e9..9c69bbac35 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComRender.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComRender.lua @@ -15,10 +15,8 @@ -- @return Node#Node ret (return value: cc.Node) -------------------------------- --- overload function: create(cc.Node, char) --- --- overload function: create() --- +-- @overload self, cc.Node, char +-- @overload self -- @function [parent=#ComRender] create -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/Control.lua b/cocos/scripting/lua-bindings/auto/api/Control.lua index 40bcd17e69..8e832134da 100644 --- a/cocos/scripting/lua-bindings/auto/api/Control.lua +++ b/cocos/scripting/lua-bindings/auto/api/Control.lua @@ -18,7 +18,7 @@ -------------------------------- -- @function [parent=#Control] getState -- @param self --- @return Control::State#Control::State ret (return value: cc.Control::State) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Control] onTouchEnded @@ -29,7 +29,7 @@ -------------------------------- -- @function [parent=#Control] sendActionsForControlEvents -- @param self --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#Control] setSelected diff --git a/cocos/scripting/lua-bindings/auto/api/ControlButton.lua b/cocos/scripting/lua-bindings/auto/api/ControlButton.lua index 3b1d35b203..005e6b28da 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlButton.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlButton.lua @@ -18,7 +18,7 @@ -- @function [parent=#ControlButton] setTitleLabelForState -- @param self -- @param #cc.Node node --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setAdjustBackgroundImage @@ -39,7 +39,7 @@ -- @function [parent=#ControlButton] setTitleForState -- @param self -- @param #string str --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setLabelAnchorPoint @@ -54,20 +54,20 @@ -------------------------------- -- @function [parent=#ControlButton] getTitleTTFSizeForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return float#float ret (return value: float) -------------------------------- -- @function [parent=#ControlButton] setTitleTTFForState -- @param self -- @param #string str --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setTitleTTFSizeForState -- @param self -- @param #float float --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setTitleLabel @@ -92,7 +92,7 @@ -------------------------------- -- @function [parent=#ControlButton] getBackgroundSpriteForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return Scale9Sprite#Scale9Sprite ret (return value: cc.Scale9Sprite) -------------------------------- @@ -105,10 +105,8 @@ -- @param self -------------------------------- --- overload function: getCurrentTitle() --- --- overload function: getCurrentTitle() --- +-- @overload self +-- @overload self -- @function [parent=#ControlButton] getCurrentTitle -- @param self -- @return string#string ret (retunr value: string) @@ -121,7 +119,7 @@ -------------------------------- -- @function [parent=#ControlButton] getTitleTTFForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return string#string ret (return value: string) -------------------------------- @@ -132,14 +130,14 @@ -------------------------------- -- @function [parent=#ControlButton] getTitleColorForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- -- @function [parent=#ControlButton] setTitleColorForState -- @param self -- @param #color3b_table color3b --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] doesAdjustBackgroundImage @@ -150,13 +148,13 @@ -- @function [parent=#ControlButton] setBackgroundSpriteFrameForState -- @param self -- @param #cc.SpriteFrame spriteframe --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setBackgroundSpriteForState -- @param self -- @param #cc.Scale9Sprite scale9sprite --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] setScaleRatio @@ -186,7 +184,7 @@ -------------------------------- -- @function [parent=#ControlButton] getTitleLabelForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return Node#Node ret (return value: cc.Node) -------------------------------- @@ -199,12 +197,12 @@ -- @function [parent=#ControlButton] setTitleBMFontForState -- @param self -- @param #string str --- @param #cc.Control::State state +-- @param #int state -------------------------------- -- @function [parent=#ControlButton] getTitleBMFontForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return string#string ret (return value: string) -------------------------------- @@ -215,18 +213,14 @@ -------------------------------- -- @function [parent=#ControlButton] getTitleForState -- @param self --- @param #cc.Control::State state +-- @param #int state -- @return string#string ret (return value: string) -------------------------------- --- overload function: create(cc.Scale9Sprite) --- --- overload function: create() --- --- overload function: create(cc.Node, cc.Scale9Sprite) --- --- overload function: create(string, string, float) --- +-- @overload self, cc.Scale9Sprite +-- @overload self +-- @overload self, cc.Node, cc.Scale9Sprite +-- @overload self, string, string, float -- @function [parent=#ControlButton] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua b/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua index 0f79c5fa2e..f7e3e3cbe2 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua @@ -23,7 +23,7 @@ -- @function [parent=#ControlColourPicker] hueSliderValueChanged -- @param self -- @param #cc.Ref ref --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#ControlColourPicker] getcolourPicker @@ -49,7 +49,7 @@ -- @function [parent=#ControlColourPicker] colourSliderValueChanged -- @param self -- @param #cc.Ref ref --- @param #cc.Control::EventType eventtype +-- @param #int eventtype -------------------------------- -- @function [parent=#ControlColourPicker] setHuePicker diff --git a/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua b/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua index 9708cfea37..d192cf7a93 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua @@ -80,10 +80,8 @@ -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- --- overload function: initWithSprites(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite) --- --- overload function: initWithSprites(cc.Sprite, cc.Sprite, cc.Sprite) --- +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSlider] initWithSprites -- @param self -- @param #cc.Sprite sprite @@ -129,14 +127,10 @@ -- @param #float float -------------------------------- --- overload function: create(cc.Sprite, cc.Sprite, cc.Sprite) --- --- overload function: create(char, char, char) --- --- overload function: create(char, char, char, char) --- --- overload function: create(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite) --- +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite +-- @overload self, char, char, char +-- @overload self, char, char, char, char +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSlider] create -- @param self -- @param #cc.Sprite sprite diff --git a/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua b/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua index f553d252b2..fdff4eddfa 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua @@ -10,10 +10,8 @@ -- @param #bool bool -------------------------------- --- overload function: setOn(bool) --- --- overload function: setOn(bool, bool) --- +-- @overload self, bool +-- @overload self, bool, bool -- @function [parent=#ControlSwitch] setOn -- @param self -- @param #bool bool @@ -25,10 +23,8 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: initWithMaskSprite(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label) --- --- overload function: initWithMaskSprite(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite) --- +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSwitch] initWithMaskSprite -- @param self -- @param #cc.Sprite sprite @@ -51,10 +47,8 @@ -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- --- overload function: create(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite) --- --- overload function: create(cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label) --- +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite +-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label -- @function [parent=#ControlSwitch] create -- @param self -- @param #cc.Sprite sprite diff --git a/cocos/scripting/lua-bindings/auto/api/Director.lua b/cocos/scripting/lua-bindings/auto/api/Director.lua index 1215d9dd17..6d684c5988 100644 --- a/cocos/scripting/lua-bindings/auto/api/Director.lua +++ b/cocos/scripting/lua-bindings/auto/api/Director.lua @@ -40,7 +40,7 @@ -------------------------------- -- @function [parent=#Director] pushMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -------------------------------- -- @function [parent=#Director] setGLDefaultValues @@ -63,7 +63,7 @@ -------------------------------- -- @function [parent=#Director] loadMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -- @param #mat4_table mat4 -------------------------------- @@ -217,7 +217,7 @@ -------------------------------- -- @function [parent=#Director] getMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- @@ -232,12 +232,12 @@ -------------------------------- -- @function [parent=#Director] setProjection -- @param self --- @param #cc.Director::Projection projection +-- @param #int projection -------------------------------- -- @function [parent=#Director] loadIdentityMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -------------------------------- -- @function [parent=#Director] setNextDeltaTimeZero @@ -251,7 +251,7 @@ -------------------------------- -- @function [parent=#Director] popMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -------------------------------- -- @function [parent=#Director] getVisibleSize @@ -296,7 +296,7 @@ -------------------------------- -- @function [parent=#Director] multiplyMatrix -- @param self --- @param #cc.MATRIX_STACK_TYPE matrix_stack_type +-- @param #int matrix_stack_type -- @param #mat4_table mat4 -------------------------------- diff --git a/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua b/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua index c194aa4e8f..0739f44691 100644 --- a/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua @@ -17,7 +17,7 @@ -------------------------------- -- @function [parent=#DisplayManager] getDisplayRenderNodeType -- @param self --- @return DisplayType#DisplayType ret (return value: ccs.DisplayType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#DisplayManager] removeDisplay @@ -46,20 +46,16 @@ -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- --- overload function: addDisplay(cc.Node, int) --- --- overload function: addDisplay(ccs.DisplayData, int) --- +-- @overload self, cc.Node, int +-- @overload self, ccs.DisplayData, int -- @function [parent=#DisplayManager] addDisplay -- @param self -- @param #ccs.DisplayData displaydata -- @param #int int -------------------------------- --- overload function: containPoint(float, float) --- --- overload function: containPoint(vec2_table) --- +-- @overload self, float, float +-- @overload self, vec2_table -- @function [parent=#DisplayManager] containPoint -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua index 82c112dcd2..b38769fd4d 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(cc.ActionInterval) --- --- overload function: create(cc.ActionInterval, float) --- +-- @overload self, cc.ActionInterval +-- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticIn] create -- @param self -- @param #cc.ActionInterval actioninterval diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua index b6df287c83..5d836c34ae 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(cc.ActionInterval) --- --- overload function: create(cc.ActionInterval, float) --- +-- @overload self, cc.ActionInterval +-- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticInOut] create -- @param self -- @param #cc.ActionInterval actioninterval diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua index c735a4bc0c..a3a2498473 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(cc.ActionInterval) --- --- overload function: create(cc.ActionInterval, float) --- +-- @overload self, cc.ActionInterval +-- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticOut] create -- @param self -- @param #cc.ActionInterval actioninterval diff --git a/cocos/scripting/lua-bindings/auto/api/EditBox.lua b/cocos/scripting/lua-bindings/auto/api/EditBox.lua index dd67151c56..35579ac4c8 100644 --- a/cocos/scripting/lua-bindings/auto/api/EditBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/EditBox.lua @@ -32,7 +32,7 @@ -------------------------------- -- @function [parent=#EditBox] setInputMode -- @param self --- @param #cc.EditBox::InputMode inputmode +-- @param #int inputmode -------------------------------- -- @function [parent=#EditBox] setPlaceholderFontColor @@ -70,12 +70,12 @@ -------------------------------- -- @function [parent=#EditBox] setReturnType -- @param self --- @param #cc.EditBox::KeyboardReturnType keyboardreturntype +-- @param #int keyboardreturntype -------------------------------- -- @function [parent=#EditBox] setInputFlag -- @param self --- @param #cc.EditBox::InputFlag inputflag +-- @param #int inputflag -------------------------------- -- @function [parent=#EditBox] getMaxLength diff --git a/cocos/scripting/lua-bindings/auto/api/Event.lua b/cocos/scripting/lua-bindings/auto/api/Event.lua index 293ef68255..aebf35b831 100644 --- a/cocos/scripting/lua-bindings/auto/api/Event.lua +++ b/cocos/scripting/lua-bindings/auto/api/Event.lua @@ -12,7 +12,7 @@ -------------------------------- -- @function [parent=#Event] getType -- @param self --- @return Event::Type#Event::Type ret (return value: cc.Event::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Event] getCurrentTarget diff --git a/cocos/scripting/lua-bindings/auto/api/EventController.lua b/cocos/scripting/lua-bindings/auto/api/EventController.lua index 289b55d97c..e727158d6f 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventController.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventController.lua @@ -7,7 +7,7 @@ -------------------------------- -- @function [parent=#EventController] getControllerEventType -- @param self --- @return EventController::ControllerEventType#EventController::ControllerEventType ret (return value: cc.EventController::ControllerEventType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#EventController] setConnectStatus @@ -35,13 +35,11 @@ -- @return int#int ret (return value: int) -------------------------------- --- overload function: EventController(cc.EventController::ControllerEventType, cc.Controller, bool) --- --- overload function: EventController(cc.EventController::ControllerEventType, cc.Controller, int) --- +-- @overload self, int, cc.Controller, bool +-- @overload self, int, cc.Controller, int -- @function [parent=#EventController] EventController -- @param self --- @param #cc.EventController::ControllerEventType controllereventtype +-- @param #int controllereventtype -- @param #cc.Controller controller -- @param #int int diff --git a/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua b/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua index b0c8468789..84c8901a93 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua @@ -79,7 +79,7 @@ -------------------------------- -- @function [parent=#EventDispatcher] removeEventListenersForType -- @param self --- @param #cc.EventListener::Type type +-- @param #int type -------------------------------- -- @function [parent=#EventDispatcher] EventDispatcher diff --git a/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua b/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua index 638f0797ce..86f722ae6b 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua @@ -7,7 +7,7 @@ -------------------------------- -- @function [parent=#EventKeyboard] EventKeyboard -- @param self --- @param #cc.EventKeyboard::KeyCode keycode +-- @param #int keycode -- @param #bool bool return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventMouse.lua b/cocos/scripting/lua-bindings/auto/api/EventMouse.lua index cb79459b55..b4327c9b51 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventMouse.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventMouse.lua @@ -49,6 +49,6 @@ -------------------------------- -- @function [parent=#EventMouse] EventMouse -- @param self --- @param #cc.EventMouse::MouseEventType mouseeventtype +-- @param #int mouseeventtype return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventTouch.lua b/cocos/scripting/lua-bindings/auto/api/EventTouch.lua index ab36b3dabc..d32256fd93 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventTouch.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventTouch.lua @@ -7,12 +7,12 @@ -------------------------------- -- @function [parent=#EventTouch] getEventCode -- @param self --- @return EventTouch::EventCode#EventTouch::EventCode ret (return value: cc.EventTouch::EventCode) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#EventTouch] setEventCode -- @param self --- @param #cc.EventTouch::EventCode eventcode +-- @param #int eventcode -------------------------------- -- @function [parent=#EventTouch] EventTouch diff --git a/cocos/scripting/lua-bindings/auto/api/FastTMXLayer.lua b/cocos/scripting/lua-bindings/auto/api/FastTMXLayer.lua deleted file mode 100644 index d159f6f54d..0000000000 --- a/cocos/scripting/lua-bindings/auto/api/FastTMXLayer.lua +++ /dev/null @@ -1,146 +0,0 @@ - --------------------------------- --- @module FastTMXLayer --- @extend Node --- @parent_module cc - --------------------------------- --- @function [parent=#FastTMXLayer] getPositionAt --- @param self --- @param #vec2_table vec2 --- @return vec2_table#vec2_table ret (return value: vec2_table) - --------------------------------- --- @function [parent=#FastTMXLayer] setLayerOrientation --- @param self --- @param #int int - --------------------------------- --- @function [parent=#FastTMXLayer] getLayerSize --- @param self --- @return size_table#size_table ret (return value: size_table) - --------------------------------- --- @function [parent=#FastTMXLayer] setMapTileSize --- @param self --- @param #size_table size - --------------------------------- --- @function [parent=#FastTMXLayer] getLayerOrientation --- @param self --- @return int#int ret (return value: int) - --------------------------------- --- @function [parent=#FastTMXLayer] setProperties --- @param self --- @param #map_table map - --------------------------------- --- @function [parent=#FastTMXLayer] setLayerName --- @param self --- @param #string str - --------------------------------- --- @function [parent=#FastTMXLayer] removeTileAt --- @param self --- @param #vec2_table vec2 - --------------------------------- --- overload function: getProperties() --- --- overload function: getProperties() --- --- @function [parent=#FastTMXLayer] getProperties --- @param self --- @return map_table#map_table ret (retunr value: map_table) - --------------------------------- --- @function [parent=#FastTMXLayer] setupTiles --- @param self - --------------------------------- --- @function [parent=#FastTMXLayer] setupTileSprite --- @param self --- @param #cc.Sprite sprite --- @param #vec2_table vec2 --- @param #int int - --------------------------------- --- overload function: setTileGID(int, vec2_table, cc.TMXTileFlags_) --- --- overload function: setTileGID(int, vec2_table) --- --- @function [parent=#FastTMXLayer] setTileGID --- @param self --- @param #int int --- @param #vec2_table vec2 --- @param #cc.TMXTileFlags_ tmxtileflags_ - --------------------------------- --- @function [parent=#FastTMXLayer] getMapTileSize --- @param self --- @return size_table#size_table ret (return value: size_table) - --------------------------------- --- @function [parent=#FastTMXLayer] getProperty --- @param self --- @param #string str --- @return Value#Value ret (return value: cc.Value) - --------------------------------- --- @function [parent=#FastTMXLayer] setLayerSize --- @param self --- @param #size_table size - --------------------------------- --- @function [parent=#FastTMXLayer] getLayerName --- @param self --- @return string#string ret (return value: string) - --------------------------------- --- @function [parent=#FastTMXLayer] setTileSet --- @param self --- @param #cc.TMXTilesetInfo tmxtilesetinfo - --------------------------------- --- @function [parent=#FastTMXLayer] getTileSet --- @param self --- @return TMXTilesetInfo#TMXTilesetInfo ret (return value: cc.TMXTilesetInfo) - --------------------------------- --- @function [parent=#FastTMXLayer] getTileAt --- @param self --- @param #vec2_table vec2 --- @return Sprite#Sprite ret (return value: cc.Sprite) - --------------------------------- --- @function [parent=#FastTMXLayer] create --- @param self --- @param #cc.TMXTilesetInfo tmxtilesetinfo --- @param #cc.TMXLayerInfo tmxlayerinfo --- @param #cc.TMXMapInfo map --- @return FastTMXLayer#FastTMXLayer ret (return value: cc.FastTMXLayer) - --------------------------------- --- @function [parent=#FastTMXLayer] removeChild --- @param self --- @param #cc.Node node --- @param #bool bool - --------------------------------- --- @function [parent=#FastTMXLayer] draw --- @param self --- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int - --------------------------------- --- @function [parent=#FastTMXLayer] getDescription --- @param self --- @return string#string ret (return value: string) - --------------------------------- --- @function [parent=#FastTMXLayer] FastTMXLayer --- @param self - -return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FastTMXTiledMap.lua b/cocos/scripting/lua-bindings/auto/api/FastTMXTiledMap.lua deleted file mode 100644 index 008fdc4b61..0000000000 --- a/cocos/scripting/lua-bindings/auto/api/FastTMXTiledMap.lua +++ /dev/null @@ -1,103 +0,0 @@ - --------------------------------- --- @module FastTMXTiledMap --- @extend Node --- @parent_module cc - --------------------------------- --- @function [parent=#FastTMXTiledMap] setObjectGroups --- @param self --- @param #array_table array - --------------------------------- --- @function [parent=#FastTMXTiledMap] getProperty --- @param self --- @param #string str --- @return Value#Value ret (return value: cc.Value) - --------------------------------- --- @function [parent=#FastTMXTiledMap] setMapSize --- @param self --- @param #size_table size - --------------------------------- --- @function [parent=#FastTMXTiledMap] getObjectGroup --- @param self --- @param #string str --- @return TMXObjectGroup#TMXObjectGroup ret (return value: cc.TMXObjectGroup) - --------------------------------- --- overload function: getObjectGroups() --- --- overload function: getObjectGroups() --- --- @function [parent=#FastTMXTiledMap] getObjectGroups --- @param self --- @return array_table#array_table ret (retunr value: array_table) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getTileSize --- @param self --- @return size_table#size_table ret (return value: size_table) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getMapSize --- @param self --- @return size_table#size_table ret (return value: size_table) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getProperties --- @param self --- @return map_table#map_table ret (return value: map_table) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getPropertiesForGID --- @param self --- @param #int int --- @return Value#Value ret (return value: cc.Value) - --------------------------------- --- @function [parent=#FastTMXTiledMap] setTileSize --- @param self --- @param #size_table size - --------------------------------- --- @function [parent=#FastTMXTiledMap] setProperties --- @param self --- @param #map_table map - --------------------------------- --- @function [parent=#FastTMXTiledMap] getLayer --- @param self --- @param #string str --- @return FastTMXLayer#FastTMXLayer ret (return value: cc.FastTMXLayer) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getMapOrientation --- @param self --- @return int#int ret (return value: int) - --------------------------------- --- @function [parent=#FastTMXTiledMap] setMapOrientation --- @param self --- @param #int int - --------------------------------- --- @function [parent=#FastTMXTiledMap] create --- @param self --- @param #string str --- @return FastTMXTiledMap#FastTMXTiledMap ret (return value: cc.FastTMXTiledMap) - --------------------------------- --- @function [parent=#FastTMXTiledMap] createWithXML --- @param self --- @param #string str --- @param #string str --- @return FastTMXTiledMap#FastTMXTiledMap ret (return value: cc.FastTMXTiledMap) - --------------------------------- --- @function [parent=#FastTMXTiledMap] getDescription --- @param self --- @return string#string ret (return value: string) - -return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FileUtils.lua b/cocos/scripting/lua-bindings/auto/api/FileUtils.lua index 015c13c8bb..55ba23c983 100644 --- a/cocos/scripting/lua-bindings/auto/api/FileUtils.lua +++ b/cocos/scripting/lua-bindings/auto/api/FileUtils.lua @@ -74,11 +74,13 @@ -- @function [parent=#FileUtils] addSearchResolutionsOrder -- @param self -- @param #string str +-- @param #bool bool -------------------------------- -- @function [parent=#FileUtils] addSearchPath -- @param self -- @param #string str +-- @param #bool bool -------------------------------- -- @function [parent=#FileUtils] isFileExist diff --git a/cocos/scripting/lua-bindings/auto/api/GLProgram.lua b/cocos/scripting/lua-bindings/auto/api/GLProgram.lua index fdeb5ae58e..21a267ccf7 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLProgram.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLProgram.lua @@ -33,10 +33,8 @@ -- @return string#string ret (return value: string) -------------------------------- --- overload function: setUniformsForBuiltins(mat4_table) --- --- overload function: setUniformsForBuiltins() --- +-- @overload self, mat4_table +-- @overload self -- @function [parent=#GLProgram] setUniformsForBuiltins -- @param self -- @param #mat4_table mat4 diff --git a/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua b/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua index a0cd6455d6..45e1e90168 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua @@ -5,24 +5,18 @@ -- @parent_module cc -------------------------------- --- overload function: setUniformTexture(string, unsigned int) --- --- overload function: setUniformTexture(string, cc.Texture2D) --- --- overload function: setUniformTexture(int, cc.Texture2D) --- --- overload function: setUniformTexture(int, unsigned int) --- +-- @overload self, string, unsigned int +-- @overload self, string, cc.Texture2D +-- @overload self, int, cc.Texture2D +-- @overload self, int, unsigned int -- @function [parent=#GLProgramState] setUniformTexture -- @param self -- @param #int int -- @param #unsigned int int -------------------------------- --- overload function: setUniformMat4(int, mat4_table) --- --- overload function: setUniformMat4(string, mat4_table) --- +-- @overload self, int, mat4_table +-- @overload self, string, mat4_table -- @function [parent=#GLProgramState] setUniformMat4 -- @param self -- @param #string str @@ -47,30 +41,24 @@ -- @param self -------------------------------- --- overload function: setUniformFloat(int, float) --- --- overload function: setUniformFloat(string, float) --- +-- @overload self, int, float +-- @overload self, string, float -- @function [parent=#GLProgramState] setUniformFloat -- @param self -- @param #string str -- @param #float float -------------------------------- --- overload function: setUniformVec3(int, vec3_table) --- --- overload function: setUniformVec3(string, vec3_table) --- +-- @overload self, int, vec3_table +-- @overload self, string, vec3_table -- @function [parent=#GLProgramState] setUniformVec3 -- @param self -- @param #string str -- @param #vec3_table vec3 -------------------------------- --- overload function: setUniformInt(int, int) --- --- overload function: setUniformInt(string, int) --- +-- @overload self, int, int +-- @overload self, string, int -- @function [parent=#GLProgramState] setUniformInt -- @param self -- @param #string str @@ -82,10 +70,8 @@ -- @return long#long ret (return value: long) -------------------------------- --- overload function: setUniformVec4(int, vec4_table) --- --- overload function: setUniformVec4(string, vec4_table) --- +-- @overload self, int, vec4_table +-- @overload self, string, vec4_table -- @function [parent=#GLProgramState] setUniformVec4 -- @param self -- @param #string str @@ -97,10 +83,8 @@ -- @param #cc.GLProgram glprogram -------------------------------- --- overload function: setUniformVec2(int, vec2_table) --- --- overload function: setUniformVec2(string, vec2_table) --- +-- @overload self, int, vec2_table +-- @overload self, string, vec2_table -- @function [parent=#GLProgramState] setUniformVec2 -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/GLViewProtocol.lua b/cocos/scripting/lua-bindings/auto/api/GLViewProtocol.lua index b0b93132a7..f9da3d2a92 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLViewProtocol.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLViewProtocol.lua @@ -79,12 +79,12 @@ -- @param self -- @param #float float -- @param #float float --- @param #ResolutionPolicy resolutionpolicy +-- @param #int resolutionpolicy -------------------------------- -- @function [parent=#GLViewProtocol] getResolutionPolicy -- @param self --- @return ResolutionPolicy#ResolutionPolicy ret (return value: ResolutionPolicy) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#GLViewProtocol] setViewPortInPoints diff --git a/cocos/scripting/lua-bindings/auto/api/Grid3D.lua b/cocos/scripting/lua-bindings/auto/api/Grid3D.lua index e8bec38e53..8adbad9174 100644 --- a/cocos/scripting/lua-bindings/auto/api/Grid3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Grid3D.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(size_table) --- --- overload function: create(size_table, cc.Texture2D, bool) --- +-- @overload self, size_table +-- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#Grid3D] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/GridBase.lua b/cocos/scripting/lua-bindings/auto/api/GridBase.lua index 1aff5ed5a8..e42656495f 100644 --- a/cocos/scripting/lua-bindings/auto/api/GridBase.lua +++ b/cocos/scripting/lua-bindings/auto/api/GridBase.lua @@ -66,10 +66,8 @@ -- @return int#int ret (return value: int) -------------------------------- --- overload function: initWithSize(size_table) --- --- overload function: initWithSize(size_table, cc.Texture2D, bool) --- +-- @overload self, size_table +-- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#GridBase] initWithSize -- @param self -- @param #size_table size @@ -92,10 +90,8 @@ -- @param self -------------------------------- --- overload function: create(size_table) --- --- overload function: create(size_table, cc.Texture2D, bool) --- +-- @overload self, size_table +-- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#GridBase] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/HBox.lua b/cocos/scripting/lua-bindings/auto/api/HBox.lua index 181a10056b..54ce53f9e3 100644 --- a/cocos/scripting/lua-bindings/auto/api/HBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/HBox.lua @@ -5,10 +5,8 @@ -- @parent_module ccui -------------------------------- --- overload function: create(size_table) --- --- overload function: create() --- +-- @overload self, size_table +-- @overload self -- @function [parent=#HBox] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/Image.lua b/cocos/scripting/lua-bindings/auto/api/Image.lua index 9ef913ad02..b491b70e7c 100644 --- a/cocos/scripting/lua-bindings/auto/api/Image.lua +++ b/cocos/scripting/lua-bindings/auto/api/Image.lua @@ -55,7 +55,7 @@ -------------------------------- -- @function [parent=#Image] getFileType -- @param self --- @return Image::Format#Image::Format ret (return value: cc.Image::Format) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Image] getNumberOfMipmaps @@ -65,7 +65,7 @@ -------------------------------- -- @function [parent=#Image] getRenderFormat -- @param self --- @return Texture2D::PixelFormat#Texture2D::PixelFormat ret (return value: cc.Texture2D::PixelFormat) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Image] Image diff --git a/cocos/scripting/lua-bindings/auto/api/ImageView.lua b/cocos/scripting/lua-bindings/auto/api/ImageView.lua index d5bbc0662c..395449e067 100644 --- a/cocos/scripting/lua-bindings/auto/api/ImageView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ImageView.lua @@ -8,7 +8,7 @@ -- @function [parent=#ImageView] loadTexture -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#ImageView] setScale9Enabled @@ -36,14 +36,12 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: create(string, ccui.Widget::TextureResType) --- --- overload function: create() --- +-- @overload self, string, int +-- @overload self -- @function [parent=#ImageView] create -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -- @return ImageView#ImageView ret (retunr value: ccui.ImageView) -------------------------------- diff --git a/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua b/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua index c12d6e02bd..5de5259f53 100644 --- a/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua @@ -7,7 +7,7 @@ -------------------------------- -- @function [parent=#InnerActionFrame] getInnerActionType -- @param self --- @return InnerActionType#InnerActionType ret (return value: ccs.InnerActionType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#InnerActionFrame] setStartFrameIndex @@ -17,7 +17,7 @@ -------------------------------- -- @function [parent=#InnerActionFrame] setInnerActionType -- @param self --- @param #ccs.InnerActionType inneractiontype +-- @param #int inneractiontype -------------------------------- -- @function [parent=#InnerActionFrame] getStartFrameIndex diff --git a/cocos/scripting/lua-bindings/auto/api/Label.lua b/cocos/scripting/lua-bindings/auto/api/Label.lua index 976af067da..52319e86ec 100644 --- a/cocos/scripting/lua-bindings/auto/api/Label.lua +++ b/cocos/scripting/lua-bindings/auto/api/Label.lua @@ -57,7 +57,7 @@ -------------------------------- -- @function [parent=#Label] getHorizontalAlignment -- @param self --- @return TextHAlignment#TextHAlignment ret (return value: cc.TextHAlignment) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Label] setClipMarginEnabled @@ -127,12 +127,9 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: setCharMap(cc.Texture2D, int, int, int) --- --- overload function: setCharMap(string, int, int, int) --- --- overload function: setCharMap(string) --- +-- @overload self, cc.Texture2D, int, int, int +-- @overload self, string, int, int, int +-- @overload self, string -- @function [parent=#Label] setCharMap -- @param self -- @param #string str @@ -159,7 +156,7 @@ -------------------------------- -- @function [parent=#Label] setVerticalAlignment -- @param self --- @param #cc.TextVAlignment textvalignment +-- @param #int textvalignment -------------------------------- -- @function [parent=#Label] getLineHeight @@ -174,7 +171,7 @@ -------------------------------- -- @function [parent=#Label] getVerticalAlignment -- @param self --- @return TextVAlignment#TextVAlignment ret (return value: cc.TextVAlignment) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Label] setTextColor @@ -215,7 +212,7 @@ -------------------------------- -- @function [parent=#Label] getTextAlignment -- @param self --- @return TextHAlignment#TextHAlignment ret (return value: cc.TextHAlignment) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Label] getBMFontFilePath @@ -225,24 +222,22 @@ -------------------------------- -- @function [parent=#Label] setHorizontalAlignment -- @param self --- @param #cc.TextHAlignment texthalignment +-- @param #int texthalignment -------------------------------- --- overload function: setAlignment(cc.TextHAlignment, cc.TextVAlignment) --- --- overload function: setAlignment(cc.TextHAlignment) --- +-- @overload self, int, int +-- @overload self, int -- @function [parent=#Label] setAlignment -- @param self --- @param #cc.TextHAlignment texthalignment --- @param #cc.TextVAlignment textvalignment +-- @param #int texthalignment +-- @param #int textvalignment -------------------------------- -- @function [parent=#Label] createWithBMFont -- @param self -- @param #string str -- @param #string str --- @param #cc.TextHAlignment texthalignment +-- @param #int texthalignment -- @param #int int -- @param #vec2_table vec2 -- @return Label#Label ret (return value: cc.Label) @@ -253,12 +248,9 @@ -- @return Label#Label ret (return value: cc.Label) -------------------------------- --- overload function: createWithCharMap(cc.Texture2D, int, int, int) --- --- overload function: createWithCharMap(string, int, int, int) --- --- overload function: createWithCharMap(string) --- +-- @overload self, cc.Texture2D, int, int, int +-- @overload self, string, int, int, int +-- @overload self, string -- @function [parent=#Label] createWithCharMap -- @param self -- @param #string str @@ -274,8 +266,8 @@ -- @param #string str -- @param #float float -- @param #size_table size --- @param #cc.TextHAlignment texthalignment --- @param #cc.TextVAlignment textvalignment +-- @param #int texthalignment +-- @param #int textvalignment -- @return Label#Label ret (return value: cc.Label) -------------------------------- diff --git a/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua b/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua index 16578c5420..50753ea4c0 100644 --- a/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua +++ b/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua @@ -10,12 +10,9 @@ -- @param #string str -------------------------------- --- overload function: initWithString(string, string) --- --- overload function: initWithString(string, string, int, int, int) --- --- overload function: initWithString(string, cc.Texture2D, int, int, int) --- +-- @overload self, string, string +-- @overload self, string, string, int, int, int +-- @overload self, string, cc.Texture2D, int, int, int -- @function [parent=#LabelAtlas] initWithString -- @param self -- @param #string str @@ -35,12 +32,9 @@ -- @return string#string ret (return value: string) -------------------------------- --- overload function: create(string, string, int, int, int) --- --- overload function: create() --- --- overload function: create(string, string) --- +-- @overload self, string, string, int, int, int +-- @overload self +-- @overload self, string, string -- @function [parent=#LabelAtlas] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/LayerColor.lua b/cocos/scripting/lua-bindings/auto/api/LayerColor.lua index 0196157212..6a190c9eb1 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayerColor.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayerColor.lua @@ -21,12 +21,9 @@ -- @param #float float -------------------------------- --- overload function: create(color4b_table, float, float) --- --- overload function: create() --- --- overload function: create(color4b_table) --- +-- @overload self, color4b_table, float, float +-- @overload self +-- @overload self, color4b_table -- @function [parent=#LayerColor] create -- @param self -- @param #color4b_table color4b diff --git a/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua b/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua index d7f1b3c4df..8f18269408 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua @@ -65,12 +65,9 @@ -- @param #color3b_table color3b -------------------------------- --- overload function: create(color4b_table, color4b_table) --- --- overload function: create() --- --- overload function: create(color4b_table, color4b_table, vec2_table) --- +-- @overload self, color4b_table, color4b_table +-- @overload self +-- @overload self, color4b_table, color4b_table, vec2_table -- @function [parent=#LayerGradient] create -- @param self -- @param #color4b_table color4b diff --git a/cocos/scripting/lua-bindings/auto/api/Layout.lua b/cocos/scripting/lua-bindings/auto/api/Layout.lua index 507e8d56ef..a16923e4dc 100644 --- a/cocos/scripting/lua-bindings/auto/api/Layout.lua +++ b/cocos/scripting/lua-bindings/auto/api/Layout.lua @@ -12,12 +12,12 @@ -------------------------------- -- @function [parent=#Layout] setClippingType -- @param self --- @param #ccui.Layout::ClippingType clippingtype +-- @param #int clippingtype -------------------------------- -- @function [parent=#Layout] setBackGroundColorType -- @param self --- @param #ccui.Layout::BackGroundColorType backgroundcolortype +-- @param #int backgroundcolortype -------------------------------- -- @function [parent=#Layout] setLoopFocus @@ -37,7 +37,7 @@ -------------------------------- -- @function [parent=#Layout] getClippingType -- @param self --- @return Layout::ClippingType#Layout::ClippingType ret (return value: ccui.Layout::ClippingType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Layout] isLoopFocus @@ -67,13 +67,11 @@ -- @function [parent=#Layout] setBackGroundImage -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- --- overload function: setBackGroundColor(color3b_table, color3b_table) --- --- overload function: setBackGroundColor(color3b_table) --- +-- @overload self, color3b_table, color3b_table +-- @overload self, color3b_table -- @function [parent=#Layout] setBackGroundColor -- @param self -- @param #color3b_table color3b @@ -111,7 +109,7 @@ -------------------------------- -- @function [parent=#Layout] getBackGroundColorType -- @param self --- @return Layout::BackGroundColorType#Layout::BackGroundColorType ret (return value: ccui.Layout::BackGroundColorType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Layout] getBackGroundEndColor @@ -146,7 +144,7 @@ -------------------------------- -- @function [parent=#Layout] getLayoutType -- @param self --- @return Layout::Type#Layout::Type ret (return value: ccui.Layout::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Layout] setPassFocusToChild @@ -166,7 +164,7 @@ -------------------------------- -- @function [parent=#Layout] setLayoutType -- @param self --- @param #ccui.Layout::Type type +-- @param #int type -------------------------------- -- @function [parent=#Layout] create @@ -179,14 +177,10 @@ -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- --- overload function: addChild(cc.Node, int) --- --- overload function: addChild(cc.Node) --- --- overload function: addChild(cc.Node, int, int) --- --- overload function: addChild(cc.Node, int, string) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int +-- @overload self, cc.Node, int, string -- @function [parent=#Layout] addChild -- @param self -- @param #cc.Node node @@ -210,7 +204,7 @@ -------------------------------- -- @function [parent=#Layout] findNextFocusedWidget -- @param self --- @param #ccui.Widget::FocusDirection focusdirection +-- @param #int focusdirection -- @param #ccui.Widget widget -- @return Widget#Widget ret (return value: ccui.Widget) diff --git a/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua index 4d1c68a03b..590f5ea26d 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua @@ -12,7 +12,7 @@ -------------------------------- -- @function [parent=#LayoutParameter] getLayoutType -- @param self --- @return LayoutParameter::Type#LayoutParameter::Type ret (return value: ccui.LayoutParameter::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#LayoutParameter] createCloneInstance diff --git a/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua index 07d39ec85b..81db029efb 100644 --- a/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua @@ -7,12 +7,12 @@ -------------------------------- -- @function [parent=#LinearLayoutParameter] setGravity -- @param self --- @param #ccui.LinearLayoutParameter::LinearGravity lineargravity +-- @param #int lineargravity -------------------------------- -- @function [parent=#LinearLayoutParameter] getGravity -- @param self --- @return LinearLayoutParameter::LinearGravity#LinearLayoutParameter::LinearGravity ret (return value: ccui.LinearLayoutParameter::LinearGravity) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#LinearLayoutParameter] create diff --git a/cocos/scripting/lua-bindings/auto/api/ListView.lua b/cocos/scripting/lua-bindings/auto/api/ListView.lua index 0ac5fec932..eb0b32815d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ListView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ListView.lua @@ -17,7 +17,7 @@ -------------------------------- -- @function [parent=#ListView] setGravity -- @param self --- @param #ccui.ListView::Gravity gravity +-- @param #int gravity -------------------------------- -- @function [parent=#ListView] pushBackCustomItem @@ -107,14 +107,10 @@ -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- --- overload function: addChild(cc.Node, int) --- --- overload function: addChild(cc.Node) --- --- overload function: addChild(cc.Node, int, int) --- --- overload function: addChild(cc.Node, int, string) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int +-- @overload self, cc.Node, int, string -- @function [parent=#ListView] addChild -- @param self -- @param #cc.Node node @@ -124,7 +120,7 @@ -------------------------------- -- @function [parent=#ListView] setDirection -- @param self --- @param #ccui.ScrollView::Direction direction +-- @param #int direction -------------------------------- -- @function [parent=#ListView] getDescription diff --git a/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua b/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua index 06bd2861bf..132912332c 100644 --- a/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua +++ b/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua @@ -13,12 +13,12 @@ -- @function [parent=#LoadingBar] loadTexture -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#LoadingBar] setDirection -- @param self --- @param #ccui.LoadingBar::Direction direction +-- @param #int direction -------------------------------- -- @function [parent=#LoadingBar] setScale9Enabled @@ -33,7 +33,7 @@ -------------------------------- -- @function [parent=#LoadingBar] getDirection -- @param self --- @return LoadingBar::Direction#LoadingBar::Direction ret (return value: ccui.LoadingBar::Direction) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#LoadingBar] getCapInsets @@ -51,10 +51,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: create(string, float) --- --- overload function: create() --- +-- @overload self, string, float +-- @overload self -- @function [parent=#LoadingBar] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/Menu.lua b/cocos/scripting/lua-bindings/auto/api/Menu.lua index 52362692c9..3a228e3443 100644 --- a/cocos/scripting/lua-bindings/auto/api/Menu.lua +++ b/cocos/scripting/lua-bindings/auto/api/Menu.lua @@ -33,14 +33,10 @@ -- @param self -------------------------------- --- overload function: addChild(cc.Node, int) --- --- overload function: addChild(cc.Node) --- --- overload function: addChild(cc.Node, int, int) --- --- overload function: addChild(cc.Node, int, string) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int +-- @overload self, cc.Node, int, string -- @function [parent=#Menu] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/Mesh.lua b/cocos/scripting/lua-bindings/auto/api/Mesh.lua index 88935a52a7..42b24b5016 100644 --- a/cocos/scripting/lua-bindings/auto/api/Mesh.lua +++ b/cocos/scripting/lua-bindings/auto/api/Mesh.lua @@ -16,7 +16,7 @@ -------------------------------- -- @function [parent=#Mesh] getIndexFormat -- @param self --- @return Mesh::IndexFormat#Mesh::IndexFormat ret (return value: cc.Mesh::IndexFormat) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Mesh] getVertexSizeInBytes @@ -26,7 +26,7 @@ -------------------------------- -- @function [parent=#Mesh] getPrimitiveType -- @param self --- @return Mesh::PrimitiveType#Mesh::PrimitiveType ret (return value: cc.Mesh::PrimitiveType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Mesh] getIndexCount diff --git a/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua b/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua index 817e2c4984..47f6c9dbeb 100644 --- a/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua +++ b/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua @@ -44,10 +44,8 @@ -- @param #bool bool -------------------------------- --- overload function: create(float, float, float, color3b_table, cc.Texture2D) --- --- overload function: create(float, float, float, color3b_table, string) --- +-- @overload self, float, float, float, color3b_table, cc.Texture2D +-- @overload self, float, float, float, color3b_table, string -- @function [parent=#MotionStreak] create -- @param self -- @param #float float @@ -98,20 +96,16 @@ -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- --- overload function: setPosition(float, float) --- --- overload function: setPosition(vec2_table) --- +-- @overload self, float, float +-- @overload self, vec2_table -- @function [parent=#MotionStreak] setPosition -- @param self -- @param #float float -- @param #float float -------------------------------- --- overload function: getPosition(float, float) --- --- overload function: getPosition() --- +-- @overload self, float, float +-- @overload self -- @function [parent=#MotionStreak] getPosition -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/Node.lua b/cocos/scripting/lua-bindings/auto/api/Node.lua index 846ddc9af9..33f956653b 100644 --- a/cocos/scripting/lua-bindings/auto/api/Node.lua +++ b/cocos/scripting/lua-bindings/auto/api/Node.lua @@ -5,14 +5,10 @@ -- @parent_module cc -------------------------------- --- overload function: addChild(cc.Node, int) --- --- overload function: addChild(cc.Node) --- --- overload function: addChild(cc.Node, int, int) --- --- overload function: addChild(cc.Node, int, string) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int +-- @overload self, cc.Node, int, string -- @function [parent=#Node] addChild -- @param self -- @param #cc.Node node @@ -51,10 +47,8 @@ -- @param #bool bool -------------------------------- --- overload function: getChildren() --- --- overload function: getChildren() --- +-- @overload self +-- @overload self -- @function [parent=#Node] getChildren -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -134,11 +128,6 @@ -- @param self -- @return int#int ret (return value: int) --------------------------------- --- @function [parent=#Node] getonEnterTransitionDidFinishCallback --- @param self --- @return function#function ret (return value: function) - -------------------------------- -- @function [parent=#Node] getGLProgram -- @param self @@ -213,10 +202,8 @@ -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- --- overload function: removeAllChildrenWithCleanup(bool) --- --- overload function: removeAllChildrenWithCleanup() --- +-- @overload self, bool +-- @overload self -- @function [parent=#Node] removeAllChildrenWithCleanup -- @param self -- @param #bool bool @@ -257,11 +244,6 @@ -- @param #cc.Touch touch -- @return vec2_table#vec2_table ret (return value: vec2_table) --------------------------------- --- @function [parent=#Node] getOnEnterCallback --- @param self --- @return function#function ret (return value: function) - -------------------------------- -- @function [parent=#Node] convertToNodeSpace -- @param self @@ -278,10 +260,8 @@ -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- --- overload function: setPosition(float, float) --- --- overload function: setPosition(vec2_table) --- +-- @overload self, float, float +-- @overload self, vec2_table -- @function [parent=#Node] setPosition -- @param self -- @param #float float @@ -391,10 +371,8 @@ -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- --- overload function: visit() --- --- overload function: visit(cc.Renderer, mat4_table, unsigned int) --- +-- @overload self +-- @overload self, cc.Renderer, mat4_table, unsigned int -- @function [parent=#Node] visit -- @param self -- @param #cc.Renderer renderer @@ -448,10 +426,8 @@ -- @param #string str -------------------------------- --- overload function: setAdditionalTransform(cc.AffineTransform) --- --- overload function: setAdditionalTransform(mat4_table) --- +-- @overload self, cc.AffineTransform +-- @overload self, mat4_table -- @function [parent=#Node] setAdditionalTransform -- @param self -- @param #mat4_table mat4 @@ -467,10 +443,8 @@ -- @return int#int ret (return value: int) -------------------------------- --- overload function: getScheduler() --- --- overload function: getScheduler() --- +-- @overload self +-- @overload self -- @function [parent=#Node] getScheduler -- @param self -- @return Scheduler#Scheduler ret (retunr value: cc.Scheduler) @@ -501,10 +475,8 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: getParent() --- --- overload function: getParent() --- +-- @overload self +-- @overload self -- @function [parent=#Node] getParent -- @param self -- @return Node#Node ret (retunr value: cc.Node) @@ -561,20 +533,13 @@ -- @param #float float -------------------------------- --- overload function: setScale(float, float) --- --- overload function: setScale(float) --- +-- @overload self, float, float +-- @overload self, float -- @function [parent=#Node] setScale -- @param self -- @param #float float -- @param #float float --------------------------------- --- @function [parent=#Node] getOnExitCallback --- @param self --- @return function#function ret (return value: function) - -------------------------------- -- @function [parent=#Node] getChildByTag -- @param self @@ -657,10 +622,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: draw() --- --- overload function: draw(cc.Renderer, mat4_table, unsigned int) --- +-- @overload self +-- @overload self, cc.Renderer, mat4_table, unsigned int -- @function [parent=#Node] draw -- @param self -- @param #cc.Renderer renderer @@ -673,15 +636,8 @@ -- @param #cc.Ref ref -------------------------------- --- @function [parent=#Node] getonExitTransitionDidStartCallback --- @param self --- @return function#function ret (return value: function) - --------------------------------- --- overload function: removeFromParentAndCleanup(bool) --- --- overload function: removeFromParentAndCleanup() --- +-- @overload self, bool +-- @overload self -- @function [parent=#Node] removeFromParentAndCleanup -- @param self -- @param #bool bool @@ -741,10 +697,8 @@ -- @param #cc.Action action -------------------------------- --- overload function: getActionManager() --- --- overload function: getActionManager() --- +-- @overload self +-- @overload self -- @function [parent=#Node] getActionManager -- @param self -- @return ActionManager#ActionManager ret (retunr value: cc.ActionManager) diff --git a/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua b/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua index c441d06407..2d99049a3c 100644 --- a/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua +++ b/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua @@ -10,10 +10,8 @@ -- @param #cc.Node node -------------------------------- --- overload function: getGrid() --- --- overload function: getGrid() --- +-- @overload self +-- @overload self -- @function [parent=#NodeGrid] getGrid -- @param self -- @return GridBase#GridBase ret (retunr value: cc.GridBase) diff --git a/cocos/scripting/lua-bindings/auto/api/PageView.lua b/cocos/scripting/lua-bindings/auto/api/PageView.lua index 7f2b8b76cf..2e660a0635 100644 --- a/cocos/scripting/lua-bindings/auto/api/PageView.lua +++ b/cocos/scripting/lua-bindings/auto/api/PageView.lua @@ -75,7 +75,7 @@ -------------------------------- -- @function [parent=#PageView] getLayoutType -- @param self --- @return Layout::Type#Layout::Type ret (return value: ccui.Layout::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#PageView] getDescription @@ -90,7 +90,7 @@ -------------------------------- -- @function [parent=#PageView] setLayoutType -- @param self --- @param #ccui.Layout::Type type +-- @param #int type -------------------------------- -- @function [parent=#PageView] PageView diff --git a/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua b/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua index 5cc4cb76a0..3a55ee2e5a 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua @@ -23,10 +23,8 @@ -- @return ParallaxNode#ParallaxNode ret (return value: cc.ParallaxNode) -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#ParallaxNode] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua b/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua index 7329dd4887..1adde946b7 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua @@ -61,10 +61,8 @@ -- @return ParticleBatchNode#ParticleBatchNode ret (return value: cc.ParticleBatchNode) -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#ParticleBatchNode] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua index c53937b97d..3a36b92a5c 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua @@ -32,7 +32,7 @@ -------------------------------- -- @function [parent=#ParticleSystem] getPositionType -- @param self --- @return ParticleSystem::PositionType#ParticleSystem::PositionType ret (return value: cc.ParticleSystem::PositionType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#ParticleSystem] setPosVar @@ -171,7 +171,7 @@ -------------------------------- -- @function [parent=#ParticleSystem] setPositionType -- @param self --- @param #cc.ParticleSystem::PositionType positiontype +-- @param #int positiontype -------------------------------- -- @function [parent=#ParticleSystem] stopSystem @@ -274,7 +274,7 @@ -------------------------------- -- @function [parent=#ParticleSystem] setEmitterMode -- @param self --- @param #cc.ParticleSystem::Mode mode +-- @param #int mode -------------------------------- -- @function [parent=#ParticleSystem] getDuration @@ -334,7 +334,7 @@ -------------------------------- -- @function [parent=#ParticleSystem] getEmitterMode -- @param self --- @return ParticleSystem::Mode#ParticleSystem::Mode ret (return value: cc.ParticleSystem::Mode) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#ParticleSystem] setEndSpinVar diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua index 3b41c5710a..92e7402676 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua @@ -21,12 +21,9 @@ -- @param #cc.EventCustom eventcustom -------------------------------- --- overload function: create(string) --- --- overload function: create() --- --- overload function: create(map_table) --- +-- @overload self, string +-- @overload self +-- @overload self, map_table -- @function [parent=#ParticleSystemQuad] create -- @param self -- @param #map_table map diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua index 8b250c7e07..6e90f80f52 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua @@ -49,10 +49,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: applyImpulse(vec2_table, vec2_table) --- --- overload function: applyImpulse(vec2_table) --- +-- @overload self, vec2_table, vec2_table +-- @overload self, vec2_table -- @function [parent=#PhysicsBody] applyImpulse -- @param self -- @param #vec2_table vec2 @@ -64,10 +62,8 @@ -- @param #float float -------------------------------- --- overload function: applyForce(vec2_table, vec2_table) --- --- overload function: applyForce(vec2_table) --- +-- @overload self, vec2_table, vec2_table +-- @overload self, vec2_table -- @function [parent=#PhysicsBody] applyForce -- @param self -- @param #vec2_table vec2 @@ -222,10 +218,8 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: removeShape(int, bool) --- --- overload function: removeShape(cc.PhysicsShape, bool) --- +-- @overload self, int, bool +-- @overload self, cc.PhysicsShape, bool -- @function [parent=#PhysicsBody] removeShape -- @param self -- @param #cc.PhysicsShape physicsshape @@ -346,12 +340,9 @@ -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- --- overload function: create(float) --- --- overload function: create() --- --- overload function: create(float, float) --- +-- @overload self, float +-- @overload self +-- @overload self, float, float -- @function [parent=#PhysicsBody] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua index 235025d62e..30d6f985d3 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua @@ -12,7 +12,7 @@ -------------------------------- -- @function [parent=#PhysicsContact] getEventCode -- @param self --- @return PhysicsContact::EventCode#PhysicsContact::EventCode ret (return value: cc.PhysicsContact::EventCode) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#PhysicsContact] getPreContactData diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua index c94147a645..796d4143c2 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua @@ -45,10 +45,8 @@ -- @param #float float -------------------------------- --- overload function: construct(cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table, float, float) --- --- overload function: construct(cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table) --- +-- @overload self, cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table, float, float +-- @overload self, cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table -- @function [parent=#PhysicsJointLimit] construct -- @param self -- @param #cc.PhysicsBody physicsbody diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua index 28052bb064..db5d66222e 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua @@ -25,10 +25,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: construct(cc.PhysicsBody, cc.PhysicsBody) --- --- overload function: construct(cc.PhysicsBody, cc.PhysicsBody, float, float) --- +-- @overload self, cc.PhysicsBody, cc.PhysicsBody +-- @overload self, cc.PhysicsBody, cc.PhysicsBody, float, float -- @function [parent=#PhysicsJointRotaryLimit] construct -- @param self -- @param #cc.PhysicsBody physicsbody diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua index a4559f2f2b..56d5538836 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua @@ -68,7 +68,7 @@ -------------------------------- -- @function [parent=#PhysicsShape] getType -- @param self --- @return PhysicsShape::Type#PhysicsShape::Type ret (return value: cc.PhysicsShape::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#PhysicsShape] getContactTestBitmask diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua index 373323444e..df5c6d9783 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua @@ -24,10 +24,8 @@ -- @return float#float ret (return value: float) -------------------------------- --- overload function: removeBody(int) --- --- overload function: removeBody(cc.PhysicsBody) --- +-- @overload self, int +-- @overload self, cc.PhysicsBody -- @function [parent=#PhysicsWorld] removeBody -- @param self -- @param #cc.PhysicsBody physicsbody diff --git a/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua b/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua index 4fb722c3c1..d19cf74354 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua @@ -27,7 +27,7 @@ -------------------------------- -- @function [parent=#ProgressTimer] getType -- @param self --- @return ProgressTimer::Type#ProgressTimer::Type ret (return value: cc.ProgressTimer::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#ProgressTimer] getSprite @@ -45,10 +45,8 @@ -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- --- overload function: setReverseDirection(bool) --- --- overload function: setReverseDirection(bool) --- +-- @overload self, bool +-- @overload self, bool -- @function [parent=#ProgressTimer] setReverseDirection -- @param self -- @param #bool bool @@ -66,7 +64,7 @@ -------------------------------- -- @function [parent=#ProgressTimer] setType -- @param self --- @param #cc.ProgressTimer::Type type +-- @param #int type -------------------------------- -- @function [parent=#ProgressTimer] create diff --git a/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua b/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua index e3b177c2a1..7cdaa73327 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua @@ -5,12 +5,9 @@ -- @parent_module cc -------------------------------- --- overload function: addProtectedChild(cc.Node, int) --- --- overload function: addProtectedChild(cc.Node) --- --- overload function: addProtectedChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int -- @function [parent=#ProtectedNode] addProtectedChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua b/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua index 92702c7770..a12a3b8f4a 100644 --- a/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua @@ -5,10 +5,8 @@ -- @parent_module ccui -------------------------------- --- overload function: create(size_table) --- --- overload function: create() --- +-- @overload self, size_table +-- @overload self -- @function [parent=#RelativeBox] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua index 9938baeeb4..ec81d4f44e 100644 --- a/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua @@ -7,7 +7,7 @@ -------------------------------- -- @function [parent=#RelativeLayoutParameter] setAlign -- @param self --- @param #ccui.RelativeLayoutParameter::RelativeAlign relativealign +-- @param #int relativealign -------------------------------- -- @function [parent=#RelativeLayoutParameter] setRelativeToWidgetName @@ -32,7 +32,7 @@ -------------------------------- -- @function [parent=#RelativeLayoutParameter] getAlign -- @param self --- @return RelativeLayoutParameter::RelativeAlign#RelativeLayoutParameter::RelativeAlign ret (return value: ccui.RelativeLayoutParameter::RelativeAlign) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#RelativeLayoutParameter] create diff --git a/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua b/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua index 35d6c9e5f2..4717d8015e 100644 --- a/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua +++ b/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua @@ -65,14 +65,12 @@ -- @param self -------------------------------- --- overload function: saveToFile(string, cc.Image::Format, bool) --- --- overload function: saveToFile(string, bool) --- +-- @overload self, string, int, bool +-- @overload self, string, bool -- @function [parent=#RenderTexture] saveToFile -- @param self -- @param #string str --- @param #cc.Image::Format format +-- @param #int format -- @param #bool bool -- @return bool#bool ret (retunr value: bool) @@ -91,12 +89,9 @@ -- @param self -------------------------------- --- overload function: beginWithClear(float, float, float, float, float) --- --- overload function: beginWithClear(float, float, float, float) --- --- overload function: beginWithClear(float, float, float, float, float, int) --- +-- @overload self, float, float, float, float, float +-- @overload self, float, float, float, float +-- @overload self, float, float, float, float, float, int -- @function [parent=#RenderTexture] beginWithClear -- @param self -- @param #float float @@ -140,30 +135,25 @@ -- @param #float float -------------------------------- --- overload function: initWithWidthAndHeight(int, int, cc.Texture2D::PixelFormat, unsigned int) --- --- overload function: initWithWidthAndHeight(int, int, cc.Texture2D::PixelFormat) --- +-- @overload self, int, int, int, unsigned int +-- @overload self, int, int, int -- @function [parent=#RenderTexture] initWithWidthAndHeight -- @param self -- @param #int int -- @param #int int --- @param #cc.Texture2D::PixelFormat pixelformat +-- @param #int pixelformat -- @param #unsigned int int -- @return bool#bool ret (retunr value: bool) -------------------------------- --- overload function: create(int, int, cc.Texture2D::PixelFormat) --- --- overload function: create(int, int, cc.Texture2D::PixelFormat, unsigned int) --- --- overload function: create(int, int) --- +-- @overload self, int, int, int +-- @overload self, int, int, int, unsigned int +-- @overload self, int, int -- @function [parent=#RenderTexture] create -- @param self -- @param #int int -- @param #int int --- @param #cc.Texture2D::PixelFormat pixelformat +-- @param #int pixelformat -- @param #unsigned int int -- @return RenderTexture#RenderTexture ret (retunr value: cc.RenderTexture) diff --git a/cocos/scripting/lua-bindings/auto/api/RichText.lua b/cocos/scripting/lua-bindings/auto/api/RichText.lua index 1785502d9c..c332a6f8e7 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichText.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichText.lua @@ -35,10 +35,8 @@ -- @param self -------------------------------- --- overload function: removeElement(ccui.RichElement) --- --- overload function: removeElement(int) --- +-- @overload self, ccui.RichElement +-- @overload self, int -- @function [parent=#RichText] removeElement -- @param self -- @param #int int diff --git a/cocos/scripting/lua-bindings/auto/api/RotateBy.lua b/cocos/scripting/lua-bindings/auto/api/RotateBy.lua index 3737e0502a..8d1d33c55e 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotateBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotateBy.lua @@ -5,12 +5,9 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, float, float) --- --- overload function: create(float, float) --- --- overload function: create(float, vec3_table) --- +-- @overload self, float, float, float +-- @overload self, float, float +-- @overload self, float, vec3_table -- @function [parent=#RotateBy] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/RotateTo.lua b/cocos/scripting/lua-bindings/auto/api/RotateTo.lua index a6ec1f2149..49f29e13b4 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotateTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotateTo.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, float) --- --- overload function: create(float, float, float) --- +-- @overload self, float, float +-- @overload self, float, float, float -- @function [parent=#RotateTo] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua b/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua index 27ed890c1a..5a394237fa 100644 --- a/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua +++ b/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua @@ -16,10 +16,8 @@ -- @param #float float -------------------------------- --- overload function: initWithSpriteFrameName(string) --- --- overload function: initWithSpriteFrameName(string, rect_table) --- +-- @overload self, string +-- @overload self, string, rect_table -- @function [parent=#Scale9Sprite] initWithSpriteFrameName -- @param self -- @param #string str @@ -47,10 +45,8 @@ -- @param #cc.SpriteFrame spriteframe -------------------------------- --- overload function: initWithBatchNode(cc.SpriteBatchNode, rect_table, rect_table) --- --- overload function: initWithBatchNode(cc.SpriteBatchNode, rect_table, bool, rect_table) --- +-- @overload self, cc.SpriteBatchNode, rect_table, rect_table +-- @overload self, cc.SpriteBatchNode, rect_table, bool, rect_table -- @function [parent=#Scale9Sprite] initWithBatchNode -- @param self -- @param #cc.SpriteBatchNode spritebatchnode @@ -89,14 +85,10 @@ -- @return size_table#size_table ret (return value: size_table) -------------------------------- --- overload function: initWithFile(string, rect_table) --- --- overload function: initWithFile(string, rect_table, rect_table) --- --- overload function: initWithFile(rect_table, string) --- --- overload function: initWithFile(string) --- +-- @overload self, string, rect_table +-- @overload self, string, rect_table, rect_table +-- @overload self, rect_table, string +-- @overload self, string -- @function [parent=#Scale9Sprite] initWithFile -- @param self -- @param #string str @@ -115,10 +107,8 @@ -- @param #float float -------------------------------- --- overload function: initWithSpriteFrame(cc.SpriteFrame) --- --- overload function: initWithSpriteFrame(cc.SpriteFrame, rect_table) --- +-- @overload self, cc.SpriteFrame +-- @overload self, cc.SpriteFrame, rect_table -- @function [parent=#Scale9Sprite] initWithSpriteFrame -- @param self -- @param #cc.SpriteFrame spriteframe @@ -146,16 +136,11 @@ -- @param #float float -------------------------------- --- overload function: create(string, rect_table, rect_table) --- --- overload function: create() --- --- overload function: create(rect_table, string) --- --- overload function: create(string, rect_table) --- --- overload function: create(string) --- +-- @overload self, string, rect_table, rect_table +-- @overload self +-- @overload self, rect_table, string +-- @overload self, string, rect_table +-- @overload self, string -- @function [parent=#Scale9Sprite] create -- @param self -- @param #string str @@ -164,10 +149,8 @@ -- @return Scale9Sprite#Scale9Sprite ret (retunr value: cc.Scale9Sprite) -------------------------------- --- overload function: createWithSpriteFrameName(string, rect_table) --- --- overload function: createWithSpriteFrameName(string) --- +-- @overload self, string, rect_table +-- @overload self, string -- @function [parent=#Scale9Sprite] createWithSpriteFrameName -- @param self -- @param #string str @@ -175,10 +158,8 @@ -- @return Scale9Sprite#Scale9Sprite ret (retunr value: cc.Scale9Sprite) -------------------------------- --- overload function: createWithSpriteFrame(cc.SpriteFrame, rect_table) --- --- overload function: createWithSpriteFrame(cc.SpriteFrame) --- +-- @overload self, cc.SpriteFrame, rect_table +-- @overload self, cc.SpriteFrame -- @function [parent=#Scale9Sprite] createWithSpriteFrame -- @param self -- @param #cc.SpriteFrame spriteframe diff --git a/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua b/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua index b414e11083..3d2e657b72 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua @@ -5,12 +5,9 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, float, float) --- --- overload function: create(float, float) --- --- overload function: create(float, float, float, float) --- +-- @overload self, float, float, float +-- @overload self, float, float +-- @overload self, float, float, float, float -- @function [parent=#ScaleBy] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua b/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua index d6b9894f1e..3869dffc97 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua @@ -5,12 +5,9 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, float, float) --- --- overload function: create(float, float) --- --- overload function: create(float, float, float, float) --- +-- @overload self, float, float, float +-- @overload self, float, float +-- @overload self, float, float, float, float -- @function [parent=#ScaleTo] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/Scene.lua b/cocos/scripting/lua-bindings/auto/api/Scene.lua index 070e380146..ba1bec9356 100644 --- a/cocos/scripting/lua-bindings/auto/api/Scene.lua +++ b/cocos/scripting/lua-bindings/auto/api/Scene.lua @@ -41,10 +41,8 @@ -- @param #float float -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#Scene] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/SceneReader.lua b/cocos/scripting/lua-bindings/auto/api/SceneReader.lua index bf0b3f8a8b..7ea99e4d21 100644 --- a/cocos/scripting/lua-bindings/auto/api/SceneReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/SceneReader.lua @@ -12,13 +12,13 @@ -- @function [parent=#SceneReader] createNodeWithSceneFile -- @param self -- @param #string str --- @param #ccs.SceneReader::AttachComponentType attachcomponenttype +-- @param #int attachcomponenttype -- @return Node#Node ret (return value: cc.Node) -------------------------------- -- @function [parent=#SceneReader] getAttachComponentType -- @param self --- @return SceneReader::AttachComponentType#SceneReader::AttachComponentType ret (return value: ccs.SceneReader::AttachComponentType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#SceneReader] getNodeByTag diff --git a/cocos/scripting/lua-bindings/auto/api/ScrollView.lua b/cocos/scripting/lua-bindings/auto/api/ScrollView.lua index ca67c9aeef..f1a9bab896 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScrollView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScrollView.lua @@ -32,7 +32,7 @@ -------------------------------- -- @function [parent=#ScrollView] getDirection -- @param self --- @return ScrollView::Direction#ScrollView::Direction ret (return value: ccui.ScrollView::Direction) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#ScrollView] scrollToBottomLeft @@ -52,7 +52,7 @@ -------------------------------- -- @function [parent=#ScrollView] setDirection -- @param self --- @param #ccui.ScrollView::Direction direction +-- @param #int direction -------------------------------- -- @function [parent=#ScrollView] scrollToTopLeft @@ -181,14 +181,10 @@ -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- --- overload function: addChild(cc.Node, int) --- --- overload function: addChild(cc.Node) --- --- overload function: addChild(cc.Node, int, int) --- --- overload function: addChild(cc.Node, int, string) --- +-- @overload self, cc.Node, int +-- @overload self, cc.Node +-- @overload self, cc.Node, int, int +-- @overload self, cc.Node, int, string -- @function [parent=#ScrollView] addChild -- @param self -- @param #cc.Node node @@ -214,7 +210,7 @@ -------------------------------- -- @function [parent=#ScrollView] getLayoutType -- @param self --- @return Layout::Type#Layout::Type ret (return value: ccui.Layout::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#ScrollView] removeAllChildrenWithCleanup @@ -228,7 +224,7 @@ -------------------------------- -- @function [parent=#ScrollView] findNextFocusedWidget -- @param self --- @param #ccui.Widget::FocusDirection focusdirection +-- @param #int focusdirection -- @param #ccui.Widget widget -- @return Widget#Widget ret (return value: ccui.Widget) @@ -239,10 +235,8 @@ -- @param #bool bool -------------------------------- --- overload function: getChildren() --- --- overload function: getChildren() --- +-- @overload self +-- @overload self -- @function [parent=#ScrollView] getChildren -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -261,7 +255,7 @@ -------------------------------- -- @function [parent=#ScrollView] setLayoutType -- @param self --- @param #ccui.Layout::Type type +-- @param #int type -------------------------------- -- @function [parent=#ScrollView] ScrollView diff --git a/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua b/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua index 06f8e2b827..a3cd0aad24 100644 --- a/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua +++ b/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua @@ -19,12 +19,4 @@ -- @function [parent=#SkeletonAnimation] clearTrack -- @param self --------------------------------- --- @function [parent=#SkeletonAnimation] onAnimationStateEvent --- @param self --- @param #int int --- @param #spEventType speventtype --- @param #spEvent spevent --- @param #int int - return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Skin.lua b/cocos/scripting/lua-bindings/auto/api/Skin.lua index 4f3f58bc67..10b1e77183 100644 --- a/cocos/scripting/lua-bindings/auto/api/Skin.lua +++ b/cocos/scripting/lua-bindings/auto/api/Skin.lua @@ -41,10 +41,8 @@ -- @param #ccs.Bone bone -------------------------------- --- overload function: create(string) --- --- overload function: create() --- +-- @overload self, string +-- @overload self -- @function [parent=#Skin] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/Slider.lua b/cocos/scripting/lua-bindings/auto/api/Slider.lua index 3cbc1c0b83..ade0016d08 100644 --- a/cocos/scripting/lua-bindings/auto/api/Slider.lua +++ b/cocos/scripting/lua-bindings/auto/api/Slider.lua @@ -13,25 +13,25 @@ -- @function [parent=#Slider] loadSlidBallTextureDisabled -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] loadSlidBallTextureNormal -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] loadBarTexture -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] loadProgressBarTexture -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] loadSlidBallTextures @@ -39,7 +39,7 @@ -- @param #string str -- @param #string str -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] setCapInsetProgressBarRebderer @@ -75,7 +75,7 @@ -- @function [parent=#Slider] loadSlidBallTexturePressed -- @param self -- @param #string str --- @param #ccui.Widget::TextureResType texturerestype +-- @param #int texturerestype -------------------------------- -- @function [parent=#Slider] isScale9Enabled diff --git a/cocos/scripting/lua-bindings/auto/api/Sprite.lua b/cocos/scripting/lua-bindings/auto/api/Sprite.lua index 942735e816..7be402618d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Sprite.lua +++ b/cocos/scripting/lua-bindings/auto/api/Sprite.lua @@ -5,19 +5,15 @@ -- @parent_module cc -------------------------------- --- overload function: setSpriteFrame(cc.SpriteFrame) --- --- overload function: setSpriteFrame(string) --- +-- @overload self, cc.SpriteFrame +-- @overload self, string -- @function [parent=#Sprite] setSpriteFrame -- @param self -- @param #string str -------------------------------- --- overload function: setTexture(cc.Texture2D) --- --- overload function: setTexture(string) --- +-- @overload self, cc.Texture2D +-- @overload self, string -- @function [parent=#Sprite] setTexture -- @param self -- @param #string str @@ -57,10 +53,8 @@ -- @param self -------------------------------- --- overload function: setTextureRect(rect_table, bool, size_table) --- --- overload function: setTextureRect(rect_table) --- +-- @overload self, rect_table, bool, size_table +-- @overload self, rect_table -- @function [parent=#Sprite] setTextureRect -- @param self -- @param #rect_table rect @@ -145,12 +139,9 @@ -- @param #rect_table rect -------------------------------- --- overload function: create(string) --- --- overload function: create() --- --- overload function: create(string, rect_table) --- +-- @overload self, string +-- @overload self +-- @overload self, string, rect_table -- @function [parent=#Sprite] create -- @param self -- @param #string str @@ -158,10 +149,8 @@ -- @return Sprite#Sprite ret (retunr value: cc.Sprite) -------------------------------- --- overload function: createWithTexture(cc.Texture2D, rect_table, bool) --- --- overload function: createWithTexture(cc.Texture2D) --- +-- @overload self, cc.Texture2D, rect_table, bool +-- @overload self, cc.Texture2D -- @function [parent=#Sprite] createWithTexture -- @param self -- @param #cc.Texture2D texture2d @@ -189,10 +178,8 @@ -- @param #unsigned int int -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#Sprite] addChild -- @param self -- @param #cc.Node node @@ -240,10 +227,8 @@ -- @param #float float -------------------------------- --- overload function: setScale(float) --- --- overload function: setScale(float, float) --- +-- @overload self, float +-- @overload self, float, float -- @function [parent=#Sprite] setScale -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua b/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua index 7ccbd43161..1af4d44bcd 100644 --- a/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: setTexture(cc.Texture2D) --- --- overload function: setTexture(string) --- +-- @overload self, cc.Texture2D +-- @overload self, string -- @function [parent=#Sprite3D] setTexture -- @param self -- @param #string str @@ -29,10 +27,8 @@ -- @param #cc.BlendFunc blendfunc -------------------------------- --- overload function: create(string, string) --- --- overload function: create(string) --- +-- @overload self, string, string +-- @overload self, string -- @function [parent=#Sprite3D] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua b/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua index c90efa107d..66321568dd 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua @@ -109,10 +109,8 @@ -- @return SpriteBatchNode#SpriteBatchNode ret (return value: cc.SpriteBatchNode) -------------------------------- --- overload function: addChild(cc.Node, int, string) --- --- overload function: addChild(cc.Node, int, int) --- +-- @overload self, cc.Node, int, string +-- @overload self, cc.Node, int, int -- @function [parent=#SpriteBatchNode] addChild -- @param self -- @param #cc.Node node diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua b/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua index 4751bae0ad..cca90af1d0 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua @@ -90,10 +90,8 @@ -- @return size_table#size_table ret (return value: size_table) -------------------------------- --- overload function: create(string, rect_table, bool, vec2_table, size_table) --- --- overload function: create(string, rect_table) --- +-- @overload self, string, rect_table, bool, vec2_table, size_table +-- @overload self, string, rect_table -- @function [parent=#SpriteFrame] create -- @param self -- @param #string str @@ -104,10 +102,8 @@ -- @return SpriteFrame#SpriteFrame ret (retunr value: cc.SpriteFrame) -------------------------------- --- overload function: createWithTexture(cc.Texture2D, rect_table, bool, vec2_table, size_table) --- --- overload function: createWithTexture(cc.Texture2D, rect_table) --- +-- @overload self, cc.Texture2D, rect_table, bool, vec2_table, size_table +-- @overload self, cc.Texture2D, rect_table -- @function [parent=#SpriteFrame] createWithTexture -- @param self -- @param #cc.Texture2D texture2d diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua b/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua index 8c1cc29b20..0d8ee97edf 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua @@ -5,12 +5,9 @@ -- @parent_module cc -------------------------------- --- overload function: addSpriteFramesWithFile(string, string) --- --- overload function: addSpriteFramesWithFile(string) --- --- overload function: addSpriteFramesWithFile(string, cc.Texture2D) --- +-- @overload self, string, string +-- @overload self, string +-- @overload self, string, cc.Texture2D -- @function [parent=#SpriteFrameCache] addSpriteFramesWithFile -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua b/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua index 6fb6367046..315b1a4f20 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua @@ -1,8 +1,8 @@ -------------------------------- -- @module TMXLayer --- @extend SpriteBatchNode --- @parent_module cc +-- @extend Node +-- @parent_module ccexp -------------------------------- -- @function [parent=#TMXLayer] getPositionAt @@ -15,10 +15,6 @@ -- @param self -- @param #int int --------------------------------- --- @function [parent=#TMXLayer] releaseMap --- @param self - -------------------------------- -- @function [parent=#TMXLayer] getLayerSize -- @param self @@ -50,27 +46,31 @@ -- @param #vec2_table vec2 -------------------------------- --- @function [parent=#TMXLayer] initWithTilesetInfo +-- @overload self +-- @overload self +-- @function [parent=#TMXLayer] getProperties -- @param self --- @param #cc.TMXTilesetInfo tmxtilesetinfo --- @param #cc.TMXLayerInfo tmxlayerinfo --- @param #cc.TMXMapInfo map --- @return bool#bool ret (return value: bool) - +-- @return map_table#map_table ret (retunr value: map_table) + -------------------------------- -- @function [parent=#TMXLayer] setupTiles -- @param self -------------------------------- --- overload function: setTileGID(unsigned int, vec2_table, cc.TMXTileFlags_) --- --- overload function: setTileGID(unsigned int, vec2_table) --- +-- @function [parent=#TMXLayer] setupTileSprite +-- @param self +-- @param #cc.Sprite sprite +-- @param #vec2_table vec2 +-- @param #int int + +-------------------------------- +-- @overload self, int, vec2_table, int +-- @overload self, int, vec2_table -- @function [parent=#TMXLayer] setTileGID -- @param self --- @param #unsigned int int +-- @param #int int -- @param #vec2_table vec2 --- @param #cc.TMXTileFlags_ tmxtileflags_ +-- @param #int tmxtileflags_ -------------------------------- -- @function [parent=#TMXLayer] getMapTileSize @@ -103,15 +103,6 @@ -- @param self -- @return TMXTilesetInfo#TMXTilesetInfo ret (return value: cc.TMXTilesetInfo) --------------------------------- --- overload function: getProperties() --- --- overload function: getProperties() --- --- @function [parent=#TMXLayer] getProperties --- @param self --- @return map_table#map_table ret (retunr value: map_table) - -------------------------------- -- @function [parent=#TMXLayer] getTileAt -- @param self @@ -124,19 +115,7 @@ -- @param #cc.TMXTilesetInfo tmxtilesetinfo -- @param #cc.TMXLayerInfo tmxlayerinfo -- @param #cc.TMXMapInfo map --- @return TMXLayer#TMXLayer ret (return value: cc.TMXLayer) - --------------------------------- --- @function [parent=#TMXLayer] addChild --- @param self --- @param #cc.Node node --- @param #int int --- @param #int int - --------------------------------- --- @function [parent=#TMXLayer] getDescription --- @param self --- @return string#string ret (return value: string) +-- @return experimental::TMXLayer#experimental::TMXLayer ret (return value: cc.experimental::TMXLayer) -------------------------------- -- @function [parent=#TMXLayer] removeChild @@ -144,6 +123,18 @@ -- @param #cc.Node node -- @param #bool bool +-------------------------------- +-- @function [parent=#TMXLayer] draw +-- @param self +-- @param #cc.Renderer renderer +-- @param #mat4_table mat4 +-- @param #unsigned int int + +-------------------------------- +-- @function [parent=#TMXLayer] getDescription +-- @param self +-- @return string#string ret (return value: string) + -------------------------------- -- @function [parent=#TMXLayer] TMXLayer -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua b/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua index e5b3ab7d62..ef098ce6f2 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua @@ -57,19 +57,15 @@ -- @return bool#bool ret (return value: bool) -------------------------------- --- overload function: getLayers() --- --- overload function: getLayers() --- +-- @overload self +-- @overload self -- @function [parent=#TMXMapInfo] getLayers -- @param self -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- --- overload function: getTilesets() --- --- overload function: getTilesets() --- +-- @overload self +-- @overload self -- @function [parent=#TMXMapInfo] getTilesets -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -112,10 +108,8 @@ -- @return map_table#map_table ret (return value: map_table) -------------------------------- --- overload function: getObjectGroups() --- --- overload function: getObjectGroups() --- +-- @overload self +-- @overload self -- @function [parent=#TMXMapInfo] getObjectGroups -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -166,10 +160,8 @@ -- @param #array_table array -------------------------------- --- overload function: getProperties() --- --- overload function: getProperties() --- +-- @overload self +-- @overload self -- @function [parent=#TMXMapInfo] getProperties -- @param self -- @return map_table#map_table ret (retunr value: map_table) diff --git a/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua b/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua index e5d58455c7..2a2330d036 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua @@ -27,10 +27,8 @@ -- @return map_table#map_table ret (return value: map_table) -------------------------------- --- overload function: getObjects() --- --- overload function: getObjects() --- +-- @overload self +-- @overload self -- @function [parent=#TMXObjectGroup] getObjects -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -41,10 +39,8 @@ -- @param #string str -------------------------------- --- overload function: getProperties() --- --- overload function: getProperties() --- +-- @overload self +-- @overload self -- @function [parent=#TMXObjectGroup] getProperties -- @param self -- @return map_table#map_table ret (retunr value: map_table) diff --git a/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua b/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua index ad971f4749..86175d51f4 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua @@ -2,7 +2,7 @@ -------------------------------- -- @module TMXTiledMap -- @extend Node --- @parent_module cc +-- @parent_module ccexp -------------------------------- -- @function [parent=#TMXTiledMap] setObjectGroups @@ -27,10 +27,8 @@ -- @return TMXObjectGroup#TMXObjectGroup ret (return value: cc.TMXObjectGroup) -------------------------------- --- overload function: getObjectGroups() --- --- overload function: getObjectGroups() --- +-- @overload self +-- @overload self -- @function [parent=#TMXTiledMap] getObjectGroups -- @param self -- @return array_table#array_table ret (retunr value: array_table) @@ -50,6 +48,12 @@ -- @param self -- @return map_table#map_table ret (return value: map_table) +-------------------------------- +-- @function [parent=#TMXTiledMap] getPropertiesForGID +-- @param self +-- @param #int int +-- @return Value#Value ret (return value: cc.Value) + -------------------------------- -- @function [parent=#TMXTiledMap] setTileSize -- @param self @@ -64,7 +68,7 @@ -- @function [parent=#TMXTiledMap] getLayer -- @param self -- @param #string str --- @return TMXLayer#TMXLayer ret (return value: cc.TMXLayer) +-- @return experimental::TMXLayer#experimental::TMXLayer ret (return value: cc.experimental::TMXLayer) -------------------------------- -- @function [parent=#TMXTiledMap] getMapOrientation @@ -80,14 +84,14 @@ -- @function [parent=#TMXTiledMap] create -- @param self -- @param #string str --- @return TMXTiledMap#TMXTiledMap ret (return value: cc.TMXTiledMap) +-- @return experimental::TMXTiledMap#experimental::TMXTiledMap ret (return value: cc.experimental::TMXTiledMap) -------------------------------- -- @function [parent=#TMXTiledMap] createWithXML -- @param self -- @param #string str -- @param #string str --- @return TMXTiledMap#TMXTiledMap ret (return value: cc.TMXTiledMap) +-- @return experimental::TMXTiledMap#experimental::TMXTiledMap ret (return value: cc.experimental::TMXTiledMap) -------------------------------- -- @function [parent=#TMXTiledMap] getDescription diff --git a/cocos/scripting/lua-bindings/auto/api/TableView.lua b/cocos/scripting/lua-bindings/auto/api/TableView.lua index 1dc639a3d7..2efa32f127 100644 --- a/cocos/scripting/lua-bindings/auto/api/TableView.lua +++ b/cocos/scripting/lua-bindings/auto/api/TableView.lua @@ -12,7 +12,7 @@ -------------------------------- -- @function [parent=#TableView] setVerticalFillOrder -- @param self --- @param #cc.TableView::VerticalFillOrder verticalfillorder +-- @param #int verticalfillorder -------------------------------- -- @function [parent=#TableView] scrollViewDidZoom @@ -26,7 +26,7 @@ -------------------------------- -- @function [parent=#TableView] getVerticalFillOrder -- @param self --- @return TableView::VerticalFillOrder#TableView::VerticalFillOrder ret (return value: cc.TableView::VerticalFillOrder) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#TableView] removeCellAtIndex diff --git a/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua b/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua index d5be1e7cf1..82d934aab5 100644 --- a/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: getForcedTarget() --- --- overload function: getForcedTarget() --- +-- @overload self +-- @overload self -- @function [parent=#TargetedAction] getForcedTarget -- @param self -- @return Node#Node ret (retunr value: cc.Node) diff --git a/cocos/scripting/lua-bindings/auto/api/Text.lua b/cocos/scripting/lua-bindings/auto/api/Text.lua index 59aabe41e9..15ebbd4c3c 100644 --- a/cocos/scripting/lua-bindings/auto/api/Text.lua +++ b/cocos/scripting/lua-bindings/auto/api/Text.lua @@ -33,7 +33,7 @@ -------------------------------- -- @function [parent=#Text] getTextVerticalAlignment -- @param self --- @return TextVAlignment#TextVAlignment ret (return value: cc.TextVAlignment) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Text] getString @@ -52,12 +52,12 @@ -------------------------------- -- @function [parent=#Text] getTextHorizontalAlignment -- @param self --- @return TextHAlignment#TextHAlignment ret (return value: cc.TextHAlignment) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Text] setTextVerticalAlignment -- @param self --- @param #cc.TextVAlignment textvalignment +-- @param #int textvalignment -------------------------------- -- @function [parent=#Text] enableGlow @@ -72,7 +72,7 @@ -------------------------------- -- @function [parent=#Text] setTextHorizontalAlignment -- @param self --- @param #cc.TextHAlignment texthalignment +-- @param #int texthalignment -------------------------------- -- @function [parent=#Text] setFontSize @@ -87,7 +87,7 @@ -------------------------------- -- @function [parent=#Text] getType -- @param self --- @return Text::Type#Text::Type ret (return value: ccui.Text::Type) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Text] disableEffect @@ -104,10 +104,8 @@ -- @param #size_table size -------------------------------- --- overload function: create(string, string, int) --- --- overload function: create() --- +-- @overload self, string, string, int +-- @overload self -- @function [parent=#Text] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua b/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua index 5b331fcce3..2ee69b8e6e 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua @@ -33,10 +33,8 @@ -- @param self -------------------------------- --- overload function: create(string, string, int, int, string) --- --- overload function: create() --- +-- @overload self, string, string, int, int, string +-- @overload self -- @function [parent=#TextAtlas] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua b/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua index 73c0b93931..424c43eda3 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua @@ -25,10 +25,8 @@ -- @return string#string ret (return value: string) -------------------------------- --- overload function: create(string, string) --- --- overload function: create() --- +-- @overload self, string, string +-- @overload self -- @function [parent=#TextBMFont] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/TextField.lua b/cocos/scripting/lua-bindings/auto/api/TextField.lua index 89ae5c77f1..b2c82a059d 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextField.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextField.lua @@ -57,7 +57,7 @@ -------------------------------- -- @function [parent=#TextField] setTextVerticalAlignment -- @param self --- @param #cc.TextVAlignment textvalignment +-- @param #int textvalignment -------------------------------- -- @function [parent=#TextField] addEventListener @@ -130,7 +130,7 @@ -------------------------------- -- @function [parent=#TextField] setTextHorizontalAlignment -- @param self --- @param #cc.TextHAlignment texthalignment +-- @param #int texthalignment -------------------------------- -- @function [parent=#TextField] getMaxLength @@ -179,10 +179,8 @@ -- @return size_table#size_table ret (return value: size_table) -------------------------------- --- overload function: create(string, string, int) --- --- overload function: create() --- +-- @overload self, string, string, int +-- @overload self -- @function [parent=#TextField] create -- @param self -- @param #string str diff --git a/cocos/scripting/lua-bindings/auto/api/Texture2D.lua b/cocos/scripting/lua-bindings/auto/api/Texture2D.lua index d1db2503f1..81a1947825 100644 --- a/cocos/scripting/lua-bindings/auto/api/Texture2D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Texture2D.lua @@ -15,14 +15,12 @@ -- @return char#char ret (return value: char) -------------------------------- --- overload function: initWithImage(cc.Image, cc.Texture2D::PixelFormat) --- --- overload function: initWithImage(cc.Image) --- +-- @overload self, cc.Image, int +-- @overload self, cc.Image -- @function [parent=#Texture2D] initWithImage -- @param self -- @param #cc.Image image --- @param #cc.Texture2D::PixelFormat pixelformat +-- @param #int pixelformat -- @return bool#bool ret (retunr value: bool) -------------------------------- @@ -45,13 +43,11 @@ -- @return int#int ret (return value: int) -------------------------------- --- overload function: getBitsPerPixelForFormat(cc.Texture2D::PixelFormat) --- --- overload function: getBitsPerPixelForFormat() --- +-- @overload self, int +-- @overload self -- @function [parent=#Texture2D] getBitsPerPixelForFormat -- @param self --- @param #cc.Texture2D::PixelFormat pixelformat +-- @param #int pixelformat -- @return unsigned int#unsigned int ret (retunr value: unsigned int) -------------------------------- @@ -60,18 +56,16 @@ -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- --- overload function: initWithString(char, cc.FontDefinition) --- --- overload function: initWithString(char, string, float, size_table, cc.TextHAlignment, cc.TextVAlignment) --- +-- @overload self, char, cc.FontDefinition +-- @overload self, char, string, float, size_table, int, int -- @function [parent=#Texture2D] initWithString -- @param self -- @param #char char -- @param #string str -- @param #float float -- @param #size_table size --- @param #cc.TextHAlignment texthalignment --- @param #cc.TextVAlignment textvalignment +-- @param #int texthalignment +-- @param #int textvalignment -- @return bool#bool ret (retunr value: bool) -------------------------------- @@ -109,7 +103,7 @@ -------------------------------- -- @function [parent=#Texture2D] getPixelFormat -- @param self --- @return Texture2D::PixelFormat#Texture2D::PixelFormat ret (return value: cc.Texture2D::PixelFormat) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Texture2D] setGLProgram @@ -149,12 +143,12 @@ -------------------------------- -- @function [parent=#Texture2D] setDefaultAlphaPixelFormat -- @param self --- @param #cc.Texture2D::PixelFormat pixelformat +-- @param #int pixelformat -------------------------------- -- @function [parent=#Texture2D] getDefaultAlphaPixelFormat -- @param self --- @return Texture2D::PixelFormat#Texture2D::PixelFormat ret (return value: cc.Texture2D::PixelFormat) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Texture2D] PVRImagesHavePremultipliedAlpha diff --git a/cocos/scripting/lua-bindings/auto/api/TextureCache.lua b/cocos/scripting/lua-bindings/auto/api/TextureCache.lua index 74b93c8ded..fbcaadd1ac 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextureCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextureCache.lua @@ -34,10 +34,8 @@ -- @return string#string ret (return value: string) -------------------------------- --- overload function: addImage(cc.Image, string) --- --- overload function: addImage(string) --- +-- @overload self, cc.Image, string +-- @overload self, string -- @function [parent=#TextureCache] addImage -- @param self -- @param #cc.Image image diff --git a/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua b/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua index 01a779f136..53ad06354a 100644 --- a/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(size_table) --- --- overload function: create(size_table, cc.Texture2D, bool) --- +-- @overload self, size_table +-- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#TiledGrid3D] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua index 14da7ec620..73bd19113b 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua @@ -5,10 +5,8 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, color3b_table) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, color3b_table -- @function [parent=#TransitionFade] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua index 909801bbb8..e8be2f3f92 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipAngular] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionFlipAngular#TransitionFlipAngular ret (retunr value: cc.TransitionFlipAngular) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua index 721f23f447..bd3d3d3660 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipX] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionFlipX#TransitionFlipX ret (retunr value: cc.TransitionFlipX) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua index fe23b1bf0c..eebe6b56bc 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipY] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionFlipY#TransitionFlipY ret (retunr value: cc.TransitionFlipY) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua index fa8d58c4fc..1c655d6fab 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua @@ -33,8 +33,4 @@ -- @param #mat4_table mat4 -- @param #unsigned int int --------------------------------- --- @function [parent=#TransitionPageTurn] TransitionPageTurn --- @param self - return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua index dd78bcf0e7..d05379f82b 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua @@ -11,8 +11,4 @@ -- @param #cc.Scene scene -- @return TransitionProgress#TransitionProgress ret (return value: cc.TransitionProgress) --------------------------------- --- @function [parent=#TransitionProgress] TransitionProgress --- @param self - return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua index b565055c4f..965126e682 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua @@ -9,7 +9,7 @@ -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionSceneOriented#TransitionSceneOriented ret (return value: cc.TransitionSceneOriented) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua index 039e476142..10360d5cf8 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipAngular] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionZoomFlipAngular#TransitionZoomFlipAngular ret (retunr value: cc.TransitionZoomFlipAngular) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua index 92bae22d88..fa6ed5fd29 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipX] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionZoomFlipX#TransitionZoomFlipX ret (retunr value: cc.TransitionZoomFlipX) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua index d9ec479508..d137a545e9 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua @@ -5,15 +5,13 @@ -- @parent_module cc -------------------------------- --- overload function: create(float, cc.Scene) --- --- overload function: create(float, cc.Scene, cc.TransitionScene::Orientation) --- +-- @overload self, float, cc.Scene +-- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipY] create -- @param self -- @param #float float -- @param #cc.Scene scene --- @param #cc.TransitionScene::Orientation orientation +-- @param #int orientation -- @return TransitionZoomFlipY#TransitionZoomFlipY ret (retunr value: cc.TransitionZoomFlipY) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua b/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua index 74f28e88f5..c7ffd3d8f4 100644 --- a/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua @@ -15,10 +15,8 @@ -- @param #vec2_table vec2 -------------------------------- --- overload function: create(float, size_table, unsigned int) --- --- overload function: create(float, size_table) --- +-- @overload self, float, size_table, unsigned int +-- @overload self, float, size_table -- @function [parent=#TurnOffTiles] create -- @param self -- @param #float float diff --git a/cocos/scripting/lua-bindings/auto/api/UserDefault.lua b/cocos/scripting/lua-bindings/auto/api/UserDefault.lua index 5d733a2c9e..173263c472 100644 --- a/cocos/scripting/lua-bindings/auto/api/UserDefault.lua +++ b/cocos/scripting/lua-bindings/auto/api/UserDefault.lua @@ -10,10 +10,8 @@ -- @param #int int -------------------------------- --- overload function: getFloatForKey(char, float) --- --- overload function: getFloatForKey(char) --- +-- @overload self, char, float +-- @overload self, char -- @function [parent=#UserDefault] getFloatForKey -- @param self -- @param #char char @@ -21,10 +19,8 @@ -- @return float#float ret (retunr value: float) -------------------------------- --- overload function: getBoolForKey(char, bool) --- --- overload function: getBoolForKey(char) --- +-- @overload self, char, bool +-- @overload self, char -- @function [parent=#UserDefault] getBoolForKey -- @param self -- @param #char char @@ -44,10 +40,8 @@ -- @param #float float -------------------------------- --- overload function: getStringForKey(char, string) --- --- overload function: getStringForKey(char) --- +-- @overload self, char, string +-- @overload self, char -- @function [parent=#UserDefault] getStringForKey -- @param self -- @param #char char @@ -65,10 +59,8 @@ -- @param self -------------------------------- --- overload function: getIntegerForKey(char, int) --- --- overload function: getIntegerForKey(char) --- +-- @overload self, char, int +-- @overload self, char -- @function [parent=#UserDefault] getIntegerForKey -- @param self -- @param #char char @@ -76,10 +68,8 @@ -- @return int#int ret (retunr value: int) -------------------------------- --- overload function: getDoubleForKey(char, double) --- --- overload function: getDoubleForKey(char) --- +-- @overload self, char, double +-- @overload self, char -- @function [parent=#UserDefault] getDoubleForKey -- @param self -- @param #char char diff --git a/cocos/scripting/lua-bindings/auto/api/VBox.lua b/cocos/scripting/lua-bindings/auto/api/VBox.lua index ddc31a60b1..0955ae7c9e 100644 --- a/cocos/scripting/lua-bindings/auto/api/VBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/VBox.lua @@ -5,10 +5,8 @@ -- @parent_module ccui -------------------------------- --- overload function: create(size_table) --- --- overload function: create() --- +-- @overload self, size_table +-- @overload self -- @function [parent=#VBox] create -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua b/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua index 81ca7db206..36954f071d 100644 --- a/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua +++ b/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua @@ -2,7 +2,7 @@ -------------------------------- -- @module VideoPlayer -- @extend Widget --- @parent_module ccexprimental +-- @parent_module ccexp -------------------------------- -- @function [parent=#VideoPlayer] getFileName @@ -58,7 +58,7 @@ -------------------------------- -- @function [parent=#VideoPlayer] onPlayEvent -- @param self --- @param #cc.experimental::ui::VideoPlayer::EventType eventtype +-- @param #int int -------------------------------- -- @function [parent=#VideoPlayer] isFullScreenEnabled diff --git a/cocos/scripting/lua-bindings/auto/api/Widget.lua b/cocos/scripting/lua-bindings/auto/api/Widget.lua index 2a254f1f5f..4cb3995919 100644 --- a/cocos/scripting/lua-bindings/auto/api/Widget.lua +++ b/cocos/scripting/lua-bindings/auto/api/Widget.lua @@ -52,7 +52,7 @@ -------------------------------- -- @function [parent=#Widget] setPositionType -- @param self --- @param #ccui.Widget::PositionType positiontype +-- @param #int positiontype -------------------------------- -- @function [parent=#Widget] isIgnoreContentAdaptWithSize @@ -77,14 +77,14 @@ -------------------------------- -- @function [parent=#Widget] findNextFocusedWidget -- @param self --- @param #ccui.Widget::FocusDirection focusdirection +-- @param #int focusdirection -- @param #ccui.Widget widget -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- -- @function [parent=#Widget] getPositionType -- @param self --- @return Widget::PositionType#Widget::PositionType ret (return value: ccui.Widget::PositionType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Widget] getTopBoundary @@ -159,7 +159,7 @@ -------------------------------- -- @function [parent=#Widget] setBrightStyle -- @param self --- @param #ccui.Widget::BrightStyle brightstyle +-- @param #int brightstyle -------------------------------- -- @function [parent=#Widget] setLayoutParameter @@ -196,10 +196,8 @@ -- @param self -------------------------------- --- overload function: updateSizeAndPosition(size_table) --- --- overload function: updateSizeAndPosition() --- +-- @overload self, size_table +-- @overload self -- @function [parent=#Widget] updateSizeAndPosition -- @param self -- @param #size_table size @@ -212,7 +210,7 @@ -------------------------------- -- @function [parent=#Widget] getSizeType -- @param self --- @return Widget::SizeType#Widget::SizeType ret (return value: ccui.Widget::SizeType) +-- @return int#int ret (return value: int) -------------------------------- -- @function [parent=#Widget] addTouchEventListener @@ -254,7 +252,7 @@ -------------------------------- -- @function [parent=#Widget] setSizeType -- @param self --- @param #ccui.Widget::SizeType sizetype +-- @param #int sizetype -------------------------------- -- @function [parent=#Widget] setBright diff --git a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_auto_api.lua b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_auto_api.lua index 2d798d773a..1e6649afb8 100644 --- a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_auto_api.lua +++ b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_auto_api.lua @@ -1196,16 +1196,6 @@ -- @field [parent=#cc] TileMapAtlas#TileMapAtlas TileMapAtlas preloaded module --------------------------------------------------------- --- the cc FastTMXTiledMap --- @field [parent=#cc] FastTMXTiledMap#FastTMXTiledMap FastTMXTiledMap preloaded module - - --------------------------------------------------------- --- the cc FastTMXLayer --- @field [parent=#cc] FastTMXLayer#FastTMXLayer FastTMXLayer preloaded module - - -------------------------------------------------------- -- the cc Component -- @field [parent=#cc] Component#Component Component preloaded module diff --git a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_auto_api.lua b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_auto_api.lua new file mode 100644 index 0000000000..56a40c50ac --- /dev/null +++ b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_auto_api.lua @@ -0,0 +1,14 @@ +-------------------------------- +-- @module ccexp + +-------------------------------------------------------- +-- the ccexp TMXLayer +-- @field [parent=#ccexp] TMXLayer#TMXLayer TMXLayer preloaded module + + +-------------------------------------------------------- +-- the ccexp TMXTiledMap +-- @field [parent=#ccexp] TMXTiledMap#TMXTiledMap TMXTiledMap preloaded module + + +return nil diff --git a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_video_auto_api.lua b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_video_auto_api.lua index 515fad0841..b9de15b788 100644 --- a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_video_auto_api.lua +++ b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_video_auto_api.lua @@ -1,9 +1,9 @@ -------------------------------- --- @module ccexprimental +-- @module ccexp -------------------------------------------------------- --- the ccexprimental VideoPlayer --- @field [parent=#ccexprimental] VideoPlayer#VideoPlayer VideoPlayer preloaded module +-- the ccexp VideoPlayer +-- @field [parent=#ccexp] VideoPlayer#VideoPlayer VideoPlayer preloaded module return nil diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp index c64da13f70..9f9266e91c 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp @@ -4721,50 +4721,6 @@ int lua_cocos2dx_Node_getTag(lua_State* tolua_S) return 0; } -int lua_cocos2dx_Node_getonEnterTransitionDidFinishCallback(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::Node* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getonEnterTransitionDidFinishCallback'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const std::function& ret = cobj->getonEnterTransitionDidFinishCallback(); - #pragma warning NO CONVERSION FROM NATIVE FOR std::function; - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getonEnterTransitionDidFinishCallback",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getonEnterTransitionDidFinishCallback'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_Node_getGLProgram(lua_State* tolua_S) { int argc = 0; @@ -5782,50 +5738,6 @@ int lua_cocos2dx_Node_convertTouchToNodeSpaceAR(lua_State* tolua_S) return 0; } -int lua_cocos2dx_Node_getOnEnterCallback(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::Node* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getOnEnterCallback'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const std::function& ret = cobj->getOnEnterCallback(); - #pragma warning NO CONVERSION FROM NATIVE FOR std::function; - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getOnEnterCallback",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getOnEnterCallback'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_Node_convertToNodeSpace(lua_State* tolua_S) { int argc = 0; @@ -8379,50 +8291,6 @@ int lua_cocos2dx_Node_setScale(lua_State* tolua_S) return 0; } -int lua_cocos2dx_Node_getOnExitCallback(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::Node* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getOnExitCallback'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const std::function& ret = cobj->getOnExitCallback(); - #pragma warning NO CONVERSION FROM NATIVE FOR std::function; - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getOnExitCallback",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getOnExitCallback'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_Node_getChildByTag(lua_State* tolua_S) { int argc = 0; @@ -9245,50 +9113,6 @@ int lua_cocos2dx_Node_setUserObject(lua_State* tolua_S) return 0; } -int lua_cocos2dx_Node_getonExitTransitionDidStartCallback(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::Node* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Node",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::Node*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_Node_getonExitTransitionDidStartCallback'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const std::function& ret = cobj->getonExitTransitionDidStartCallback(); - #pragma warning NO CONVERSION FROM NATIVE FOR std::function; - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getonExitTransitionDidStartCallback",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_Node_getonExitTransitionDidStartCallback'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_Node_removeFromParentAndCleanup(lua_State* tolua_S) { int argc = 0; @@ -9942,7 +9766,6 @@ int lua_register_cocos2dx_Node(lua_State* tolua_S) tolua_function(tolua_S,"removeAllComponents",lua_cocos2dx_Node_removeAllComponents); tolua_function(tolua_S,"_setLocalZOrder",lua_cocos2dx_Node__setLocalZOrder); tolua_function(tolua_S,"getTag",lua_cocos2dx_Node_getTag); - tolua_function(tolua_S,"getonEnterTransitionDidFinishCallback",lua_cocos2dx_Node_getonEnterTransitionDidFinishCallback); tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_Node_getGLProgram); tolua_function(tolua_S,"getNodeToWorldTransform",lua_cocos2dx_Node_getNodeToWorldTransform); tolua_function(tolua_S,"getPosition3D",lua_cocos2dx_Node_getPosition3D); @@ -9965,7 +9788,6 @@ int lua_register_cocos2dx_Node(lua_State* tolua_S) tolua_function(tolua_S,"getRotation3D",lua_cocos2dx_Node_getRotation3D); tolua_function(tolua_S,"getNodeToParentTransform",lua_cocos2dx_Node_getNodeToParentTransform); tolua_function(tolua_S,"convertTouchToNodeSpaceAR",lua_cocos2dx_Node_convertTouchToNodeSpaceAR); - tolua_function(tolua_S,"getOnEnterCallback",lua_cocos2dx_Node_getOnEnterCallback); tolua_function(tolua_S,"convertToNodeSpace",lua_cocos2dx_Node_convertToNodeSpace); tolua_function(tolua_S,"resume",lua_cocos2dx_Node_resume); tolua_function(tolua_S,"getPhysicsBody",lua_cocos2dx_Node_getPhysicsBody); @@ -10021,7 +9843,6 @@ int lua_register_cocos2dx_Node(lua_State* tolua_S) tolua_function(tolua_S,"getParentToNodeTransform",lua_cocos2dx_Node_getParentToNodeTransform); tolua_function(tolua_S,"setGlobalZOrder",lua_cocos2dx_Node_setGlobalZOrder); tolua_function(tolua_S,"setScale",lua_cocos2dx_Node_setScale); - tolua_function(tolua_S,"getOnExitCallback",lua_cocos2dx_Node_getOnExitCallback); tolua_function(tolua_S,"getChildByTag",lua_cocos2dx_Node_getChildByTag); tolua_function(tolua_S,"setOrderOfArrival",lua_cocos2dx_Node_setOrderOfArrival); tolua_function(tolua_S,"getScaleZ",lua_cocos2dx_Node_getScaleZ); @@ -10040,7 +9861,6 @@ int lua_register_cocos2dx_Node(lua_State* tolua_S) tolua_function(tolua_S,"getGlobalZOrder",lua_cocos2dx_Node_getGlobalZOrder); tolua_function(tolua_S,"draw",lua_cocos2dx_Node_draw); tolua_function(tolua_S,"setUserObject",lua_cocos2dx_Node_setUserObject); - tolua_function(tolua_S,"getonExitTransitionDidStartCallback",lua_cocos2dx_Node_getonExitTransitionDidStartCallback); tolua_function(tolua_S,"removeFromParent",lua_cocos2dx_Node_removeFromParentAndCleanup); tolua_function(tolua_S,"setPosition3D",lua_cocos2dx_Node_setPosition3D); tolua_function(tolua_S,"update",lua_cocos2dx_Node_update); @@ -15700,6 +15520,19 @@ int lua_cocos2dx_FileUtils_addSearchResolutionsOrder(lua_State* tolua_S) cobj->addSearchResolutionsOrder(arg0); return 0; } + if (argc == 2) + { + std::string arg0; + bool arg1; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + + ok &= luaval_to_boolean(tolua_S, 3,&arg1); + if(!ok) + return 0; + cobj->addSearchResolutionsOrder(arg0, arg1); + return 0; + } CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "addSearchResolutionsOrder",argc, 1); return 0; @@ -15746,6 +15579,19 @@ int lua_cocos2dx_FileUtils_addSearchPath(lua_State* tolua_S) cobj->addSearchPath(arg0); return 0; } + if (argc == 2) + { + std::string arg0; + bool arg1; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + + ok &= luaval_to_boolean(tolua_S, 3,&arg1); + if(!ok) + return 0; + cobj->addSearchPath(arg0, arg1); + return 0; + } CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "addSearchPath",argc, 1); return 0; @@ -39201,40 +39047,6 @@ int lua_cocos2dx_TransitionPageTurn_create(lua_State* tolua_S) #endif return 0; } -int lua_cocos2dx_TransitionPageTurn_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::TransitionPageTurn* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::TransitionPageTurn(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionPageTurn"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "TransitionPageTurn",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_constructor'.",&tolua_err); -#endif - - return 0; -} - static int lua_cocos2dx_TransitionPageTurn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionPageTurn)"); @@ -39247,7 +39059,6 @@ int lua_register_cocos2dx_TransitionPageTurn(lua_State* tolua_S) tolua_cclass(tolua_S,"TransitionPageTurn","cc.TransitionPageTurn","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionPageTurn"); - tolua_function(tolua_S,"new",lua_cocos2dx_TransitionPageTurn_constructor); tolua_function(tolua_S,"actionWithSize",lua_cocos2dx_TransitionPageTurn_actionWithSize); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionPageTurn_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionPageTurn_create); @@ -39293,40 +39104,6 @@ int lua_cocos2dx_TransitionProgress_create(lua_State* tolua_S) #endif return 0; } -int lua_cocos2dx_TransitionProgress_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::TransitionProgress* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::TransitionProgress(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgress"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "TransitionProgress",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgress_constructor'.",&tolua_err); -#endif - - return 0; -} - static int lua_cocos2dx_TransitionProgress_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgress)"); @@ -39339,7 +39116,6 @@ int lua_register_cocos2dx_TransitionProgress(lua_State* tolua_S) tolua_cclass(tolua_S,"TransitionProgress","cc.TransitionProgress","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionProgress"); - tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgress_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgress_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgress).name(); @@ -61973,1751 +61749,6 @@ int lua_register_cocos2dx_TileMapAtlas(lua_State* tolua_S) return 1; } -int lua_cocos2dx_FastTMXTiledMap_setObjectGroups(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_setObjectGroups'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Vector arg0; - - ok &= luaval_to_ccvector(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setObjectGroups(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setObjectGroups",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_setObjectGroups'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getProperty(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getProperty'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - std::string arg0; - - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cocos2d::Value ret = cobj->getProperty(arg0); - ccvalue_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperty",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getProperty'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_setMapSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_setMapSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Size arg0; - - ok &= luaval_to_size(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setMapSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_setMapSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getObjectGroup(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getObjectGroup'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - std::string arg0; - - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cocos2d::TMXObjectGroup* ret = cobj->getObjectGroup(arg0); - object_to_luaval(tolua_S, "cc.TMXObjectGroup",(cocos2d::TMXObjectGroup*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getObjectGroup",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getObjectGroup'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getObjectGroups(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getObjectGroups'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 0) { - cocos2d::Vector& ret = cobj->getObjectGroups(); - ccvector_to_luaval(tolua_S, ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 0) { - const cocos2d::Vector& ret = cobj->getObjectGroups(); - ccvector_to_luaval(tolua_S, ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getObjectGroups",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getObjectGroups'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getTileSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getTileSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const cocos2d::Size& ret = cobj->getTileSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getTileSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getMapSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getMapSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const cocos2d::Size& ret = cobj->getMapSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getMapSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getProperties(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getProperties'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const cocos2d::ValueMap& ret = cobj->getProperties(); - ccvaluemap_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperties",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getProperties'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getPropertiesForGID(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getPropertiesForGID'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - if(!ok) - return 0; - cocos2d::Value ret = cobj->getPropertiesForGID(arg0); - ccvalue_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getPropertiesForGID",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getPropertiesForGID'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_setTileSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_setTileSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Size arg0; - - ok &= luaval_to_size(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setTileSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_setTileSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_setProperties(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_setProperties'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::ValueMap arg0; - - ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setProperties(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setProperties",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_setProperties'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getLayer(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getLayer'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - std::string arg0; - - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cocos2d::FastTMXLayer* ret = cobj->getLayer(arg0); - object_to_luaval(tolua_S, "cc.FastTMXLayer",(cocos2d::FastTMXLayer*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayer",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getLayer'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_getMapOrientation(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_getMapOrientation'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - int ret = cobj->getMapOrientation(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapOrientation",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_getMapOrientation'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_setMapOrientation(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXTiledMap* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXTiledMap*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXTiledMap_setMapOrientation'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - if(!ok) - return 0; - cobj->setMapOrientation(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapOrientation",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_setMapOrientation'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_create(lua_State* tolua_S) -{ - int argc = 0; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertable(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S) - 1; - - if (argc == 1) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cocos2d::FastTMXTiledMap* ret = cocos2d::FastTMXTiledMap::create(arg0); - object_to_luaval(tolua_S, "cc.FastTMXTiledMap",(cocos2d::FastTMXTiledMap*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "create",argc, 1); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_create'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_FastTMXTiledMap_createWithXML(lua_State* tolua_S) -{ - int argc = 0; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertable(tolua_S,1,"cc.FastTMXTiledMap",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S) - 1; - - if (argc == 2) - { - std::string arg0; - std::string arg1; - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - ok &= luaval_to_std_string(tolua_S, 3,&arg1); - if(!ok) - return 0; - cocos2d::FastTMXTiledMap* ret = cocos2d::FastTMXTiledMap::createWithXML(arg0, arg1); - object_to_luaval(tolua_S, "cc.FastTMXTiledMap",(cocos2d::FastTMXTiledMap*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "createWithXML",argc, 2); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXTiledMap_createWithXML'.",&tolua_err); -#endif - return 0; -} -static int lua_cocos2dx_FastTMXTiledMap_finalize(lua_State* tolua_S) -{ - printf("luabindings: finalizing LUA object (FastTMXTiledMap)"); - return 0; -} - -int lua_register_cocos2dx_FastTMXTiledMap(lua_State* tolua_S) -{ - tolua_usertype(tolua_S,"cc.FastTMXTiledMap"); - tolua_cclass(tolua_S,"FastTMXTiledMap","cc.FastTMXTiledMap","cc.Node",nullptr); - - tolua_beginmodule(tolua_S,"FastTMXTiledMap"); - tolua_function(tolua_S,"setObjectGroups",lua_cocos2dx_FastTMXTiledMap_setObjectGroups); - tolua_function(tolua_S,"getProperty",lua_cocos2dx_FastTMXTiledMap_getProperty); - tolua_function(tolua_S,"setMapSize",lua_cocos2dx_FastTMXTiledMap_setMapSize); - tolua_function(tolua_S,"getObjectGroup",lua_cocos2dx_FastTMXTiledMap_getObjectGroup); - tolua_function(tolua_S,"getObjectGroups",lua_cocos2dx_FastTMXTiledMap_getObjectGroups); - tolua_function(tolua_S,"getTileSize",lua_cocos2dx_FastTMXTiledMap_getTileSize); - tolua_function(tolua_S,"getMapSize",lua_cocos2dx_FastTMXTiledMap_getMapSize); - tolua_function(tolua_S,"getProperties",lua_cocos2dx_FastTMXTiledMap_getProperties); - tolua_function(tolua_S,"getPropertiesForGID",lua_cocos2dx_FastTMXTiledMap_getPropertiesForGID); - tolua_function(tolua_S,"setTileSize",lua_cocos2dx_FastTMXTiledMap_setTileSize); - tolua_function(tolua_S,"setProperties",lua_cocos2dx_FastTMXTiledMap_setProperties); - tolua_function(tolua_S,"getLayer",lua_cocos2dx_FastTMXTiledMap_getLayer); - tolua_function(tolua_S,"getMapOrientation",lua_cocos2dx_FastTMXTiledMap_getMapOrientation); - tolua_function(tolua_S,"setMapOrientation",lua_cocos2dx_FastTMXTiledMap_setMapOrientation); - tolua_function(tolua_S,"create", lua_cocos2dx_FastTMXTiledMap_create); - tolua_function(tolua_S,"createWithXML", lua_cocos2dx_FastTMXTiledMap_createWithXML); - tolua_endmodule(tolua_S); - std::string typeName = typeid(cocos2d::FastTMXTiledMap).name(); - g_luaType[typeName] = "cc.FastTMXTiledMap"; - g_typeCast["FastTMXTiledMap"] = "cc.FastTMXTiledMap"; - return 1; -} - -int lua_cocos2dx_FastTMXLayer_getPositionAt(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getPositionAt'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Vec2 arg0; - - ok &= luaval_to_vec2(tolua_S, 2, &arg0); - if(!ok) - return 0; - cocos2d::Vec2 ret = cobj->getPositionAt(arg0); - vec2_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getPositionAt",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getPositionAt'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setLayerOrientation(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setLayerOrientation'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - if(!ok) - return 0; - cobj->setLayerOrientation(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerOrientation",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setLayerOrientation'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getLayerSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getLayerSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const cocos2d::Size& ret = cobj->getLayerSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getLayerSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setMapTileSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setMapTileSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Size arg0; - - ok &= luaval_to_size(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setMapTileSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapTileSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setMapTileSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getLayerOrientation(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getLayerOrientation'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - int ret = cobj->getLayerOrientation(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerOrientation",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getLayerOrientation'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setProperties(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setProperties'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::ValueMap arg0; - - ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setProperties(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setProperties",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setProperties'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setLayerName(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setLayerName'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - std::string arg0; - - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cobj->setLayerName(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerName",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setLayerName'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_removeTileAt(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_removeTileAt'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Vec2 arg0; - - ok &= luaval_to_vec2(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->removeTileAt(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "removeTileAt",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_removeTileAt'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getProperties(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getProperties'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 0) { - cocos2d::ValueMap& ret = cobj->getProperties(); - ccvaluemap_to_luaval(tolua_S, ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 0) { - const cocos2d::ValueMap& ret = cobj->getProperties(); - ccvaluemap_to_luaval(tolua_S, ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperties",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getProperties'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setupTiles(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setupTiles'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj->setupTiles(); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setupTiles",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setupTiles'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setupTileSprite(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setupTileSprite'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 3) - { - cocos2d::Sprite* arg0; - cocos2d::Vec2 arg1; - int arg2; - - ok &= luaval_to_object(tolua_S, 2, "cc.Sprite",&arg0); - - ok &= luaval_to_vec2(tolua_S, 3, &arg1); - - ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2); - if(!ok) - return 0; - cobj->setupTileSprite(arg0, arg1, arg2); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setupTileSprite",argc, 3); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setupTileSprite'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setTileGID(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setTileGID'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 3) { - int arg0; - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - - if (!ok) { break; } - cocos2d::Vec2 arg1; - ok &= luaval_to_vec2(tolua_S, 3, &arg1); - - if (!ok) { break; } - cocos2d::TMXTileFlags_ arg2; - ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2); - - if (!ok) { break; } - cobj->setTileGID(arg0, arg1, arg2); - return 0; - } - }while(0); - ok = true; - do{ - if (argc == 2) { - int arg0; - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - - if (!ok) { break; } - cocos2d::Vec2 arg1; - ok &= luaval_to_vec2(tolua_S, 3, &arg1); - - if (!ok) { break; } - cobj->setTileGID(arg0, arg1); - return 0; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileGID",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setTileGID'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getMapTileSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getMapTileSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const cocos2d::Size& ret = cobj->getMapTileSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapTileSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getMapTileSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getProperty(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getProperty'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - std::string arg0; - - ok &= luaval_to_std_string(tolua_S, 2,&arg0); - if(!ok) - return 0; - cocos2d::Value ret = cobj->getProperty(arg0); - ccvalue_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperty",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getProperty'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setLayerSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setLayerSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Size arg0; - - ok &= luaval_to_size(tolua_S, 2, &arg0); - if(!ok) - return 0; - cobj->setLayerSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setLayerSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getLayerName(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getLayerName'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const std::string& ret = cobj->getLayerName(); - tolua_pushcppstring(tolua_S,ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerName",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getLayerName'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_setTileSet(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_setTileSet'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::TMXTilesetInfo* arg0; - - ok &= luaval_to_object(tolua_S, 2, "cc.TMXTilesetInfo",&arg0); - if(!ok) - return 0; - cobj->setTileSet(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileSet",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_setTileSet'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getTileSet(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getTileSet'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cocos2d::TMXTilesetInfo* ret = cobj->getTileSet(); - object_to_luaval(tolua_S, "cc.TMXTilesetInfo",(cocos2d::TMXTilesetInfo*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileSet",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getTileSet'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_getTileAt(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getTileAt'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Vec2 arg0; - - ok &= luaval_to_vec2(tolua_S, 2, &arg0); - if(!ok) - return 0; - cocos2d::Sprite* ret = cobj->getTileAt(arg0); - object_to_luaval(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileAt",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getTileAt'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_FastTMXLayer_create(lua_State* tolua_S) -{ - int argc = 0; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertable(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S) - 1; - - if (argc == 3) - { - cocos2d::TMXTilesetInfo* arg0; - cocos2d::TMXLayerInfo* arg1; - cocos2d::TMXMapInfo* arg2; - ok &= luaval_to_object(tolua_S, 2, "cc.TMXTilesetInfo",&arg0); - ok &= luaval_to_object(tolua_S, 3, "cc.TMXLayerInfo",&arg1); - ok &= luaval_to_object(tolua_S, 4, "cc.TMXMapInfo",&arg2); - if(!ok) - return 0; - cocos2d::FastTMXLayer* ret = cocos2d::FastTMXLayer::create(arg0, arg1, arg2); - object_to_luaval(tolua_S, "cc.FastTMXLayer",(cocos2d::FastTMXLayer*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "create",argc, 3); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_create'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_FastTMXLayer_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::FastTMXLayer(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.FastTMXLayer"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "FastTMXLayer",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_constructor'.",&tolua_err); -#endif - - return 0; -} - -static int lua_cocos2dx_FastTMXLayer_finalize(lua_State* tolua_S) -{ - printf("luabindings: finalizing LUA object (FastTMXLayer)"); - return 0; -} - -int lua_register_cocos2dx_FastTMXLayer(lua_State* tolua_S) -{ - tolua_usertype(tolua_S,"cc.FastTMXLayer"); - tolua_cclass(tolua_S,"FastTMXLayer","cc.FastTMXLayer","cc.Node",nullptr); - - tolua_beginmodule(tolua_S,"FastTMXLayer"); - tolua_function(tolua_S,"new",lua_cocos2dx_FastTMXLayer_constructor); - tolua_function(tolua_S,"getPositionAt",lua_cocos2dx_FastTMXLayer_getPositionAt); - tolua_function(tolua_S,"setLayerOrientation",lua_cocos2dx_FastTMXLayer_setLayerOrientation); - tolua_function(tolua_S,"getLayerSize",lua_cocos2dx_FastTMXLayer_getLayerSize); - tolua_function(tolua_S,"setMapTileSize",lua_cocos2dx_FastTMXLayer_setMapTileSize); - tolua_function(tolua_S,"getLayerOrientation",lua_cocos2dx_FastTMXLayer_getLayerOrientation); - tolua_function(tolua_S,"setProperties",lua_cocos2dx_FastTMXLayer_setProperties); - tolua_function(tolua_S,"setLayerName",lua_cocos2dx_FastTMXLayer_setLayerName); - tolua_function(tolua_S,"removeTileAt",lua_cocos2dx_FastTMXLayer_removeTileAt); - tolua_function(tolua_S,"getProperties",lua_cocos2dx_FastTMXLayer_getProperties); - tolua_function(tolua_S,"setupTiles",lua_cocos2dx_FastTMXLayer_setupTiles); - tolua_function(tolua_S,"setupTileSprite",lua_cocos2dx_FastTMXLayer_setupTileSprite); - tolua_function(tolua_S,"setTileGID",lua_cocos2dx_FastTMXLayer_setTileGID); - tolua_function(tolua_S,"getMapTileSize",lua_cocos2dx_FastTMXLayer_getMapTileSize); - tolua_function(tolua_S,"getProperty",lua_cocos2dx_FastTMXLayer_getProperty); - tolua_function(tolua_S,"setLayerSize",lua_cocos2dx_FastTMXLayer_setLayerSize); - tolua_function(tolua_S,"getLayerName",lua_cocos2dx_FastTMXLayer_getLayerName); - tolua_function(tolua_S,"setTileSet",lua_cocos2dx_FastTMXLayer_setTileSet); - tolua_function(tolua_S,"getTileSet",lua_cocos2dx_FastTMXLayer_getTileSet); - tolua_function(tolua_S,"getTileAt",lua_cocos2dx_FastTMXLayer_getTileAt); - tolua_function(tolua_S,"create", lua_cocos2dx_FastTMXLayer_create); - tolua_endmodule(tolua_S); - std::string typeName = typeid(cocos2d::FastTMXLayer).name(); - g_luaType[typeName] = "cc.FastTMXLayer"; - g_typeCast["FastTMXLayer"] = "cc.FastTMXLayer"; - return 1; -} - int lua_cocos2dx_Component_setEnabled(lua_State* tolua_S) { int argc = 0; @@ -67047,7 +65078,6 @@ TOLUA_API int register_all_cocos2dx(lua_State* tolua_S) lua_register_cocos2dx_Sprite3D(tolua_S); lua_register_cocos2dx_EventListenerMouse(tolua_S); lua_register_cocos2dx_TiledGrid3D(tolua_S); - lua_register_cocos2dx_FastTMXTiledMap(tolua_S); lua_register_cocos2dx_ParticleGalaxy(tolua_S); lua_register_cocos2dx_Twirl(tolua_S); lua_register_cocos2dx_MenuItemLabel(tolua_S); @@ -67080,7 +65110,6 @@ TOLUA_API int register_all_cocos2dx(lua_State* tolua_S) lua_register_cocos2dx_SpriteFrame(tolua_S); lua_register_cocos2dx_ActionManager(tolua_S); lua_register_cocos2dx_UserDefault(tolua_S); - lua_register_cocos2dx_FastTMXLayer(tolua_S); lua_register_cocos2dx_TransitionZoomFlipX(tolua_S); lua_register_cocos2dx_EventFocus(tolua_S); lua_register_cocos2dx_EaseQuinticActionInOut(tolua_S); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp index a14e56b1b4..082c44f7d7 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp @@ -1550,51 +1550,6 @@ int register_all_cocos2dx(lua_State* tolua_S); - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.cpp new file mode 100644 index 0000000000..4e7ff2d009 --- /dev/null +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.cpp @@ -0,0 +1,1766 @@ +#include "lua_cocos2dx_experimental_auto.hpp" +#include "CCFastTMXLayer.h" +#include "CCFastTMXTiledMap.h" +#include "tolua_fix.h" +#include "LuaBasicConversions.h" + + + +int lua_cocos2dx_experimental_TMXLayer_getPositionAt(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getPositionAt'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Vec2 arg0; + + ok &= luaval_to_vec2(tolua_S, 2, &arg0); + if(!ok) + return 0; + cocos2d::Vec2 ret = cobj->getPositionAt(arg0); + vec2_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getPositionAt",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getPositionAt'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setLayerOrientation(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setLayerOrientation'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + int arg0; + + ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); + if(!ok) + return 0; + cobj->setLayerOrientation(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerOrientation",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setLayerOrientation'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getLayerSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getLayerSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const cocos2d::Size& ret = cobj->getLayerSize(); + size_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerSize",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getLayerSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setMapTileSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setMapTileSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Size arg0; + + ok &= luaval_to_size(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setMapTileSize(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapTileSize",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setMapTileSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getLayerOrientation(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getLayerOrientation'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + int ret = cobj->getLayerOrientation(); + tolua_pushnumber(tolua_S,(lua_Number)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerOrientation",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getLayerOrientation'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setProperties(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setProperties'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::ValueMap arg0; + + ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setProperties(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setProperties",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setProperties'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setLayerName(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setLayerName'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + std::string arg0; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cobj->setLayerName(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerName",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setLayerName'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_removeTileAt(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_removeTileAt'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Vec2 arg0; + + ok &= luaval_to_vec2(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->removeTileAt(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "removeTileAt",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_removeTileAt'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getProperties(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getProperties'", nullptr); + return 0; + } +#endif + argc = lua_gettop(tolua_S)-1; + do{ + if (argc == 0) { + cocos2d::ValueMap& ret = cobj->getProperties(); + ccvaluemap_to_luaval(tolua_S, ret); + return 1; + } + }while(0); + ok = true; + do{ + if (argc == 0) { + const cocos2d::ValueMap& ret = cobj->getProperties(); + ccvaluemap_to_luaval(tolua_S, ret); + return 1; + } + }while(0); + ok = true; + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperties",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getProperties'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setupTiles(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setupTiles'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + cobj->setupTiles(); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setupTiles",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setupTiles'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setupTileSprite(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setupTileSprite'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 3) + { + cocos2d::Sprite* arg0; + cocos2d::Vec2 arg1; + int arg2; + + ok &= luaval_to_object(tolua_S, 2, "cc.Sprite",&arg0); + + ok &= luaval_to_vec2(tolua_S, 3, &arg1); + + ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2); + if(!ok) + return 0; + cobj->setupTileSprite(arg0, arg1, arg2); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setupTileSprite",argc, 3); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setupTileSprite'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setTileGID(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setTileGID'", nullptr); + return 0; + } +#endif + argc = lua_gettop(tolua_S)-1; + do{ + if (argc == 3) { + int arg0; + ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); + + if (!ok) { break; } + cocos2d::Vec2 arg1; + ok &= luaval_to_vec2(tolua_S, 3, &arg1); + + if (!ok) { break; } + cocos2d::TMXTileFlags_ arg2; + ok &= luaval_to_int32(tolua_S, 4,(int *)&arg2); + + if (!ok) { break; } + cobj->setTileGID(arg0, arg1, arg2); + return 0; + } + }while(0); + ok = true; + do{ + if (argc == 2) { + int arg0; + ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); + + if (!ok) { break; } + cocos2d::Vec2 arg1; + ok &= luaval_to_vec2(tolua_S, 3, &arg1); + + if (!ok) { break; } + cobj->setTileGID(arg0, arg1); + return 0; + } + }while(0); + ok = true; + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileGID",argc, 2); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setTileGID'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getMapTileSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getMapTileSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const cocos2d::Size& ret = cobj->getMapTileSize(); + size_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapTileSize",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getMapTileSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getProperty(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getProperty'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + std::string arg0; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cocos2d::Value ret = cobj->getProperty(arg0); + ccvalue_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperty",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getProperty'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setLayerSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setLayerSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Size arg0; + + ok &= luaval_to_size(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setLayerSize(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setLayerSize",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setLayerSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getLayerName(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getLayerName'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const std::string& ret = cobj->getLayerName(); + tolua_pushcppstring(tolua_S,ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayerName",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getLayerName'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_setTileSet(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_setTileSet'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::TMXTilesetInfo* arg0; + + ok &= luaval_to_object(tolua_S, 2, "cc.TMXTilesetInfo",&arg0); + if(!ok) + return 0; + cobj->setTileSet(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileSet",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_setTileSet'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getTileSet(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getTileSet'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + cocos2d::TMXTilesetInfo* ret = cobj->getTileSet(); + object_to_luaval(tolua_S, "cc.TMXTilesetInfo",(cocos2d::TMXTilesetInfo*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileSet",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getTileSet'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_getTileAt(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getTileAt'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Vec2 arg0; + + ok &= luaval_to_vec2(tolua_S, 2, &arg0); + if(!ok) + return 0; + cocos2d::Sprite* ret = cobj->getTileAt(arg0); + object_to_luaval(tolua_S, "cc.Sprite",(cocos2d::Sprite*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileAt",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getTileAt'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_create(lua_State* tolua_S) +{ + int argc = 0; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertable(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + argc = lua_gettop(tolua_S) - 1; + + if (argc == 3) + { + cocos2d::TMXTilesetInfo* arg0; + cocos2d::TMXLayerInfo* arg1; + cocos2d::TMXMapInfo* arg2; + ok &= luaval_to_object(tolua_S, 2, "cc.TMXTilesetInfo",&arg0); + ok &= luaval_to_object(tolua_S, 3, "cc.TMXLayerInfo",&arg1); + ok &= luaval_to_object(tolua_S, 4, "cc.TMXMapInfo",&arg2); + if(!ok) + return 0; + cocos2d::experimental::TMXLayer* ret = cocos2d::experimental::TMXLayer::create(arg0, arg1, arg2); + object_to_luaval(tolua_S, "ccexp.TMXLayer",(cocos2d::experimental::TMXLayer*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "create",argc, 3); + return 0; +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_create'.",&tolua_err); +#endif + return 0; +} +int lua_cocos2dx_experimental_TMXLayer_constructor(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + cobj = new cocos2d::experimental::TMXLayer(); + cobj->autorelease(); + int ID = (int)cobj->_ID ; + int* luaID = &cobj->_luaID ; + toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"ccexp.TMXLayer"); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "TMXLayer",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_constructor'.",&tolua_err); +#endif + + return 0; +} + +static int lua_cocos2dx_experimental_TMXLayer_finalize(lua_State* tolua_S) +{ + printf("luabindings: finalizing LUA object (TMXLayer)"); + return 0; +} + +int lua_register_cocos2dx_experimental_TMXLayer(lua_State* tolua_S) +{ + tolua_usertype(tolua_S,"ccexp.TMXLayer"); + tolua_cclass(tolua_S,"TMXLayer","ccexp.TMXLayer","cc.Node",nullptr); + + tolua_beginmodule(tolua_S,"TMXLayer"); + tolua_function(tolua_S,"new",lua_cocos2dx_experimental_TMXLayer_constructor); + tolua_function(tolua_S,"getPositionAt",lua_cocos2dx_experimental_TMXLayer_getPositionAt); + tolua_function(tolua_S,"setLayerOrientation",lua_cocos2dx_experimental_TMXLayer_setLayerOrientation); + tolua_function(tolua_S,"getLayerSize",lua_cocos2dx_experimental_TMXLayer_getLayerSize); + tolua_function(tolua_S,"setMapTileSize",lua_cocos2dx_experimental_TMXLayer_setMapTileSize); + tolua_function(tolua_S,"getLayerOrientation",lua_cocos2dx_experimental_TMXLayer_getLayerOrientation); + tolua_function(tolua_S,"setProperties",lua_cocos2dx_experimental_TMXLayer_setProperties); + tolua_function(tolua_S,"setLayerName",lua_cocos2dx_experimental_TMXLayer_setLayerName); + tolua_function(tolua_S,"removeTileAt",lua_cocos2dx_experimental_TMXLayer_removeTileAt); + tolua_function(tolua_S,"getProperties",lua_cocos2dx_experimental_TMXLayer_getProperties); + tolua_function(tolua_S,"setupTiles",lua_cocos2dx_experimental_TMXLayer_setupTiles); + tolua_function(tolua_S,"setupTileSprite",lua_cocos2dx_experimental_TMXLayer_setupTileSprite); + tolua_function(tolua_S,"setTileGID",lua_cocos2dx_experimental_TMXLayer_setTileGID); + tolua_function(tolua_S,"getMapTileSize",lua_cocos2dx_experimental_TMXLayer_getMapTileSize); + tolua_function(tolua_S,"getProperty",lua_cocos2dx_experimental_TMXLayer_getProperty); + tolua_function(tolua_S,"setLayerSize",lua_cocos2dx_experimental_TMXLayer_setLayerSize); + tolua_function(tolua_S,"getLayerName",lua_cocos2dx_experimental_TMXLayer_getLayerName); + tolua_function(tolua_S,"setTileSet",lua_cocos2dx_experimental_TMXLayer_setTileSet); + tolua_function(tolua_S,"getTileSet",lua_cocos2dx_experimental_TMXLayer_getTileSet); + tolua_function(tolua_S,"getTileAt",lua_cocos2dx_experimental_TMXLayer_getTileAt); + tolua_function(tolua_S,"create", lua_cocos2dx_experimental_TMXLayer_create); + tolua_endmodule(tolua_S); + std::string typeName = typeid(cocos2d::experimental::TMXLayer).name(); + g_luaType[typeName] = "ccexp.TMXLayer"; + g_typeCast["TMXLayer"] = "ccexp.TMXLayer"; + return 1; +} + +int lua_cocos2dx_experimental_TMXTiledMap_setObjectGroups(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_setObjectGroups'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Vector arg0; + + ok &= luaval_to_ccvector(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setObjectGroups(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setObjectGroups",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_setObjectGroups'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getProperty(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getProperty'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + std::string arg0; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cocos2d::Value ret = cobj->getProperty(arg0); + ccvalue_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperty",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getProperty'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_setMapSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_setMapSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Size arg0; + + ok &= luaval_to_size(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setMapSize(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapSize",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_setMapSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getObjectGroup(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getObjectGroup'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + std::string arg0; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cocos2d::TMXObjectGroup* ret = cobj->getObjectGroup(arg0); + object_to_luaval(tolua_S, "cc.TMXObjectGroup",(cocos2d::TMXObjectGroup*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getObjectGroup",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getObjectGroup'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getObjectGroups(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getObjectGroups'", nullptr); + return 0; + } +#endif + argc = lua_gettop(tolua_S)-1; + do{ + if (argc == 0) { + cocos2d::Vector& ret = cobj->getObjectGroups(); + ccvector_to_luaval(tolua_S, ret); + return 1; + } + }while(0); + ok = true; + do{ + if (argc == 0) { + const cocos2d::Vector& ret = cobj->getObjectGroups(); + ccvector_to_luaval(tolua_S, ret); + return 1; + } + }while(0); + ok = true; + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getObjectGroups",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getObjectGroups'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getTileSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getTileSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const cocos2d::Size& ret = cobj->getTileSize(); + size_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileSize",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getTileSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getMapSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getMapSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const cocos2d::Size& ret = cobj->getMapSize(); + size_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapSize",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getMapSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getProperties(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getProperties'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + const cocos2d::ValueMap& ret = cobj->getProperties(); + ccvaluemap_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getProperties",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getProperties'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getPropertiesForGID(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getPropertiesForGID'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + int arg0; + + ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); + if(!ok) + return 0; + cocos2d::Value ret = cobj->getPropertiesForGID(arg0); + ccvalue_to_luaval(tolua_S, ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getPropertiesForGID",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getPropertiesForGID'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_setTileSize(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_setTileSize'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Size arg0; + + ok &= luaval_to_size(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setTileSize(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setTileSize",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_setTileSize'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_setProperties(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_setProperties'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::ValueMap arg0; + + ok &= luaval_to_ccvaluemap(tolua_S, 2, &arg0); + if(!ok) + return 0; + cobj->setProperties(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setProperties",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_setProperties'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getLayer(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getLayer'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + std::string arg0; + + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cocos2d::experimental::TMXLayer* ret = cobj->getLayer(arg0); + object_to_luaval(tolua_S, "ccexp.TMXLayer",(cocos2d::experimental::TMXLayer*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getLayer",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getLayer'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_getMapOrientation(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_getMapOrientation'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 0) + { + if(!ok) + return 0; + int ret = cobj->getMapOrientation(); + tolua_pushnumber(tolua_S,(lua_Number)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getMapOrientation",argc, 0); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_getMapOrientation'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_setMapOrientation(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXTiledMap* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXTiledMap*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXTiledMap_setMapOrientation'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + int arg0; + + ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); + if(!ok) + return 0; + cobj->setMapOrientation(arg0); + return 0; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "setMapOrientation",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_setMapOrientation'.",&tolua_err); +#endif + + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_create(lua_State* tolua_S) +{ + int argc = 0; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertable(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + argc = lua_gettop(tolua_S) - 1; + + if (argc == 1) + { + std::string arg0; + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + if(!ok) + return 0; + cocos2d::experimental::TMXTiledMap* ret = cocos2d::experimental::TMXTiledMap::create(arg0); + object_to_luaval(tolua_S, "ccexp.TMXTiledMap",(cocos2d::experimental::TMXTiledMap*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "create",argc, 1); + return 0; +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_create'.",&tolua_err); +#endif + return 0; +} +int lua_cocos2dx_experimental_TMXTiledMap_createWithXML(lua_State* tolua_S) +{ + int argc = 0; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertable(tolua_S,1,"ccexp.TMXTiledMap",0,&tolua_err)) goto tolua_lerror; +#endif + + argc = lua_gettop(tolua_S) - 1; + + if (argc == 2) + { + std::string arg0; + std::string arg1; + ok &= luaval_to_std_string(tolua_S, 2,&arg0); + ok &= luaval_to_std_string(tolua_S, 3,&arg1); + if(!ok) + return 0; + cocos2d::experimental::TMXTiledMap* ret = cocos2d::experimental::TMXTiledMap::createWithXML(arg0, arg1); + object_to_luaval(tolua_S, "ccexp.TMXTiledMap",(cocos2d::experimental::TMXTiledMap*)ret); + return 1; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "createWithXML",argc, 2); + return 0; +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXTiledMap_createWithXML'.",&tolua_err); +#endif + return 0; +} +static int lua_cocos2dx_experimental_TMXTiledMap_finalize(lua_State* tolua_S) +{ + printf("luabindings: finalizing LUA object (TMXTiledMap)"); + return 0; +} + +int lua_register_cocos2dx_experimental_TMXTiledMap(lua_State* tolua_S) +{ + tolua_usertype(tolua_S,"ccexp.TMXTiledMap"); + tolua_cclass(tolua_S,"TMXTiledMap","ccexp.TMXTiledMap","cc.Node",nullptr); + + tolua_beginmodule(tolua_S,"TMXTiledMap"); + tolua_function(tolua_S,"setObjectGroups",lua_cocos2dx_experimental_TMXTiledMap_setObjectGroups); + tolua_function(tolua_S,"getProperty",lua_cocos2dx_experimental_TMXTiledMap_getProperty); + tolua_function(tolua_S,"setMapSize",lua_cocos2dx_experimental_TMXTiledMap_setMapSize); + tolua_function(tolua_S,"getObjectGroup",lua_cocos2dx_experimental_TMXTiledMap_getObjectGroup); + tolua_function(tolua_S,"getObjectGroups",lua_cocos2dx_experimental_TMXTiledMap_getObjectGroups); + tolua_function(tolua_S,"getTileSize",lua_cocos2dx_experimental_TMXTiledMap_getTileSize); + tolua_function(tolua_S,"getMapSize",lua_cocos2dx_experimental_TMXTiledMap_getMapSize); + tolua_function(tolua_S,"getProperties",lua_cocos2dx_experimental_TMXTiledMap_getProperties); + tolua_function(tolua_S,"getPropertiesForGID",lua_cocos2dx_experimental_TMXTiledMap_getPropertiesForGID); + tolua_function(tolua_S,"setTileSize",lua_cocos2dx_experimental_TMXTiledMap_setTileSize); + tolua_function(tolua_S,"setProperties",lua_cocos2dx_experimental_TMXTiledMap_setProperties); + tolua_function(tolua_S,"getLayer",lua_cocos2dx_experimental_TMXTiledMap_getLayer); + tolua_function(tolua_S,"getMapOrientation",lua_cocos2dx_experimental_TMXTiledMap_getMapOrientation); + tolua_function(tolua_S,"setMapOrientation",lua_cocos2dx_experimental_TMXTiledMap_setMapOrientation); + tolua_function(tolua_S,"create", lua_cocos2dx_experimental_TMXTiledMap_create); + tolua_function(tolua_S,"createWithXML", lua_cocos2dx_experimental_TMXTiledMap_createWithXML); + tolua_endmodule(tolua_S); + std::string typeName = typeid(cocos2d::experimental::TMXTiledMap).name(); + g_luaType[typeName] = "ccexp.TMXTiledMap"; + g_typeCast["TMXTiledMap"] = "ccexp.TMXTiledMap"; + return 1; +} +TOLUA_API int register_all_cocos2dx_experimental(lua_State* tolua_S) +{ + tolua_open(tolua_S); + + tolua_module(tolua_S,"ccexp",0); + tolua_beginmodule(tolua_S,"ccexp"); + + lua_register_cocos2dx_experimental_TMXTiledMap(tolua_S); + lua_register_cocos2dx_experimental_TMXLayer(tolua_S); + + tolua_endmodule(tolua_S); + return 1; +} + diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.hpp new file mode 100644 index 0000000000..1510f395f7 --- /dev/null +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.hpp @@ -0,0 +1,54 @@ +#include "base/ccConfig.h" +#ifndef __cocos2dx_experimental_h__ +#define __cocos2dx_experimental_h__ + +#ifdef __cplusplus +extern "C" { +#endif +#include "tolua++.h" +#ifdef __cplusplus +} +#endif + +int register_all_cocos2dx_experimental(lua_State* tolua_S); + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +#endif // __cocos2dx_experimental_h__ diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.cpp index 408da55ffc..e62111ffaf 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.cpp @@ -522,7 +522,7 @@ int lua_cocos2dx_experimental_video_VideoPlayer_onPlayEvent(lua_State* tolua_S) argc = lua_gettop(tolua_S)-1; if (argc == 1) { - cocos2d::experimental::ui::VideoPlayer::EventType arg0; + int arg0; ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); if(!ok) @@ -743,8 +743,8 @@ TOLUA_API int register_all_cocos2dx_experimental_video(lua_State* tolua_S) { tolua_open(tolua_S); - tolua_module(tolua_S,"ccexprimental",0); - tolua_beginmodule(tolua_S,"ccexprimental"); + tolua_module(tolua_S,"ccexp",0); + tolua_beginmodule(tolua_S,"ccexp"); lua_register_cocos2dx_experimental_video_VideoPlayer(tolua_S); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp index 55c306c217..fb68e466e2 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp @@ -494,61 +494,6 @@ int lua_cocos2dx_spine_SkeletonAnimation_clearTrack(lua_State* tolua_S) return 0; } -int lua_cocos2dx_spine_SkeletonAnimation_onAnimationStateEvent(lua_State* tolua_S) -{ - int argc = 0; - spine::SkeletonAnimation* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"sp.SkeletonAnimation",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (spine::SkeletonAnimation*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_spine_SkeletonAnimation_onAnimationStateEvent'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 4) - { - int arg0; - spEventType arg1; - spEvent* arg2; - int arg3; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0); - - ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1); - - #pragma warning NO CONVERSION TO NATIVE FOR spEvent*; - - ok &= luaval_to_int32(tolua_S, 5,(int *)&arg3); - if(!ok) - return 0; - cobj->onAnimationStateEvent(arg0, arg1, arg2, arg3); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "onAnimationStateEvent",argc, 4); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_spine_SkeletonAnimation_onAnimationStateEvent'.",&tolua_err); -#endif - - return 0; -} static int lua_cocos2dx_spine_SkeletonAnimation_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (SkeletonAnimation)"); @@ -564,7 +509,6 @@ int lua_register_cocos2dx_spine_SkeletonAnimation(lua_State* tolua_S) tolua_function(tolua_S,"setMix",lua_cocos2dx_spine_SkeletonAnimation_setMix); tolua_function(tolua_S,"clearTracks",lua_cocos2dx_spine_SkeletonAnimation_clearTracks); tolua_function(tolua_S,"clearTrack",lua_cocos2dx_spine_SkeletonAnimation_clearTrack); - tolua_function(tolua_S,"onAnimationStateEvent",lua_cocos2dx_spine_SkeletonAnimation_onAnimationStateEvent); tolua_endmodule(tolua_S); std::string typeName = typeid(spine::SkeletonAnimation).name(); g_luaType[typeName] = "sp.SkeletonAnimation"; diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.hpp index 82266a8afb..aedd24b3f5 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.hpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.hpp @@ -24,5 +24,4 @@ int register_all_cocos2dx_spine(lua_State* tolua_S); - #endif // __cocos2dx_spine_h__ diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.cpp index ead974be37..b4352556a9 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.cpp @@ -2103,58 +2103,6 @@ int lua_cocos2dx_studio_ActionObject_getLoop(lua_State* tolua_S) return 0; } -int lua_cocos2dx_studio_ActionObject_initWithBinary(lua_State* tolua_S) -{ - int argc = 0; - cocostudio::ActionObject* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"ccs.ActionObject",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocostudio::ActionObject*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_studio_ActionObject_initWithBinary'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 3) - { - cocostudio::CocoLoader* arg0; - cocostudio::stExpCocoNode* arg1; - cocos2d::Ref* arg2; - - ok &= luaval_to_object(tolua_S, 2, "ccs.CocoLoader",&arg0); - - #pragma warning NO CONVERSION TO NATIVE FOR stExpCocoNode*; - - ok &= luaval_to_object(tolua_S, 4, "cc.Ref",&arg2); - if(!ok) - return 0; - cobj->initWithBinary(arg0, arg1, arg2); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "initWithBinary",argc, 3); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_studio_ActionObject_initWithBinary'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_studio_ActionObject_addActionNode(lua_State* tolua_S) { int argc = 0; @@ -2485,7 +2433,6 @@ int lua_register_cocos2dx_studio_ActionObject(lua_State* tolua_S) tolua_function(tolua_S,"getCurrentTime",lua_cocos2dx_studio_ActionObject_getCurrentTime); tolua_function(tolua_S,"removeActionNode",lua_cocos2dx_studio_ActionObject_removeActionNode); tolua_function(tolua_S,"getLoop",lua_cocos2dx_studio_ActionObject_getLoop); - tolua_function(tolua_S,"initWithBinary",lua_cocos2dx_studio_ActionObject_initWithBinary); tolua_function(tolua_S,"addActionNode",lua_cocos2dx_studio_ActionObject_addActionNode); tolua_function(tolua_S,"getUnitTime",lua_cocos2dx_studio_ActionObject_getUnitTime); tolua_function(tolua_S,"isPlaying",lua_cocos2dx_studio_ActionObject_isPlaying); @@ -2616,61 +2563,6 @@ int lua_cocos2dx_studio_ActionManagerEx_getActionByName(lua_State* tolua_S) return 0; } -int lua_cocos2dx_studio_ActionManagerEx_initWithBinary(lua_State* tolua_S) -{ - int argc = 0; - cocostudio::ActionManagerEx* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"ccs.ActionManagerEx",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocostudio::ActionManagerEx*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_studio_ActionManagerEx_initWithBinary'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 4) - { - const char* arg0; - cocos2d::Ref* arg1; - cocostudio::CocoLoader* arg2; - cocostudio::stExpCocoNode* arg3; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp); arg0 = arg0_tmp.c_str(); - - ok &= luaval_to_object(tolua_S, 3, "cc.Ref",&arg1); - - ok &= luaval_to_object(tolua_S, 4, "ccs.CocoLoader",&arg2); - - #pragma warning NO CONVERSION TO NATIVE FOR stExpCocoNode*; - if(!ok) - return 0; - cobj->initWithBinary(arg0, arg1, arg2, arg3); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "initWithBinary",argc, 4); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_studio_ActionManagerEx_initWithBinary'.",&tolua_err); -#endif - - return 0; -} int lua_cocos2dx_studio_ActionManagerEx_releaseActions(lua_State* tolua_S) { int argc = 0; @@ -2789,7 +2681,6 @@ int lua_register_cocos2dx_studio_ActionManagerEx(lua_State* tolua_S) tolua_beginmodule(tolua_S,"ActionManagerEx"); tolua_function(tolua_S,"playActionByName",lua_cocos2dx_studio_ActionManagerEx_playActionByName); tolua_function(tolua_S,"getActionByName",lua_cocos2dx_studio_ActionManagerEx_getActionByName); - tolua_function(tolua_S,"initWithBinary",lua_cocos2dx_studio_ActionManagerEx_initWithBinary); tolua_function(tolua_S,"releaseActions",lua_cocos2dx_studio_ActionManagerEx_releaseActions); tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_studio_ActionManagerEx_destroyInstance); tolua_function(tolua_S,"getInstance", lua_cocos2dx_studio_ActionManagerEx_getInstance); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.hpp index a97498c0c3..db4b08da77 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.hpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_studio_auto.hpp @@ -489,8 +489,6 @@ int register_all_cocos2dx_studio(lua_State* tolua_S); - - diff --git a/cocos/scripting/lua-bindings/manual/CCLuaStack.cpp b/cocos/scripting/lua-bindings/manual/CCLuaStack.cpp index d8fc0cf0d6..144850b298 100644 --- a/cocos/scripting/lua-bindings/manual/CCLuaStack.cpp +++ b/cocos/scripting/lua-bindings/manual/CCLuaStack.cpp @@ -71,8 +71,12 @@ extern "C" { #include "lua_cocos2dx_physics_manual.hpp" #include "lua_cocos2dx_ui_auto.hpp" #include "lua_cocos2dx_ui_manual.hpp" +#include "lua_cocos2dx_experimental_auto.hpp" +#include "lua_cocos2dx_experimental_manual.hpp" +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS || CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) #include "lua_cocos2dx_experimental_video_auto.hpp" #include "lua_cocos2dx_experimental_video_manual.hpp" +#endif namespace { int lua_print(lua_State * luastate) @@ -182,6 +186,8 @@ bool LuaStack::init(void) #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS || CC_TARGET_PLATFORM == CC_PLATFORM_MAC) LuaObjcBridge::luaopen_luaoc(_state); #endif + register_all_cocos2dx_experimental(_state); + register_all_cocos2dx_experimental_manual(_state); #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS || CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) register_all_cocos2dx_experimental_video(_state); diff --git a/cocos/scripting/lua-bindings/manual/Cocos2dxLuaLoader.cpp b/cocos/scripting/lua-bindings/manual/Cocos2dxLuaLoader.cpp index e11d541626..e9d8d8a9fc 100644 --- a/cocos/scripting/lua-bindings/manual/Cocos2dxLuaLoader.cpp +++ b/cocos/scripting/lua-bindings/manual/Cocos2dxLuaLoader.cpp @@ -77,7 +77,6 @@ extern "C" pos = prefix.find("?.lua"); chunkName = prefix.substr(0, pos) + filename + BYTECODE_FILE_EXT; - chunkName = utils->fullPathForFilename(chunkName.c_str()); if (utils->isFileExist(chunkName)) { chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize); @@ -86,7 +85,6 @@ extern "C" else { chunkName = prefix.substr(0, pos) + filename + NOT_BYTECODE_FILE_EXT; - chunkName = utils->fullPathForFilename(chunkName.c_str()); if (utils->isFileExist(chunkName)) { chunk = utils->getFileData(chunkName.c_str(), "rb", &chunkSize); diff --git a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h index 7adce3e77e..f332afb076 100644 --- a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h +++ b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h @@ -79,7 +79,7 @@ extern bool luaval_to_ttfconfig(lua_State* L, int lo, cocos2d::TTFConfig* outVal extern bool luaval_to_uniform(lua_State* L, int lo, cocos2d::Uniform* outValue); extern bool luaval_to_vertexattrib(lua_State* L, int lo, cocos2d::VertexAttrib* outValue); -CC_DEPRECATED_ATTRIBUTE static inline bool luaval_to_point(lua_State* L,int lo,cocos2d::Vec2* outValue) +static inline bool luaval_to_point(lua_State* L,int lo,cocos2d::Vec2* outValue) { return luaval_to_vec2(L, lo, outValue); } @@ -258,7 +258,7 @@ extern void ttfconfig_to_luaval(lua_State* L, const cocos2d::TTFConfig& config); extern void uniform_to_luaval(lua_State* L, const cocos2d::Uniform& uniform); extern void vertexattrib_to_luaval(lua_State* L, const cocos2d::VertexAttrib& verAttrib); -CC_DEPRECATED_ATTRIBUTE static inline void point_to_luaval(lua_State* L,const cocos2d::Vec2& pt) +static inline void point_to_luaval(lua_State* L,const cocos2d::Vec2& pt) { vec2_to_luaval(L, pt); } diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_coco_studio_manual.cpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_coco_studio_manual.cpp index 5291ac5a92..a33e1adb2f 100644 --- a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_coco_studio_manual.cpp +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_coco_studio_manual.cpp @@ -201,8 +201,8 @@ static int lua_cocos2dx_ArmatureAnimation_setFrameEventCallFunc(lua_State* L) #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(L,"#ferror in function 'setFrameEventCallFunc'.",&tolua_err); - return 0; #endif + return 0; } static void extendArmatureAnimation(lua_State* L) @@ -293,8 +293,8 @@ static int lua_cocos2dx_ArmatureDataManager_addArmatureFileInfoAsyncCallFunc(lua #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(L,"#ferror in function 'addArmatureFileInfoAsync'.",&tolua_err); - return 0; #endif + return 0; } static void extendArmatureDataManager(lua_State* L) @@ -538,8 +538,8 @@ static int lua_cocos2dx_ActionTimeline_setFrameEventCallFunc(lua_State* L) #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(L,"#ferror in function 'setFrameEventCallFunc'.",&tolua_err); - return 0; #endif + return 0; } static void extendActionTimeline(lua_State* L) diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.cpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.cpp new file mode 100644 index 0000000000..33cc751dd1 --- /dev/null +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.cpp @@ -0,0 +1,93 @@ +#include "lua_cocos2dx_experimental_manual.hpp" +#include "UIVideoPlayer.h" +#include "tolua_fix.h" +#include "LuaBasicConversions.h" +#include "CCLuaValue.h" +#include "CCLuaEngine.h" + +static int lua_cocos2dx_experimental_TMXLayer_getTileGIDAt(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::experimental::TMXLayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccexp.TMXLayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::experimental::TMXLayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_experimental_TMXLayer_getTileGIDAt'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + cocos2d::Vec2 arg0; + + ok &= luaval_to_vec2(tolua_S, 2, &arg0); + if(!ok) + return 0; + int ret = cobj->getTileGIDAt(arg0); + tolua_pushnumber(tolua_S,(lua_Number)ret); + tolua_pushnumber(tolua_S,(lua_Number)0); + return 2; + } + if (argc == 2) + { + cocos2d::Vec2 arg0; + int arg1 = 0; + + ok &= luaval_to_vec2(tolua_S, 2, &arg0); + ok &= luaval_to_int32(tolua_S, 3, &arg1); + + if(!ok) + return 0; + + unsigned int ret = cobj->getTileGIDAt(arg0, (cocos2d::TMXTileFlags*)&arg1); + tolua_pushnumber(tolua_S,(lua_Number)ret); + tolua_pushnumber(tolua_S,(lua_Number)arg1); + return 2; + } + CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileGIDAt",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 +tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_experimental_TMXLayer_getTileGIDAt'.",&tolua_err); +#endif + + return 0; +} + +static void extendExperimentalTMXLayer(lua_State* tolua_S) +{ + lua_pushstring(tolua_S, "ccexp.TMXLayer"); + lua_rawget(tolua_S, LUA_REGISTRYINDEX); + if (lua_istable(tolua_S,-1)) + { + tolua_function(tolua_S, "getTileGIDAt", lua_cocos2dx_experimental_TMXLayer_getTileGIDAt); + } + lua_pop(tolua_S, 1); +} + +int register_all_cocos2dx_experimental_manual(lua_State* L) +{ + if (nullptr == L) + return 0; + + extendExperimentalTMXLayer(L); + + return 0; +} + diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.hpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.hpp new file mode 100644 index 0000000000..a80dddc6e3 --- /dev/null +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.hpp @@ -0,0 +1,39 @@ +/**************************************************************************** + Copyright (c) 2013-2014 Chukong Technologies Inc. + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ +#include "base/ccConfig.h" + +#ifndef COCOS_SCRIPTING_LUA_BINDINGS_LUA_COCOS2DX_EXPERIMENTAL_MANUAL_H +#define COCOS_SCRIPTING_LUA_BINDINGS_LUA_COCOS2DX_EXPERIMENTAL_MANUAL_H + +#ifdef __cplusplus +extern "C" { +#endif +#include "tolua++.h" +#ifdef __cplusplus +} +#endif + +TOLUA_API int register_all_cocos2dx_experimental_manual(lua_State* L); + +#endif //#ifndef COCOS_SCRIPTING_LUA_BINDINGS_LUA_COCOS2DX_EXPERIMENTAL_MANUAL_H diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.hpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.hpp index fa4072a24e..6201540e59 100644 --- a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.hpp +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.hpp @@ -37,5 +37,5 @@ extern "C" { TOLUA_API int register_all_cocos2dx_experimental_video_manual(lua_State* L); -#endif // COCOS_SCRIPTING_LUA_BINDINGS_LUA_COCOS2DX_EXPERIMENTAL_VIDEO_MANUAL_H +#endif //#ifndef COCOS_SCRIPTING_LUA_BINDINGS_LUA_COCOS2DX_EXPERIMENTAL_VIDEO_MANUAL_H #endif //#if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID || CC_TARGET_PLATFORM == CC_PLATFORM_IOS) diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_manual.cpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_manual.cpp index c19e2b77c3..d8daf44b63 100644 --- a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_manual.cpp +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_manual.cpp @@ -1234,7 +1234,7 @@ static int lua_cocos2dx_Layer_setAccelerometerInterval(lua_State* L) goto tolua_lerror; #endif double interval = tolua_tonumber(L, 2, 0); - Device::setAccelerometerEnabled(interval); + Device::setAccelerometerInterval(interval); return 0; } @@ -5900,7 +5900,7 @@ static int lua_cocos2dx_GLProgramState_setVertexAttribPointer(lua_State* tolua_S if(!ok) return 0; - cobj->setVertexAttribPointer(arg0, arg1, arg2, arg3, arg4, (void*)arg5); + cobj->setVertexAttribPointer(arg0, arg1, arg2, arg3, arg4, (void*)&arg5); return 0; } else if (argc == 7) @@ -6090,7 +6090,8 @@ int lua_cocos2dx_TMXLayer_getTileGIDAt(lua_State* tolua_S) return 0; unsigned int ret = cobj->getTileGIDAt(arg0); tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; + tolua_pushnumber(tolua_S,(lua_Number)0); + return 2; } if (argc == 2) { @@ -6105,7 +6106,8 @@ int lua_cocos2dx_TMXLayer_getTileGIDAt(lua_State* tolua_S) unsigned int ret = cobj->getTileGIDAt(arg0, (cocos2d::TMXTileFlags*)&arg1); tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; + tolua_pushnumber(tolua_S,(lua_Number)arg1); + return 2; } CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileGIDAt",argc, 1); return 0; @@ -6436,76 +6438,69 @@ static void extendApplication(lua_State* tolua_S) lua_pop(tolua_S, 1); } -static int lua_cocos2dx_FastTMXLayer_getTileGIDAt(lua_State* tolua_S) +static int lua_cocos2dx_TextureCache_addImageAsync(lua_State* tolua_S) { + if (nullptr == tolua_S) + return 0 ; + int argc = 0; - cocos2d::FastTMXLayer* cobj = nullptr; - bool ok = true; + TextureCache* self = nullptr; #if COCOS2D_DEBUG >= 1 tolua_Error tolua_err; + if (!tolua_isusertype(tolua_S,1,"cc.TextureCache",0,&tolua_err)) goto tolua_lerror; #endif + self = static_cast(tolua_tousertype(tolua_S,1,0)); #if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.FastTMXLayer",0,&tolua_err)) goto tolua_lerror; + if (nullptr == self) { + tolua_error(tolua_S,"invalid 'self' in function 'lua_cocos2dx_TextureCache_addImageAsync'\n", NULL); + return 0; + } #endif + argc = lua_gettop(tolua_S) - 1; - cobj = (cocos2d::FastTMXLayer*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) + if (2 == argc) { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_FastTMXLayer_getTileGIDAt'", nullptr); +#if COCOS2D_DEBUG >= 1 + if (!tolua_isstring(tolua_S, 2, 0, &tolua_err) || + !toluafix_isfunction(tolua_S,3,"LUA_FUNCTION",0,&tolua_err)) + { + goto tolua_lerror; + } +#endif + const char* configFilePath = tolua_tostring(tolua_S, 2, ""); + LUA_FUNCTION handler = ( toluafix_ref_function(tolua_S, 3, 0)); + + + self->addImageAsync(configFilePath, [=](Texture2D* tex){ + int ID = (tex) ? (int)tex->_ID : -1; + int* luaID = (tex) ? &tex->_luaID : nullptr; + toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)tex, "cc.Texture2D"); + LuaEngine::getInstance()->getLuaStack()->executeFunctionByHandler(handler,1); + LuaEngine::getInstance()->removeScriptHandler(handler); + }); + return 0; } -#endif - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Vec2 arg0; - - ok &= luaval_to_vec2(tolua_S, 2, &arg0); - if(!ok) - return 0; - int ret = cobj->getTileGIDAt(arg0); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - if (argc == 2) - { - cocos2d::Vec2 arg0; - int arg1 = 0; - - ok &= luaval_to_vec2(tolua_S, 2, &arg0); - ok &= luaval_to_int32(tolua_S, 3, &arg1); - - if(!ok) - return 0; - - unsigned int ret = cobj->getTileGIDAt(arg0, (cocos2d::TMXTileFlags*)&arg1); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "getTileGIDAt",argc, 1); - return 0; + CCLOG("'addImageAsync' function of TextureCache has wrong number of arguments: %d, was expecting %d\n", argc, 1); #if COCOS2D_DEBUG >= 1 tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_FastTMXLayer_getTileGIDAt'.",&tolua_err); + tolua_error(tolua_S,"#ferror in function 'addImageAsync'.",&tolua_err); #endif - return 0; } -static void extendFastTMXLayer(lua_State* tolua_S) +static void extendTextureCache(lua_State* tolua_S) { - lua_pushstring(tolua_S, "cc.FastTMXLayer"); + lua_pushstring(tolua_S, "cc.TextureCache"); lua_rawget(tolua_S, LUA_REGISTRYINDEX); if (lua_istable(tolua_S,-1)) { - tolua_function(tolua_S, "getTileGIDAt", lua_cocos2dx_FastTMXLayer_getTileGIDAt); + tolua_function(tolua_S, "addImageAsync", lua_cocos2dx_TextureCache_addImageAsync); } lua_pop(tolua_S, 1); } @@ -6563,7 +6558,7 @@ int register_all_cocos2dx_manual(lua_State* tolua_S) extendTMXLayer(tolua_S); extendEventListenerFocus(tolua_S); extendApplication(tolua_S); - extendFastTMXLayer(tolua_S); + extendTextureCache(tolua_S); return 0; } diff --git a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_spine_manual.cpp b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_spine_manual.cpp index 5e2bc3f8bf..003e5527a2 100644 --- a/cocos/scripting/lua-bindings/manual/lua_cocos2dx_spine_manual.cpp +++ b/cocos/scripting/lua-bindings/manual/lua_cocos2dx_spine_manual.cpp @@ -136,8 +136,8 @@ static int lua_cocos2dx_CCSkeletonAnimation_createWithFile(lua_State* L) #if COCOS2D_DEBUG >= 1 tolua_lerror: tolua_error(L,"#ferror in function 'createWithFile'.",&tolua_err); - return 0; #endif + return 0; } int tolua_Cocos2d_CCSkeletonAnimation_registerSpineEventHandler00(lua_State* tolua_S) diff --git a/cocos/scripting/lua-bindings/proj.ios_mac/cocos2d_lua_bindings.xcodeproj/project.pbxproj b/cocos/scripting/lua-bindings/proj.ios_mac/cocos2d_lua_bindings.xcodeproj/project.pbxproj index 8306a270c4..80163c3135 100644 --- a/cocos/scripting/lua-bindings/proj.ios_mac/cocos2d_lua_bindings.xcodeproj/project.pbxproj +++ b/cocos/scripting/lua-bindings/proj.ios_mac/cocos2d_lua_bindings.xcodeproj/project.pbxproj @@ -19,10 +19,18 @@ 1540AF58193EC30500717D8E /* xxtea.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1540AF55193EC30500717D8E /* xxtea.cpp */; }; 1540AF59193EC30500717D8E /* xxtea.h in Headers */ = {isa = PBXBuildFile; fileRef = 1540AF56193EC30500717D8E /* xxtea.h */; }; 1540AF5A193EC30500717D8E /* xxtea.h in Headers */ = {isa = PBXBuildFile; fileRef = 1540AF56193EC30500717D8E /* xxtea.h */; }; - 15AECE12195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15AECE10195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.cpp */; }; - 15AECE13195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 15AECE11195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.hpp */; }; - 15AECE16195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15AECE14195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.cpp */; }; - 15AECE17195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 15AECE15195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.hpp */; }; + 15622969197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15622967197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp */; }; + 1562296A197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 15622968197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp */; }; + 1562297519778209009C9067 /* lua_cocos2dx_experimental_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1562297119778209009C9067 /* lua_cocos2dx_experimental_manual.cpp */; }; + 1562297619778209009C9067 /* lua_cocos2dx_experimental_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 1562297219778209009C9067 /* lua_cocos2dx_experimental_manual.hpp */; }; + 156EADF31977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 156EADF11977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.cpp */; }; + 156EADF41977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 156EADF21977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.hpp */; }; + 156EADF51977A2BF00F53709 /* lua_cocos2dx_experimental_auto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15622967197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp */; }; + 156EADF61977A2C200F53709 /* lua_cocos2dx_experimental_auto.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 15622968197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp */; }; + 156EADF91977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 156EADF71977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.cpp */; }; + 156EADFA1977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 156EADF81977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.hpp */; }; + 156EADFB1977A3A300F53709 /* lua_cocos2dx_experimental_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1562297119778209009C9067 /* lua_cocos2dx_experimental_manual.cpp */; }; + 156EADFC1977A3A500F53709 /* lua_cocos2dx_experimental_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 1562297219778209009C9067 /* lua_cocos2dx_experimental_manual.hpp */; }; 1A262AB818BEEF5900D2DB92 /* tolua_fix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A262AB718BEEF5900D2DB92 /* tolua_fix.cpp */; }; 1A262AB918BEEF5900D2DB92 /* tolua_fix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A262AB718BEEF5900D2DB92 /* tolua_fix.cpp */; }; 1AACE7B518BC45C200215002 /* lua_cocos2dx_auto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AACE74918BC45C200215002 /* lua_cocos2dx_auto.cpp */; }; @@ -211,6 +219,7 @@ 2905FAD718CF143800240AA3 /* lua_cocos2dx_ui_manual.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2905FAD418CF143800240AA3 /* lua_cocos2dx_ui_manual.cpp */; }; 2905FAD818CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 2905FAD518CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp */; }; 2905FAD918CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 2905FAD518CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp */; }; + C08D4F731974E00F00C87690 /* liblua.a in Frameworks */ = {isa = PBXBuildFile; fileRef = C0D9BAFA1974D30000EC35BB /* liblua.a */; }; C0FEF4D618BE0E70001F446C /* lua_debugger.c in Sources */ = {isa = PBXBuildFile; fileRef = C0FEF4D418BE0E70001F446C /* lua_debugger.c */; }; C0FEF4D718BE0E70001F446C /* lua_debugger.c in Sources */ = {isa = PBXBuildFile; fileRef = C0FEF4D418BE0E70001F446C /* lua_debugger.c */; }; C0FEF4D818BE0E70001F446C /* lua_debugger.h in Headers */ = {isa = PBXBuildFile; fileRef = C0FEF4D518BE0E70001F446C /* lua_debugger.h */; }; @@ -224,10 +233,14 @@ 1503FAA018DA8A1C00F6518C /* io.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = io.h; sourceTree = ""; }; 1540AF55193EC30500717D8E /* xxtea.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = xxtea.cpp; sourceTree = ""; }; 1540AF56193EC30500717D8E /* xxtea.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = xxtea.h; sourceTree = ""; }; - 15AECE10195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_video_auto.cpp; sourceTree = ""; }; - 15AECE11195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_video_auto.hpp; sourceTree = ""; }; - 15AECE14195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_video_manual.cpp; sourceTree = ""; }; - 15AECE15195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_video_manual.hpp; sourceTree = ""; }; + 15622967197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_auto.cpp; sourceTree = ""; }; + 15622968197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_auto.hpp; sourceTree = ""; }; + 1562297119778209009C9067 /* lua_cocos2dx_experimental_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_manual.cpp; sourceTree = ""; }; + 1562297219778209009C9067 /* lua_cocos2dx_experimental_manual.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_manual.hpp; sourceTree = ""; }; + 156EADF11977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_video_auto.cpp; sourceTree = ""; }; + 156EADF21977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_video_auto.hpp; sourceTree = ""; }; + 156EADF71977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_experimental_video_manual.cpp; sourceTree = ""; }; + 156EADF81977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_experimental_video_manual.hpp; sourceTree = ""; }; 1A262AB718BEEF5900D2DB92 /* tolua_fix.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = tolua_fix.cpp; sourceTree = ""; }; 1AACE74618BC45A000215002 /* libluabindings Mac.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libluabindings Mac.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 1AACE74718BC45A000215002 /* libluabindings iOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libluabindings iOS.a"; sourceTree = BUILT_PRODUCTS_DIR; }; @@ -325,6 +338,7 @@ 2905FACF18CF12E600240AA3 /* lua_cocos2dx_ui_auto.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_ui_auto.hpp; sourceTree = ""; }; 2905FAD418CF143800240AA3 /* lua_cocos2dx_ui_manual.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lua_cocos2dx_ui_manual.cpp; sourceTree = ""; }; 2905FAD518CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = lua_cocos2dx_ui_manual.hpp; sourceTree = ""; }; + C0D9BAFA1974D30000EC35BB /* liblua.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = liblua.a; path = ../../../../external/lua/lua/prebuilt/ios/liblua.a; sourceTree = ""; }; C0FEF4D418BE0E70001F446C /* lua_debugger.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = lua_debugger.c; sourceTree = ""; }; C0FEF4D518BE0E70001F446C /* lua_debugger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lua_debugger.h; sourceTree = ""; }; /* End PBXFileReference section */ @@ -334,6 +348,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + C08D4F731974E00F00C87690 /* liblua.a in Frameworks */, 1ABCA1F418CD8F540087CE3A /* libluajit.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -362,6 +377,7 @@ 1551A334158F2AB200E66CFE = { isa = PBXGroup; children = ( + C0D9BAFA1974D30000EC35BB /* liblua.a */, 1ABCA1E218CD8F230087CE3A /* external */, 1AACE74818BC45C200215002 /* auto */, 1AACE75B18BC45C200215002 /* manual */, @@ -373,8 +389,10 @@ 1AACE74818BC45C200215002 /* auto */ = { isa = PBXGroup; children = ( - 15AECE10195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.cpp */, - 15AECE11195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.hpp */, + 156EADF11977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.cpp */, + 156EADF21977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.hpp */, + 15622967197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp */, + 15622968197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp */, 2905FACE18CF12E600240AA3 /* lua_cocos2dx_ui_auto.cpp */, 2905FACF18CF12E600240AA3 /* lua_cocos2dx_ui_auto.hpp */, 1AACE74918BC45C200215002 /* lua_cocos2dx_auto.cpp */, @@ -395,8 +413,10 @@ 1AACE75B18BC45C200215002 /* manual */ = { isa = PBXGroup; children = ( - 15AECE14195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.cpp */, - 15AECE15195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.hpp */, + 156EADF71977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.cpp */, + 156EADF81977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.hpp */, + 1562297119778209009C9067 /* lua_cocos2dx_experimental_manual.cpp */, + 1562297219778209009C9067 /* lua_cocos2dx_experimental_manual.hpp */, 2905FAD418CF143800240AA3 /* lua_cocos2dx_ui_manual.cpp */, 2905FAD518CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp */, 1AACE75E18BC45C200215002 /* CCBProxy.cpp */, @@ -590,6 +610,7 @@ 1AACE7E818BC45C200215002 /* CCLuaStack.h in Headers */, 1ABCA1EF18CD8F470087CE3A /* luaconf.h in Headers */, 1ABCA23C18CD8F7D0087CE3A /* inet.h in Headers */, + 1562296A197780DE009C9067 /* lua_cocos2dx_experimental_auto.hpp in Headers */, 1AACE7D018BC45C200215002 /* lua_cocos2dx_spine_auto.hpp in Headers */, 1ABCA1EB18CD8F470087CE3A /* lauxlib.h in Headers */, 1AACE81018BC45C200215002 /* lua_extensions.h in Headers */, @@ -600,9 +621,11 @@ 1AACE81818BC45C200215002 /* lua_xml_http_request.h in Headers */, 1AACE87C18BC45C200215002 /* tolua_fix.h in Headers */, 1AACE83218BC45C200215002 /* CCLuaObjcBridge.h in Headers */, + 1562297619778209009C9067 /* lua_cocos2dx_experimental_manual.hpp in Headers */, 1AACE82418BC45C200215002 /* LuaScriptHandlerMgr.h in Headers */, 1AACE7FC18BC45C200215002 /* lua_cocos2dx_extension_manual.h in Headers */, 2905FAD318CF12E600240AA3 /* lua_cocos2dx_ui_auto.hpp in Headers */, + 156EADF41977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.hpp in Headers */, 1AACE7EC18BC45C200215002 /* CCLuaValue.h in Headers */, 2905FAD918CF143800240AA3 /* lua_cocos2dx_ui_manual.hpp in Headers */, 1AACE80C18BC45C200215002 /* lua_cocos2dx_spine_manual.hpp in Headers */, @@ -623,10 +646,9 @@ 1ABCA1ED18CD8F470087CE3A /* lua.h in Headers */, 1AACE7F418BC45C200215002 /* lua_cocos2dx_coco_studio_manual.hpp in Headers */, 1ABCA26818CD8F7D0087CE3A /* udp.h in Headers */, - 15AECE17195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.hpp in Headers */, + 156EADFA1977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.hpp in Headers */, 1ABCA25418CD8F7D0087CE3A /* select.h in Headers */, 1AACE7D618BC45C200215002 /* lua_cocos2dx_studio_auto.hpp in Headers */, - 15AECE13195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.hpp in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -653,6 +675,8 @@ 1AACE7CF18BC45C200215002 /* lua_cocos2dx_spine_auto.hpp in Headers */, 1ABCA1EA18CD8F470087CE3A /* lauxlib.h in Headers */, 1AACE80F18BC45C200215002 /* lua_extensions.h in Headers */, + 156EADF61977A2C200F53709 /* lua_cocos2dx_experimental_auto.hpp in Headers */, + 156EADFC1977A3A500F53709 /* lua_cocos2dx_experimental_manual.hpp in Headers */, 1AACE81F18BC45C200215002 /* LuaOpengl.h in Headers */, 1503FAA318DA8A1C00F6518C /* buffer.h in Headers */, 1ABCA25F18CD8F7D0087CE3A /* tcp.h in Headers */, @@ -759,6 +783,7 @@ files = ( 1AACE7C818BC45C200215002 /* lua_cocos2dx_physics_auto.cpp in Sources */, 1AACE83418BC45C200215002 /* CCLuaObjcBridge.mm in Sources */, + 15622969197780DE009C9067 /* lua_cocos2dx_experimental_auto.cpp in Sources */, 1ABCA20518CD8F6E0087CE3A /* tolua_is.c in Sources */, 1AACE7F618BC45C200215002 /* lua_cocos2dx_deprecated.cpp in Sources */, 1ABCA24E18CD8F7D0087CE3A /* options.c in Sources */, @@ -766,11 +791,9 @@ 1AACE81E18BC45C200215002 /* LuaOpengl.cpp in Sources */, 1AACE7CE18BC45C200215002 /* lua_cocos2dx_spine_auto.cpp in Sources */, 1AACE80218BC45C200215002 /* lua_cocos2dx_manual.cpp in Sources */, - 15AECE16195C28DF00907DB0 /* lua_cocos2dx_experimental_video_manual.cpp in Sources */, 1ABCA23E18CD8F7D0087CE3A /* luasocket.c in Sources */, 1ABCA25218CD8F7D0087CE3A /* select.c in Sources */, 1ABCA24A18CD8F7D0087CE3A /* mime.c in Sources */, - 15AECE12195C277100907DB0 /* lua_cocos2dx_experimental_video_auto.cpp in Sources */, 1540AF58193EC30500717D8E /* xxtea.cpp in Sources */, 1ABCA26218CD8F7D0087CE3A /* timeout.c in Sources */, 1503FAA618DA8A1C00F6518C /* io.c in Sources */, @@ -782,6 +805,7 @@ 1AACE7F218BC45C200215002 /* lua_cocos2dx_coco_studio_manual.cpp in Sources */, 1503FAA218DA8A1C00F6518C /* buffer.c in Sources */, 1AACE80E18BC45C200215002 /* lua_extensions.c in Sources */, + 1562297519778209009C9067 /* lua_cocos2dx_experimental_manual.cpp in Sources */, 1AACE7EA18BC45C200215002 /* CCLuaValue.cpp in Sources */, 1AACE7D418BC45C200215002 /* lua_cocos2dx_studio_auto.cpp in Sources */, 1AACE7BC18BC45C200215002 /* lua_cocos2dx_extension_auto.cpp in Sources */, @@ -792,6 +816,7 @@ 1AACE81A18BC45C200215002 /* LuaBasicConversions.cpp in Sources */, 1AACE7EE18BC45C200215002 /* Cocos2dxLuaLoader.cpp in Sources */, 1AACE7DA18BC45C200215002 /* CCBProxy.cpp in Sources */, + 156EADF91977A39F00F53709 /* lua_cocos2dx_experimental_video_manual.cpp in Sources */, 1AACE81618BC45C200215002 /* lua_xml_http_request.cpp in Sources */, 1ABCA23A18CD8F7D0087CE3A /* inet.c in Sources */, 2905FAD118CF12E600240AA3 /* lua_cocos2dx_ui_auto.cpp in Sources */, @@ -802,6 +827,7 @@ 1AACE7DE18BC45C200215002 /* CCLuaBridge.cpp in Sources */, 1ABCA23218CD8F7D0087CE3A /* auxiliar.c in Sources */, 1ABCA20118CD8F6E0087CE3A /* tolua_event.c in Sources */, + 156EADF31977A2BA00F53709 /* lua_cocos2dx_experimental_video_auto.cpp in Sources */, C0FEF4D718BE0E70001F446C /* lua_debugger.c in Sources */, 1AACE7E618BC45C200215002 /* CCLuaStack.cpp in Sources */, 1AACE80618BC45C200215002 /* lua_cocos2dx_physics_manual.cpp in Sources */, @@ -840,6 +866,7 @@ 1503FAA118DA8A1C00F6518C /* buffer.c in Sources */, 1AACE80D18BC45C200215002 /* lua_extensions.c in Sources */, 1AACE7E918BC45C200215002 /* CCLuaValue.cpp in Sources */, + 156EADF51977A2BF00F53709 /* lua_cocos2dx_experimental_auto.cpp in Sources */, 1AACE7D318BC45C200215002 /* lua_cocos2dx_studio_auto.cpp in Sources */, 1AACE7BB18BC45C200215002 /* lua_cocos2dx_extension_auto.cpp in Sources */, 1ABCA20818CD8F6E0087CE3A /* tolua_push.c in Sources */, @@ -856,6 +883,7 @@ 1ABCA26D18CD8F7D0087CE3A /* usocket.c in Sources */, 1AACE81118BC45C200215002 /* Lua_web_socket.cpp in Sources */, 1AACE7F918BC45C200215002 /* lua_cocos2dx_extension_manual.cpp in Sources */, + 156EADFB1977A3A300F53709 /* lua_cocos2dx_experimental_manual.cpp in Sources */, 1AACE7DD18BC45C200215002 /* CCLuaBridge.cpp in Sources */, 1ABCA23118CD8F7D0087CE3A /* auxiliar.c in Sources */, 1ABCA20018CD8F6E0087CE3A /* tolua_event.c in Sources */, @@ -959,7 +987,6 @@ "$(SRCROOT)/../../../../external/lua/luajit/prebuilt/ios", "$(SRCROOT)/../../../../external/lua/lua/prebuilt/ios", ); - "OTHER_LDFLAGS[arch=arm64]" = "-llua"; "OTHER_LDFLAGS[sdk=iphonesimulator7.1]" = "-llua"; "OTHER_LDFLAGS[sdk=iphonesimulator8.0]" = "-llua"; SDKROOT = iphoneos; @@ -985,7 +1012,6 @@ "$(SRCROOT)/../../../../external/lua/luajit/prebuilt/ios", "$(SRCROOT)/../../../../external/lua/lua/prebuilt/ios", ); - "OTHER_LDFLAGS[arch=arm64]" = "-llua"; "OTHER_LDFLAGS[sdk=iphonesimulator7.1]" = "-llua"; "OTHER_LDFLAGS[sdk=iphonesimulator8.0]" = "-llua"; SDKROOT = iphoneos; diff --git a/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj b/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj index 4ebf5661d4..8afd7fae0a 100644 --- a/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj +++ b/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj @@ -31,6 +31,7 @@ + @@ -48,6 +49,7 @@ + @@ -82,6 +84,7 @@ + @@ -99,6 +102,7 @@ + diff --git a/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj.filters b/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj.filters index af8cd09e62..17e309c94c 100644 --- a/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj.filters +++ b/cocos/scripting/lua-bindings/proj.win32/liblua.vcxproj.filters @@ -165,6 +165,12 @@ xxtea + + manual + + + auto + @@ -314,6 +320,12 @@ xxtea + + manual + + + auto + diff --git a/cocos/scripting/lua-bindings/script/DeprecatedEnum.lua b/cocos/scripting/lua-bindings/script/DeprecatedEnum.lua index 738f2a2014..fd21cc4ecb 100644 --- a/cocos/scripting/lua-bindings/script/DeprecatedEnum.lua +++ b/cocos/scripting/lua-bindings/script/DeprecatedEnum.lua @@ -492,3 +492,5 @@ ccui.LayoutType.linearVertical = ccui.LayoutType.VERTICAL ccui.LayoutType.linearHorizontal = ccui.LayoutType.HORIZONTAL ccui.LayoutType.relative = ccui.LayoutType.RELATIVE +ccui.ListViewEventType.onsSelectedItem = ccui.ListViewEventType.ONSELECTEDITEM_START + diff --git a/cocos/scripting/lua-bindings/script/GuiConstants.lua b/cocos/scripting/lua-bindings/script/GuiConstants.lua index e322d3bfaf..1b3ce7e439 100644 --- a/cocos/scripting/lua-bindings/script/GuiConstants.lua +++ b/cocos/scripting/lua-bindings/script/GuiConstants.lua @@ -151,7 +151,8 @@ ccui.ListViewMoveDirection = { } ccui.ListViewEventType = { - onsSelectedItem = 0, + ONSELECTEDITEM_START = 0, + ONSELECTEDITEM_END = 1, } ccui.PageViewEventType = { diff --git a/cocos/scripting/lua-bindings/script/bitExtend.lua b/cocos/scripting/lua-bindings/script/bitExtend.lua new file mode 100644 index 0000000000..1f152bb895 --- /dev/null +++ b/cocos/scripting/lua-bindings/script/bitExtend.lua @@ -0,0 +1,95 @@ +-- bit operation + +bit = bit or {} +bit.data32 = {} +for i=1,32 do + bit.data32[i]=2^(32-i) +end + +function bit._b2d(arg) + local nr=0 + for i=1,32 do + if arg[i] ==1 then + nr=nr+bit.data32[i] + end + end + return nr +end + +function bit._d2b(arg) + arg = arg >= 0 and arg or (0xFFFFFFFF + arg + 1) + local tr={} + for i=1,32 do + if arg >= bit.data32[i] then + tr[i]=1 + arg=arg-bit.data32[i] + else + tr[i]=0 + end + end + return tr +end + +function bit._and(a,b) + local op1=bit._d2b(a) + local op2=bit._d2b(b) + local r={} + + for i=1,32 do + if op1[i]==1 and op2[i]==1 then + r[i]=1 + else + r[i]=0 + end + end + return bit._b2d(r) + +end + +function bit._rshift(a,n) + local op1=bit._d2b(a) + n = n <= 32 and n or 32 + n = n >= 0 and n or 0 + + for i=32, n+1, -1 do + op1[i] = op1[i-n] + end + for i=1, n do + op1[i] = 0 + end + + return bit._b2d(op1) +end + +function bit._not(a) + local op1=bit._d2b(a) + local r={} + + for i=1,32 do + if op1[i]==1 then + r[i]=0 + else + r[i]=1 + end + end + return bit._b2d(r) +end + +function bit._or(a,b) + local op1=bit._d2b(a) + local op2=bit._d2b(b) + local r={} + + for i=1,32 do + if op1[i]==1 or op2[i]==1 then + r[i]=1 + else + r[i]=0 + end + end + return bit._b2d(r) +end + +bit.band = bit.band or bit._and +bit.rshift = bit.rshift or bit._rshift +bit.bnot = bit.bnot or bit._not \ No newline at end of file diff --git a/cocos/scripting/lua-bindings/script/experimentalConstants.lua b/cocos/scripting/lua-bindings/script/experimentalConstants.lua index 9fea50ca3b..63a65648ea 100644 --- a/cocos/scripting/lua-bindings/script/experimentalConstants.lua +++ b/cocos/scripting/lua-bindings/script/experimentalConstants.lua @@ -1,7 +1,7 @@ -ccexprimental = ccexprimental or {} +ccexp = ccexp or {} -ccexprimental.VideoPlayerEvent = { +ccexp.VideoPlayerEvent = { PLAYING = 0, PAUSED = 1, STOPPED= 2, diff --git a/cocos/ui/UIButton.h b/cocos/ui/UIButton.h index 82ba742fb3..0510717c56 100644 --- a/cocos/ui/UIButton.h +++ b/cocos/ui/UIButton.h @@ -80,7 +80,7 @@ public: * * @param disabled disabled state texture name. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextures(const std::string& normal, const std::string& selected, @@ -92,7 +92,7 @@ public: * * @param normal normal state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureNormal(const std::string& normal, TextureResType texType = TextureResType::LOCAL); @@ -101,7 +101,7 @@ public: * * @param selected selected state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTexturePressed(const std::string& selected, TextureResType texType = TextureResType::LOCAL); @@ -110,7 +110,7 @@ public: * * @param disabled dark state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureDisabled(const std::string& disabled, TextureResType texType = TextureResType::LOCAL); diff --git a/cocos/ui/UICheckBox.h b/cocos/ui/UICheckBox.h index b1b6a28177..db7900fcbf 100644 --- a/cocos/ui/UICheckBox.h +++ b/cocos/ui/UICheckBox.h @@ -86,7 +86,7 @@ public: * * @param frontCrossDisabled cross dark state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ static CheckBox* create(const std::string& backGround, const std::string& backGroundSeleted, @@ -106,7 +106,7 @@ public: * * @param frontCrossDisabled cross dark state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextures(const std::string& backGround, const std::string& backGroundSelected, @@ -120,7 +120,7 @@ public: * * @param backGround backGround texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureBackGround(const std::string& backGround,TextureResType type = TextureResType::LOCAL); @@ -129,7 +129,7 @@ public: * * @param backGroundSelected backGround selected state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureBackGroundSelected(const std::string& backGroundSelected,TextureResType texType = TextureResType::LOCAL); @@ -138,7 +138,7 @@ public: * * @param cross cross texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureFrontCross(const std::string&,TextureResType texType = TextureResType::LOCAL); @@ -147,7 +147,7 @@ public: * * @param backGroundDisabled backGroundDisabled texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureBackGroundDisabled(const std::string& backGroundDisabled,TextureResType texType = TextureResType::LOCAL); @@ -156,7 +156,7 @@ public: * * @param frontCrossDisabled frontCrossDisabled texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTextureFrontCrossDisabled(const std::string& frontCrossDisabled,TextureResType texType = TextureResType::LOCAL); diff --git a/cocos/ui/UIImageView.h b/cocos/ui/UIImageView.h index 8afa3514bb..ada869b34a 100644 --- a/cocos/ui/UIImageView.h +++ b/cocos/ui/UIImageView.h @@ -61,7 +61,7 @@ public: * * @param imageFileName file name of texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ static ImageView* create(const std::string& imageFileName, TextureResType texType = TextureResType::LOCAL); @@ -71,7 +71,7 @@ public: * * @param fileName file name of texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTexture(const std::string& fileName,TextureResType texType = TextureResType::LOCAL); diff --git a/cocos/ui/UILayout.cpp b/cocos/ui/UILayout.cpp index 7064ec73d5..50074ae5ae 100644 --- a/cocos/ui/UILayout.cpp +++ b/cocos/ui/UILayout.cpp @@ -1137,7 +1137,7 @@ float Layout::calculateNearestDistance(Widget* baseWidget) return distance; } -float Layout::calculateFarestDistance(cocos2d::ui::Widget *baseWidget) +float Layout::calculateFarthestDistance(cocos2d::ui::Widget *baseWidget) { float distance = -FLT_MAX; @@ -1147,7 +1147,7 @@ float Layout::calculateFarestDistance(cocos2d::ui::Widget *baseWidget) Layout *layout = dynamic_cast(node); int length; if (layout) { - length = layout->calculateFarestDistance(baseWidget); + length = layout->calculateFarthestDistance(baseWidget); } else { @@ -1231,7 +1231,7 @@ int Layout::findNearestChildWidgetIndex(FocusDirection direction, Widget* baseWi return 0; } -int Layout::findFarestChildWidgetIndex(FocusDirection direction, cocos2d::ui::Widget *baseWidget) +int Layout::findFarthestChildWidgetIndex(FocusDirection direction, cocos2d::ui::Widget *baseWidget) { if (baseWidget == nullptr || baseWidget == this) { @@ -1256,7 +1256,7 @@ int Layout::findFarestChildWidgetIndex(FocusDirection direction, cocos2d::ui::Wi Layout *layout = dynamic_cast(w); if (layout) { - length = layout->calculateFarestDistance(baseWidget); + length = layout->calculateFarthestDistance(baseWidget); } else { @@ -1337,11 +1337,11 @@ void Layout::findProperSearchingFunctor(FocusDirection dir, Widget* baseWidget) onPassFocusToChild = CC_CALLBACK_2(Layout::findNearestChildWidgetIndex, this); } else{ - onPassFocusToChild = CC_CALLBACK_2(Layout::findFarestChildWidgetIndex, this); + onPassFocusToChild = CC_CALLBACK_2(Layout::findFarthestChildWidgetIndex, this); } }else if(dir == FocusDirection::RIGHT){ if (previousWidgetPosition.x > widgetPosition.x) { - onPassFocusToChild = CC_CALLBACK_2(Layout::findFarestChildWidgetIndex, this); + onPassFocusToChild = CC_CALLBACK_2(Layout::findFarthestChildWidgetIndex, this); } else{ onPassFocusToChild = CC_CALLBACK_2(Layout::findNearestChildWidgetIndex, this); @@ -1350,13 +1350,13 @@ void Layout::findProperSearchingFunctor(FocusDirection dir, Widget* baseWidget) if (previousWidgetPosition.y > widgetPosition.y) { onPassFocusToChild = CC_CALLBACK_2(Layout::findNearestChildWidgetIndex, this); }else{ - onPassFocusToChild = CC_CALLBACK_2(Layout::findFarestChildWidgetIndex, this); + onPassFocusToChild = CC_CALLBACK_2(Layout::findFarthestChildWidgetIndex, this); } }else if(dir == FocusDirection::UP){ if (previousWidgetPosition.y < widgetPosition.y) { onPassFocusToChild = CC_CALLBACK_2(Layout::findNearestChildWidgetIndex, this); }else{ - onPassFocusToChild = CC_CALLBACK_2(Layout::findFarestChildWidgetIndex, this); + onPassFocusToChild = CC_CALLBACK_2(Layout::findFarthestChildWidgetIndex, this); } }else{ CCASSERT(0, "invalid direction!"); diff --git a/cocos/ui/UILayout.h b/cocos/ui/UILayout.h index e2c9798d37..e43df22522 100644 --- a/cocos/ui/UILayout.h +++ b/cocos/ui/UILayout.h @@ -110,7 +110,7 @@ public: * * @param fileName image file path. * - * @param texType @see TextureResType. UI_TEX_TYPE_LOCAL means local file, UI_TEX_TYPE_PLIST means sprite frame. + * @param texType @see TextureResType. TextureResType::LOCAL means local file, TextureResType::PLIST means sprite frame. */ void setBackGroundImage(const std::string& fileName,TextureResType texType = TextureResType::LOCAL); @@ -143,7 +143,7 @@ public: bool isBackGroundImageScale9Enabled()const; /** - * Sets background color for layout, if color type is LAYOUT_COLOR_SOLID + * Sets background color for layout, if color type is BackGroundColorType::SOLIDE * * @param color */ @@ -152,7 +152,7 @@ public: const Color3B& getBackGroundColor()const; /** - * Sets background color for layout, if color type is LAYOUT_COLOR_GRADIENT + * Sets background color for layout, if color type is BackGroundColorType::GRADIENT * * @param start color * @@ -174,7 +174,7 @@ public: GLubyte getBackGroundColorOpacity()const; /** - * Sets background color vector for layout, if color type is LAYOUT_COLOR_GRADIENT + * Sets background color vector for layout, if color type is BackGroundColorType::GRADIENT * * @param vector */ @@ -365,11 +365,11 @@ protected: /** * When the layout get focused, it the layout pass the focus to its child, it will use this method to determine which child - * will get the focus. The current algorithm to determine which child will get focus is farest-distance-priority algorithm + * will get the focus. The current algorithm to determine which child will get focus is farthest-distance-priority algorithm *@param dir next focused widget direction *@return The index of child widget in the container */ - int findFarestChildWidgetIndex(FocusDirection direction, Widget* baseWidget); + int findFarthestChildWidgetIndex(FocusDirection direction, Widget* baseWidget); /** * caculate the nearest distance between the baseWidget and the children of the layout @@ -379,15 +379,15 @@ protected: float calculateNearestDistance(Widget* baseWidget); /** - * caculate the farest distance between the baseWidget and the children of the layout + * caculate the farthest distance between the baseWidget and the children of the layout *@param the base widget which will be used to caculate the distance between the layout's children and itself - *@return return the farest distance between the baseWidget and the layout's children + *@return return the farthest distance between the baseWidget and the layout's children */ - float calculateFarestDistance(Widget* baseWidget); + float calculateFarthestDistance(Widget* baseWidget); /** - * when a layout pass the focus to it's child, use this method to determine which algorithm to use, nearest or farest distance algorithm or not + * when a layout pass the focus to it's child, use this method to determine which algorithm to use, nearest or farthest distance algorithm or not */ void findProperSearchingFunctor(FocusDirection dir, Widget* baseWidget); diff --git a/cocos/ui/UIListView.h b/cocos/ui/UIListView.h index 2409bd3763..53737812a6 100644 --- a/cocos/ui/UIListView.h +++ b/cocos/ui/UIListView.h @@ -180,9 +180,9 @@ public: /** * Changes scroll direction of scrollview. * - * @see SCROLLVIEW_DIR SCROLLVIEW_DIR_VERTICAL means vertical scroll, SCROLLVIEW_DIR_HORIZONTAL means horizontal scroll + * @see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll * - * @param SCROLLVIEW_DIR + * @param dir, set the list view's scroll direction */ virtual void setDirection(Direction dir) override; diff --git a/cocos/ui/UILoadingBar.h b/cocos/ui/UILoadingBar.h index 1a0d6cbe6a..6fe4910130 100644 --- a/cocos/ui/UILoadingBar.h +++ b/cocos/ui/UILoadingBar.h @@ -89,7 +89,7 @@ public: * * @param texture file name of texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadTexture(const std::string& texture,TextureResType texType = TextureResType::LOCAL); diff --git a/cocos/ui/UIPageView.cpp b/cocos/ui/UIPageView.cpp index 0dce9f9afa..fcca3e38b7 100644 --- a/cocos/ui/UIPageView.cpp +++ b/cocos/ui/UIPageView.cpp @@ -336,10 +336,6 @@ void PageView::autoScroll(float dt) bool PageView::onTouchBegan(Touch *touch, Event *unusedEvent) { bool pass = Layout::onTouchBegan(touch, unusedEvent); - if (_hitted) - { - handlePressLogic(touch); - } return pass; } @@ -433,10 +429,6 @@ bool PageView::scrollPages(float touchOffset) return true; } -void PageView::handlePressLogic(Touch *touch) -{ - //no-op -} void PageView::handleMoveLogic(Touch *touch) { @@ -507,7 +499,7 @@ void PageView::interceptTouchEvent(TouchEventType event, Widget *sender, Touch * switch (event) { case TouchEventType::BEGAN: - handlePressLogic(touch); + //no-op break; case TouchEventType::MOVED: { diff --git a/cocos/ui/UIPageView.h b/cocos/ui/UIPageView.h index 70c764ee6a..52df2509ef 100644 --- a/cocos/ui/UIPageView.h +++ b/cocos/ui/UIPageView.h @@ -127,8 +127,7 @@ public: */ ssize_t getCurPageIndex() const; - //TODO: add Vector member variables into UIPageView, but it only used for reference purpose, - //all the pages are added into proteced node, so does scrollview, listview + Vector& getPages(); Layout* getPage(ssize_t index); @@ -186,7 +185,6 @@ protected: void updateAllPagesPosition(); void autoScroll(float dt); - virtual void handlePressLogic(Touch *touch); virtual void handleMoveLogic(Touch *touch) ; virtual void handleReleaseLogic(Touch *touch) ; virtual void interceptTouchEvent(TouchEventType event, Widget* sender,Touch *touch) ; diff --git a/cocos/ui/UIRichText.cpp b/cocos/ui/UIRichText.cpp index 6bff82c007..af9bb06265 100644 --- a/cocos/ui/UIRichText.cpp +++ b/cocos/ui/UIRichText.cpp @@ -26,26 +26,47 @@ #include "platform/CCFileUtils.h" #include "2d/CCLabel.h" #include "2d/CCSprite.h" +#include "base/ccUTF8.h" NS_CC_BEGIN namespace ui { -static int _calcCharCount(const char * pszText) +static std::string utf8_substr(const std::string& str, unsigned long start, unsigned long leng) { - int n = 0; - char ch = 0; - while ((ch = *pszText)) + if (leng==0) { - CC_BREAK_IF(! ch); - - if (0x80 != (0xC0 & ch)) - { - ++n; - } - ++pszText; + return ""; } - return n; + unsigned long c, i, ix, q, min=std::string::npos, max=std::string::npos; + for (q=0, i=0, ix=str.length(); i < ix; i++, q++) + { + if (q==start) + { + min = i; + } + if (q <= start+leng || leng==std::string::npos) + { + max = i; + } + + c = (unsigned char) str[i]; + + if (c<=127) i+=0; + else if ((c & 0xE0) == 0xC0) i+=1; + else if ((c & 0xF0) == 0xE0) i+=2; + else if ((c & 0xF8) == 0xF0) i+=3; + else return "";//invalid utf8 + } + if (q <= start+leng || leng == std::string::npos) + { + max = i; + } + if (min==std::string::npos || max==std::string::npos) + { + return ""; + } + return str.substr(min,max); } bool RichElement::init(int tag, const Color3B &color, GLubyte opacity) @@ -295,20 +316,20 @@ void RichText::handleTextRenderer(const std::string& text, const std::string& fo { float overstepPercent = (-_leftSpaceWidth) / textRendererWidth; std::string curText = text; - size_t stringLength = _calcCharCount(text.c_str()); + size_t stringLength = StringUtils::getCharacterCountInUTF8String(text); int leftLength = stringLength * (1.0f - overstepPercent); - std::string leftWords = curText.substr(0, leftLength); - std::string cutWords = curText.substr(leftLength, curText.length()-1); + std::string leftWords = utf8_substr(curText,0,leftLength); + std::string cutWords = utf8_substr(curText, leftLength, curText.length() - leftLength); if (leftLength > 0) { Label* leftRenderer = nullptr; if (fileExist) { - leftRenderer = Label::createWithTTF(leftWords.substr(0, leftLength).c_str(), fontName, fontSize); - } + leftRenderer = Label::createWithTTF(utf8_substr(leftWords, 0, leftLength), fontName, fontSize); + } else { - leftRenderer = Label::createWithSystemFont(leftWords.substr(0, leftLength).c_str(), fontName, fontSize); + leftRenderer = Label::createWithSystemFont(utf8_substr(leftWords, 0, leftLength), fontName, fontSize); } if (leftRenderer) { diff --git a/cocos/ui/UIScrollView.h b/cocos/ui/UIScrollView.h index c02d68fd1e..ae2bd6ab43 100644 --- a/cocos/ui/UIScrollView.h +++ b/cocos/ui/UIScrollView.h @@ -95,18 +95,18 @@ public: /** * Changes scroll direction of scrollview. * - * @see SCROLLVIEW_DIR SCROLLVIEW_DIR_VERTICAL means vertical scroll, SCROLLVIEW_DIR_HORIZONTAL means horizontal scroll + * @see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll * - * @param SCROLLVIEW_DIR + * @param dir */ virtual void setDirection(Direction dir); /** * Gets scroll direction of scrollview. * - * @see SCROLLVIEW_DIR SCROLLVIEW_DIR_VERTICAL means vertical scroll, SCROLLVIEW_DIR_HORIZONTAL means horizontal scroll + * @see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll * - * @return SCROLLVIEW_DIR + * @return Direction */ Direction getDirection()const; diff --git a/cocos/ui/UISlider.h b/cocos/ui/UISlider.h index f8a711dcf1..de8ed765b2 100644 --- a/cocos/ui/UISlider.h +++ b/cocos/ui/UISlider.h @@ -76,7 +76,7 @@ public: * * @param fileName file name of texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadBarTexture(const std::string& fileName,TextureResType texType = TextureResType::LOCAL); @@ -123,7 +123,7 @@ public: * * @param slider ball disabled dark state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadSlidBallTextures(const std::string& normal, const std::string& pressed, @@ -135,7 +135,7 @@ public: * * @param normal normal state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadSlidBallTextureNormal(const std::string& normal,TextureResType texType = TextureResType::LOCAL); @@ -144,7 +144,7 @@ public: * * @param selected selected state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadSlidBallTexturePressed(const std::string& pressed,TextureResType texType = TextureResType::LOCAL); @@ -153,7 +153,7 @@ public: * * @param disabled dark state texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadSlidBallTextureDisabled(const std::string& disabled,TextureResType texType = TextureResType::LOCAL); @@ -162,7 +162,7 @@ public: * * @param fileName file path of texture. * - * @param texType @see UI_TEX_TYPE_LOCAL + * @param texType @see TextureResType */ void loadProgressBarTexture(const std::string& fileName, TextureResType texType = TextureResType::LOCAL); diff --git a/cocos/ui/UIText.cpp b/cocos/ui/UIText.cpp index e0d0f1ae38..2a0cd717b8 100644 --- a/cocos/ui/UIText.cpp +++ b/cocos/ui/UIText.cpp @@ -296,7 +296,6 @@ void Text::labelScaleChangedWithSize() { if (_ignoreSize) { - _labelRenderer->setDimensions(0,0); _labelRenderer->setScale(1.0f); _normalScaleValueX = _normalScaleValueY = 1.0f; } diff --git a/cocos/ui/UITextField.cpp b/cocos/ui/UITextField.cpp index 7d6cf660f7..8b70bb5297 100644 --- a/cocos/ui/UITextField.cpp +++ b/cocos/ui/UITextField.cpp @@ -23,6 +23,7 @@ THE SOFTWARE. ****************************************************************************/ #include "ui/UITextField.h" +#include "platform/CCFileUtils.h" NS_CC_BEGIN @@ -366,7 +367,10 @@ _textFieldEventListener(nullptr), _textFieldEventSelector(nullptr), _eventCallback(nullptr), _passwordStyleText(""), -_textFieldRendererAdaptDirty(true) +_textFieldRendererAdaptDirty(true), +_fontName("Thonburi"), +_fontSize(10), +_fontType(FontType::SYSTEM) { } @@ -541,26 +545,44 @@ const std::string& TextField::getPlaceHolder()const void TextField::setFontSize(int size) { - _textFieldRenderer->setSystemFontSize(size); + if (_fontType == FontType::SYSTEM) { + _textFieldRenderer->setSystemFontSize(size); + } else { + TTFConfig config = _textFieldRenderer->getTTFConfig(); + config.fontSize = size; + _textFieldRenderer->setTTFConfig(config); + } + _fontSize = size; _textFieldRendererAdaptDirty = true; updateContentSizeWithTextureSize(_textFieldRenderer->getContentSize()); } int TextField::getFontSize()const { - return _textFieldRenderer->getSystemFontSize(); + return _fontSize; } void TextField::setFontName(const std::string& name) { - _textFieldRenderer->setSystemFontName(name); + if(FileUtils::getInstance()->isFileExist(name)) + { + TTFConfig config = _textFieldRenderer->getTTFConfig(); + config.fontFilePath = name; + config.fontSize = _fontSize; + _textFieldRenderer->setTTFConfig(config); + _fontType = FontType::TTF; + } else { + _textFieldRenderer->setSystemFontName(name); + _fontType = FontType::SYSTEM; + } + _fontName = name; _textFieldRendererAdaptDirty = true; updateContentSizeWithTextureSize(_textFieldRenderer->getContentSize()); } const std::string& TextField::getFontName()const { - return _textFieldRenderer->getSystemFontName(); + return _fontName; } void TextField::didNotSelectSelf() @@ -777,24 +799,9 @@ void TextField::adaptRenderers() void TextField::textfieldRendererScaleChangedWithSize() { - if (_ignoreSize) - { - _textFieldRenderer->setDimensions(0,0); - _textFieldRenderer->setScale(1.0f); - } - else + if (!_ignoreSize) { _textFieldRenderer->setDimensions(_contentSize.width, _contentSize.height); - Size textureSize = getContentSize(); - if (textureSize.width <= 0.0f || textureSize.height <= 0.0f) - { - _textFieldRenderer->setScale(1.0f); - return; - } - float scaleX = _contentSize.width / textureSize.width; - float scaleY = _contentSize.height / textureSize.height; - _textFieldRenderer->setScaleX(scaleX); - _textFieldRenderer->setScaleY(scaleY); } _textFieldRenderer->setPosition(_contentSize.width / 2.0f, _contentSize.height / 2.0f); } @@ -831,8 +838,8 @@ void TextField::copySpecialProperties(Widget *widget) { setText(textField->_textFieldRenderer->getString()); setPlaceHolder(textField->getStringValue()); - setFontSize(textField->_textFieldRenderer->getSystemFontSize()); - setFontName(textField->_textFieldRenderer->getSystemFontName()); + setFontSize(textField->_fontSize); + setFontName(textField->_fontName); setMaxLengthEnabled(textField->isMaxLengthEnabled()); setMaxLength(textField->getMaxLength()); setPasswordEnabled(textField->isPasswordEnabled()); @@ -849,7 +856,7 @@ void TextField::copySpecialProperties(Widget *widget) void TextField::setTextAreaSize(const Size &size) { - _textFieldRenderer->setDimensions(size.width,size.height); + this->setContentSize(size); } void TextField::setTextHorizontalAlignment(TextHAlignment alignment) diff --git a/cocos/ui/UITextField.h b/cocos/ui/UITextField.h index cc7ef355a8..b26456fd33 100644 --- a/cocos/ui/UITextField.h +++ b/cocos/ui/UITextField.h @@ -228,6 +228,16 @@ protected: std::string _passwordStyleText; bool _textFieldRendererAdaptDirty; +private: + enum class FontType + { + SYSTEM, + TTF + }; + + std::string _fontName; + int _fontSize; + FontType _fontType; }; } diff --git a/cocos/ui/UIVideoPlayer.h b/cocos/ui/UIVideoPlayer.h index 81d0787236..deb029aaee 100644 --- a/cocos/ui/UIVideoPlayer.h +++ b/cocos/ui/UIVideoPlayer.h @@ -73,7 +73,7 @@ namespace experimental{ virtual void addEventListener(const VideoPlayer::ccVideoPlayerCallback& callback); - virtual void onPlayEvent(VideoPlayer::EventType event); + virtual void onPlayEvent(int event); virtual void draw(Renderer *renderer, const Mat4& transform, uint32_t flags) override; protected: diff --git a/cocos/ui/UIVideoPlayerAndroid.cpp b/cocos/ui/UIVideoPlayerAndroid.cpp index a9deb991f3..aecf889a51 100644 --- a/cocos/ui/UIVideoPlayerAndroid.cpp +++ b/cocos/ui/UIVideoPlayerAndroid.cpp @@ -37,10 +37,12 @@ //----------------------------------------------------------------------------------------------------------- #define CLASS_NAME "org/cocos2dx/lib/Cocos2dxVideoHelper" -void executeVideoCallback(int index,int event); - USING_NS_CC; +static void executeVideoCallback(int index,int event); + +#define QUIT_FULLSCREEN 1000 + extern "C" { void Java_org_cocos2dx_lib_Cocos2dxVideoHelper_nativeExecuteVideoCallback(JNIEnv * env, jobject obj, jint index,jint event) { executeVideoCallback(index,event); @@ -87,6 +89,17 @@ void setVideoRectJNI(int index,int left,int top,int width,int height) } } +void setFullScreenEnabledJni(int index,bool enabled, int width, int height) +{ + JniMethodInfo t; + + if (JniHelper::getStaticMethodInfo(t, CLASS_NAME, "setFullScreenEnabled", "(IZII)V")) { + t.env->CallStaticVoidMethod(t.classID, t.methodID, index, enabled, width, height); + + t.env->DeleteLocalRef(t.classID); + } +} + void setVideoURLJNI(int index,int videoSource,const std::string& videoUrl) { JniMethodInfo t; @@ -166,16 +179,6 @@ VideoPlayer::VideoPlayer() { _videoPlayerIndex = createVideoWidgetJNI(); s_allVideoPlayers[_videoPlayerIndex] = this; - - auto listener = EventListenerKeyboard::create(); - listener->onKeyReleased = [&](EventKeyboard::KeyCode keycode, cocos2d::Event* event){ - if (keycode == EventKeyboard::KeyCode::KEY_BACKSPACE && _fullScreenEnabled) - { - this->setFullScreenEnabled(false); - } - }; - - _eventDispatcher->addEventListenerWithSceneGraphPriority(listener, this); } VideoPlayer::~VideoPlayer() @@ -202,31 +205,23 @@ void VideoPlayer::draw(Renderer* renderer, const Mat4 &transform, uint32_t flags { cocos2d::ui::Widget::draw(renderer,transform,flags); - if ((flags&FLAGS_TRANSFORM_DIRTY) || _fullScreenDirty) + if (flags & FLAGS_TRANSFORM_DIRTY) { - _fullScreenDirty = false; auto directorInstance = Director::getInstance(); auto glView = directorInstance->getOpenGLView(); auto frameSize = glView->getFrameSize(); - if (_fullScreenEnabled) - { - setVideoRectJNI(_videoPlayerIndex,0,0,frameSize.width,frameSize.height); - } - else - { - auto winSize = directorInstance->getWinSize(); + auto winSize = directorInstance->getWinSize(); - auto leftBottom = convertToWorldSpace(Point::ZERO); - auto rightTop = convertToWorldSpace(Point(_contentSize.width,_contentSize.height)); + auto leftBottom = convertToWorldSpace(Point::ZERO); + auto rightTop = convertToWorldSpace(Point(_contentSize.width,_contentSize.height)); - auto uiLeft = frameSize.width / 2 + (leftBottom.x - winSize.width / 2 ) * glView->getScaleX(); - auto uiTop = frameSize.height /2 - (rightTop.y - winSize.height / 2) * glView->getScaleY(); + auto uiLeft = frameSize.width / 2 + (leftBottom.x - winSize.width / 2 ) * glView->getScaleX(); + auto uiTop = frameSize.height /2 - (rightTop.y - winSize.height / 2) * glView->getScaleY(); - setVideoRectJNI(_videoPlayerIndex,uiLeft,uiTop, - (rightTop.x - leftBottom.x) * glView->getScaleX(), - (rightTop.y - leftBottom.y) * glView->getScaleY()); - } + setVideoRectJNI(_videoPlayerIndex,uiLeft,uiTop, + (rightTop.x - leftBottom.x) * glView->getScaleX(), + (rightTop.y - leftBottom.y) * glView->getScaleY()); } #if CC_VIDEOPLAYER_DEBUG_DRAW @@ -241,7 +236,9 @@ void VideoPlayer::setFullScreenEnabled(bool enabled) if (_fullScreenEnabled != enabled) { _fullScreenEnabled = enabled; - _fullScreenDirty = true; + + auto frameSize = Director::getInstance()->getOpenGLView()->getFrameSize(); + setFullScreenEnabledJni(_videoPlayerIndex, enabled, frameSize.width, frameSize.height); } } @@ -344,17 +341,25 @@ void VideoPlayer::addEventListener(const VideoPlayer::ccVideoPlayerCallback& cal _eventCallback = callback; } -void VideoPlayer::onPlayEvent(VideoPlayer::EventType event) +void VideoPlayer::onPlayEvent(int event) { - if (event == VideoPlayer::EventType::PLAYING) { - _isPlaying = true; - } else { - _isPlaying = false; - } - - if (_eventCallback) + if (event == QUIT_FULLSCREEN) { - _eventCallback(this,event); + _fullScreenEnabled = false; + } + else + { + VideoPlayer::EventType videoEvent = (VideoPlayer::EventType)event; + if (videoEvent == VideoPlayer::EventType::PLAYING) { + _isPlaying = true; + } else { + _isPlaying = false; + } + + if (_eventCallback) + { + _eventCallback(this,videoEvent); + } } } @@ -385,7 +390,7 @@ void executeVideoCallback(int index,int event) auto it = s_allVideoPlayers.find(index); if (it != s_allVideoPlayers.end()) { - s_allVideoPlayers[index]->onPlayEvent((VideoPlayer::EventType)event); + s_allVideoPlayers[index]->onPlayEvent(event); } } diff --git a/cocos/ui/UIVideoPlayerIOS.mm b/cocos/ui/UIVideoPlayerIOS.mm index 7bf359f822..ae26500b0e 100644 --- a/cocos/ui/UIVideoPlayerIOS.mm +++ b/cocos/ui/UIVideoPlayerIOS.mm @@ -171,7 +171,7 @@ using namespace cocos2d::experimental::ui; { if([self.moviePlayer playbackState] != MPMoviePlaybackStateStopped) { - _videoPlayer->onPlayEvent(VideoPlayer::EventType::COMPLETED); + _videoPlayer->onPlayEvent((int)VideoPlayer::EventType::COMPLETED); } } } @@ -181,13 +181,13 @@ using namespace cocos2d::experimental::ui; MPMoviePlaybackState state = [self.moviePlayer playbackState]; switch (state) { case MPMoviePlaybackStatePaused: - _videoPlayer->onPlayEvent(VideoPlayer::EventType::PAUSED); + _videoPlayer->onPlayEvent((int)VideoPlayer::EventType::PAUSED); break; case MPMoviePlaybackStateStopped: - _videoPlayer->onPlayEvent(VideoPlayer::EventType::STOPPED); + _videoPlayer->onPlayEvent((int)VideoPlayer::EventType::STOPPED); break; case MPMoviePlaybackStatePlaying: - _videoPlayer->onPlayEvent(VideoPlayer::EventType::PLAYING); + _videoPlayer->onPlayEvent((int)VideoPlayer::EventType::PLAYING); break; case MPMoviePlaybackStateInterrupted: break; @@ -449,9 +449,9 @@ void VideoPlayer::addEventListener(const VideoPlayer::ccVideoPlayerCallback& cal _eventCallback = callback; } -void VideoPlayer::onPlayEvent(VideoPlayer::EventType event) +void VideoPlayer::onPlayEvent(int event) { - if (event == VideoPlayer::EventType::PLAYING) { + if (event == (int)VideoPlayer::EventType::PLAYING) { _isPlaying = true; } else { _isPlaying = false; @@ -459,7 +459,7 @@ void VideoPlayer::onPlayEvent(VideoPlayer::EventType event) if (_eventCallback) { - _eventCallback(this,event); + _eventCallback(this, (VideoPlayer::EventType)event); } } diff --git a/cocos/ui/UIWidget.h b/cocos/ui/UIWidget.h index 935d6f8628..8ea40cc9d5 100644 --- a/cocos/ui/UIWidget.h +++ b/cocos/ui/UIWidget.h @@ -169,7 +169,7 @@ public: * * @see BrightStyle * - * @param style BRIGHT_NORMAL the widget is normal state, BRIGHT_HIGHLIGHT the widget is height light state. + * @param style BrightStyle::NORMAL means the widget is in normal state, BrightStyle::HIGHLIGHT means the widget is in highlight state. */ void setBrightStyle(BrightStyle style); @@ -197,7 +197,7 @@ public: void setHighlighted(bool hilight); /** - * Gets the left boundary position of this widget. + * Gets the left boundary position of this widget in parent's coordination system. * * @return The left boundary position of this widget. */ @@ -205,7 +205,7 @@ public: float getLeftBoundary() const; /** - * Gets the bottom boundary position of this widget. + * Gets the bottom boundary position of this widget in parent's coordination system. * * @return The bottom boundary position of this widget. */ @@ -213,7 +213,7 @@ public: float getBottomBoundary() const; /** - * Gets the right boundary position of this widget. + * Gets the right boundary position of this widget in parent's coordination system. * * @return The right boundary position of this widget. */ @@ -221,7 +221,7 @@ public: float getRightBoundary() const; /** - * Gets the top boundary position of this widget. + * Gets the top boundary position of this widget in parent's coordination system. * * @return The top boundary position of this widget. */ @@ -236,7 +236,6 @@ public: CC_DEPRECATED_ATTRIBUTE void addTouchEventListener(Ref* target,SEL_TouchEvent selector); void addTouchEventListener(ccWidgetTouchCallback callback); - //cocos2d property /** * Changes the position (x,y) of the widget in OpenGL coordinates @@ -249,10 +248,7 @@ public: virtual void setPosition(const Vec2 &pos) override; /** - * Changes the position (x,y) of the widget in OpenGL coordinates - * - * Usually we use p(x,y) to compose Vec2 object. - * The original point (0,0) is at the left-bottom corner of screen. + * Set the percent(x,y) of the widget in OpenGL coordinates * * @param percent The percent (x,y) of the widget in OpenGL coordinates */ @@ -456,16 +452,18 @@ public: /** - * Ignore the widget size * - * @param ignore, true that widget will ignore it's size, use texture size, false otherwise. Default value is true. + * Note: when you set _ignoreSize to true, no matther you call setContentSize or not, + * the widget size is always equal to the return value of the member function getVirtualRendererSize. + * + * @param ignore, set member variabl _ignoreSize to ignore */ virtual void ignoreContentAdaptWithSize(bool ignore); /** - * Gets the widget if is ignore it's size. + * Query whether the widget ignores user deinfed content size or not * - * @param ignore, true that widget will ignore it's size, use texture size, false otherwise. Default value is true. + * @return bool */ bool isIgnoreContentAdaptWithSize() const; @@ -485,15 +483,9 @@ public: */ virtual Node* getVirtualRenderer(); -// /** -// * Gets the content size of widget. -// * -// * Content size is widget's texture size. -// */ -// virtual const Size& getContentSize() const; + virtual const Size& getVirtualRendererSize() const; - /** * Returns the "class name" of widget. @@ -644,19 +636,19 @@ protected: void cleanupWidget(); protected: - bool _enabled; ///< Highest control of widget - bool _bright; ///< is this widget bright - bool _touchEnabled; ///< is this widget touch endabled - bool _highlight; ///< is the widget on focus + bool _enabled; + bool _bright; + bool _touchEnabled; + bool _highlight; bool _reorderWidgetChildDirty; bool _affectByClipping; bool _ignoreSize; - BrightStyle _brightStyle; ///< bright style + BrightStyle _brightStyle; SizeType _sizeType; PositionType _positionType; - //use + //used for search widget by action tag in UIHelper class int _actionTag; Size _customSize; @@ -666,9 +658,9 @@ protected: bool _hitted; EventListenerTouchOneByOne* _touchListener; - Vec2 _touchBeganPosition; ///< touch began point - Vec2 _touchMovePosition; ///< touch moved point - Vec2 _touchEndPosition; ///< touch ended point + Vec2 _touchBeganPosition; + Vec2 _touchMovePosition; + Vec2 _touchEndPosition; bool _flippedX; bool _flippedY; @@ -684,7 +676,6 @@ protected: */ static Widget *_focusedWidget; //both layout & widget will be stored in this variable - //if use the old API, we must retain the _touchEventListener Ref* _touchEventListener; #if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) #pragma GCC diagnostic ignored "-Wdeprecated-declarations" diff --git a/docs/RELEASE_NOTES.md b/docs/RELEASE_NOTES.md index 0ebf4815cd..48060de875 100644 --- a/docs/RELEASE_NOTES.md +++ b/docs/RELEASE_NOTES.md @@ -1,8 +1,8 @@ -# cocos2d-x v3.2rc0 Release Notes # +# cocos2d-x v3.2 Release Notes # **Table of Contents** *generated with [DocToc](http://doctoc.herokuapp.com/)* -- [cocos2d-x v3.2rc0 Release Notes](#user-content-cocos2d-x-v32rc0-release-notes) +- [cocos2d-x v3.2 Release Notes](#user-content-cocos2d-x-v32-release-notes) - [Misc Information](#user-content-misc-information) - [Requirements](#user-content-requirements) - [Runtime Requirements](#user-content-runtime-requirements) @@ -13,21 +13,24 @@ - [Windows](#user-content-windows) - [Linux](#user-content-linux) - [How to start a new game](#user-content-how-to-start-a-new-game) -- [Highlights of v3.2rc0](#user-content-highlights-of-v32rc0) +- [Highlights of v3.2](#user-content-highlights-of-v32) +- [Documents](#user-content-documents) - [Toolchain requirement changed](#user-content-toolchain-requirement-changed) +- [atof issue on Android](#user-content-atof-issue-on-android) - [Features in detail](#user-content-features-in-detail) - - [Sprite3d](#user-content-sprite3d) + - [Sprite3D & Animation3D](#user-content-sprite3d--animation3d) - [fbx-conv usage](#user-content-fbx-conv-usage) - - [Controller support](#user-content-controller-support) + - [Game controller](#user-content-game-controller) - [Fast tilemap](#user-content-fast-tilemap) - [Node::enumerateChildren](#user-content-nodeenumeratechildren) - [utils::findChildren](#user-content-utilsfindchildren) + - [Node::setNormalizedPosition](#user-content-nodesetnormalizedposition) # Misc Information -* Download: http://cdn.cocos2d-x.org/cocos2d-x-3.2rc0.zip -* Full Changelog: https://github.com/cocos2d/cocos2d-x/blob/cocos2d-x-3.2rc0/CHANGELOG -* API Reference: http://www.cocos2d-x.org/reference/native-cpp/V3.2rc0/index.html +* Download: http://cdn.cocos2d-x.org/cocos2d-x-3.2.zip +* Full Changelog: https://github.com/cocos2d/cocos2d-x/blob/cocos2d-x-3.2/CHANGELOG +* API Reference: http://www.cocos2d-x.org/reference/native-cpp/V3.2/index.html * v3.0 Release Notes can be found here: [v3.0 Release Notes](https://github.com/cocos2d/cocos2d-x/blob/cocos2d-x-3.0/docs/RELEASE_NOTES.md) # Requirements @@ -44,7 +47,7 @@ ## Compiler Requirements -* Xcode 4.6 or newer for iOS or Mac +* Xcode 5.1 or newer for iOS or Mac * gcc 4.9 or newer for Linux * ndk-r9d or newer for Android * Visual Studio 2012 or newer for Windows (win32) @@ -114,33 +117,63 @@ Run Please refer to this document: [ReadMe](../README.md) -# Highlights of v3.2rc0 +# Highlights of v3.2 -* `fbx-conv` support generating binary format, and `Sprite3D` support it -* about 20% performance improved in `Sprite3D` -* game controller support -* fast tilemap support, it is faster for static tilemap -* physics body supports scale and rotation -* added Node::enumearteChildren(), and support c++ 11 regular expression +* `Animation3D`/`Animate3D`, new nodes for 3d animation +* `fbx-conv` supports generating binary format which is supported by `Sprite3D` +* Game controller support +* Fast tilemap support +* Added `utils::cpatureScreen` to take screenshot +* Physics body supports scale and rotation +* Added `Node::enumerateChildren` and `utils::findChildren`, and support c++ 11 regular expression +* Added `Node::setNormalizedPosition`, `Node`'s position in pixel will be calculated according its parent's content size + +# Documents + +* [Sprite3D & Animation3D](http://cocos2d-x.org/wiki/Sprite3D) +* [Game controller](http://www.cocos2d-x.org/wiki/Game_Controller) +* [How to compile shader on WP8](http://cocos2d-x.org/wiki/How_to_update_wp8_shader) # Toolchain requirement changed -`Node::enumerateChildren()` uses `std::regex` which will cause crash using gcc v4.8 or lower version. So +`Node::enumerateChildren()` uses `std::regex` which will cause crash using gcc v4.8 or lower version. +Because `OTHER_LDFLAGS` can not work in Xcode6 beta3. So we used fat library(including 64-bit libaries) on iOS. But Xcode 5.0 or lower version has building problem by this way. + +So * NDK r9d or newer version is required for Android building * gcc 4.9 is required for linux building +* Xcode 5.1 or newer is required on iOS +# atof issue on Android + +We found a bug of `atof` on Android when using libc++. The bug is that, the return value of `atof` may be `-inf` when passing some valid digit string. + +For example + +```c++ +atof("90.099998474121094"); // -> return value is -inf +``` + +We have reported it to google guys, and they confirmed that it is a bug. In order to work around this issue, we added `utils::atof()`. + +The corresponding pull request for this issue is [here](https://github.com/cocos2d/cocos2d-x/pull/7440). You can refer to this pull request for demail information. # Features in detail -## Sprite3d +## Sprite3D & Animation3D Sample code to use binary version ```c++ auto sprite3d = Sprite3D::create("filename.c3b"); addChild(sprite3d); + +auto animation3d = Animation3D("filename.c3b"); +auto animate3d = Animate3D::create(animation3d); +sprite3d->runAction(RepeatForEver::create(animate)); ``` +Detail information please refer to [Sprite3D & Animation3D](http://cocos2d-x.org/wiki/Sprite3D). ### `fbx-conv` usage @@ -164,19 +197,43 @@ Options: * -b: export binary format * -t: export text format -## Controller support +## Game controller Supported controller type: -* amazon tv +* Android standard controllers +* Amazon tv * OUYA * Moga * Nibiru * iOS standard controllers -In order to use controller on Android, you should refer to this Android project(`COCOS2DX_ROOT/cocos/platform/android/ControllerManualAdapter`). +Sample codes +```c++ +// register event listener +auto listener = EventListenerController::create(); +listner->onKeyDown = ... +... +eventDispatcher->addEventListenerWithSceneGraphPriority(listener, this); -Full demo please refer to `COCOS2DX_ROOT/tests/game-controler-test`. +// start connecting controller +Controller::startDiscoveryController(); + +// handler key down/ key up event +void GameControllerTest::onKeyDown(Controller *controller, int keyCode, Event *event) +{ + switch (keyCode) + { + case Controller::Key::BUTTON_A: + ... + break; + + ... + } +} +``` + +Detail information please refer to [Game controller](http://www.cocos2d-x.org/wiki/Game_Controller). ## Fast tilemap @@ -184,7 +241,7 @@ Fast tilemap has the same API as `TMXTiledMap` without deprecated functions. Sample code ```c++ -auto tilemap = FastTMXTiledMap::create("MyFile.tmx"); +auto tilemap = cocos2d::experimental::TMXTiledMap::create("MyFile.tmx"); addChild(tilemap); ``` @@ -192,7 +249,7 @@ Full demo please refer to `COCOS2DX_ROOT/tests/cpp-tests/Classes/TileMapTest/Til ## Node::enumerateChildren -This functions is used to enumerate children of a `Node` recursively. It supports c++ 11 regular expression. +This functions is used to enumerate children of a `Node`. It supports c++ 11 regular expression. ```c++ // Find nodes whose name is 'nameToFind' and end with digits. @@ -200,6 +257,12 @@ node->enumerateChildren("nameToFind[[:digit:]]+", [](Node* node) -> bool { ... return false; // return true to stop at first match }); + +// Find nodes whose name is 'nameToFind' and end with digits recursively. +node->enumerateChildren("nameToFind[[:digit:]]+", [](Node* node) -> bool { + ... + return false; // return true to stop at first match +}); ``` Full test please refer to `NodeNameTest` in `COCOS2DX_ROOT/tests/cpp-tests/NodeTest/NodeTest.cpp`. @@ -215,3 +278,18 @@ auto children = utils::findChildren(node, "nameToFind"); ... ``` + +## Node::setNormalizedPosition + +Can use this function to set Node's position(x,y) using value between 0 and 1. `Can use this function when it has a parent node.` The positions in pixels is calculated like the following: + +```c++ +// pseudo code +void setNormalizedPosition(Vec2 pos) +{ + Size s = getParent()->getContentSize(); + _position = pos * s; +} +``` + +Full test please refer to `NodeNormalizedPositionTest1/2` in `tests/cpp-tests/Classes/NodeTest/NodeTest.cpp`. diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm b/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm index fbeed2ee37..8ca0fd5d25 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm +++ b/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm @@ -404,11 +404,15 @@ void EditBoxImplMac::setText(const char* pText) { NSString *string = [NSString stringWithUTF8String:pText]; _sysEdit.textField.stringValue = string; - _sysEdit.textField.stringValue = string; + _sysEdit.secureTextField.stringValue = string; } const char* EditBoxImplMac::getText(void) { + if (_sysEdit.secureTextField.superview) { + return [_sysEdit.secureTextField.stringValue UTF8String]; + } + return [_sysEdit.textField.stringValue UTF8String]; } diff --git a/extensions/GUI/CCScrollView/CCScrollView.h b/extensions/GUI/CCScrollView/CCScrollView.h index d26c9240e0..2f4c224418 100644 --- a/extensions/GUI/CCScrollView/CCScrollView.h +++ b/extensions/GUI/CCScrollView/CCScrollView.h @@ -52,12 +52,12 @@ public: * @js NA * @lua NA */ - virtual void scrollViewDidScroll(ScrollView* view) = 0; + virtual void scrollViewDidScroll(ScrollView* view) {}; /** * @js NA * @lua NA */ - virtual void scrollViewDidZoom(ScrollView* view) = 0; + virtual void scrollViewDidZoom(ScrollView* view) {}; }; diff --git a/external/config.json b/external/config.json index 69d401fe6e..4fd1120e81 100644 --- a/external/config.json +++ b/external/config.json @@ -1,5 +1,5 @@ { - "version":"v3-deps-4", + "version":"v3-deps-5", "zip_file_size":"57171285", "repo_name":"cocos2d-x-3rd-party-libs-bin", "repo_parent":"https://github.com/cocos2d/" diff --git a/plugin b/plugin index 51ceded726..8d1888ac8f 160000 --- a/plugin +++ b/plugin @@ -1 +1 @@ -Subproject commit 51ceded726cc034cdc939e379e1b24249e0ebad4 +Subproject commit 8d1888ac8f2846a67094905b7f362f746ae5a31f diff --git a/setup.py b/setup.py index 49f67ba7ff..e5fec47e9f 100755 --- a/setup.py +++ b/setup.py @@ -98,7 +98,11 @@ class SetEnvVar(object): return sys.platform == 'darwin' def _is_zsh(self): - return os.environ.get('SHELL')[-3:] == "zsh" + shellItem = os.environ.get('SHELL') + if shellItem is not None: + if len(shellItem) >= 3: + return shellItem[-3:] == "zsh" + return False def _get_unix_file_list(self): file_list = None @@ -553,7 +557,7 @@ class SetEnvVar(object): if ret is not None: print(" ->Path " + ret + " was found\n") else: - print(" ->Command " + ret + " not found\n") + print(" ->Command " + cmd + " not found\n") return ret def _find_value_from_sys(self, var_name): diff --git a/templates/cocos2dx_files.json b/templates/cocos2dx_files.json index d34076a41e..5859854630 100644 --- a/templates/cocos2dx_files.json +++ b/templates/cocos2dx_files.json @@ -1323,7 +1323,6 @@ "external/curl/prebuilt/android/armeabi/libcurl.a", "external/curl/prebuilt/android/x86/libcurl.a", "external/curl/prebuilt/ios/libcurl.a", - "external/curl/prebuilt/ios/libcurl_arm64.a", "external/curl/prebuilt/win32/libcurl.dll", "external/curl/prebuilt/win32/libcurl_imp.lib", "external/curl/prebuilt/wp8/arm/libcurl.dll", @@ -1923,7 +1922,6 @@ "external/freetype2/prebuilt/android/armeabi/libfreetype.a", "external/freetype2/prebuilt/android/x86/libfreetype.a", "external/freetype2/prebuilt/ios/libfreetype.a", - "external/freetype2/prebuilt/ios/libfreetype_arm64.a", "external/freetype2/prebuilt/linux/32-bit/libfreetype.a", "external/freetype2/prebuilt/linux/64-bit/libfreetype.a", "external/freetype2/prebuilt/mac/libfreetype.a", @@ -1978,7 +1976,6 @@ "external/jpeg/prebuilt/android/armeabi/libjpeg.a", "external/jpeg/prebuilt/android/x86/libjpeg.a", "external/jpeg/prebuilt/ios/libjpeg.a", - "external/jpeg/prebuilt/ios/libjpeg_arm64.a", "external/jpeg/prebuilt/linux/32-bit/libjpeg.a", "external/jpeg/prebuilt/linux/64-bit/libjpeg.a", "external/jpeg/prebuilt/mac/libjpeg.a", @@ -2055,7 +2052,6 @@ "external/png/prebuilt/android/armeabi/libpng.a", "external/png/prebuilt/android/x86/libpng.a", "external/png/prebuilt/ios/libpng.a", - "external/png/prebuilt/ios/libpng_arm64.a", "external/png/prebuilt/mac/libpng.a", "external/png/prebuilt/win32/libpng.lib", "external/png/prebuilt/winrt/ARM/libpng.lib", @@ -2108,7 +2104,6 @@ "external/tiff/prebuilt/android/armeabi/libtiff.a", "external/tiff/prebuilt/android/x86/libtiff.a", "external/tiff/prebuilt/ios/libtiff.a", - "external/tiff/prebuilt/ios/libtiff_arm64.a", "external/tiff/prebuilt/linux/32-bit/libtiff.a", "external/tiff/prebuilt/linux/64-bit/libtiff.a", "external/tiff/prebuilt/mac/libtiff.a", @@ -2147,7 +2142,6 @@ "external/webp/prebuilt/android/armeabi/libwebp.a", "external/webp/prebuilt/android/x86/libwebp.a", "external/webp/prebuilt/ios/libwebp.a", - "external/webp/prebuilt/ios/libwebp_arm64.a", "external/webp/prebuilt/linux/32-bit/libwebp.a", "external/webp/prebuilt/linux/64-bit/libwebp.a", "external/webp/prebuilt/mac/libwebp.a", @@ -2177,7 +2171,6 @@ "external/websockets/prebuilt/android/armeabi/libwebsockets.a", "external/websockets/prebuilt/android/x86/libwebsockets.a", "external/websockets/prebuilt/ios/libwebsockets.a", - "external/websockets/prebuilt/ios/libwebsockets_arm64.a", "external/websockets/prebuilt/linux/32-bit/libwebsockets.a", "external/websockets/prebuilt/linux/64-bit/libwebsockets.a", "external/websockets/prebuilt/mac/libwebsockets.a", @@ -3705,8 +3698,6 @@ "cocos/scripting/lua-bindings/auto/api/FadeOutTRTiles.lua", "cocos/scripting/lua-bindings/auto/api/FadeOutUpTiles.lua", "cocos/scripting/lua-bindings/auto/api/FadeTo.lua", - "cocos/scripting/lua-bindings/auto/api/FastTMXLayer.lua", - "cocos/scripting/lua-bindings/auto/api/FastTMXTiledMap.lua", "cocos/scripting/lua-bindings/auto/api/FileUtils.lua", "cocos/scripting/lua-bindings/auto/api/FiniteTimeAction.lua", "cocos/scripting/lua-bindings/auto/api/FlipX.lua", @@ -3944,6 +3935,7 @@ "cocos/scripting/lua-bindings/auto/api/ZOrderFrame.lua", "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_auto_api.lua", "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_controller_auto_api.lua", + "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_auto_api.lua", "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_experimental_video_auto_api.lua", "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_extension_auto_api.lua", "cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_physics_auto_api.lua", @@ -3954,6 +3946,8 @@ "cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp", "cocos/scripting/lua-bindings/auto/lua_cocos2dx_controller_auto.cpp", "cocos/scripting/lua-bindings/auto/lua_cocos2dx_controller_auto.hpp", + "cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.cpp", + "cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_auto.hpp", "cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.cpp", "cocos/scripting/lua-bindings/auto/lua_cocos2dx_experimental_video_auto.hpp", "cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.cpp", @@ -3994,6 +3988,8 @@ "cocos/scripting/lua-bindings/manual/lua_cocos2dx_controller_manual.hpp", "cocos/scripting/lua-bindings/manual/lua_cocos2dx_deprecated.cpp", "cocos/scripting/lua-bindings/manual/lua_cocos2dx_deprecated.h", + "cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.cpp", + "cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_manual.hpp", "cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.cpp", "cocos/scripting/lua-bindings/manual/lua_cocos2dx_experimental_video_manual.hpp", "cocos/scripting/lua-bindings/manual/lua_cocos2dx_extension_manual.cpp", @@ -4038,6 +4034,7 @@ "cocos/scripting/lua-bindings/script/Opengl.lua", "cocos/scripting/lua-bindings/script/OpenglConstants.lua", "cocos/scripting/lua-bindings/script/StudioConstants.lua", + "cocos/scripting/lua-bindings/script/bitExtend.lua", "cocos/scripting/lua-bindings/script/experimentalConstants.lua", "cocos/scripting/lua-bindings/script/extern.lua", "cocos/scripting/lua-bindings/script/json.lua", @@ -4424,6 +4421,7 @@ "tools/tolua/README.mdown", "tools/tolua/cocos2dx.ini", "tools/tolua/cocos2dx_controller.ini", + "tools/tolua/cocos2dx_experimental.ini", "tools/tolua/cocos2dx_experimental_video.ini", "tools/tolua/cocos2dx_extension.ini", "tools/tolua/cocos2dx_physics.ini", diff --git a/templates/cpp-template-default/CMakeLists.txt b/templates/cpp-template-default/CMakeLists.txt index 8a79be8465..cfc1fb578e 100644 --- a/templates/cpp-template-default/CMakeLists.txt +++ b/templates/cpp-template-default/CMakeLists.txt @@ -127,6 +127,7 @@ link_directories( elseif(UNIX) #assumed linux include_directories( /usr/local/include/GLFW + /usr/include/GLFW ${COCOS2D_ROOT} ${COCOS2D_ROOT}/cocos ${COCOS2D_ROOT}/cocos/audio/include diff --git a/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj b/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj index 20dc740a62..15fe6d6f6b 100644 --- a/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj +++ b/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj @@ -941,6 +941,7 @@ "$(SRCROOT)/../cocos2d/external", "$(SRCROOT)/../cocos2d/external/chipmunk/include/chipmunk", ); + MACOSX_DEPLOYMENT_TARGET = 10.7; ONLY_ACTIVE_ARCH = YES; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; @@ -969,6 +970,7 @@ "$(SRCROOT)/../cocos2d/external", "$(SRCROOT)/../cocos2d/external/chipmunk/include/chipmunk", ); + MACOSX_DEPLOYMENT_TARGET = 10.7; OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; diff --git a/templates/cpp-template-default/proj.wp8-xaml/AppComponent/src/Cocos2dRenderer.cpp b/templates/cpp-template-default/proj.wp8-xaml/AppComponent/src/Cocos2dRenderer.cpp index 608a524861..4e74c6f298 100644 --- a/templates/cpp-template-default/proj.wp8-xaml/AppComponent/src/Cocos2dRenderer.cpp +++ b/templates/cpp-template-default/proj.wp8-xaml/AppComponent/src/Cocos2dRenderer.cpp @@ -67,8 +67,8 @@ void Cocos2dRenderer::CreateGLResources() cocos2d::ShaderCache::getInstance()->reloadDefaultGLPrograms(); cocos2d::DrawPrimitives::init(); cocos2d::VolatileTextureMgr::reloadAllTextures(); - cocos2d::EventCustom foregroundEvent(EVENT_COME_TO_FOREGROUND); - director->getEventDispatcher()->dispatchEvent(&foregroundEvent); + cocos2d::EventCustom recreatedEvent(EVENT_RENDERER_RECREATED); + director->getEventDispatcher()->dispatchEvent(&recreatedEvent); cocos2d::Application::getInstance()->applicationWillEnterForeground(); director->setGLDefaultValues(); } diff --git a/templates/lua-template-runtime/.settings/version.json b/templates/lua-template-runtime/.settings/version.json index 5f06abfbad..62ee19a364 100644 --- a/templates/lua-template-runtime/.settings/version.json +++ b/templates/lua-template-runtime/.settings/version.json @@ -1,4 +1,4 @@ { - "templateVersion":"1.2", - "runtimeVersion":"1.2" + "templateVersion":"1.3", + "runtimeVersion":"1.3" } \ No newline at end of file diff --git a/templates/lua-template-runtime/config.json b/templates/lua-template-runtime/config.json index 09215954df..c88d6cf401 100644 --- a/templates/lua-template-runtime/config.json +++ b/templates/lua-template-runtime/config.json @@ -4,7 +4,8 @@ "name": "HelloLua", "width": 960, "height": 640, - "entry": "src/main.lua" + "entry": "src/main.lua", + "consolePort": 6010 }, "simulator_screen_size": [ { diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp b/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp index 1b2efff673..515cfdc6b0 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp @@ -46,9 +46,7 @@ bool AppDelegate::applicationDidFinishLaunching() #endif } - // turn on display FPS - director->setDisplayStats(true); - + // set FPS. the default value is 1.0/60 if you don't call this director->setAnimationInterval(1.0 / 60); diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.cpp b/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.cpp index 9054ac4ca8..9e5381a07a 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.cpp +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.cpp @@ -24,6 +24,7 @@ bool ConfigParser::isInit() void ConfigParser::readConfig() { _isInit = true; + _consolePort = 6010; string filecfg = "config.json"; string fileContent; @@ -69,6 +70,9 @@ void ConfigParser::readConfig() if (objectInitView.HasMember("entry") && objectInitView["entry"].IsString()) { _entryfile = objectInitView["entry"].GetString(); } + if (objectInitView.HasMember("consolePort")){ + _consolePort = objectInitView["consolePort"].GetUint(); + } } } if (_docRootjson.HasMember("simulator_screen_size")) @@ -123,6 +127,10 @@ bool ConfigParser::isLanscape() return _isLandscape; } +int ConfigParser::getConsolePort() +{ + return _consolePort; +} int ConfigParser::getScreenSizeCount(void) { return (int)_screenSizeArray.size(); diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.h b/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.h index 7b2f536bb6..adae188dd5 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.h +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/ConfigParser.h @@ -36,6 +36,7 @@ public: string getEntryFile(); rapidjson::Document& getConfigJsonRoot(); const SimulatorScreenSize getScreenSize(int index); + int getConsolePort(); bool isLanscape(); bool isInit(); @@ -48,6 +49,7 @@ private: string _entryfile; bool _isLandscape; bool _isInit; + int _consolePort; rapidjson::Document _docRootjson; }; diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/protobuf-lite/google/protobuf/stubs/atomicops_internals_x86_gcc.cc b/templates/lua-template-runtime/frameworks/runtime-src/Classes/protobuf-lite/google/protobuf/stubs/atomicops_internals_x86_gcc.cc new file mode 100644 index 0000000000..07748723f6 --- /dev/null +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/protobuf-lite/google/protobuf/stubs/atomicops_internals_x86_gcc.cc @@ -0,0 +1,137 @@ +// Protocol Buffers - Google's data interchange format +// Copyright 2012 Google Inc. All rights reserved. +// http://code.google.com/p/protobuf/ +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +// This module gets enough CPU information to optimize the +// atomicops module on x86. + +#include + +#include + +// This file only makes sense with atomicops_internals_x86_gcc.h -- it +// depends on structs that are defined in that file. If atomicops.h +// doesn't sub-include that file, then we aren't needed, and shouldn't +// try to do anything. +#ifdef GOOGLE_PROTOBUF_ATOMICOPS_INTERNALS_X86_GCC_H_ + +// Inline cpuid instruction. In PIC compilations, %ebx contains the address +// of the global offset table. To avoid breaking such executables, this code +// must preserve that register's value across cpuid instructions. +#if defined(__i386__) +#define cpuid(a, b, c, d, inp) \ + asm("mov %%ebx, %%edi\n" \ + "cpuid\n" \ + "xchg %%edi, %%ebx\n" \ + : "=a" (a), "=D" (b), "=c" (c), "=d" (d) : "a" (inp)) +#elif defined(__x86_64__) +#define cpuid(a, b, c, d, inp) \ + asm("mov %%rbx, %%rdi\n" \ + "cpuid\n" \ + "xchg %%rdi, %%rbx\n" \ + : "=a" (a), "=D" (b), "=c" (c), "=d" (d) : "a" (inp)) +#endif + +#if defined(cpuid) // initialize the struct only on x86 + +namespace google { +namespace protobuf { +namespace internal { + +// Set the flags so that code will run correctly and conservatively, so even +// if we haven't been initialized yet, we're probably single threaded, and our +// default values should hopefully be pretty safe. +struct AtomicOps_x86CPUFeatureStruct AtomicOps_Internalx86CPUFeatures = { + false, // bug can't exist before process spawns multiple threads + false, // no SSE2 +}; + +namespace { + +// Initialize the AtomicOps_Internalx86CPUFeatures struct. +void AtomicOps_Internalx86CPUFeaturesInit() { + uint32_t eax; + uint32_t ebx; + uint32_t ecx; + uint32_t edx; + + // Get vendor string (issue CPUID with eax = 0) + cpuid(eax, ebx, ecx, edx, 0); + char vendor[13]; + memcpy(vendor, &ebx, 4); + memcpy(vendor + 4, &edx, 4); + memcpy(vendor + 8, &ecx, 4); + vendor[12] = 0; + + // get feature flags in ecx/edx, and family/model in eax + cpuid(eax, ebx, ecx, edx, 1); + + int family = (eax >> 8) & 0xf; // family and model fields + int model = (eax >> 4) & 0xf; + if (family == 0xf) { // use extended family and model fields + family += (eax >> 20) & 0xff; + model += ((eax >> 16) & 0xf) << 4; + } + + // Opteron Rev E has a bug in which on very rare occasions a locked + // instruction doesn't act as a read-acquire barrier if followed by a + // non-locked read-modify-write instruction. Rev F has this bug in + // pre-release versions, but not in versions released to customers, + // so we test only for Rev E, which is family 15, model 32..63 inclusive. + if (strcmp(vendor, "AuthenticAMD") == 0 && // AMD + family == 15 && + 32 <= model && model <= 63) { + AtomicOps_Internalx86CPUFeatures.has_amd_lock_mb_bug = true; + } else { + AtomicOps_Internalx86CPUFeatures.has_amd_lock_mb_bug = false; + } + + // edx bit 26 is SSE2 which we use to tell use whether we can use mfence + AtomicOps_Internalx86CPUFeatures.has_sse2 = ((edx >> 26) & 1); +} + +class AtomicOpsx86Initializer { + public: + AtomicOpsx86Initializer() { + AtomicOps_Internalx86CPUFeaturesInit(); + } +}; + +// A global to get use initialized on startup via static initialization :/ +AtomicOpsx86Initializer g_initer; + +} // namespace + +} // namespace internal +} // namespace protobuf +} // namespace google + +#endif // __i386__ + +#endif // GOOGLE_PROTOBUF_ATOMICOPS_INTERNALS_X86_GCC_H_ diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.cpp b/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.cpp index 1dddcd2832..07bb6906bb 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.cpp +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.cpp @@ -35,6 +35,7 @@ THE SOFTWARE. #include "ConfigParser.h" #include "Protos.pb.h" #include "zlib.h" +#include "lua.h" #ifdef _WIN32 #include @@ -49,7 +50,7 @@ using namespace std; using namespace cocos2d; std::string g_resourcePath; -extern string getIPAddress(); + //1M size #define MAXPROTOLENGTH 1048576 @@ -60,11 +61,81 @@ extern string getIPAddress(); #define usleep(t) usleep(t) #endif +extern string getIPAddress(); const char* getRuntimeVersion() { - return "1.2"; + return "1.3"; } +static string& replaceAll(string& str,const string& old_value,const string& new_value) +{ + while(true) + { + int pos=0; + if((pos=str.find(old_value,0))!=string::npos) + str.replace(pos,old_value.length(),new_value); + else break; + } + return str; +} +static bool resetLuaModule(string fileName) +{ + if (fileName.empty()) + { + CCLOG("fileName is null"); + return false; + } + auto engine = LuaEngine::getInstance(); + LuaStack* luaStack = engine->getLuaStack(); + lua_State* stack=luaStack->getLuaState(); + lua_getglobal(stack, "package"); /* L: package */ + lua_getfield(stack, -1, "loaded"); /* L: package loaded */ + lua_pushnil(stack); /* L: lotable ?-.. nil */ + while ( 0 != lua_next(stack, -2 ) ) /* L: lotable ?-.. key value */ + { + //CCLOG("%s - %s \n", tolua_tostring(stack, -2, ""), lua_typename(stack, lua_type(stack, -1))); + std::string key=tolua_tostring(stack, -2, ""); + std::string tableKey =key; + int found = tableKey.rfind(".lua"); + if (found!=std::string::npos) + tableKey = tableKey.substr(0,found); + tableKey=replaceAll(tableKey,".","/"); + tableKey=replaceAll(tableKey,"\\","/"); + tableKey.append(".lua"); + found = fileName.rfind(tableKey); + if (0 == found || ( found!=std::string::npos && fileName.at(found-1) == '/')) + { + lua_pushstring(stack, key.c_str()); + lua_pushnil(stack); + if (lua_istable(stack, -5)) + { + lua_settable(stack, -5); + } + } + lua_pop(stack, 1); + } + lua_pop(stack, 2); + return true; +} +bool reloadScript(string modulefile) +{ + auto director = Director::getInstance(); + FontFNT::purgeCachedData(); + if (director->getOpenGLView()) + { + SpriteFrameCache::getInstance()->removeSpriteFrames(); + director->getTextureCache()->removeAllTextures(); + } + FileUtils::getInstance()->purgeCachedEntries(); + if (!resetLuaModule(modulefile)) + { + modulefile = ConfigParser::getInstance()->getEntryFile().c_str(); + } + auto engine = LuaEngine::getInstance(); + LuaStack* luaStack = engine->getLuaStack(); + std::string require = "require \'" + modulefile + "\'"; + return luaStack->executeString(require.c_str()); +} void startScript(string strDebugArg) { // register lua engine @@ -77,28 +148,8 @@ void startScript(string strDebugArg) engine->executeScriptFile(ConfigParser::getInstance()->getEntryFile().c_str()); } -bool reloadScript(const string& modulefile) -{ - string strfile = modulefile; - if (strfile.empty()) - { - strfile = ConfigParser::getInstance()->getEntryFile().c_str(); - } - auto director = Director::getInstance(); - FontFNT::purgeCachedData(); - if (director->getOpenGLView()) - { - SpriteFrameCache::getInstance()->removeSpriteFrames(); - director->getTextureCache()->removeAllTextures(); - } - FileUtils::getInstance()->purgeCachedEntries(); - - director->getScheduler()->unscheduleAll(); - director->getScheduler()->scheduleUpdate(director->getActionManager(), Scheduler::PRIORITY_SYSTEM, false); - - return (LuaEngine::getInstance()->reload(strfile.c_str())==0); -} + #if defined(_MSC_VER) || defined(__MINGW32__) #include @@ -231,7 +282,7 @@ void FileServer::readResFileFinfo() if (!pFile) return ; fwrite(str,sizeof(char),strlen(str),pFile); fclose(pFile); - },this, 10.0f, false, "fileinfo"); + },this, 5.0f, false, "fileinfo"); } void FileServer::addResFileInfo(const char* filename,uint64_t u64) @@ -337,19 +388,8 @@ void FileServer::stop() } } -string& replaceAll(string& str,const string& old_value,const string& new_value) -{ - while(true) - { - int pos=0; - if((pos=str.find(old_value,0))!=string::npos) - str.replace(pos,old_value.length(),new_value); - else break; - } - return str; -} -bool CreateDir(const char *sPathName) +static bool CreateDir(const char *sPathName) { char DirName[256]={0}; strcpy(DirName, sPathName); @@ -382,7 +422,7 @@ bool CreateDir(const char *sPathName) return true; } -void recvBuf(int fd,char *pbuf,int bufsize) +static void recvBuf(int fd,char *pbuf,int bufsize) { int startFlagLen = bufsize; while (startFlagLen != 0){ @@ -447,7 +487,14 @@ void FileServer::loopReceiveFile() } } int contentSize = recvDataBuf.fileProto.content_size(); - if (contentSize>0){ + if (contentSize == 0) + { + recvDataBuf.contentBuf=""; + _recvBufListMutex.lock(); + _recvBufList.push_back(recvDataBuf); + _recvBufListMutex.unlock(); + }else if(contentSize>0) + { //recv body data Bytef *contentbuf= new Bytef[contentSize+1]; memset(contentbuf,0,contentSize+1); @@ -513,7 +560,7 @@ void FileServer::loopWriteFile() _fileNameMutex.lock(); _strFileName = filename; _fileNameMutex.unlock(); - cocos2d::log("WriteFile:: fullfilename = %s",filename.c_str()); + //cocos2d::log("WriteFile:: fullfilename = %s",filename.c_str()); CreateDir(fullfilename.substr(0,fullfilename.find_last_of("/")).c_str()); FILE *fp= nullptr; @@ -531,7 +578,7 @@ void FileServer::loopWriteFile() continue; } if (fp){ - if (0 == fwrite(recvDataBuf.contentBuf.c_str(), sizeof(char), recvDataBuf.contentBuf.size(),fp)){ + if (recvDataBuf.contentBuf.size() > 0 && 0 == fwrite(recvDataBuf.contentBuf.c_str(), sizeof(char), recvDataBuf.contentBuf.size(),fp)){ addResponse(recvDataBuf.fd,filename,runtime::FileSendComplete::RESULTTYPE::FileSendComplete_RESULTTYPE_FWRITE_ERROR,errno); fclose(fp); continue; @@ -751,16 +798,23 @@ public: for (int i=0;i< sizeof(commands)/sizeof(Console::Command);i++) { _console->addCommand(commands[i]); } +#if(CC_PLATFORM_MAC == CC_TARGET_PLATFORM || CC_PLATFORM_WIN32 == CC_TARGET_PLATFORM) + _console->listenOnTCP(ConfigParser::getInstance()->getConsolePort()); +#else _console->listenOnTCP(6010); - +#endif + _fileserver = nullptr; +#if(CC_PLATFORM_MAC != CC_TARGET_PLATFORM && CC_PLATFORM_WIN32 != CC_TARGET_PLATFORM) _fileserver= FileServer::getShareInstance(); _fileserver->listenOnTCP(6020); _fileserver->readResFileFinfo(); +#endif } ~ConsoleCustomCommand() { Director::getInstance()->getConsole()->stop(); + if(_fileserver) _fileserver->stop(); } @@ -810,9 +864,11 @@ public: dReplyParse.AddMember("code",0,dReplyParse.GetAllocator()); }else if(strcmp(strcmd.c_str(),"getfileinfo")==0){ rapidjson::Value bodyvalue(rapidjson::kObjectType); - rapidjson::Document* filecfgjson = _fileserver->getFileCfgJson(); - for (auto it=filecfgjson->MemberonBegin();it!=filecfgjson->MemberonEnd();++it){ - bodyvalue.AddMember(it->name.GetString(),it->value.GetString(),dReplyParse.GetAllocator()); + if(_fileserver){ + rapidjson::Document* filecfgjson = _fileserver->getFileCfgJson(); + for (auto it=filecfgjson->MemberonBegin();it!=filecfgjson->MemberonEnd();++it){ + bodyvalue.AddMember(it->name.GetString(),it->value.GetString(),dReplyParse.GetAllocator()); + } } dReplyParse.AddMember("body",bodyvalue,dReplyParse.GetAllocator()); dReplyParse.AddMember("code",0,dReplyParse.GetAllocator()); @@ -1056,6 +1112,11 @@ bool initRuntime() searchPathArray.insert(searchPathArray.begin(),g_resourcePath); FileUtils::getInstance()->setSearchPaths(searchPathArray); + auto engine = LuaEngine::getInstance(); + ScriptEngineManager::getInstance()->setScriptEngine(engine); + LuaStack* stack = engine->getLuaStack(); + register_runtime_override_function(stack->getLuaState()); + luaopen_debugger(engine->getLuaStack()->getLuaState()); return true; } @@ -1075,16 +1136,13 @@ bool startRuntime() #endif #endif - static ConsoleCustomCommand s_customCommand; - s_customCommand.init(); - auto engine = LuaEngine::getInstance(); - ScriptEngineManager::getInstance()->setScriptEngine(engine); + // turn on display FPS + Director::getInstance()->setDisplayStats(true); - LuaStack* stack = engine->getLuaStack(); - register_runtime_override_function(stack->getLuaState()); - - luaopen_debugger(engine->getLuaStack()->getLuaState()); - + static ConsoleCustomCommand *g_customCommand; + g_customCommand = new ConsoleCustomCommand(); + g_customCommand->init(); + auto scene = Scene::create(); auto connectLayer = new ConnectWaitLayer(); connectLayer->autorelease(); diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.h b/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.h index 284c34942f..34d662924b 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.h +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/runtime/Runtime.h @@ -31,7 +31,7 @@ using namespace std; bool initRuntime(); bool startRuntime(); -bool reloadScript(const string& modulefile); +bool reloadScript(string modulefile); #endif // _RUNTIME__H_ diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.android/jni/Android.mk b/templates/lua-template-runtime/frameworks/runtime-src/proj.android/jni/Android.mk index d4ea0d1d11..c86a999470 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.android/jni/Android.mk +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.android/jni/Android.mk @@ -13,6 +13,7 @@ LOCAL_SRC_FILES := \ ../../Classes/protobuf-lite/google/protobuf/generated_message_util.cc \ ../../Classes/protobuf-lite/google/protobuf/message_lite.cc \ ../../Classes/protobuf-lite/google/protobuf/stubs/once.cc \ +../../Classes/protobuf-lite/google/protobuf/stubs/atomicops_internals_x86_gcc.cc \ ../../Classes/protobuf-lite/google/protobuf/repeated_field.cc \ ../../Classes/protobuf-lite/google/protobuf/wire_format_lite.cc \ ../../Classes/protobuf-lite/google/protobuf/io/zero_copy_stream.cc \ diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.android/src/org/cocos2dx/lua/AppActivity.java b/templates/lua-template-runtime/frameworks/runtime-src/proj.android/src/org/cocos2dx/lua/AppActivity.java index d4dd55873a..512805a1aa 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.android/src/org/cocos2dx/lua/AppActivity.java +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.android/src/org/cocos2dx/lua/AppActivity.java @@ -30,6 +30,7 @@ import java.net.InetAddress; import java.net.NetworkInterface; import java.net.SocketException; import java.util.Enumeration; +import java.util.ArrayList; import org.cocos2dx.lib.Cocos2dxActivity; @@ -48,6 +49,7 @@ import android.os.Environment; import android.provider.Settings; import android.text.format.Formatter; import android.util.Log; +import android.view.WindowManager; import android.widget.Toast; // The name of .so is specified in AndroidMenifest.xml. NativityActivity will load it automatically for you. @@ -72,7 +74,8 @@ public class AppActivity extends Cocos2dxActivity{ // Check the wifi is opened when the native is debug. if(nativeIsDebug()) { - if(!isWifiConnected()) + getWindow().setFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON, WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); + if(!isNetworkConnected()) { AlertDialog.Builder builder=new AlertDialog.Builder(this); builder.setTitle("Warning"); @@ -92,11 +95,20 @@ public class AppActivity extends Cocos2dxActivity{ } hostIPAdress = getHostIpAddress(); } - private boolean isWifiConnected() { + private boolean isNetworkConnected() { ConnectivityManager cm = (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE); if (cm != null) { NetworkInfo networkInfo = cm.getActiveNetworkInfo(); - if (networkInfo != null && networkInfo.getType() == ConnectivityManager.TYPE_WIFI) { + ArrayList networkTypes = new ArrayList(); + networkTypes.add(ConnectivityManager.TYPE_WIFI); + try { + networkTypes.add(ConnectivityManager.class.getDeclaredField("TYPE_ETHERNET").getInt(null)); + } catch (NoSuchFieldException nsfe) { + } + catch (IllegalAccessException iae) { + throw new RuntimeException(iae); + } + if (networkInfo != null && networkTypes.contains(networkInfo.getType())) { return true; } } diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/HelloLua.xcodeproj/project.pbxproj b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/HelloLua.xcodeproj/project.pbxproj index 7f79759d56..e3f1928ef5 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/HelloLua.xcodeproj/project.pbxproj +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/HelloLua.xcodeproj/project.pbxproj @@ -44,6 +44,7 @@ 3EB5156D1952865D006966AA /* stringprintf.cc in Sources */ = {isa = PBXBuildFile; fileRef = 3EB515511952865D006966AA /* stringprintf.cc */; }; 3EB5156E1952865D006966AA /* wire_format_lite.cc in Sources */ = {isa = PBXBuildFile; fileRef = 3EB515551952865D006966AA /* wire_format_lite.cc */; }; 3EB5156F1952865D006966AA /* wire_format_lite.cc in Sources */ = {isa = PBXBuildFile; fileRef = 3EB515551952865D006966AA /* wire_format_lite.cc */; }; + 3EEEDB61197107C0006A9FF8 /* MediaPlayer.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3EEEDB60197107C0006A9FF8 /* MediaPlayer.framework */; }; 5023811817EBBCAC00990C9B /* AppController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5023810817EBBCAC00990C9B /* AppController.mm */; }; 5023811917EBBCAC00990C9B /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 5023810917EBBCAC00990C9B /* Default-568h@2x.png */; }; 5023811A17EBBCAC00990C9B /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 5023810A17EBBCAC00990C9B /* Default.png */; }; @@ -161,9 +162,6 @@ C08D5D6718E567C6009071A4 /* tp.lua in Resources */ = {isa = PBXBuildFile; fileRef = C08D5D5418E567C6009071A4 /* tp.lua */; }; C08D5D6818E567C6009071A4 /* url.lua in Resources */ = {isa = PBXBuildFile; fileRef = C08D5D5518E567C6009071A4 /* url.lua */; }; C08D5D6918E567C6009071A4 /* url.lua in Resources */ = {isa = PBXBuildFile; fileRef = C08D5D5518E567C6009071A4 /* url.lua */; }; - C09BA7E718BC929700A85A3E /* WorkSpaceDialog.xib in Resources */ = {isa = PBXBuildFile; fileRef = C09BA7E418BC929700A85A3E /* WorkSpaceDialog.xib */; }; - C09BA7E818BC929700A85A3E /* WorkSpaceDialogController.mm in Sources */ = {isa = PBXBuildFile; fileRef = C09BA7E618BC929700A85A3E /* WorkSpaceDialogController.mm */; }; - C09BA7EE18BCA49600A85A3E /* NSAppSheetAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = C09BA7ED18BCA49600A85A3E /* NSAppSheetAdditions.m */; }; D6B061351803AC000077942B /* CoreMotion.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D6B061341803AC000077942B /* CoreMotion.framework */; }; F293B3CD15EB7BE500256477 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3CC15EB7BE500256477 /* QuartzCore.framework */; }; F293B3D115EB7BE500256477 /* OpenAL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F293B3D015EB7BE500256477 /* OpenAL.framework */; }; @@ -390,6 +388,7 @@ 3EB515551952865D006966AA /* wire_format_lite.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = wire_format_lite.cc; sourceTree = ""; }; 3EB515561952865D006966AA /* wire_format_lite.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = wire_format_lite.h; sourceTree = ""; }; 3EB515571952865D006966AA /* wire_format_lite_inl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = wire_format_lite_inl.h; sourceTree = ""; }; + 3EEEDB60197107C0006A9FF8 /* MediaPlayer.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MediaPlayer.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.1.sdk/System/Library/Frameworks/MediaPlayer.framework; sourceTree = DEVELOPER_DIR; }; 5023810717EBBCAC00990C9B /* AppController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppController.h; sourceTree = ""; }; 5023810817EBBCAC00990C9B /* AppController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AppController.mm; sourceTree = ""; }; 5023810917EBBCAC00990C9B /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; @@ -471,11 +470,6 @@ C08D5D5318E567C6009071A4 /* socket.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = socket.lua; path = "../../cocos2d-x/external/lua/luasocket/socket.lua"; sourceTree = ""; }; C08D5D5418E567C6009071A4 /* tp.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = tp.lua; path = "../../cocos2d-x/external/lua/luasocket/tp.lua"; sourceTree = ""; }; C08D5D5518E567C6009071A4 /* url.lua */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = url.lua; path = "../../cocos2d-x/external/lua/luasocket/url.lua"; sourceTree = ""; }; - C09BA7E418BC929700A85A3E /* WorkSpaceDialog.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = WorkSpaceDialog.xib; sourceTree = ""; }; - C09BA7E518BC929700A85A3E /* WorkSpaceDialogController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WorkSpaceDialogController.h; sourceTree = ""; }; - C09BA7E618BC929700A85A3E /* WorkSpaceDialogController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WorkSpaceDialogController.mm; sourceTree = ""; }; - C09BA7EC18BCA49600A85A3E /* NSAppSheetAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSAppSheetAdditions.h; sourceTree = ""; }; - C09BA7ED18BCA49600A85A3E /* NSAppSheetAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSAppSheetAdditions.m; sourceTree = ""; }; D6B061341803AC000077942B /* CoreMotion.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMotion.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/System/Library/Frameworks/CoreMotion.framework; sourceTree = DEVELOPER_DIR; }; F293B3C815EB7BE500256477 /* HelloLua iOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "HelloLua iOS.app"; sourceTree = BUILT_PRODUCTS_DIR; }; F293B3CC15EB7BE500256477 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; @@ -518,6 +512,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 3EEEDB61197107C0006A9FF8 /* MediaPlayer.framework in Frameworks */, C03781F618BF65B100FE4F13 /* libluabindings iOS.a in Frameworks */, 15A8A4441834C43700142BE0 /* libchipmunk iOS.a in Frameworks */, 15A8A4451834C43700142BE0 /* libcocos2dx iOS.a in Frameworks */, @@ -689,11 +684,6 @@ 5023817117EBBE3400990C9B /* mac */ = { isa = PBXGroup; children = ( - C09BA7EC18BCA49600A85A3E /* NSAppSheetAdditions.h */, - C09BA7ED18BCA49600A85A3E /* NSAppSheetAdditions.m */, - C09BA7E418BC929700A85A3E /* WorkSpaceDialog.xib */, - C09BA7E518BC929700A85A3E /* WorkSpaceDialogController.h */, - C09BA7E618BC929700A85A3E /* WorkSpaceDialogController.mm */, 5023817217EBBE3400990C9B /* Icon.icns */, C07828F418B4D72E00BD2287 /* main.m */, C07828F518B4D72E00BD2287 /* MainMenu.xib */, @@ -780,6 +770,7 @@ F293B3CB15EB7BE500256477 /* Frameworks */ = { isa = PBXGroup; children = ( + 3EEEDB60197107C0006A9FF8 /* MediaPlayer.framework */, 3EB51526195187AF006966AA /* CFNetwork.framework */, 15A8A4871834C90E00142BE0 /* libcurl.dylib */, D6B061341803AC000077942B /* CoreMotion.framework */, @@ -1019,7 +1010,6 @@ C08D5D6118E567C6009071A4 /* mime.lua in Resources */, C03781D418BF656A00FE4F13 /* Cocos2d.lua in Resources */, C03781BA18BF655400FE4F13 /* res in Resources */, - C09BA7E718BC929700A85A3E /* WorkSpaceDialog.xib in Resources */, C03781BC18BF655400FE4F13 /* src in Resources */, C08D5D6918E567C6009071A4 /* url.lua in Resources */, C03781E218BF656A00FE4F13 /* DrawPrimitives.lua in Resources */, @@ -1148,12 +1138,10 @@ 3EB515691952865D006966AA /* common.cc in Sources */, 3EB515651952865D006966AA /* repeated_field.cc in Sources */, 3EB5156B1952865D006966AA /* once.cc in Sources */, - C09BA7EE18BCA49600A85A3E /* NSAppSheetAdditions.m in Sources */, 3EB5155D1952865D006966AA /* coded_stream.cc in Sources */, C00FD4991938512100C6382D /* Portrait_png.cpp in Sources */, C06C3797191A1D1E00617BED /* ConfigParser.cpp in Sources */, 3EB5156D1952865D006966AA /* stringprintf.cc in Sources */, - C09BA7E818BC929700A85A3E /* WorkSpaceDialogController.mm in Sources */, C07828F818B4D72E00BD2287 /* main.m in Sources */, 3EB515611952865D006966AA /* zero_copy_stream_impl_lite.cc in Sources */, 3EB5156F1952865D006966AA /* wire_format_lite.cc in Sources */, diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/MainMenu.xib b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/MainMenu.xib index 1d691c1d28..a803574695 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/MainMenu.xib +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/MainMenu.xib @@ -2,10 +2,10 @@ 1060 - 13C64 + 13D65 5056 - 1265.19 - 697.40 + 1265.20 + 698.00 com.apple.InterfaceBuilder.CocoaPlugin 5056 @@ -164,14 +164,6 @@ File - - - ChangeProject - - 2147483647 - - - Close @@ -299,6 +291,14 @@ + + + Keep Window Top + + 2147483647 + + + @@ -386,14 +386,6 @@ tSA-7z-LPk - - - onChangeProject: - - - - KV1-nK-nLn - onFileClose: @@ -458,6 +450,14 @@ XXg-eJ-YSn + + + onSetTop: + + + + jvv-x1-KeN + menu @@ -594,16 +594,10 @@ 81 - - - UUd-nT-0Tr - - - 611 @@ -687,6 +681,7 @@ + @@ -718,6 +713,11 @@ + + CXy-V7-NaY + + + @@ -761,6 +761,7 @@ com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -777,8 +778,6 @@ com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin com.apple.InterfaceBuilder.CocoaPlugin @@ -801,7 +800,68 @@ - + + + + AppController + NSObject + + id + id + id + id + id + id + id + + + + onFileClose: + id + + + onRelaunch: + id + + + onScreenLandscape: + id + + + onScreenPortait: + id + + + onScreenZoomOut: + id + + + onSetTop: + id + + + onViewChangeFrameSize: + id + + + + menu + NSMenu + + + menu + + menu + NSMenu + + + + IBProjectSource + ./Classes/AppController.h + + + + 0 IBCocoaFramework YES @@ -811,7 +871,7 @@ com.apple.InterfaceBuilder.CocoaPlugin.macosx - + com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3 diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.h b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.h deleted file mode 100644 index 0f7e43b3ce..0000000000 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.h +++ /dev/null @@ -1,8 +0,0 @@ - -#import - -@interface NSApplication (SheetAdditions) - -- (void)beginSheet:(NSWindow *)sheet modalForWindow:(NSWindow *)docWindow didEndBlock:(void (^)(NSInteger returnCode))block; - -@end diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.m b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.m deleted file mode 100644 index b5845bd784..0000000000 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/NSAppSheetAdditions.m +++ /dev/null @@ -1,22 +0,0 @@ - -#import "NSAppSheetAdditions.h" - -@implementation NSApplication (SheetAdditions) - -- (void)beginSheet:(NSWindow *)sheet modalForWindow:(NSWindow *)docWindow didEndBlock:(void (^)(NSInteger returnCode))block -{ - [self beginSheet:sheet - modalForWindow:docWindow - modalDelegate:self - didEndSelector:@selector(my_blockSheetDidEnd:returnCode:contextInfo:) - contextInfo:Block_copy(block)]; -} - -- (void)my_blockSheetDidEnd:(NSWindow *)sheet returnCode:(NSInteger)returnCode contextInfo:(void *)contextInfo -{ - void (^block)(NSInteger returnCode) = contextInfo; - block(returnCode); - Block_release(block); -} - -@end diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.h b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.h index 411a256e9f..d7815e3ef7 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.h +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.h @@ -41,7 +41,7 @@ void createSimulator(const char* viewName, float width, float height,bool isLand @property (nonatomic, assign) IBOutlet NSMenu* menu; -- (IBAction) onChangeProject:(id)sender; +- (IBAction) onSetTop:(id)sender; - (IBAction) onFileClose:(id)sender; - (IBAction) onScreenPortait:(id)sender; - (IBAction) onScreenLandscape:(id)sender; diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.mm b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.mm index 43cce5504e..b860aac9e9 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.mm +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/SimulatorApp.mm @@ -22,16 +22,13 @@ THE SOFTWARE. ****************************************************************************/ -#import "SimulatorApp.h" -#import "WorkSpaceDialogController.h" -#import "NSAppSheetAdditions.h" - #include #include #include #include #include +#import "SimulatorApp.h" #include "AppDelegate.h" #include "glfw3.h" #include "glfw3native.h" @@ -43,6 +40,7 @@ using namespace cocos2d; bool g_landscape = false; +bool g_windTop = true; cocos2d::Size g_screenSize; GLView* g_eglView = nullptr; @@ -104,7 +102,7 @@ std::string getCurAppPath(void) width = height; height = tmpvalue; } - + g_windTop = true; g_eglView = GLView::createWithRect([viewName cStringUsingEncoding:NSUTF8StringEncoding],cocos2d::Rect(0.0f,0.0f,width,height),frameZoomFactor); auto director = Director::getInstance(); director->setOpenGLView(g_eglView); @@ -115,7 +113,7 @@ std::string getCurAppPath(void) [self createViewMenu]; [self updateMenu]; [window center]; - + [window becomeFirstResponder]; [window makeKeyAndOrderFront:self]; } @@ -172,6 +170,18 @@ void createSimulator(const char* viewName, float width, float height,bool isLand [itemPortait setState:NSOnState]; [itemLandscape setState:NSOffState]; } + + NSMenu *menuControl = [[[window menu] itemWithTitle:@"Control"] submenu]; + NSMenuItem *itemTop = [menuControl itemWithTitle:@"Keep Window Top"]; + if (g_windTop) { + [window setLevel:NSFloatingWindowLevel]; + [itemTop setState:NSOnState]; + } + else + { + [window setLevel:NSNormalWindowLevel]; + [itemTop setState:NSOffState]; + } int scale = g_eglView->getFrameZoomFactor()*100; @@ -223,7 +233,6 @@ void createSimulator(const char* viewName, float width, float height,bool isLand } - //[window setTitle:[NSString stringWithFormat:@"quick-x-player (%0.0f%%)", projectConfig.getFrameScale() * 100]]; } @@ -261,17 +270,10 @@ void createSimulator(const char* viewName, float width, float height,bool isLand [[NSRunningApplication currentApplication] terminate]; } -- (IBAction) onChangeProject:(id)sender +- (IBAction) onSetTop:(id)sender { - - WorkSpaceDialogController *controller = [[WorkSpaceDialogController alloc] initWithWindowNibName:@"WorkSpaceDialog"]; - [NSApp beginSheet:controller.window modalForWindow:window didEndBlock:^(NSInteger returnCode) { - if (returnCode == NSRunStoppedResponse) - { - CCLOG("1111"); - } - [controller release]; - }]; + g_windTop = !g_windTop; + [self updateMenu]; } diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialog.xib b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialog.xib deleted file mode 100644 index 7ebed71aa1..0000000000 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialog.xib +++ /dev/null @@ -1,846 +0,0 @@ - - - - 1070 - 13C64 - 5056 - 1265.19 - 697.40 - - com.apple.InterfaceBuilder.CocoaPlugin - 5056 - - - IBNSLayoutConstraint - NSButton - NSButtonCell - NSCustomObject - NSTextField - NSTextFieldCell - NSView - NSWindowTemplate - - - com.apple.InterfaceBuilder.CocoaPlugin - - - PluginDependencyRecalculationVersion - - - - - WorkSpaceDialogController - - - FirstResponder - - - NSApplication - - - 3 - 2 - {{196, 240}, {650, 150}} - 544736256 - Change Project - NSWindow - - - - - 256 - - - - 268 - {{17, 113}, {626, 17}} - - - YES - - 68157504 - 272630784 - Choose Project Directory: - - .LucidaGrandeUI - 13 - 1044 - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - NO - 1 - - - - 268 - {{20, 83}, {516, 22}} - - - YES - - -1804599231 - 272630848 - - - - YES - - 6 - System - textBackgroundColor - - 3 - MQA - - - - 6 - System - textColor - - - - NO - 1 - - - - 268 - {{538, 77}, {108, 32}} - - - {250, 750} - YES - - 67108864 - 134217728 - Select... - - - -2038284288 - 129 - - .LucidaGrandeUI - 13 - 16 - - - - 400 - 75 - - NO - - - - 268 - {{538, 22}, {109, 32}} - - - {250, 750} - YES - - 67108864 - 134217728 - Open Project - - - -2038284288 - 129 - - - - 400 - 75 - - NO - - - - 268 - {{13, 32}, {82, 32}} - - - {250, 750} - YES - - 67108864 - 134217728 - Cancel - - - -2038284288 - 129 - - - Gw - 400 - 75 - - NO - - - {650, 150} - - - - {{0, 0}, {1920, 1058}} - {10000000000000, 10000000000000} - NO - - - - NO - - - - textFieldProjectDirectory - - - - 307 - - - - window - - - - 308 - - - - browseProjectDirectory: - - - - 315 - - - - onOpenProject: - - - - OsS-1W-RIl - - - - onCancel: - - - - NeH-n8-xBM - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 1 - - - - - - - - 2 - - - - - - - - - - 9 - 0 - - 9 - 1 - 1 - - 0.0 - - 1000 - - 6 - 24 - 2 - NO - - - - 4 - 0 - - 4 - 1 - 1 - - 29 - - 1000 - - 3 - 9 - 3 - NO - - - - 6 - 0 - - 6 - 1 - 1 - - 0.0 - - 1000 - - 6 - 24 - 2 - NO - - - - 3 - 0 - - 4 - 1 - 1 - - 8 - - 1000 - - 6 - 24 - 3 - NO - - - - 5 - 0 - - 5 - 1 - 1 - - 0.0 - - 1000 - - 6 - 24 - 2 - NO - - - - 5 - 0 - - 6 - 1 - 1 - - 8 - - 1000 - - 6 - 24 - 3 - NO - - - - 4 - 0 - - 4 - 1 - 1 - - 39 - - 1000 - - 3 - 9 - 3 - NO - - - - 5 - 0 - - 5 - 1 - 1 - - 20 - - 1000 - - 8 - 23 - 3 - NO - - - - 3 - 0 - - 4 - 1 - 1 - - 8 - - 1000 - - 6 - 24 - 3 - NO - - - - 5 - 0 - - 5 - 1 - 1 - - 0.0 - - 1000 - - 6 - 24 - 2 - NO - - - - 3 - 0 - - 3 - 1 - 1 - - 20 - - 1000 - - 8 - 23 - 3 - NO - - - - - - 3 - - - - - - 7 - 0 - - 0 - 1 - 1 - - 622 - - 1000 - - 3 - 9 - 1 - NO - - - - - - 4 - - - - - 9 - - - - - - 7 - 0 - - 0 - 1 - 1 - - 516 - - 1000 - - 3 - 9 - 1 - NO - - - - - - 10 - - - - - 15 - - - - - - 7 - 0 - - 0 - 1 - 1 - - 96 - - 1000 - - 3 - 9 - 1 - NO - - - - - - 16 - - - - - 290 - - - - - - - - 291 - - - - - h9P-cE-Nn4 - - - - - - - - IHP-6G-mVo - - - - - iMi-xo-eWy - - - - - YJ1-Hw-Y6d - - - - - PG0-hY-geV - - - - - i6K-RE-2fe - - - - - gk1-TV-YZn - - - - - pS2-KY-JwZ - - - - - H3W-Ag-EM4 - - - - - uNq-ax-eLX - - - - - G4a-SP-Ne5 - - - - - V9F-80-0WS - - - - - jJo-kq-191 - - - - - LdE-9Z-oWz - - - - - 88D-6W-iEt - - - - - DKd-WY-ZYy - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - - - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - - - - WorkSpaceDialogController - NSWindowController - - id - id - id - - - - browseProjectDirectory: - id - - - onCancel: - id - - - onOpenProject: - id - - - - NSButton - NSTextField - NSTextField - - - - buttonOpenProject - NSButton - - - textFieldProjectDirectory - NSTextField - - - textFieldScriptFile - NSTextField - - - - IBProjectSource - ./Classes/WorkSpaceDialogController.h - - - - - 0 - IBCocoaFramework - YES - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - - com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3 - - - YES - 3 - YES - - diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.h b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.h deleted file mode 100644 index 2b9cddbd15..0000000000 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.h +++ /dev/null @@ -1,22 +0,0 @@ - -#import - -@interface WorkSpaceDialogController : NSWindowController -{ - - NSTextField *textFieldProjectDirectory; - NSTextField *textFieldScriptFile; - NSButton *buttonOpenProject; -} - -@property (nonatomic, assign) IBOutlet NSTextField *textFieldProjectDirectory; -@property (nonatomic, assign) IBOutlet NSTextField *textFieldScriptFile; - -@property (nonatomic, assign) IBOutlet NSButton *buttonOpenProject; - -- (IBAction) browseProjectDirectory:(id)sender; - -- (IBAction) onCancel:(id)sender; -- (IBAction) onOpenProject:(id)sender; - -@end diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.mm b/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.mm deleted file mode 100644 index 223803e55e..0000000000 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.ios_mac/mac/WorkSpaceDialogController.mm +++ /dev/null @@ -1,97 +0,0 @@ - -#import "WorkSpaceDialogController.h" - -#pragma mark - - -@implementation WorkSpaceDialogController - -@synthesize textFieldProjectDirectory; -@synthesize textFieldScriptFile; -@synthesize buttonOpenProject; - -NSString* projectPath=nil; -- (id)initWithWindow:(NSWindow *)window -{ - self = [super initWithWindow:window]; - if (self) { - // Initialization code here. - } - - return self; -} - -- (void)dealloc -{ - [super dealloc]; - NSLog(@"[WorkSpaceDialogController dealloc]"); -} - -- (void)windowDidLoad -{ - [super windowDidLoad]; - - // Implement this method to handle any initialization after your window controller's window has been loaded from its nib file. - [self.window makeFirstResponder:textFieldProjectDirectory]; - if (nil != projectPath && 0 != projectPath.length) - { - [textFieldProjectDirectory setStringValue:projectPath]; - } -} - -#pragma mark - -#pragma mark functions - -- (NSString*) browseFolder:(NSString*)title -{ - NSOpenPanel* openDlg = [NSOpenPanel openPanel]; - [openDlg setTitle:title]; - [openDlg setCanChooseDirectories:YES]; - [openDlg setCanChooseFiles:NO]; - [openDlg setCanHide:YES]; - [openDlg setCanCreateDirectories:NO]; - [openDlg setCanSelectHiddenExtension:NO]; - [openDlg setAllowsMultipleSelection:NO]; - - if ([openDlg runModal] == NSFileHandlingPanelOKButton) - { - NSURL *url = [openDlg.URLs objectAtIndex:0]; - return [url path]; - } - return nil; -} - -#pragma mark - -#pragma mark outlet - -- (IBAction) browseProjectDirectory:(id)sender -{ - NSString *path = [self browseFolder:@"Choose Project Directory"]; - if (path) - { - [textFieldProjectDirectory setStringValue:path]; - } -} - - -- (IBAction) onCancel:(id)sender -{ - [self close]; - [NSApp endSheet:self.window returnCode:NSRunAbortedResponse]; -} - -- (IBAction) onOpenProject:(id)sender -{ - if([[textFieldProjectDirectory stringValue] isEqualToString:@""]) - { - NSRunAlertPanel(@"Waring", - @"Project path empty!", - @"OK", NULL, NULL); - return; - } - projectPath = [textFieldProjectDirectory stringValue]; - [self close]; - [NSApp endSheet:self.window returnCode:NSRunAbortedResponse]; -} - - -@end diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/SimulatorWindow.cpp b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/SimulatorWindow.cpp index d4ed7258a9..8e64c3d2cb 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/SimulatorWindow.cpp +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/SimulatorWindow.cpp @@ -38,6 +38,7 @@ using namespace cocos2d; WNDPROC g_oldProc=NULL; bool g_landscape=false; +bool g_windTop = true; CCSize g_screenSize; GLView* g_eglView=NULL; INT_PTR CALLBACK AboutDialogCallback(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); @@ -70,6 +71,7 @@ void updateMenu() { HMENU hSysMenu = GetSystemMenu(glfwGetWin32Window(g_eglView->getWindow()), FALSE); HMENU viewMenu = GetSubMenu(hSysMenu, 8); + HMENU viewControl = GetSubMenu(hSysMenu, 9); if (g_landscape) { @@ -82,6 +84,16 @@ void updateMenu() CheckMenuItem(viewMenu, ID_VIEW_LANDSCAPE, MF_BYCOMMAND | MF_UNCHECKED); } + if (g_windTop) + { + ::SetWindowPos(glfwGetWin32Window(g_eglView->getWindow()),HWND_TOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE); + CheckMenuItem(viewControl, ID_CONTROL_TOP, MF_BYCOMMAND | MF_CHECKED); + + }else + { + ::SetWindowPos(glfwGetWin32Window(g_eglView->getWindow()),HWND_NOTOPMOST,0,0,0,0,SWP_NOMOVE|SWP_NOSIZE); + CheckMenuItem(viewControl, ID_CONTROL_TOP, MF_BYCOMMAND | MF_UNCHECKED); + } int width = g_screenSize.width; int height = g_screenSize.height; if (height > width) @@ -244,6 +256,10 @@ LRESULT CALLBACK SNewWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPar switch (wmId) { + case ID_CONTROL_TOP: + g_windTop = !g_windTop; + updateView(); + break; case ID_FILE_EXIT: shutDownApp(); break; @@ -324,6 +340,7 @@ void createSimulator(const char* viewName, float width, float height, bool isLan width = height; height = tmpvalue; } + g_windTop = true; g_eglView = GLView::createWithRect(viewName,Rect(0,0,width,height),frameZoomFactor); auto director = Director::getInstance(); diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/game.rc b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/game.rc index 556a26c626..46a66d6cf7 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/game.rc +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/game.rc @@ -66,6 +66,7 @@ BEGIN POPUP "&Control" BEGIN MENUITEM "Restart(F5)", ID_CONTROL_RELOAD + MENUITEM "Keep Window Top", ID_CONTROL_TOP END POPUP "&Help" BEGIN @@ -88,19 +89,6 @@ BEGIN LTEXT "Cocos2d-x-Simulator",IDC_STATIC,29,17,169,25 END -IDD_DIALOG_VIEWCUSTOM DIALOGEX 0, 0, 179, 98 -STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Custom" -FONT 8, "MS Shell Dlg", 400, 0, 0x1 -BEGIN - DEFPUSHBUTTON "OK",IDOK,47,77,50,14 - PUSHBUTTON "Cancel",IDCANCEL,104,77,50,14 - LTEXT "Width",IDC_STATIC,15,14,30,8 - LTEXT "Height",IDC_STATIC,15,36,36,12 - EDITTEXT IDC_EDIT_WIDTH,60,15,89,14,ES_AUTOHSCROLL - EDITTEXT IDC_EDIT_HEIGHT,62,36,87,14,ES_AUTOHSCROLL -END - ///////////////////////////////////////////////////////////////////////////// // @@ -117,14 +105,6 @@ BEGIN TOPMARGIN, 7 BOTTOMMARGIN, 87 END - - IDD_DIALOG_VIEWCUSTOM, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 172 - TOPMARGIN, 7 - BOTTOMMARGIN, 91 - END END #endif // APSTUDIO_INVOKED diff --git a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/resource.h b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/resource.h index 6f04655931..d3ddc2bd16 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/resource.h +++ b/templates/lua-template-runtime/frameworks/runtime-src/proj.win32/resource.h @@ -7,10 +7,7 @@ #define IDR_MENU_COCOS 201 #define IDD_DIALOG1 202 #define IDD_DIALOG_ABOUT 202 -#define IDD_DIALOG_VIEWCUSTOM 203 -#define IDC_EDIT_WIDTH 1000 #define IDC_EDIT2 1001 -#define IDC_EDIT_HEIGHT 1001 #define ID_VIEW_SIZE 30001 #define ID_FILE_NEW_WINDOW 32771 #define ID_VIEW_PORTRAIT 32775 @@ -27,13 +24,14 @@ #define ID_VIEW_ZOOMOUT75 32786 #define ID_VIEW_ZOOMOUT50 32787 #define ID_VIEW_ZOOMOUT25 32788 +#define ID_CONTROL_TOP 32793 // Next default values for new objects // #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS #define _APS_NEXT_RESOURCE_VALUE 201 -#define _APS_NEXT_COMMAND_VALUE 32793 +#define _APS_NEXT_COMMAND_VALUE 32794 #define _APS_NEXT_CONTROL_VALUE 1000 #define _APS_NEXT_SYMED_VALUE 101 #endif diff --git a/templates/lua-template-runtime/runtime/config.json b/templates/lua-template-runtime/runtime/config.json index 7d3a94ae77..4f28c9624c 100644 --- a/templates/lua-template-runtime/runtime/config.json +++ b/templates/lua-template-runtime/runtime/config.json @@ -1,6 +1,6 @@ { - "version":"v3-lua-runtime-1.2", - "zip_file_size":"24461574 ", + "version":"v3-lua-runtime-1.3.1", + "zip_file_size":"24660780", "repo_name":"cocos-runtime-bin", "repo_parent":"https://github.com/chukong/" } diff --git a/templates/lua-template-runtime/src/GameScene.lua b/templates/lua-template-runtime/src/GameScene.lua new file mode 100644 index 0000000000..cd817c5ba0 --- /dev/null +++ b/templates/lua-template-runtime/src/GameScene.lua @@ -0,0 +1,184 @@ +require "Cocos2d" +require "Cocos2dConstants" + +local GameScene = class("GameScene",function() + return cc.Scene:create() +end) + +function GameScene.create() + local scene = GameScene.new() + scene:addChild(scene:createLayerFarm()) + scene:addChild(scene:createLayerMenu()) + return scene +end + + +function GameScene:ctor() + self.visibleSize = cc.Director:getInstance():getVisibleSize() + self.origin = cc.Director:getInstance():getVisibleOrigin() + self.schedulerID = nil +end + +function GameScene:playBgMusic() + local bgMusicPath = cc.FileUtils:getInstance():fullPathForFilename("background.mp3") + cc.SimpleAudioEngine:getInstance():playMusic(bgMusicPath, true) + local effectPath = cc.FileUtils:getInstance():fullPathForFilename("effect1.wav") + cc.SimpleAudioEngine:getInstance():preloadEffect(effectPath) +end + +function GameScene:creatDog() + local frameWidth = 105 + local frameHeight = 95 + + -- create dog animate + local textureDog = cc.Director:getInstance():getTextureCache():addImage("dog.png") + local rect = cc.rect(0, 0, frameWidth, frameHeight) + local frame0 = cc.SpriteFrame:createWithTexture(textureDog, rect) + rect = cc.rect(frameWidth, 0, frameWidth, frameHeight) + local frame1 = cc.SpriteFrame:createWithTexture(textureDog, rect) + + local spriteDog = cc.Sprite:createWithSpriteFrame(frame0) + spriteDog:setPosition(self.origin.x, self.origin.y + self.visibleSize.height / 4 * 3) + spriteDog.isPaused = false + + local animation = cc.Animation:createWithSpriteFrames({frame0,frame1}, 0.5) + local animate = cc.Animate:create(animation); + spriteDog:runAction(cc.RepeatForever:create(animate)) + + -- moving dog at every frame + local function tick() + if spriteDog.isPaused then return end + local x, y = spriteDog:getPosition() + if x > self.origin.x + self.visibleSize.width then + x = self.origin.x + else + x = x + 1 + end + + spriteDog:setPositionX(x) + end + + self.schedulerID = cc.Director:getInstance():getScheduler():scheduleScriptFunc(tick, 0, false) + + return spriteDog +end + +-- create farm +function GameScene:createLayerFarm() + local layerFarm = cc.Layer:create() + -- add in farm background + local bg = cc.Sprite:create("farm.jpg") + bg:setPosition(self.origin.x + self.visibleSize.width / 2 + 80, self.origin.y + self.visibleSize.height / 2) + layerFarm:addChild(bg) + + -- add land sprite + for i = 0, 3 do + for j = 0, 1 do + local spriteLand = cc.Sprite:create("land.png") + spriteLand:setPosition(200 + j * 180 - i % 2 * 90, 10 + i * 95 / 2) + layerFarm:addChild(spriteLand) + end + end + + -- add crop + local frameCrop = cc.SpriteFrame:create("crop.png", cc.rect(0, 0, 105, 95)) + for i = 0, 3 do + for j = 0, 1 do + local spriteCrop = cc.Sprite:createWithSpriteFrame(frameCrop); + spriteCrop:setPosition(210 + j * 180 - i % 2 * 90, 40 + i * 95 / 2) + layerFarm:addChild(spriteCrop) + end + end + + -- add moving dog + local spriteDog = self:creatDog() + layerFarm:addChild(spriteDog) + + -- handing touch events + local touchBeginPoint = nil + local function onTouchBegan(touch, event) + local location = touch:getLocation() + --cclog("onTouchBegan: %0.2f, %0.2f", location.x, location.y) + touchBeginPoint = {x = location.x, y = location.y} + spriteDog.isPaused = true + -- CCTOUCHBEGAN event must return true + return true + end + + local function onTouchMoved(touch, event) + local location = touch:getLocation() + --cclog("onTouchMoved: %0.2f, %0.2f", location.x, location.y) + if touchBeginPoint then + local cx, cy = layerFarm:getPosition() + layerFarm:setPosition(cx + location.x - touchBeginPoint.x, + cy + location.y - touchBeginPoint.y) + touchBeginPoint = {x = location.x, y = location.y} + end + end + + local function onTouchEnded(touch, event) + local location = touch:getLocation() + --cclog("onTouchEnded: %0.2f, %0.2f", location.x, location.y) + touchBeginPoint = nil + spriteDog.isPaused = false + end + + local listener = cc.EventListenerTouchOneByOne:create() + listener:registerScriptHandler(onTouchBegan,cc.Handler.EVENT_TOUCH_BEGAN ) + listener:registerScriptHandler(onTouchMoved,cc.Handler.EVENT_TOUCH_MOVED ) + listener:registerScriptHandler(onTouchEnded,cc.Handler.EVENT_TOUCH_ENDED ) + local eventDispatcher = layerFarm:getEventDispatcher() + eventDispatcher:addEventListenerWithSceneGraphPriority(listener, layerFarm) + + local function onNodeEvent(event) + if "exit" == event then + cc.Director:getInstance():getScheduler():unscheduleScriptEntry(self.schedulerID) + end + end + layerFarm:registerScriptHandler(onNodeEvent) + + return layerFarm +end + +-- create menu +function GameScene:createLayerMenu() + + local layerMenu = cc.Layer:create() + local menuPopup, menuTools, effectID + + local function menuCallbackClosePopup() + -- stop test sound effect + cc.SimpleAudioEngine:getInstance():stopEffect(effectID) + menuPopup:setVisible(false) + end + + local function menuCallbackOpenPopup() + -- loop test sound effect + local effectPath = cc.FileUtils:getInstance():fullPathForFilename("effect1.wav") + effectID = cc.SimpleAudioEngine:getInstance():playEffect(effectPath) + menuPopup:setVisible(true) + end + + -- add a popup menu + local menuPopupItem = cc.MenuItemImage:create("menu2.png", "menu2.png") + menuPopupItem:setPosition(0, 0) + menuPopupItem:registerScriptTapHandler(menuCallbackClosePopup) + menuPopup = cc.Menu:create(menuPopupItem) + menuPopup:setPosition(self.origin.x + self.visibleSize.width / 2, self.origin.y + self.visibleSize.height / 2) + menuPopup:setVisible(false) + layerMenu:addChild(menuPopup) + + -- add the left-bottom "tools" menu to invoke menuPopup + local menuToolsItem = cc.MenuItemImage:create("menu1.png", "menu1.png") + menuToolsItem:setPosition(0, 0) + menuToolsItem:registerScriptTapHandler(menuCallbackOpenPopup) + menuTools = cc.Menu:create(menuToolsItem) + local itemWidth = menuToolsItem:getContentSize().width + local itemHeight = menuToolsItem:getContentSize().height + menuTools:setPosition(self.origin.x + itemWidth/2, self.origin.y + itemHeight/2) + layerMenu:addChild(menuTools) + + return layerMenu +end + +return GameScene diff --git a/templates/lua-template-runtime/src/hello2.lua b/templates/lua-template-runtime/src/hello2.lua deleted file mode 100644 index 27158aa788..0000000000 --- a/templates/lua-template-runtime/src/hello2.lua +++ /dev/null @@ -1,3 +0,0 @@ -function myadd(x, y) - return x + y -end \ No newline at end of file diff --git a/templates/lua-template-runtime/src/main.lua b/templates/lua-template-runtime/src/main.lua index a270259bf4..32f49d9378 100644 --- a/templates/lua-template-runtime/src/main.lua +++ b/templates/lua-template-runtime/src/main.lua @@ -1,8 +1,8 @@ + require "Cocos2d" -require "Cocos2dConstants" -- cclog -cclog = function(...) +local cclog = function(...) print(string.format(...)) end @@ -20,209 +20,21 @@ local function main() -- avoid memory leak collectgarbage("setpause", 100) collectgarbage("setstepmul", 5000) + + cc.FileUtils:getInstance():addSearchPath("src") + cc.FileUtils:getInstance():addSearchPath("res") cc.Director:getInstance():getOpenGLView():setDesignResolutionSize(480, 320, 0) - cc.FileUtils:getInstance():addSearchPath("src") - cc.FileUtils:getInstance():addSearchPath("res") - local schedulerID = 0 - --support debug - local targetPlatform = cc.Application:getInstance():getTargetPlatform() - if (cc.PLATFORM_OS_IPHONE == targetPlatform) or (cc.PLATFORM_OS_IPAD == targetPlatform) or - (cc.PLATFORM_OS_ANDROID == targetPlatform) or (cc.PLATFORM_OS_WINDOWS == targetPlatform) or - (cc.PLATFORM_OS_MAC == targetPlatform) then - cclog("result is ") - --require('debugger')() - + + --create scene + local scene = require("GameScene") + local gameScene = scene.create() + gameScene:playBgMusic() + + if cc.Director:getInstance():getRunningScene() then + cc.Director:getInstance():replaceScene(gameScene) + else + cc.Director:getInstance():runWithScene(gameScene) end - require "hello2" - cclog("result is " .. myadd(1, 1)) - - --------------- - - local visibleSize = cc.Director:getInstance():getVisibleSize() - local origin = cc.Director:getInstance():getVisibleOrigin() - - -- add the moving dog - local function creatDog() - local frameWidth = 105 - local frameHeight = 95 - - -- create dog animate - local textureDog = cc.Director:getInstance():getTextureCache():addImage("dog.png") - local rect = cc.rect(0, 0, frameWidth, frameHeight) - local frame0 = cc.SpriteFrame:createWithTexture(textureDog, rect) - rect = cc.rect(frameWidth, 0, frameWidth, frameHeight) - local frame1 = cc.SpriteFrame:createWithTexture(textureDog, rect) - - local spriteDog = cc.Sprite:createWithSpriteFrame(frame0) - spriteDog.isPaused = false - spriteDog:setPosition(origin.x, origin.y + visibleSize.height / 4 * 3) ---[[ - local animFrames = CCArray:create() - - animFrames:addObject(frame0) - animFrames:addObject(frame1) -]]-- - - local animation = cc.Animation:createWithSpriteFrames({frame0,frame1}, 0.5) - local animate = cc.Animate:create(animation); - spriteDog:runAction(cc.RepeatForever:create(animate)) - - -- moving dog at every frame - local function tick() - if spriteDog.isPaused then return end - local x, y = spriteDog:getPosition() - if x > origin.x + visibleSize.width then - x = origin.x - else - x = x + 1 - end - - spriteDog:setPositionX(x) - end - - schedulerID = cc.Director:getInstance():getScheduler():scheduleScriptFunc(tick, 0, false) - - return spriteDog - end - - -- create farm - local function createLayerFarm() - local layerFarm = cc.Layer:create() - - -- add in farm background - local bg = cc.Sprite:create("farm.jpg") - bg:setPosition(origin.x + visibleSize.width / 2 + 80, origin.y + visibleSize.height / 2) - layerFarm:addChild(bg) - - -- add land sprite - for i = 0, 3 do - for j = 0, 1 do - local spriteLand = cc.Sprite:create("land.png") - spriteLand:setPosition(200 + j * 180 - i % 2 * 90, 10 + i * 95 / 2) - layerFarm:addChild(spriteLand) - end - end - - -- add crop - local frameCrop = cc.SpriteFrame:create("crop.png", cc.rect(0, 0, 105, 95)) - for i = 0, 3 do - for j = 0, 1 do - local spriteCrop = cc.Sprite:createWithSpriteFrame(frameCrop); - spriteCrop:setPosition(10 + 200 + j * 180 - i % 2 * 90, 30 + 10 + i * 95 / 2) - layerFarm:addChild(spriteCrop) - end - end - - -- add moving dog - local spriteDog = creatDog() - layerFarm:addChild(spriteDog) - - -- handing touch events - local touchBeginPoint = nil - local function onTouchBegan(touch, event) - local location = touch:getLocation() - --cclog("onTouchBegan: %0.2f, %0.2f", location.x, location.y) - touchBeginPoint = {x = location.x, y = location.y} - spriteDog.isPaused = true - -- CCTOUCHBEGAN event must return true - return true - end - - local function onTouchMoved(touch, event) - local location = touch:getLocation() - --cclog("onTouchMoved: %0.2f, %0.2f", location.x, location.y) - if touchBeginPoint then - local cx, cy = layerFarm:getPosition() - layerFarm:setPosition(cx + location.x - touchBeginPoint.x, - cy + location.y - touchBeginPoint.y) - touchBeginPoint = {x = location.x, y = location.y} - end - end - - local function onTouchEnded(touch, event) - local location = touch:getLocation() - --cclog("onTouchEnded: %0.2f, %0.2f", location.x, location.y) - touchBeginPoint = nil - spriteDog.isPaused = false - end - - local listener = cc.EventListenerTouchOneByOne:create() - listener:registerScriptHandler(onTouchBegan,cc.Handler.EVENT_TOUCH_BEGAN ) - listener:registerScriptHandler(onTouchMoved,cc.Handler.EVENT_TOUCH_MOVED ) - listener:registerScriptHandler(onTouchEnded,cc.Handler.EVENT_TOUCH_ENDED ) - local eventDispatcher = layerFarm:getEventDispatcher() - eventDispatcher:addEventListenerWithSceneGraphPriority(listener, layerFarm) - - local function onNodeEvent(event) - if "exit" == event then - cc.Director:getInstance():getScheduler():unscheduleScriptEntry(schedulerID) - end - end - layerFarm:registerScriptHandler(onNodeEvent) - - return layerFarm - end - - - -- create menu - local function createLayerMenu() - local layerMenu = cc.Layer:create() - - local menuPopup, menuTools, effectID - - local function menuCallbackClosePopup() - -- stop test sound effect - cc.SimpleAudioEngine:getInstance():stopEffect(effectID) - menuPopup:setVisible(false) - end - - local function menuCallbackOpenPopup() - -- loop test sound effect - local effectPath = cc.FileUtils:getInstance():fullPathForFilename("effect1.wav") - effectID = cc.SimpleAudioEngine:getInstance():playEffect(effectPath) - menuPopup:setVisible(true) - end - - -- add a popup menu - local menuPopupItem = cc.MenuItemImage:create("menu2.png", "menu2.png") - menuPopupItem:setPosition(0, 0) - menuPopupItem:registerScriptTapHandler(menuCallbackClosePopup) - menuPopup = cc.Menu:create(menuPopupItem) - menuPopup:setPosition(origin.x + visibleSize.width / 2, origin.y + visibleSize.height / 2) - menuPopup:setVisible(false) - layerMenu:addChild(menuPopup) - - -- add the left-bottom "tools" menu to invoke menuPopup - local menuToolsItem = cc.MenuItemImage:create("menu1.png", "menu1.png") - menuToolsItem:setPosition(0, 0) - menuToolsItem:registerScriptTapHandler(menuCallbackOpenPopup) - menuTools = cc.Menu:create(menuToolsItem) - local itemWidth = menuToolsItem:getContentSize().width - local itemHeight = menuToolsItem:getContentSize().height - menuTools:setPosition(origin.x + itemWidth/2, origin.y + itemHeight/2) - layerMenu:addChild(menuTools) - - return layerMenu - end - - -- play background music, preload effect - - -- uncomment below for the BlackBerry version - local bgMusicPath = cc.FileUtils:getInstance():fullPathForFilename("background.mp3") - cc.SimpleAudioEngine:getInstance():playMusic(bgMusicPath, true) - local effectPath = cc.FileUtils:getInstance():fullPathForFilename("effect1.wav") - cc.SimpleAudioEngine:getInstance():preloadEffect(effectPath) - - -- run - local sceneGame = cc.Scene:create() - sceneGame:addChild(createLayerFarm()) - sceneGame:addChild(createLayerMenu()) - - if cc.Director:getInstance():getRunningScene() then - cc.Director:getInstance():replaceScene(sceneGame) - else - cc.Director:getInstance():runWithScene(sceneGame) - end end diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioArmatureTest/ArmatureScene.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioArmatureTest/ArmatureScene.cpp index b2cff48fa8..88648b763a 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioArmatureTest/ArmatureScene.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioArmatureTest/ArmatureScene.cpp @@ -1540,27 +1540,31 @@ std::string TestLoadFromBinary::subtitle() const void TestLoadFromBinary::onTouchesEnded(const std::vector& touches, Event* event) { - // remove json created - // remove sync resource if(-1 == m_armatureIndex ) { + m_armatureIndex = -2; // is loading + + // remove json created and need remove their names: exprtjsone & csbs ArmatureDataManager::getInstance()->removeArmatureFileInfo(m_binaryFilesNames[0]); ArmatureDataManager::getInstance()->removeArmatureFileInfo("armature/Cowboy.ExportJson"); ArmatureDataManager::getInstance()->removeArmatureFileInfo("armature/hero.ExportJson"); ArmatureDataManager::getInstance()->removeArmatureFileInfo("armature/horse.ExportJson"); ArmatureDataManager::getInstance()->removeArmatureFileInfo("armature/HeroAnimation.ExportJson"); ArmatureDataManager::getInstance()->removeArmatureFileInfo("armature/testEasing.ExportJson"); + for( int i = 0; i < BINARYFILECOUNT; i++) + { + ArmatureDataManager::getInstance()->removeArmatureFileInfo(m_binaryFilesNames[i]); + } for( int i = 0; i < BINARYFILECOUNT; i++) { ArmatureDataManager::getInstance()->addArmatureFileInfoAsync(m_binaryFilesNames[i], this, schedule_selector(TestLoadFromBinary::dataLoaded)); } - m_armatureIndex = -2; // is loading } else if(m_armatureIndex>=0 && m_armature != nullptr) { - this->removeChild(m_armature); + m_armature->removeFromParent(); m_armatureIndex = m_armatureIndex==BINARYFILECOUNT-1 ? 0 : m_armatureIndex+1; m_armature = Armature::create(m_armatureNames[m_armatureIndex]); m_armature->setPosition(Vec2(VisibleRect::center().x, VisibleRect::center().y)); diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/SceneEditorTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/SceneEditorTest.cpp index 453b2189f9..ebc3dcb8e6 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/SceneEditorTest.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/SceneEditorTest.cpp @@ -277,6 +277,7 @@ cocos2d::Node* LoadSceneEdtiorFileTest::createGameScene() { _filePath = "scenetest/LoadSceneEdtiorFileTest/FishJoy2.json"; //default is json _rootNode = SceneReader::getInstance()->createNodeWithSceneFile(_filePath.c_str()); + ActionManagerEx::getInstance()->playActionByName("startMenu_1.json", "Animation1"); if (_rootNode == nullptr) { return nullptr; @@ -820,7 +821,6 @@ void TriggerTest::onEnter() listener->onTouchCancelled = CC_CALLBACK_2(SceneEditorTestLayer::onTouchCancelled, this); dispatcher->addEventListenerWithFixedPriority(listener, 1); _touchListener = listener; - sendEvent(TRIGGEREVENT_ENTERSCENE); } @@ -879,4 +879,5 @@ cocos2d::Node* TriggerTest::createGameScene() } void TriggerTest::defaultPlay() { + sendEvent(TRIGGEREVENT_ENTERSCENE); } diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/acts.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/acts.cpp index d48f64e1e7..28eb7a08a3 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/acts.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/acts.cpp @@ -189,7 +189,7 @@ void TMoveTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -197,7 +197,7 @@ void TMoveTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _pos.x = atof(str); + _pos.x = utils::atof(str); } } else if (key == "y") @@ -311,7 +311,7 @@ void TMoveBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -319,14 +319,14 @@ void TMoveBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _pos.x = atof(str); + _pos.x = utils::atof(str); } } else if (key == "y") { if (str != nullptr) { - _pos.y = atof(str); + _pos.y = utils::atof(str); } } else if (key == "IsReverse") @@ -424,7 +424,7 @@ void TRotateTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExp { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -432,7 +432,7 @@ void TRotateTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExp { if (str != nullptr) { - _deltaAngle = atof(str); + _deltaAngle = utils::atof(str); } } } @@ -537,7 +537,7 @@ void TRotateBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExp { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -545,7 +545,7 @@ void TRotateBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExp { if (str != nullptr) { - _deltaAngle = atof(str); + _deltaAngle = utils::atof(str); } } else if (key == "IsReverse") @@ -647,7 +647,7 @@ void TScaleTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpC { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -655,14 +655,14 @@ void TScaleTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpC { if (str != nullptr) { - _scale.x = atof(str); + _scale.x = utils::atof(str); } } else if (key == "ScaleY") { if (str != nullptr) { - _scale.y = atof(str); + _scale.y = utils::atof(str); } } } @@ -771,7 +771,7 @@ void TScaleBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpC { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -779,14 +779,14 @@ void TScaleBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpC { if (str != nullptr) { - _scale.x = atof(str); + _scale.x = utils::atof(str); } } else if (key == "ScaleY") { if (str != nullptr) { - _scale.y = atof(str); + _scale.y = utils::atof(str); } } else if (key == "IsReverse") @@ -889,7 +889,7 @@ void TSkewTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -897,14 +897,14 @@ void TSkewTo::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _skew.x = atof(str); + _skew.x = utils::atof(str); } } else if (key == "SkewY") { if (str != nullptr) { - _skew.y = atof(str); + _skew.y = utils::atof(str); } } } @@ -1012,7 +1012,7 @@ void TSkewBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _duration = atof(str); + _duration = utils::atof(str); } } @@ -1020,14 +1020,14 @@ void TSkewBy::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stExpCo { if (str != nullptr) { - _skew.x = atof(str); + _skew.x = utils::atof(str); } } else if (key == "SkewY") { if (str != nullptr) { - _skew.y = atof(str); + _skew.y = utils::atof(str); } } else if (key == "IsReverse") diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/cons.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/cons.cpp index 9ed21d1579..1810fc2112 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/cons.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioSceneTest/TriggerCode/cons.cpp @@ -64,7 +64,7 @@ void TimeElapsed::serialize(cocostudio::CocoLoader *pCocoLoader, cocostudio::stE { if (str != nullptr) { - _totalTime = atof(str); //DICTOOL->getFloatValue_json(subDict, "value"); + _totalTime = utils::atof(str); //DICTOOL->getFloatValue_json(subDict, "value"); } } } diff --git a/tests/cpp-tests/Classes/ExtensionsTest/NetworkTest/HttpClientTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/NetworkTest/HttpClientTest.cpp index ed957a8ef4..a05c87a6c6 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/NetworkTest/HttpClientTest.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/NetworkTest/HttpClientTest.cpp @@ -369,12 +369,12 @@ void HttpClientTest::onHttpRequestCompleted(HttpClient *sender, HttpResponse *re // dump data std::vector *buffer = response->getResponseData(); - printf("Http Test, dump data: "); + log("Http Test, dump data: "); for (unsigned int i = 0; i < buffer->size(); i++) { - printf("%c", (*buffer)[i]); + log("%c", (*buffer)[i]); } - printf("\n"); + log("\n"); if (response->getHttpRequest()->getReferenceCount() != 2) { log("request ref count not 2, is %d", response->getHttpRequest()->getReferenceCount()); diff --git a/tests/cpp-tests/Classes/PerformanceTest/PerformanceAllocTest.cpp b/tests/cpp-tests/Classes/PerformanceTest/PerformanceAllocTest.cpp index 141f7c9c33..7aee682d4f 100644 --- a/tests/cpp-tests/Classes/PerformanceTest/PerformanceAllocTest.cpp +++ b/tests/cpp-tests/Classes/PerformanceTest/PerformanceAllocTest.cpp @@ -230,7 +230,7 @@ void NodeCreateTest::initWithQuantityOfNodes(unsigned int nNodes) { PerformceAllocScene::initWithQuantityOfNodes(nNodes); - printf("Size of Node: %lu\n", sizeof(Node)); + log("Size of Node: %u\n", sizeof(Node)); scheduleUpdate(); } @@ -278,7 +278,7 @@ void NodeDeallocTest::initWithQuantityOfNodes(unsigned int nNodes) { PerformceAllocScene::initWithQuantityOfNodes(nNodes); - printf("Size of Node: %lu\n", sizeof(Node)); + log("Size of Node: %u\n", sizeof(Node)); scheduleUpdate(); } @@ -331,7 +331,7 @@ void SpriteCreateEmptyTest::initWithQuantityOfNodes(unsigned int nNodes) { PerformceAllocScene::initWithQuantityOfNodes(nNodes); - printf("Size of Sprite: %lu\n", sizeof(Sprite)); + log("Size of Sprite: %u\n", sizeof(Sprite)); scheduleUpdate(); } @@ -381,7 +381,7 @@ void SpriteCreateTest::initWithQuantityOfNodes(unsigned int nNodes) { PerformceAllocScene::initWithQuantityOfNodes(nNodes); - printf("Size of Sprite: %lu\n", sizeof(Sprite)); + log("Size of Sprite: %u\n", sizeof(Sprite)); scheduleUpdate(); } @@ -431,7 +431,7 @@ void SpriteDeallocTest::initWithQuantityOfNodes(unsigned int nNodes) { PerformceAllocScene::initWithQuantityOfNodes(nNodes); - printf("Size of sprite: %lu\n", sizeof(Sprite)); + log("Size of sprite: %u\n", sizeof(Sprite)); scheduleUpdate(); } diff --git a/tests/cpp-tests/Classes/PerformanceTest/PerformanceContainerTest.cpp b/tests/cpp-tests/Classes/PerformanceTest/PerformanceContainerTest.cpp index fd5ddf10a2..2ebe66e483 100644 --- a/tests/cpp-tests/Classes/PerformanceTest/PerformanceContainerTest.cpp +++ b/tests/cpp-tests/Classes/PerformanceTest/PerformanceContainerTest.cpp @@ -156,7 +156,7 @@ void PerformanceContainerScene::initWithQuantityOfNodes(unsigned int nNodes) addChild(menuLayer); menuLayer->release(); - printf("Size of Node: %lu\n", sizeof(Node)); + log("Size of Node: %u\n", sizeof(Node)); int oldFontSize = MenuItemFont::getFontSize(); MenuItemFont::setFontSize(24); diff --git a/tests/cpp-tests/Classes/Sprite3DTest/Sprite3DTest.cpp b/tests/cpp-tests/Classes/Sprite3DTest/Sprite3DTest.cpp index 6ee4a01e83..e14ca0d5ab 100644 --- a/tests/cpp-tests/Classes/Sprite3DTest/Sprite3DTest.cpp +++ b/tests/cpp-tests/Classes/Sprite3DTest/Sprite3DTest.cpp @@ -43,7 +43,10 @@ static int sceneIdx = -1; static std::function createFunctions[] = { CL(Sprite3DBasicTest), +#if (CC_TARGET_PLATFORM != CC_PLATFORM_WP8) && (CC_TARGET_PLATFORM != CC_PLATFORM_WINRT) + // 3DEffect use custom shader which is not supported on WP8/WinRT yet. CL(Sprite3DEffectTest), +#endif CL(Sprite3DWithSkinTest), CL(Animate3DTest) }; diff --git a/tests/cpp-tests/Classes/Texture2dTest/Texture2dTest.cpp b/tests/cpp-tests/Classes/Texture2dTest/Texture2dTest.cpp index eb3a4e1e65..ebc10b503e 100644 --- a/tests/cpp-tests/Classes/Texture2dTest/Texture2dTest.cpp +++ b/tests/cpp-tests/Classes/Texture2dTest/Texture2dTest.cpp @@ -1978,36 +1978,20 @@ void TextureMemoryAlloc::updateImage(cocos2d::Ref *sender) switch (tag) { case 0: - file = "Images/background.png"; + file = "Images/test_image.png"; break; -#if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) - // android can not pack .gz file into apk file case 1: - file = "Images/fire_rgba8888.pvr"; + file = "Images/test_image_rgba8888.pvr"; break; case 2: - file = "Images/grossini_pvr_rgba8888.pvr"; + file = "Images/test_image_rgb888.pvr"; break; case 3: - file = "Images/grossini_pvr_rgba4444.pvr"; + file = "Images/test_image_rgba4444.pvr"; break; case 4: file = "Images/test_image_a8.pvr"; break; -#else - case 1: - file = "Images/test_image_rgba4444.pvr.gz"; - break; - case 2: - file = "Images/test_image_rgba4444.pvr.gz"; - break; - case 3: - file = "Images/test_image_rgba4444.pvr.gz"; - break; - case 4: - file = "Images/test_image_rgba4444.pvr.gz"; - break; -#endif } _background = Sprite::create(file.c_str()); diff --git a/tests/cpp-tests/Classes/TileMapTest/TileMapTest2.cpp b/tests/cpp-tests/Classes/TileMapTest/TileMapTest2.cpp index f89cb73e62..bac5608530 100644 --- a/tests/cpp-tests/Classes/TileMapTest/TileMapTest2.cpp +++ b/tests/cpp-tests/Classes/TileMapTest/TileMapTest2.cpp @@ -4,6 +4,7 @@ #include "2d/CCFastTMXLayer.h" #include "2d/CCFastTMXTiledMap.h" + namespace { enum @@ -287,7 +288,7 @@ TMXOrthoTestNew::TMXOrthoTestNew() //auto color = LayerColor::create( Color4B(64,64,64,255) ); //addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test2.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test2.tmx"); addChild(map, 0, kTagTileMap); @@ -330,7 +331,7 @@ std::string TMXOrthoTestNew::title() const //------------------------------------------------------------------ TMXOrthoTest2New::TMXOrthoTest2New() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test1.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test1.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -351,7 +352,7 @@ std::string TMXOrthoTest2New::title() const //------------------------------------------------------------------ TMXOrthoTest3New::TMXOrthoTest3New() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test3.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test3.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -373,7 +374,7 @@ std::string TMXOrthoTest3New::title() const //------------------------------------------------------------------ TMXOrthoTest4New::TMXOrthoTest4New() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test4.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test4.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s1 = map->getContentSize(); @@ -402,7 +403,7 @@ void TMXOrthoTest4New::removeSprite(float dt) { unschedule(schedule_selector(TMXOrthoTest4New::removeSprite)); - auto map = static_cast( getChildByTag(kTagTileMap) ); + auto map = static_cast( getChildByTag(kTagTileMap) ); auto layer = map->getLayer("Layer 0"); auto s = layer->getLayerSize(); @@ -435,7 +436,7 @@ TMXReadWriteTestNew::TMXReadWriteTestNew() { _gid = 0; - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test2.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test2.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -501,8 +502,8 @@ void TMXReadWriteTestNew::removeSprite(Node* sender) void TMXReadWriteTestNew::updateCol(float dt) { - auto map = (FastTMXTiledMap*)getChildByTag(kTagTileMap); - auto layer = (FastTMXLayer*)map->getChildByTag(0); + auto map = (cocos2d::experimental::TMXTiledMap*)getChildByTag(kTagTileMap); + auto layer = (cocos2d::experimental::TMXLayer*)map->getChildByTag(0); ////----CCLOG("++++atlas quantity: %d", layer->textureAtlas()->getTotalQuads()); ////----CCLOG("++++children: %d", layer->getChildren()->count() ); @@ -522,8 +523,8 @@ void TMXReadWriteTestNew::repaintWithGID(float dt) { // unschedule:_cmd); - auto map = (FastTMXTiledMap*)getChildByTag(kTagTileMap); - auto layer = (FastTMXLayer*)map->getChildByTag(0); + auto map = (cocos2d::experimental::TMXTiledMap*)getChildByTag(kTagTileMap); + auto layer = (cocos2d::experimental::TMXLayer*)map->getChildByTag(0); auto s = layer->getLayerSize(); for( int x=0; xgetChildByTag(0); + auto map = (cocos2d::experimental::TMXTiledMap*)getChildByTag(kTagTileMap); + auto layer = (cocos2d::experimental::TMXLayer*)map->getChildByTag(0); auto s = layer->getLayerSize(); for( int y=0; y< s.height; y++ ) @@ -565,7 +566,7 @@ TMXHexTestNew::TMXHexTestNew() auto color = LayerColor::create( Color4B(64,64,64,255) ); addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/hexa-test.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/hexa-test.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -587,7 +588,7 @@ TMXIsoTestNew::TMXIsoTestNew() auto color = LayerColor::create( Color4B(64,64,64,255) ); addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/iso-test.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test.tmx"); addChild(map, 0, kTagTileMap); // move map to the center of the screen @@ -611,7 +612,7 @@ TMXIsoTest1New::TMXIsoTest1New() auto color = LayerColor::create( Color4B(64,64,64,255) ); addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/iso-test1.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test1.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -635,7 +636,7 @@ TMXIsoTest2New::TMXIsoTest2New() auto color = LayerColor::create( Color4B(64,64,64,255) ); addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/iso-test2.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test2.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -662,7 +663,7 @@ TMXUncompressedTestNew::TMXUncompressedTestNew() auto color = LayerColor::create( Color4B(64,64,64,255) ); addChild(color, -1); - auto map = FastTMXTiledMap::create("TileMaps/iso-test2-uncompressed.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test2-uncompressed.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -675,11 +676,11 @@ TMXUncompressedTestNew::TMXUncompressedTestNew() //unsupported // // testing release map -// FastTMXLayer* layer; +// TMXLayer* layer; // // auto& children = map->getChildren(); // for(const auto &node : children) { -// layer= static_cast(node); +// layer= static_cast(node); // layer->releaseMap(); // } @@ -697,7 +698,7 @@ std::string TMXUncompressedTestNew::title() const //------------------------------------------------------------------ TMXTilesetTestNew::TMXTilesetTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test5.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test5.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -716,7 +717,7 @@ std::string TMXTilesetTestNew::title() const //------------------------------------------------------------------ TMXOrthoObjectsTestNew::TMXOrthoObjectsTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/ortho-objects.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/ortho-objects.tmx"); addChild(map, -1, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -743,7 +744,7 @@ void TMXOrthoObjectsTestNew::onDraw(const Mat4 &transform, uint32_t flags) director->pushMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); director->loadMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW, transform); - auto map = static_cast( getChildByTag(kTagTileMap) ); + auto map = static_cast( getChildByTag(kTagTileMap) ); auto pos = map->getPosition(); auto group = map->getObjectGroup("Object Group 1"); @@ -790,7 +791,7 @@ std::string TMXOrthoObjectsTestNew::subtitle() const TMXIsoObjectsTestNew::TMXIsoObjectsTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/iso-test-objectgroup.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test-objectgroup.tmx"); addChild(map, -1, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -818,7 +819,7 @@ void TMXIsoObjectsTestNew::onDraw(const Mat4 &transform, uint32_t flags) director->pushMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); director->loadMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW, transform); - auto map = (FastTMXTiledMap*) getChildByTag(kTagTileMap); + auto map = (cocos2d::experimental::TMXTiledMap*) getChildByTag(kTagTileMap); auto pos = map->getPosition(); auto group = map->getObjectGroup("Object Group 1"); @@ -863,13 +864,13 @@ std::string TMXIsoObjectsTestNew::subtitle() const TMXResizeTestNew::TMXResizeTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test5.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test5.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); CCLOG("ContentSize: %f, %f", s.width,s.height); - FastTMXLayer* layer; + cocos2d::experimental::TMXLayer* layer; layer = map->getLayer("Layer 0"); auto ls = layer->getLayerSize(); @@ -900,7 +901,7 @@ std::string TMXResizeTestNew::subtitle() const //------------------------------------------------------------------ TMXIsoZorderNew::TMXIsoZorderNew() { - auto map = FastTMXTiledMap::create("TileMaps/iso-test-zorder.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test-zorder.tmx"); addChild(map, 0, kTagTileMap); auto s = map->getContentSize(); @@ -969,7 +970,7 @@ std::string TMXIsoZorderNew::subtitle() const //------------------------------------------------------------------ TMXOrthoZorderNew::TMXOrthoZorderNew() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test-zorder.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test-zorder.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -1030,7 +1031,7 @@ std::string TMXOrthoZorderNew::subtitle() const //------------------------------------------------------------------ TMXIsoVertexZNew::TMXIsoVertexZNew() { - auto map = FastTMXTiledMap::create("TileMaps/iso-test-vertexz.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test-vertexz.tmx"); addChild(map, 0, kTagTileMap); auto s = map->getContentSize(); @@ -1102,7 +1103,7 @@ std::string TMXIsoVertexZNew::subtitle() const //------------------------------------------------------------------ TMXOrthoVertexZNew::TMXOrthoVertexZNew() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test-vertexz.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test-vertexz.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -1173,7 +1174,7 @@ std::string TMXOrthoVertexZNew::subtitle() const //------------------------------------------------------------------ TMXIsoMoveLayerNew::TMXIsoMoveLayerNew() { - auto map = FastTMXTiledMap::create("TileMaps/iso-test-movelayer.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test-movelayer.tmx"); addChild(map, 0, kTagTileMap); map->setPosition(Vec2(-700,-50)); @@ -1200,7 +1201,7 @@ std::string TMXIsoMoveLayerNew::subtitle() const //------------------------------------------------------------------ TMXOrthoMoveLayerNew::TMXOrthoMoveLayerNew() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test-movelayer.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test-movelayer.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -1225,7 +1226,7 @@ std::string TMXOrthoMoveLayerNew::subtitle() const TMXTilePropertyTestNew::TMXTilePropertyTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/ortho-tile-property.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/ortho-tile-property.tmx"); addChild(map ,0 ,kTagTileMap); for(int i=1;i<=20;i++){ @@ -1254,7 +1255,7 @@ std::string TMXTilePropertyTestNew::subtitle() const TMXOrthoFlipTestNew::TMXOrthoFlipTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/ortho-rotation-test.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/ortho-rotation-test.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -1277,7 +1278,7 @@ std::string TMXOrthoFlipTestNew::title() const TMXOrthoFlipRunTimeTestNew::TMXOrthoFlipRunTimeTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/ortho-rotation-test.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/ortho-rotation-test.tmx"); addChild(map, 0, kTagTileMap); auto s = map->getContentSize(); @@ -1301,7 +1302,7 @@ std::string TMXOrthoFlipRunTimeTestNew::subtitle() const void TMXOrthoFlipRunTimeTestNew::flipIt(float dt) { - auto map = (FastTMXTiledMap*) getChildByTag(kTagTileMap); + auto map = (cocos2d::experimental::TMXTiledMap*) getChildByTag(kTagTileMap); auto layer = map->getLayer("Layer 0"); //blue diamond @@ -1349,7 +1350,7 @@ TMXOrthoFromXMLTestNew::TMXOrthoFromXMLTestNew() auto str = String::createWithContentsOfFile(FileUtils::getInstance()->fullPathForFilename(file.c_str()).c_str()); CCASSERT(str != nullptr, "Unable to open file"); - auto map = FastTMXTiledMap::createWithXML(str->getCString() ,resources.c_str()); + auto map = cocos2d::experimental::TMXTiledMap::createWithXML(str->getCString() ,resources.c_str()); addChild(map, 0, kTagTileMap); auto s = map->getContentSize(); @@ -1375,7 +1376,7 @@ TMXOrthoXMLFormatTestNew::TMXOrthoXMLFormatTestNew() // 1. load xml format tilemap // 2. gid lower than firstgid is ignored // 3. firstgid in tsx is ignored, tile property in tsx loaded correctly. - auto map = FastTMXTiledMap::create("TileMaps/xml-test.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/xml-test.tmx"); addChild(map, 0, kTagTileMap); auto s = map->getContentSize(); @@ -1401,7 +1402,7 @@ std::string TMXOrthoXMLFormatTestNew::title() const //------------------------------------------------------------------ TMXBug987New::TMXBug987New() { - auto map = FastTMXTiledMap::create("TileMaps/orthogonal-test6.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/orthogonal-test6.tmx"); addChild(map, 0, kTagTileMap); Size CC_UNUSED s1 = map->getContentSize(); @@ -1429,7 +1430,7 @@ std::string TMXBug987New::subtitle() const //------------------------------------------------------------------ TMXBug787New::TMXBug787New() { - auto map = FastTMXTiledMap::create("TileMaps/iso-test-bug787.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/iso-test-bug787.tmx"); addChild(map, 0, kTagTileMap); map->setScale(0.25f); @@ -1452,7 +1453,7 @@ std::string TMXBug787New::subtitle() const //------------------------------------------------------------------ TMXGIDObjectsTestNew::TMXGIDObjectsTestNew() { - auto map = FastTMXTiledMap::create("TileMaps/test-object-layer.tmx"); + auto map = cocos2d::experimental::TMXTiledMap::create("TileMaps/test-object-layer.tmx"); addChild(map, -1, kTagTileMap); Size CC_UNUSED s = map->getContentSize(); @@ -1477,7 +1478,7 @@ void TMXGIDObjectsTestNew::onDraw(const Mat4 &transform, uint32_t flags) director->pushMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW); director->loadMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW, transform); - auto map = (FastTMXTiledMap*)getChildByTag(kTagTileMap); + auto map = (cocos2d::experimental::TMXTiledMap*)getChildByTag(kTagTileMap); auto pos = map->getPosition(); auto group = map->getObjectGroup("Object Layer 1"); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp index e413761014..7f56938d5e 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp @@ -147,7 +147,7 @@ g_guisTests[] = UISceneManager* sceneManager = UISceneManager::sharedUISceneManager(); sceneManager->setCurrentUISceneId(kUITextFieldTest); sceneManager->setMinUISceneId(kUITextFieldTest); - sceneManager->setMaxUISceneId(kUITextFieldTest_LineWrap); + sceneManager->setMaxUISceneId(kUITextFieldTest_TrueTypeFont); Scene* scene = sceneManager->currentUIScene(); Director::getInstance()->replaceScene(scene); } diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest.cpp index 7b600324aa..05b7a8055b 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest.cpp @@ -130,7 +130,7 @@ void CocostudioParserTestScene::onEnter() //#endif MenuItemLabel* pMenuItem = MenuItemLabel::create(label, CC_CALLBACK_1(CocostudioParserTestScene::BackCallback, this)); - Menu* pMenu = Menu::create(pMenuItem, NULL); + Menu* pMenu = Menu::create(pMenuItem, nullptr); pMenu->setPosition( Vec2::ZERO ); pMenuItem->setPosition( Vec2( VisibleRect::right().x - 50, VisibleRect::bottom().y + 25) ); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest/CocostudioParserJsonTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest/CocostudioParserJsonTest.cpp index 689b3e1e4f..822bbed3fe 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest/CocostudioParserJsonTest.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocostudioParserTest/CocostudioParserJsonTest.cpp @@ -76,7 +76,7 @@ void CocostudioParserJsonScene::onEnter() //#endif MenuItemLabel* pMenuItem = MenuItemLabel::create(label, CC_CALLBACK_1(CocostudioParserJsonScene::BackCallback, this)); - Menu* pMenu = Menu::create(pMenuItem, NULL); + Menu* pMenu = Menu::create(pMenuItem, nullptr); pMenu->setPosition( Vec2::ZERO ); pMenuItem->setPosition( Vec2( VisibleRect::right().x - 50, VisibleRect::bottom().y + 25) ); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UILoadingBarTest/UILoadingBarTest_Editor.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UILoadingBarTest/UILoadingBarTest_Editor.cpp index d651621990..96081b975e 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UILoadingBarTest/UILoadingBarTest_Editor.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UILoadingBarTest/UILoadingBarTest_Editor.cpp @@ -19,6 +19,7 @@ UILoadingBarTest_Editor::~UILoadingBarTest_Editor() void UILoadingBarTest_Editor::switchLoadMethod(cocos2d::Ref *pSender) { MenuItemToggle *item = (MenuItemToggle*)pSender; + _count = 0; if (item->getSelectedIndex() == 0){ _layout->removeFromParentAndCleanup(true); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIRichTextTest/UIRichTextTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIRichTextTest/UIRichTextTest.cpp index d69288aa6b..36bdf49f94 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIRichTextTest/UIRichTextTest.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIRichTextTest/UIRichTextTest.cpp @@ -42,9 +42,9 @@ bool UIRichTextTest::init() _richText->ignoreContentAdaptWithSize(false); _richText->setContentSize(Size(100, 100)); - RichElementText* re1 = RichElementText::create(1, Color3B::WHITE, 255, "This color is white. ", "Helvetica", 10); + RichElementText* re1 = RichElementText::create(1, Color3B::WHITE, 255, "中国中国中国中国中国中国中国中国中国中国", "Marker Felt", 10); RichElementText* re2 = RichElementText::create(2, Color3B::YELLOW, 255, "And this is yellow. ", "Helvetica", 10); - RichElementText* re3 = RichElementText::create(3, Color3B::BLUE, 255, "This one is blue. ", "Helvetica", 10); + RichElementText* re3 = RichElementText::create(3, Color3B::BLUE, 255, "ご静聴ありがとうございました!!ご静聴ありがとうございました!!", "Helvetica", 10); RichElementText* re4 = RichElementText::create(4, Color3B::GREEN, 255, "And green. ", "Helvetica", 10); RichElementText* re5 = RichElementText::create(5, Color3B::RED, 255, "Last one is red ", "Helvetica", 10); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp index 69ad20c90a..edbecf2bd2 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp @@ -83,6 +83,7 @@ static const char* s_testArray[] = "UITextFieldTest_MaxLength", "UITextFieldTest_Password", "UITextFieldTest_LineWrap", + "UITextFieldTest_TrueTypeFont", "UILayoutTest", "UILayoutTest_Color", "UILayoutTest_Gradient", @@ -159,7 +160,6 @@ Scene *UISceneManager::nextUIScene() { _currentUISceneId = _minUISceneId; } -// _currentUISceneId = (_currentUISceneId + 1) % kUITestMax; return currentUIScene(); } @@ -171,13 +171,6 @@ Scene *UISceneManager::previousUIScene() { _currentUISceneId = _maxUISceneId; } - /* - _currentUISceneId = _currentUISceneId - 1; - if (_currentUISceneId < 0) - { - _currentUISceneId = kUITestMax - 1; - } - */ return currentUIScene(); } @@ -207,22 +200,6 @@ Scene *UISceneManager::currentUIScene() case kUISliderTest_Scale9: return UISliderTest_Scale9::sceneWithTitle(s_testArray[_currentUISceneId]); - /* - case kUIPotentiometerTest: - return UIPotentiometerTest::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - - /* - case kUISwitchTest_Horizontal: - return UISwitchTest_Horizontal::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUISwitchTest_Vertical: - return UISwitchTest_Vertical::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUISwitchTest_VerticalAndTitleVertical: - return UISwitchTest_VerticalAndTitleVertical::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - case kUIImageViewTest: return UIImageViewTest::sceneWithTitle(s_testArray[_currentUISceneId]); @@ -241,29 +218,6 @@ Scene *UISceneManager::currentUIScene() case kUILoadingBarTest_Right_Scale9: return UILoadingBarTest_Right_Scale9::sceneWithTitle(s_testArray[_currentUISceneId]); - /* - case kUIProgressTimerTest_Radial: - return UIProgressTimerTest_Radial::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_Horizontal: - return UIProgressTimerTest_Horizontal::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_Vertical: - return UIProgressTimerTest_Vertical::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_RadialMidpointChanged: - return UIProgressTimerTest_RadialMidpointChanged::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_BarVarious: - return UIProgressTimerTest_BarVarious::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_BarTintAndFade: - return UIProgressTimerTest_BarTintAndFade::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIProgressTimerTest_WithSpriteFrame: - return UIProgressTimerTest_WithSpriteFrame::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - case kUITextAtlasTest: return UITextAtlasTest::sceneWithTitle(s_testArray[_currentUISceneId]); @@ -295,7 +249,9 @@ Scene *UISceneManager::currentUIScene() case kUITextFieldTest_LineWrap: return UITextFieldTest_LineWrap::sceneWithTitle(s_testArray[_currentUISceneId]); - + case kUITextFieldTest_TrueTypeFont: + return UITextFieldTest_TrueTypeFont::sceneWithTitle(s_testArray[_currentUISceneId]); + case kUILayoutTest: return UILayoutTest::sceneWithTitle(s_testArray[_currentUISceneId]); @@ -323,11 +279,6 @@ Scene *UISceneManager::currentUIScene() case kUILayoutTest_Layout_Relative_Location: return UILayoutTest_Layout_Relative_Location::sceneWithTitle(s_testArray[_currentUISceneId]); - /* - case kUILayoutTest_Layout_Grid: - return UILayoutTest_Layout_Grid::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - case kUIScrollViewTest_Vertical: return UIScrollViewTest_Vertical::sceneWithTitle(s_testArray[_currentUISceneId]); @@ -353,22 +304,6 @@ Scene *UISceneManager::currentUIScene() case kUIListViewTest_Horizontal: return UIListViewTest_Horizontal::sceneWithTitle(s_testArray[_currentUISceneId]); - /* - case kUIGridViewTest_Mode_Column: - return UIGridViewTest_Mode_Column::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIGridViewTest_Mode_Row: - return UIGridViewTest_Mode_Row::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - - /* - case kUIPickerViewTest_Vertical: - return UIPickerViewTest_Vertical::sceneWithTitle(s_testArray[_currentUISceneId]); - - case kUIPickerViewTest_Horizontal: - return UIPickerViewTest_Horizontal::sceneWithTitle(s_testArray[_currentUISceneId]); - */ - case kUIWidgetAddNodeTest: return UIWidgetAddNodeTest::sceneWithTitle(s_testArray[_currentUISceneId]); diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h index 7201d4422d..0dd94ad395 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h @@ -72,6 +72,7 @@ enum kUITextFieldTest_MaxLength, kUITextFieldTest_Password, kUITextFieldTest_LineWrap, + kUITextFieldTest_TrueTypeFont, kUILayoutTest, kUILayoutTest_Color, kUILayoutTest_Gradient, diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.cpp index 97d56c47b3..29e14b8389 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.cpp @@ -275,7 +275,8 @@ bool UITextFieldTest_LineWrap::init() // Create the textfield TextField* textField = TextField::create("input words here","fonts/Marker Felt.ttf",30); textField->ignoreContentAdaptWithSize(false); - textField->setContentSize(Size(240, 160)); + ((Label*)(textField->getVirtualRenderer()))->setLineBreakWithoutSpace(true); + textField->setContentSize(Size(240, 70)); textField->setTextHorizontalAlignment(TextHAlignment::CENTER); textField->setTextVerticalAlignment(TextVAlignment::CENTER); textField->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f)); @@ -328,3 +329,80 @@ void UITextFieldTest_LineWrap::textFieldEvent(Ref *pSender, TextField::EventType break; } } + +// UITextFieldTest_TrueTypeFont +UITextFieldTest_TrueTypeFont::UITextFieldTest_TrueTypeFont() +: _displayValueLabel(nullptr) +{ + +} + +UITextFieldTest_TrueTypeFont::~UITextFieldTest_TrueTypeFont() +{ +} + +bool UITextFieldTest_TrueTypeFont::init() +{ + if (UIScene::init()) + { + Size widgetSize = _widget->getContentSize(); + + // Add a label in which the textfield events will be displayed + _displayValueLabel = Text::create("True Type Font Test - No Event","fonts/Marker Felt.ttf",32); + _displayValueLabel->setAnchorPoint(Vec2(0.5f, -1.0f)); + _displayValueLabel->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f + _displayValueLabel->getContentSize().height * 1.5f)); + _uiLayer->addChild(_displayValueLabel); + + // Add the alert + Text* alert = Text::create("TextField","fonts/Marker Felt.ttf",30); + alert->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f - alert->getContentSize().height * 3.075f)); + _uiLayer->addChild(alert); + + // Create the textfield + TextField* textField = TextField::create("input words here","fonts/A Damn Mess.ttf",30); + + textField->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f)); + textField->addEventListener(CC_CALLBACK_2(UITextFieldTest_TrueTypeFont::textFieldEvent, this)); + _uiLayer->addChild(textField); + + + return true; + } + return false; +} + +void UITextFieldTest_TrueTypeFont::textFieldEvent(Ref *pSender, TextField::EventType type) +{ + switch (type) + { + case TextField::EventType::ATTACH_WITH_IME: + { + TextField* textField = dynamic_cast(pSender); + Size screenSize = CCDirector::getInstance()->getWinSize(); + textField->runAction(CCMoveTo::create(0.225f, + Vec2(screenSize.width / 2.0f, screenSize.height / 2.0f + textField->getContentSize().height / 2.0f))); + _displayValueLabel->setString(String::createWithFormat("attach with IME")->getCString()); + } + break; + + case TextField::EventType::DETACH_WITH_IME: + { + TextField* textField = dynamic_cast(pSender); + Size screenSize = CCDirector::getInstance()->getWinSize(); + textField->runAction(CCMoveTo::create(0.175f, Vec2(screenSize.width / 2.0f, screenSize.height / 2.0f))); + _displayValueLabel->setString(String::createWithFormat("detach with IME")->getCString()); + } + break; + + case TextField::EventType::INSERT_TEXT: + _displayValueLabel->setString(String::createWithFormat("insert words")->getCString()); + break; + + case TextField::EventType::DELETE_BACKWARD: + _displayValueLabel->setString(String::createWithFormat("delete word")->getCString()); + break; + + default: + break; + } +} diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.h b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.h index 0515b51bfb..e44798cb7f 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.h +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextFieldTest/UITextFieldTest.h @@ -78,4 +78,17 @@ protected: UI_SCENE_CREATE_FUNC(UITextFieldTest_LineWrap) Text* _displayValueLabel; }; + +class UITextFieldTest_TrueTypeFont : public UIScene +{ +public: + UITextFieldTest_TrueTypeFont(); + ~UITextFieldTest_TrueTypeFont(); + bool init(); + void textFieldEvent(Ref* pSender, TextField::EventType type); + +protected: + UI_SCENE_CREATE_FUNC(UITextFieldTest_TrueTypeFont) + Text* _displayValueLabel; +}; #endif /* defined(__TestCpp__UITextFieldTest__) */ diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextTest/UITextTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextTest/UITextTest.cpp index 98dcbfba44..3496c455b2 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextTest/UITextTest.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UITextTest/UITextTest.cpp @@ -40,10 +40,25 @@ bool UITextTest_LineWrap::init() _uiLayer->addChild(alert); // Create the line wrap - Text* text = Text::create("Text can line wrap","AmericanTypewriter",32); + Text* text = Text::create("TextArea Widget can line wrap","AmericanTypewriter",32); text->ignoreContentAdaptWithSize(false); text->setContentSize(Size(280, 150)); text->setTextHorizontalAlignment(TextHAlignment::CENTER); + text->setTouchScaleChangeEnabled(true); + text->setTouchEnabled(true); + text->addTouchEventListener([=](Ref* sender, Widget::TouchEventType type) + { + if (type == Widget::TouchEventType::ENDED) + { + if ((int)text->getContentSize().width == 280) + { + text->setContentSize(Size(380,100)); + }else + { + text->setContentSize(Size(280, 150)); + } + } + }); text->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f - text->getContentSize().height / 8.0f)); _uiLayer->addChild(text); diff --git a/tests/cpp-tests/Classes/controller.cpp b/tests/cpp-tests/Classes/controller.cpp index e02aed5089..355ef40b9c 100644 --- a/tests/cpp-tests/Classes/controller.cpp +++ b/tests/cpp-tests/Classes/controller.cpp @@ -77,7 +77,9 @@ Controller g_aTestNames[] = { { "Node: Sprite", [](){return new SpriteTestScene(); } }, { "Node: Sprite3D", [](){ return new Sprite3DTestScene(); }}, { "Node: TileMap", [](){return new TileMapTestScene(); } }, +#if CC_TARGET_PLATFORM != CC_PLATFORM_WP8 { "Node: FastTileMap", [](){return new TileMapTestSceneNew(); } }, +#endif { "Node: Text Input", [](){return new TextInputTestScene(); } }, { "Node: UI", [](){ return new UITestScene(); }}, { "Mouse", []() { return new MouseTestScene(); } }, @@ -87,8 +89,10 @@ Controller g_aTestNames[] = { { "ReleasePool", [](){ return new ReleasePoolTestScene(); } }, { "Rotate World", [](){return new RotateWorldTestScene(); } }, { "Scheduler", [](){return new SchedulerTestScene(); } }, +#if CC_TARGET_PLATFORM != CC_PLATFORM_WP8 { "Shader - Basic", []() { return new ShaderTestScene(); } }, { "Shader - Sprite", []() { return new ShaderTestScene2(); } }, +#endif { "Texture2D", [](){return new TextureTestScene(); } }, { "TextureCache", []() { return new TextureCacheTestScene(); } }, { "TexturePacker Encryption", []() { return new TextureAtlasEncryptionTestScene(); } }, diff --git a/tests/game-controller-test/Classes/GameControllerTest.cpp b/tests/game-controller-test/Classes/GameControllerTest.cpp index ef27469315..de5a0d6c5c 100644 --- a/tests/game-controller-test/Classes/GameControllerTest.cpp +++ b/tests/game-controller-test/Classes/GameControllerTest.cpp @@ -196,6 +196,12 @@ void GameControllerTest::showButtonState(cocos2d::Controller *controller, int ke case Controller::Key::BUTTON_RIGHT_SHOULDER: holder->_buttonR1->setColor(Color3B(19,231,238)); break; + case Controller::Key::BUTTON_LEFT_THUMBSTICK: + holder->_leftJoystick->setColor(Color3B(19,231,238)); + break; + case Controller::Key::BUTTON_RIGHT_THUMBSTICK: + holder->_rightJoystick->setColor(Color3B(19,231,238)); + break; default: { char ketStatus[30]; @@ -239,6 +245,12 @@ void GameControllerTest::showButtonState(cocos2d::Controller *controller, int ke case Controller::Key::BUTTON_RIGHT_SHOULDER: holder->_buttonR1->setColor(Color3B::WHITE); break; + case Controller::Key::BUTTON_LEFT_THUMBSTICK: + holder->_leftJoystick->setColor(Color3B::WHITE); + break; + case Controller::Key::BUTTON_RIGHT_THUMBSTICK: + holder->_rightJoystick->setColor(Color3B::WHITE); + break; default: { char ketStatus[30]; diff --git a/tests/lua-game-controller-test/src/GameControllerTest.lua b/tests/lua-game-controller-test/src/GameControllerTest.lua index ca87a39bef..9b186fb84b 100644 --- a/tests/lua-game-controller-test/src/GameControllerTest.lua +++ b/tests/lua-game-controller-test/src/GameControllerTest.lua @@ -276,6 +276,10 @@ function GameControllerTest:registerControllerListener() holder._buttonL1:setColor(cc.c3b(19,231,238)) elseif keyCode == cc.ControllerKey.BUTTON_RIGHT_SHOULDER then holder._buttonR1:setColor(cc.c3b(19,231,238)) + elseif keyCode == cc.ControllerKey.BUTTON_LEFT_THUMBSTICK then + holder._leftJoystick:setColor(cc.c3b(19,231,238)) + elseif keyCode == cc.ControllerKey.BUTTON_RIGHT_THUMBSTICK then + holder._rightJoystick:setColor(cc.c3b(19,231,238)) else local ketStatus = string.format("Key Down:%d",keyCode) holder._externalKeyLabel:setString(ketStatus) @@ -301,6 +305,10 @@ function GameControllerTest:registerControllerListener() holder._buttonL1:setColor(cc.c3b(250,255,255)) elseif keyCode == cc.ControllerKey.BUTTON_RIGHT_SHOULDER then holder._buttonR1:setColor(cc.c3b(250,255,255)) + elseif keyCode == cc.ControllerKey.BUTTON_LEFT_THUMBSTICK then + holder._leftJoystick:setColor(cc.c3b(250,255,255)) + elseif keyCode == cc.ControllerKey.BUTTON_RIGHT_THUMBSTICK then + holder._rightJoystick:setColor(cc.c3b(250,255,255)) else local ketStatus = string.format("Key Up:%d",keyCode) holder._externalKeyLabel:setString(ketStatus) diff --git a/tests/lua-tests/src/CocoStudioTest/CocoStudioGUITest/CocoStudioGUITest.lua b/tests/lua-tests/src/CocoStudioTest/CocoStudioGUITest/CocoStudioGUITest.lua index e2a6b31408..ecf355110c 100644 --- a/tests/lua-tests/src/CocoStudioTest/CocoStudioGUITest/CocoStudioGUITest.lua +++ b/tests/lua-tests/src/CocoStudioTest/CocoStudioGUITest/CocoStudioGUITest.lua @@ -1,5 +1,6 @@ local guiSceneManager = {} guiSceneManager.currentUISceneIdx = 1 +local font_TextName = "fonts/Marker Felt.ttf" local UIScene = class("UIScene") UIScene.__index = UIScene @@ -106,7 +107,7 @@ function UIButtonTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -114,7 +115,7 @@ function UIButtonTest:initExtend() local alert = ccui.Text:create() alert:setString("Button") - alert:setFontName(font_UIButtonTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) @@ -170,7 +171,7 @@ function UIButtonScale9Test:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -178,7 +179,7 @@ function UIButtonScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("Button scale9 render") - alert:setFontName(font_UIButtonTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -236,7 +237,7 @@ function UIButtonPressedActionTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -244,7 +245,7 @@ function UIButtonPressedActionTest:initExtend() local alert = ccui.Text:create() alert:setString("Button Pressed Action") - alert:setFontName(font_UIButtonTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -301,7 +302,7 @@ function UITextButtonTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -309,7 +310,7 @@ function UITextButtonTest:initExtend() local alert = ccui.Text:create() alert:setString("TextButton") - alert:setFontName(font_UIButtonTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -365,7 +366,7 @@ function UITextButtonScale9Test:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -373,7 +374,7 @@ function UITextButtonScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("TextButton scale9 render") - alert:setFontName(font_UIButtonTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -431,7 +432,7 @@ function UICheckBoxTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIButtonTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -439,7 +440,7 @@ function UICheckBoxTest:initExtend() local alert = ccui.Text:create() alert:setString("CheckBox") - alert:setFontName(font_UICheckBoxTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -496,7 +497,7 @@ function UISliderTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move the slider thumb") - self._displayValueLabel:setFontName(font_UISliderTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -504,7 +505,7 @@ function UISliderTest:initExtend() local alert = ccui.Text:create() alert:setString("Slider") - alert:setFontName(font_UISliderTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -558,7 +559,7 @@ function UISliderScale9Test:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move the slider thumb") - self._displayValueLabel:setFontName(font_UISliderTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -566,7 +567,7 @@ function UISliderScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("Slider scale9 render") - alert:setFontName(font_UISliderTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -622,7 +623,7 @@ function UIImageViewTest:initExtend() local alert = ccui.Text:create() alert:setString("ImageView") - alert:setFontName(font_UIImageViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -663,7 +664,7 @@ function UIImageViewScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("ImageView scale9 render") - alert:setFontName(font_UIImageViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -716,7 +717,7 @@ function UILoadingBarLeftTest:initExtend() local alert = ccui.Text:create() alert:setString("LoadingBar") - alert:setFontName(font_UILoadingBarTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -842,7 +843,7 @@ function UILoadingBarRightTest:initExtend() local alert = ccui.Text:create() alert:setString("LoadingBar") - alert:setFontName(font_UILoadingBarTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -969,7 +970,7 @@ function UILoadingBarLeftScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("LoadingBar Scale9 Render") - alert:setFontName(font_UILoadingBarTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1098,7 +1099,7 @@ function UILoadingBarRightScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("LoadingBar Scale9 Render") - alert:setFontName(font_UILoadingBarTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1216,7 +1217,7 @@ function UILabelAtlasTest:initExtend() local alert = ccui.Text:create() alert:setString("LabelAtlas") - alert:setFontName(font_UILabelAtlasTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1257,7 +1258,7 @@ function UILabelBMFontTest:initExtend() local alert = ccui.Text:create() alert:setString("LabelBMFont") - alert:setFontName(font_UILabelBMFontTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1299,7 +1300,7 @@ function UILabelTest:initExtend() local alert = ccui.Text:create() alert:setString("Label") - alert:setFontName(font_UILabelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1340,7 +1341,7 @@ function UITextAreaTest:initExtend() local alert = ccui.Text:create() alert:setString("TextArea") - alert:setFontName(font_UITextAreaTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1384,7 +1385,7 @@ function UITextFieldTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UITextFieldTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -1392,7 +1393,7 @@ function UITextFieldTest:initExtend() local alert = ccui.Text:create() alert:setString("TextField") - alert:setFontName(font_UITextFieldTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1418,7 +1419,7 @@ function UITextFieldTest:initExtend() local textField = ccui.TextField:create() textField:setTouchEnabled(true) - textField:setFontName(font_UITextFieldTest) + textField:setFontName(font_TextName) textField:setFontSize(30) textField:setPlaceHolder("input words here") textField:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -1454,7 +1455,7 @@ function UITextFieldMaxLengthTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UITextFieldTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -1462,7 +1463,7 @@ function UITextFieldMaxLengthTest:initExtend() local alert = ccui.Text:create() alert:setString("TextField max length") - alert:setFontName(font_UITextFieldTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1496,7 +1497,7 @@ function UITextFieldMaxLengthTest:initExtend() textField:setMaxLengthEnabled(true) textField:setMaxLength(3) textField:setTouchEnabled(true) - textField:setFontName(font_UITextFieldTest) + textField:setFontName(font_TextName) textField:setFontSize(30) textField:setPlaceHolder("input words here") textField:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -1532,7 +1533,7 @@ function UITextFieldPasswordTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UITextFieldTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -1540,7 +1541,7 @@ function UITextFieldPasswordTest:initExtend() local alert = ccui.Text:create() alert:setString("TextField password") - alert:setFontName(font_UITextFieldTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1568,7 +1569,7 @@ function UITextFieldPasswordTest:initExtend() textField:setPasswordEnabled(true) textField:setPasswordStyleText("*") textField:setTouchEnabled(true) - textField:setFontName(font_UITextFieldTest) + textField:setFontName(font_TextName) textField:setFontSize(30) textField:setPlaceHolder("input password here") textField:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0)) @@ -1604,7 +1605,7 @@ function UIPanelTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -1672,7 +1673,7 @@ function UIPanelColorTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel color render") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -1742,7 +1743,7 @@ function UIPanelGradientTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel color Gradient") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -1812,7 +1813,7 @@ function UIPanelBackGroundImageTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel background image") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -1882,7 +1883,7 @@ function UIPanelBackGroundImageScale9Test:initExtend() local alert = ccui.Text:create() alert:setString("Panel background image scale9") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -1952,7 +1953,7 @@ function UIPanelLayoutLinearVerticalTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel Layout Linear Vertical") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2035,7 +2036,7 @@ function UIPanelLayoutLinearHorizontalTest:initExtend() local alert = ccui.Text:create() alert:setString("Panel Layout Linear Horizontal") - alert:setFontName(font_UIPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2120,7 +2121,7 @@ function UIScrollViewVerticalTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move by vertical direction") - self._displayValueLabel:setFontName(font_UIScrollViewTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2128,7 +2129,7 @@ function UIScrollViewVerticalTest:initExtend() local alert = ccui.Text:create() alert:setString("ScrollView") - alert:setFontName(font_UIScrollViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2209,7 +2210,7 @@ function UIScrollViewHorizontalTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move by horizontal direction") - self._displayValueLabel:setFontName(font_UIScrollViewTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2217,7 +2218,7 @@ function UIScrollViewHorizontalTest:initExtend() local alert = ccui.Text:create() alert:setString("ScrollView") - alert:setFontName(font_UIScrollViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2305,7 +2306,7 @@ function UIPageViewTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move by horizontal direction") - self._displayValueLabel:setFontName(font_UIPageViewTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2313,7 +2314,7 @@ function UIPageViewTest:initExtend() local alert = ccui.Text:create() alert:setString("PageView") - alert:setFontName(font_UIPageViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2346,7 +2347,7 @@ function UIPageViewTest:initExtend() local label = ccui.Text:create() local pageInfo = string.format("page %d", i) label:setString(pageInfo) - label:setFontName(font_UIPageViewTest) + label:setFontName(font_TextName) label:setFontSize(30) label:setColor(cc.c3b(192, 192, 192)) label:setPosition(cc.p(layout:getContentSize().width / 2, layout:getContentSize().height / 2)) @@ -2399,7 +2400,7 @@ function UIListViewVerticalTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move by vertical direction") - self._displayValueLabel:setFontName(font_UIListViewTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2407,7 +2408,7 @@ function UIListViewVerticalTest:initExtend() local alert = ccui.Text:create() alert:setString("ListView") - alert:setFontName(font_UIListViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2424,7 +2425,7 @@ function UIListViewVerticalTest:initExtend() end local function listViewEvent(sender, eventType) - if eventType == ccui.ListViewEventType.onsSelectedItem then + if eventType == ccui.ListViewEventType.ONSELECTEDITEM_START then print("select child index = ",sender:getCurSelectedIndex()) end end @@ -2567,7 +2568,7 @@ function UIListViewHorizontalTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("Move by vertical direction") - self._displayValueLabel:setFontName(font_UIListViewTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2575,7 +2576,7 @@ function UIListViewHorizontalTest:initExtend() local alert = ccui.Text:create() alert:setString("ListView") - alert:setFontName(font_UIListViewTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2723,7 +2724,7 @@ function UIDragPanelTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIDragPanelTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2731,7 +2732,7 @@ function UIDragPanelTest:initExtend() local alert = ccui.Text:create() alert:setString("DragPanel") - alert:setFontName(font_UIDragPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2782,7 +2783,7 @@ function UIDragPanelBounceTest:initExtend() self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("No Event") - self._displayValueLabel:setFontName(font_UIDragPanelTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2791,7 +2792,7 @@ function UIDragPanelBounceTest:initExtend() local alert = ccui.Text:create() alert:setString("DragPanel Bounce") - alert:setFontName(font_UIDragPanelTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 2.925)) @@ -2839,10 +2840,10 @@ function UINodeContainerTest:initExtend() self:init() local widgetSize = self._widget:getContentSize() - + print("setFontName before") self._displayValueLabel = ccui.Text:create() self._displayValueLabel:setString("NodeContainer Add CCNode") - self._displayValueLabel:setFontName(font_UINodeContainerTest) + self._displayValueLabel:setFontName(font_TextName) self._displayValueLabel:setFontSize(32) self._displayValueLabel:setAnchorPoint(cc.p(0.5, -1)) self._displayValueLabel:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 + self._displayValueLabel:getContentSize().height * 1.5)) @@ -2850,7 +2851,7 @@ function UINodeContainerTest:initExtend() local alert = ccui.Text:create() alert:setString("NodeContainer") - alert:setFontName(font_UINodeContainerTest) + alert:setFontName(font_TextName) alert:setFontSize(30) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 1.75)) @@ -2892,7 +2893,7 @@ function UIRichTextTest:initExtend() local widgetSize = self._widget:getContentSize() local alert = ccui.Text:create("RichText", "fonts/Marker Felt.ttf", 30) - alert:setFontName(font_UINodeContainerTest) + alert:setFontName(font_TextName) alert:setColor(cc.c3b(159, 168, 176)) alert:setPosition(cc.p(widgetSize.width / 2.0, widgetSize.height / 2.0 - alert:getContentSize().height * 3.125)) self._widget:addChild(alert) diff --git a/tests/lua-tests/src/CocoStudioTest/CocoStudioSceneTest/CocoStudioSceneTest.lua b/tests/lua-tests/src/CocoStudioTest/CocoStudioSceneTest/CocoStudioSceneTest.lua index b64aad32b8..19cdabbbe5 100644 --- a/tests/lua-tests/src/CocoStudioTest/CocoStudioSceneTest/CocoStudioSceneTest.lua +++ b/tests/lua-tests/src/CocoStudioTest/CocoStudioSceneTest/CocoStudioSceneTest.lua @@ -25,6 +25,15 @@ SceneEditorTestLayer.title = "Trigger Test", } +SceneEditorTestLayer.loadtypeStr= +{ + "change to load \nwith binary file", + "change to load \nwith json file" +} + +SceneEditorTestLayer.fileName = "" +SceneEditorTestLayer.rootNode = nil + function SceneEditorTestLayer.extend(target) local t = tolua.getpeer(target) if not t then @@ -70,9 +79,44 @@ function SceneEditorTestLayer:createTitle() title:setPosition( cc.p(VisibleRect:center().x, VisibleRect:top().y - 30)) end +function SceneEditorTestLayer:loadFileChangeHelper(filePathName) + local indexTable = {} + local index = 0 + + while true do + index = string.find(filePathName, "%.", index + 1) + if nil == index then + break + end + + indexTable[#indexTable + 1] = index + end + + if #indexTable == 0 then + return filePathName + end + + local lastIndex = indexTable[#indexTable] + if lastIndex == 1 then + return filePathName + end + local renamePathName= string.sub(filePathName, 1, lastIndex - 1) + + if self.isCsbLoad then + renamePathName = renamePathName .. ".csb" + else + renamePathName = renamePathName .. ".json" + end + print("renamePath is", renamePathName) + return renamePathName +end + +function SceneEditorTestLayer:defaultPlay() + +end + function SceneEditorTestLayer:createMenu() local menu = cc.Menu:create() - local function pre() local scene = cc.Scene:create() scene:addChild(backSceneEditorTest()) @@ -118,6 +162,41 @@ function SceneEditorTestLayer:createMenu() end end + self.isCsbLoad = false + self.loadtypeLabel = cc.Label:createWithSystemFont(self.loadtypeStr[1], "Arial", 12) + local function changeLoadTypeCallback(tag,sender) + self.isCsbLoad = not self.isCsbLoad + if self.isCsbLoad then + self.loadtypeLabel:setString(self.loadtypeStr[2]) + else + self.loadtypeLabel:setString(self.loadtypeStr[1]) + end + + if sceneEditorTestIdx == #SceneEditorTestLayer.title then + ccs.TriggerMng.getInstance():removeAll() + end + + SceneEditorTestLayer.fileName = self:loadFileChangeHelper(SceneEditorTestLayer.fileName) + + if SceneEditorTestLayer.rootNode ~= nil then + self:removeChild(SceneEditorTestLayer.rootNode, true) + SceneEditorTestLayer.rootNode = ccs.SceneReader:getInstance():createNodeWithSceneFile(SceneEditorTestLayer.fileName) + if SceneEditorTestLayer.rootNode == nil then + return + end + self:defaultPlay() + self:addChild(SceneEditorTestLayer.rootNode, 0, 1) + end + end + + local loadTypeItem = cc.MenuItemLabel:create(self.loadtypeLabel) + loadTypeItem:registerScriptTapHandler(changeLoadTypeCallback) + local loadtypeMenu = cc.Menu:create() + loadtypeMenu:addChild(loadTypeItem) + loadtypeMenu:setPosition(cc.p(0,0)) + loadTypeItem:setPosition(cc.p(VisibleRect:rightTop().x -80,VisibleRect:rightTop().y -30)) + self:addChild(loadtypeMenu, 100) + local backMenu = cc.Menu:create() cc.MenuItemFont:setFontName("Arial") cc.MenuItemFont:setFontSize(24) @@ -145,9 +224,16 @@ end function LoadSceneEdtiorFileTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/LoadSceneEdtiorFileTest/FishJoy2.json") + SceneEditorTestLayer.fileName = "scenetest/LoadSceneEdtiorFileTest/FishJoy2.json" + SceneEditorTestLayer.rootNode = node + self:defaultPlay() return node end +function LoadSceneEdtiorFileTest:defaultPlay() + +end + function LoadSceneEdtiorFileTest:onEnter() self:createMenu() self:createTitle() @@ -191,13 +277,9 @@ end function SpriteComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/SpriteComponentTest/SpriteComponentTest.json") if nil ~= node then - local action1 = cc.Blink:create(2, 10) - local action2 = cc.Blink:create(2, 5) - - local sister1 = node:getChildByTag(10003):getComponent("CCSprite") - sister1:getNode():runAction(action1) - local sister2 = node:getChildByTag(10004):getComponent("CCSprite") - sister2:getNode():runAction(action2) + SceneEditorTestLayer.fileName = "scenetest/SpriteComponentTest/SpriteComponentTest.json" + SceneEditorTestLayer.rootNode = node + self:defaultPlay() end return node @@ -209,8 +291,19 @@ function SpriteComponentTest:onEnter() local root = self:createGameScene() if nil ~= root then self:addChild(root, 0, 1) + end +end + +function SpriteComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local action1 = cc.Blink:create(2, 10) + local action2 = cc.Blink:create(2, 5) + + local sister1 = SceneEditorTestLayer.rootNode:getChildByTag(10003):getComponent("CCSprite") + sister1:getNode():runAction(action1) + local sister2 = SceneEditorTestLayer.rootNode:getChildByTag(10004):getComponent("CCSprite") + sister2:getNode():runAction(action2) end - end function SpriteComponentTest.create() @@ -246,14 +339,23 @@ end function ArmatureComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/ArmatureComponentTest/ArmatureComponentTest.json") if nil ~= node then + SceneEditorTestLayer.fileName = "scenetest/ArmatureComponentTest/ArmatureComponentTest.json" + SceneEditorTestLayer.rootNode = node + + self:defaultPlay() + end + + return node +end + +function ArmatureComponentTest:defaultPlay() + if SceneEditorTestLayer.rootName ~= nil then local blowFish = node:getChildByTag(10007):getComponent("CCArmature") blowFish:getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) local butterflyfish = node:getChildByTag(10008):getComponent("CCArmature") - butterflyfish:getNode():runAction(CCMoveBy:create(10.0, cc.p(-1000.0, 0))) + butterflyfish:getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) end - - return node end function ArmatureComponentTest:onEnter() @@ -299,23 +401,31 @@ end function UIComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/UIComponentTest/UIComponentTest.json") if nil ~= node then - local render = node:getChildByTag(10025):getComponent("GUIComponent") + SceneEditorTestLayer.fileName = "scenetest/UIComponentTest/UIComponentTest.json" + SceneEditorTestLayer.rootNode = node + self:defaultPlay() + end + + return node +end + +function UIComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local render = SceneEditorTestLayer.rootNode:getChildByTag(10025):getComponent("GUIComponent") local widget = render:getNode() local button = widget:getChildByName("Button_156") local function onTouch(sender, eventType) if eventType == ccui.TouchEventType.began then - local blowFish = node:getChildByTag(10010):getComponent("CCArmature") + local blowFish = SceneEditorTestLayer.rootNode:getChildByTag(10010):getComponent("CCArmature") blowFish:getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) - local butterflyfish = node:getChildByTag(10011):getComponent("CCArmature") + local butterflyfish = SceneEditorTestLayer.rootNode:getChildByTag(10011):getComponent("CCArmature") butterflyfish:getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) end end button:addTouchEventListener(onTouch) end - - return node end function UIComponentTest:onEnter() @@ -361,7 +471,18 @@ end function TmxMapComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/TmxMapComponentTest/TmxMapComponentTest.json") if nil ~= node then - local tmxMap = node:getChildByTag(10015):getComponent("CCTMXTiledMap") + SceneEditorTestLayer.fileName = "scenetest/TmxMapComponentTest/TmxMapComponentTest.json" + SceneEditorTestLayer.rootNode = node + + self:defaultPlay() + end + + return node +end + +function TmxMapComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local tmxMap = SceneEditorTestLayer.rootNode:getChildByTag(10015):getComponent("CCTMXTiledMap") local actionTo = cc.SkewTo:create(2, 0.0, 2.0) local rotateTo = cc.RotateTo:create(2, 61.0) local actionScaleTo = cc.ScaleTo:create(2, -0.44, 0.47) @@ -374,8 +495,6 @@ function TmxMapComponentTest:createGameScene() tmxMap:getNode():runAction(cc.Sequence:create(rotateTo, rotateToBack)) tmxMap:getNode():runAction(cc.Sequence:create(actionScaleTo, actionScaleToBack)) end - - return node end function TmxMapComponentTest:onEnter() @@ -421,13 +540,22 @@ end function ParticleComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/ParticleComponentTest/ParticleComponentTest.json") if nil ~= node then - local particle = node:getChildByTag(10020):getComponent("CCParticleSystemQuad") + SceneEditorTestLayer.fileName = "scenetest/ParticleComponentTest/ParticleComponentTest.json" + SceneEditorTestLayer.rootNode = node + + self:defaultPlay() + end + + return node +end + +function ParticleComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local particle = SceneEditorTestLayer.rootNode:getChildByTag(10020):getComponent("CCParticleSystemQuad") local jump = cc.JumpBy:create(5, cc.p(-500,0), 50, 4) local action = cc.Sequence:create( jump, jump:reverse()) particle:getNode():runAction(action) end - - return node end function ParticleComponentTest:onEnter() @@ -473,13 +601,24 @@ end function EffectComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/EffectComponentTest/EffectComponentTest.json") if nil ~= node then - local render = node:getChildByTag(10015):getComponent("CCArmature") + SceneEditorTestLayer.fileName = "scenetest/EffectComponentTest/EffectComponentTest.json" + SceneEditorTestLayer.rootNode = node + + self:defaultPlay() + end + + return node +end + +function EffectComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local render = SceneEditorTestLayer.rootNode:getChildByTag(10015):getComponent("CCArmature") local armature = render:getNode() local function animationEvent(armatureBack,movementType,movementID) local id = movementID if movementType == ccs.MovementEventType.loopComplete then if id == "Fire" then - local audio = node:getChildByTag(10015):getComponent("CCComAudio") + local audio = SceneEditorTestLayer.rootNode:getChildByTag(10015):getComponent("CCComAudio") audio:playEffect() end end @@ -487,8 +626,6 @@ function EffectComponentTest:createGameScene() armature:getAnimation():setMovementEventCallFunc(animationEvent) end - - return node end function EffectComponentTest:onEnter() @@ -534,13 +671,22 @@ end function BackgroundComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/BackgroundComponentTest/BackgroundComponentTest.json") if nil ~= node then - local audio = node:getComponent("CCBackgroundAudio") - audio:playBackgroundMusic() + SceneEditorTestLayer.fileName = "scenetest/BackgroundComponentTest/BackgroundComponentTest.json" + SceneEditorTestLayer.rootNode = node + + self:defaultPlay() end return node end +function BackgroundComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local audio = SceneEditorTestLayer.rootNode:getComponent("CCBackgroundAudio") + audio:playBackgroundMusic() + end +end + function BackgroundComponentTest:onEnter() self:createMenu() self:createTitle() @@ -583,11 +729,21 @@ end function AttributeComponentTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/AttributeComponentTest/AttributeComponentTest.json") - local attribute = node:getChildByTag(10015):getComponent("CCComAttribute") - print(string.format("Name: %s, HP: %f, MP: %f", attribute:getString("name"), attribute:getFloat("maxHP"), attribute:getFloat("maxMP"))) + if nil ~= node then + SceneEditorTestLayer.fileName = "scenetest/AttributeComponentTest/AttributeComponentTest.json" + SceneEditorTestLayer.rootNode = node + self:defaultPlay() + end return node end +function AttributeComponentTest:defaultPlay() + if SceneEditorTestLayer.rootNode ~= nil then + local attribute = SceneEditorTestLayer.rootNode:getChildByTag(10015):getComponent("CCComAttribute") + print(string.format("Name: %s, HP: %f, MP: %f", attribute:getString("name"), attribute:getFloat("maxHP"), attribute:getFloat("maxMP"))) + end +end + function AttributeComponentTest:onEnter() self:createMenu() self:createTitle() @@ -631,7 +787,12 @@ end function TriggerTest:createGameScene() local node = ccs.SceneReader:getInstance():createNodeWithSceneFile("scenetest/TriggerTest/TriggerTest.json") + if nil ~= node then + SceneEditorTestLayer.fileName = "scenetest/TriggerTest/TriggerTest.json" + SceneEditorTestLayer.rootNode = node + self:defaultPlay() + end return node end @@ -658,6 +819,17 @@ function TriggerTest:onEnter() local root = self:createGameScene() if nil ~= root then self:addChild(root, 0, 1) + local function onTouchEvent(touch, event) + if eventType == "began" then + return self:onTouchBegan(touch, event) + elseif eventType == "moved" then + self:onTouchMoved(touch, event) + elseif eventType == "ended" then + self:onTouchEnded(touch, event) + elseif eventType == "cancelled" then + self:onTouchCancelled(touch, event) + end + end self._touchListener = nil local listener = cc.EventListenerTouchOneByOne:create() listener:setSwallowTouches(true) @@ -668,20 +840,25 @@ function TriggerTest:onEnter() local eventDispatcher = self:getEventDispatcher() eventDispatcher:addEventListenerWithSceneGraphPriority(listener, self) self._touchListener = listener + + self:unscheduleUpdate() local function update(dt) ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_UPDATESCENE) end self:scheduleUpdateWithPriorityLua(update,0) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_ENTERSCENE) - end - + end +end + +function TriggerTest:defaultPlay() + ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_ENTERSCENE) end function TriggerTest:onExit() - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_LEAVESCENE) self:unscheduleUpdate() + ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_LEAVESCENE) local dispatcher = self:getEventDispatcher() dispatcher:removeEventListener(self._touchListener) + self._touchListener = nil ccs.TriggerMng.destroyInstance() ccs.ArmatureDataManager:destroyInstance() ccs.SceneReader:destroyInstance() diff --git a/tests/lua-tests/src/ExtensionTest/ExtensionTest.lua b/tests/lua-tests/src/ExtensionTest/ExtensionTest.lua index 22cf4fad6a..d0b5b72def 100644 --- a/tests/lua-tests/src/ExtensionTest/ExtensionTest.lua +++ b/tests/lua-tests/src/ExtensionTest/ExtensionTest.lua @@ -1,6 +1,5 @@ require "src/ExtensionTest/CocosBuilderTest" require "src/ExtensionTest/WebProxyTest" -require "src/ExtensionTest/SceneEditorTest" local LINE_SPACE = 40 local kItemTagBasic = 1000 @@ -14,8 +13,7 @@ local ExtensionTestEnum = TEST_EDITBOX = 4, TEST_TABLEVIEW = 5, TEST_SCROLLVIEW = 6, - TEST_STUDIOSCENE = 7, - TEST_MAX_COUNT = 8, + TEST_MAX_COUNT = 7, } local testsName = @@ -27,7 +25,6 @@ local testsName = "EditBoxTest", "TableViewTest", "ScrollViewTest", - "CocoStudioSceneTest", } @@ -1190,7 +1187,6 @@ local CreateExtensionsTestTable = runEditBoxTest, runTableViewTest, runScrollViewTest, - runStudioSceneTest, } diff --git a/tests/lua-tests/src/ExtensionTest/SceneEditorTest.lua b/tests/lua-tests/src/ExtensionTest/SceneEditorTest.lua deleted file mode 100644 index 625db70527..0000000000 --- a/tests/lua-tests/src/ExtensionTest/SceneEditorTest.lua +++ /dev/null @@ -1,270 +0,0 @@ -require "CCBReaderLoad" - -function SceneEditorTestLayer(filename) - - local layer = cc.Layer:create() - local isCsbLoad = false; - local loadtypeStr = {"change to load \nwith binary file","change to load \nwith json file"} - local loadtypelb = cc.Label:createWithSystemFont(loadtypeStr[1], "Arial", 12); - local filePath = filename - layer.rootNode = nil - function layer:defaultPlay()end - - local loadFileChangeHelper = function(filename) - if filename ~= nil then - if isCsbLoad then - return filename .. ".csb" - else - return filename .. ".json" - end - end - - return filename - end - - local changeLoadTypeCallback = function(sender) - isCsbLoad = not isCsbLoad - loadtypelb:setString(loadtypeStr[isCsbLoad == false and 1 or 2]) - local file = loadFileChangeHelper(filePath) - - if layer.rootNode ~= nil then - layer:removeChild(layer.rootNode) - layer.rootNode = SceneReader:getInstance():createNodeWithSceneFile(file) - layer:addChild(layer.rootNode, 0, 1) - layer:defaultPlay() - end - end - - function layer:enter() - layer.rootNode = SceneReader:getInstance():createNodeWithSceneFile(loadFileChangeHelper(filePath)) - layer:addChild(layer.rootNode, 0, 1) - layer:defaultPlay() - end - - function layer:exit() - ccs.ArmatureDataManager:destroyInstance() - ccs.SceneReader:destroyInstance() - ccs.ActionManagerEx:destroyInstance() - ccs.GUIReader:destroyInstance() - end - - local function onNodeEvent(event) - if "enter" == event then - layer:enter() - elseif "exit" == event then - layer:exit() - end - end - layer:registerScriptHandler(onNodeEvent) - - local itemlb = cc.MenuItemLabel:create(loadtypelb) - itemlb:registerScriptTapHandler(changeLoadTypeCallback) - local loadtypemenu = cc.Menu:create(itemlb) - loadtypemenu:setPosition(cc.p(VisibleRect:rightTop().x -50,VisibleRect:rightTop().y -20)); - layer:addChild(loadtypemenu,100); - - Helper.initWithLayer(layer) - Helper.titleLabel:setString("SceneReader Test LoadSceneEditorFile") - return layer -end - -function LoadSceneEdtiorFileTest() - local layer = SceneEditorTestLayer("scenetest/LoadSceneEdtiorFileTest/FishJoy2") - Helper.titleLabel:setString("loadSceneEdtiorFile Test") - - return layer -end - -function SpriteComponentTest() - local layer = SceneEditorTestLayer("scenetest/SpriteComponentTest/SpriteComponentTest") - Helper.titleLabel:setString("Sprite Component Test") - - function layer:defaultPlay() - layer.rootNode:getChildByTag(10003):getComponent("CCSprite"):getNode():runAction(cc.Blink:create(2, 10)); - layer.rootNode:getChildByTag(10004):getComponent("CCSprite"):getNode():runAction(cc.Blink:create(2, 5)); - end - - return layer -end - -function ArmatureComponentTest() - local layer = SceneEditorTestLayer("scenetest/ArmatureComponentTest/ArmatureComponentTest") - Helper.titleLabel:setString("Armature Component Test") - - function layer:defaultPlay() - layer.rootNode:getChildByTag(10007):getComponent("CCArmature"):getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) - layer.rootNode:getChildByTag(10008):getComponent("CCArmature"):getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) - end - - return layer -end - -function UIComponentTest() - local layer = SceneEditorTestLayer("scenetest/UIComponentTest/UIComponentTest") - Helper.titleLabel:setString("UI Component Test") - - local function touchEvent(sender,eventType) - if eventType == ccui.TouchEventType.began then - layer.rootNode:getChildByTag(10010):getComponent("CCArmature"):getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) - layer.rootNode:getChildByTag(10011):getComponent("CCArmature"):getNode():runAction(cc.MoveBy:create(10.0, cc.p(-1000.0, 0))) - end - end - - function layer:defaultPlay() - local render = layer.rootNode:getChildByTag(10025):getComponent("GUIComponent") - local widget = render:getNode() - local button = widget:getChildByName("Button_156") - button:addTouchEventListener(touchEvent) - end - - return layer -end - -function TmxMapComponentTest() - local layer = SceneEditorTestLayer("scenetest/TmxMapComponentTest/TmxMapComponentTest") - Helper.titleLabel:setString("TmxMap Component Test") - - function layer:defaultPlay() - local render = layer.rootNode:getChildByTag(10015):getComponent("CCTMXTiledMap") - - local skewTo = cc.SkewTo:create(2, 0, 2); - local rotateTo = cc.RotateTo:create(2, 61); - local scaleTo = cc.ScaleTo:create(2, -0.44, 0.47); - local scaleBack = cc.ScaleTo:create(2, 1, 1); - local rotateBack = cc.RotateTo:create(2, 0); - local skewBack = cc.SkewTo:create(2, 0, 0); - render:getNode():runAction(cc.Sequence:create(skewTo, skewBack)); - render:getNode():runAction(cc.Sequence:create(rotateTo, rotateBack)); - render:getNode():runAction(cc.Sequence:create(scaleTo, scaleBack)); - end - - return layer -end - -function ParticleComponentTest() - local layer = SceneEditorTestLayer("scenetest/ParticleComponentTest/ParticleComponentTest") - Helper.titleLabel:setString("Particle Component Test") - - function layer:defaultPlay() - local render = layer.rootNode:getChildByTag(10020):getComponent("CCParticleSystemQuad") - - local action = cc.JumpBy:create(5, cc.p(-500,0), 50, 4); - render:getNode():runAction(cc.Sequence:create(action, action:reverse())) - end - - return layer -end - -function EffectComponentTest() - local layer = SceneEditorTestLayer("scenetest/EffectComponentTest/EffectComponentTest") - Helper.titleLabel:setString("Effect Component Test") - - local animationEvent = function(armature,movementType,movementID) - if movementType == ccs.MovementEventType.loopComplete then - if movementID == "Fire" then - layer.rootNode:getChildByTag(10015):getComponent("CCComAudio"):playEffect() - end - end - end - - function layer:defaultPlay() - local render = layer.rootNode:getChildByTag(10015):getComponent("CCArmature") - - render:getNode():getAnimation():setMovementEventCallFunc(animationEvent); - end - - return layer -end - -function BackgroundComponentTest() - local layer = SceneEditorTestLayer("scenetest/BackgroundComponentTest/BackgroundComponentTest") - Helper.titleLabel:setString("Background Component Test") - - function layer:defaultPlay() - layer.rootNode:getComponent("CCBackgroundAudio"):playBackgroundMusic(); - end - - return layer -end - -function AttributeComponentTest() - local layer = SceneEditorTestLayer("scenetest/AttributeComponentTest/AttributeComponentTest") - Helper.titleLabel:setString("Attribute Component Test") - - function layer:defaultPlay() - local attribute = layer.rootNode:getChildByTag(10015):getComponent("CCComAttribute") - cclog("Name: " .. attribute:getString("name") .. ", HP: " .. attribute:getFloat("maxHP") .. ", MP: " .. attribute:getFloat("maxMP")) - end - - return layer -end - -function TriggerTest() - local layer = SceneEditorTestLayer("scenetest/TriggerTest/TriggerTest") - Helper.titleLabel:setString("Trigger Test") - - local function onTouchBegan(touch, event) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_TOUCHBEGAN) - end - local function onTouchMoved(touch, event) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_TOUCHMOVED) - end - local function onTouchEnded(touch, event) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_TOUCHENDED) - end - local function onTouchCancelled(touch, event) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_TOUCHCANCELLED) - end - - - local touchListener = cc.EventListenerTouchOneByOne:create() - touchListener:setSwallowTouches(true) - touchListener:registerScriptHandler(onTouchBegan, cc.Handler.EVENT_TOUCH_BEGAN) - touchListener:registerScriptHandler(onTouchMoved, cc.Handler.EVENT_TOUCH_MOVED) - touchListener:registerScriptHandler(onTouchEnded, cc.Handler.EVENT_TOUCH_ENDED) - touchListener:registerScriptHandler(onTouchCancelled, cc.Handler.EVENT_TOUCH_CANCELLED) - local eventDispatcher = layer:getEventDispatcher() - eventDispatcher:addEventListenerWithFixedPriority(touchListener, 1) - - - local function gameLogic(dt) - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_UPDATESCENE) - end - - local layerExit = layer.exit - function layer:exit() - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_LEAVESCENE) - layer:unschedule(gameLogic) - eventDispatcher:removeEventListener(touchListener) - layerExit(layer) - end - - schedule(layer,gameLogic) - - function layer:defaultPlay() - ccs.sendTriggerEvent(triggerEventDef.TRIGGEREVENT_ENTERSCENE); - end - - return layer -end - -function runStudioSceneTest() - local scene = cc.Scene:create() - - Helper.createFunctionTable = { - LoadSceneEdtiorFileTest, - SpriteComponentTest, - ArmatureComponentTest, - UIComponentTest, - TmxMapComponentTest, - ParticleComponentTest, - EffectComponentTest, - BackgroundComponentTest, - AttributeComponentTest, - TriggerTest, - } - - scene:addChild(Helper.createFunctionTable[1]()) - scene:addChild(CreateBackMenuItem()) - return scene -end diff --git a/tests/lua-tests/src/FastTiledMapTest/FastTiledMapTest.lua b/tests/lua-tests/src/FastTiledMapTest/FastTiledMapTest.lua index 9af3d41c98..87c001f3e7 100644 --- a/tests/lua-tests/src/FastTiledMapTest/FastTiledMapTest.lua +++ b/tests/lua-tests/src/FastTiledMapTest/FastTiledMapTest.lua @@ -144,7 +144,7 @@ local function TMXOrthoTest() --local color = cc.LayerColor:create( cc.c4b(64,64,64,255) ) --addChild(color, -1) - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test2.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test2.tmx") layer:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -178,7 +178,7 @@ end local function TMXOrthoTest2() local layer = createTileDemoLayer("TMX Ortho test2") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test1.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test1.tmx") layer:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -195,7 +195,7 @@ end -------------------------------------------------------------------- local function TMXOrthoTest3() local layer = createTileDemoLayer("TMX anchorPoint test") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test3.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test3.tmx") layer:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -214,7 +214,7 @@ end -------------------------------------------------------------------- local function TMXOrthoTest4() local ret = createTileDemoLayer("TMX width/height test") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test4.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test4.tmx") ret:addChild(map, 0, kTagTileMap) local s1 = map:getContentSize() @@ -277,7 +277,7 @@ local function TMXReadWriteTest() local ret = createTileDemoLayer("TMX Read/Write test") local m_gid = 0 local m_gid2 = 0 - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test2.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test2.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -437,7 +437,7 @@ local function TMXIsoTest() local color = cc.LayerColor:create( cc.c4b(64,64,64,255) ) ret:addChild(color, -1) - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test.tmx") ret:addChild(map, 0, kTagTileMap) -- move map to the center of the screen @@ -457,7 +457,7 @@ local function TMXIsoTest1() local color = cc.LayerColor:create( cc.c4b(64,64,64,255) ) ret:addChild(color, -1) - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test1.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test1.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -477,7 +477,7 @@ local function TMXIsoTest2() local color = cc.LayerColor:create( cc.c4b(64,64,64,255) ) ret:addChild(color, -1) - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test2.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test2.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -500,7 +500,7 @@ local function TMXUncompressedTest() local color = cc.LayerColor:create( cc.c4b(64,64,64,255) ) ret:addChild(color, -1) - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test2-uncompressed.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test2-uncompressed.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -521,7 +521,7 @@ end -------------------------------------------------------------------- local function TMXTilesetTest() local ret = createTileDemoLayer("TMX Tileset test") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test5.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test5.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -537,7 +537,7 @@ end -------------------------------------------------------------------- local function TMXOrthoObjectsTest() local ret = createTileDemoLayer("TMX Ortho object test", "You should see a white box around the 3 platforms") - local map = cc.FastTMXTiledMap:create("TileMaps/ortho-objects.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/ortho-objects.tmx") ret:addChild(map, -1, kTagTileMap) local s = map:getContentSize() @@ -610,7 +610,7 @@ end local function TMXIsoObjectsTest() local ret = createTileDemoLayer("TMX Iso object test", "You need to parse them manually. See bug #810") - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test-objectgroup.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test-objectgroup.tmx") ret:addChild(map, -1, kTagTileMap) local s = map:getContentSize() @@ -679,7 +679,7 @@ end local function TMXResizeTest() local ret = createTileDemoLayer("TMX resize test", "Should not crash. Testing issue #740") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test5.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test5.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -705,7 +705,7 @@ end local function TMXIsoZorder() local m_tamara = nil local ret = createTileDemoLayer("TMX Iso Zorder", "Sprite should hide behind the trees") - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test-zorder.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test-zorder.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -765,7 +765,7 @@ end local function TMXOrthoZorder() local m_tamara = nil local ret = createTileDemoLayer("TMX Ortho Zorder", "Sprite should hide behind the trees") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test-zorder.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test-zorder.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -823,7 +823,7 @@ end local function TMXIsoVertexZ() local m_tamara = nil local ret = createTileDemoLayer("TMX Iso VertexZ", "Sprite should hide behind the trees") - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test-vertexz.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test-vertexz.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -878,7 +878,7 @@ end local function TMXOrthoVertexZ() local m_tamara = nil local ret = createTileDemoLayer("TMX Ortho vertexZ", "Sprite should hide behind the trees") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test-vertexz.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test-vertexz.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -932,7 +932,7 @@ end -------------------------------------------------------------------- local function TMXIsoMoveLayer() local ret = createTileDemoLayer("TMX Iso Move Layer", "Trees should be horizontally aligned") - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test-movelayer.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test-movelayer.tmx") ret:addChild(map, 0, kTagTileMap) map:setPosition(cc.p(-700,-50)) @@ -950,7 +950,7 @@ end -------------------------------------------------------------------- local function TMXOrthoMoveLayer() local ret = createTileDemoLayer("TMX Ortho Move Layer", "Trees should be horizontally aligned") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test-movelayer.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test-movelayer.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -983,7 +983,7 @@ end local function TMXOrthoFlipTest() local ret = createTileDemoLayer("TMX tile flip test") - local map = cc.FastTMXTiledMap:create("TileMaps/ortho-rotation-test.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/ortho-rotation-test.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -1002,7 +1002,7 @@ end local function TMXOrthoFlipRunTimeTest() local ret = createTileDemoLayer("TMX tile flip run time test", "in 2 sec bottom left tiles will flip") - local map = cc.FastTMXTiledMap:create("TileMaps/ortho-rotation-test.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/ortho-rotation-test.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -1012,39 +1012,37 @@ local function TMXOrthoFlipRunTimeTest() map:runAction(action) local function flipIt(dt) - -- local map = tolua.cast(ret:getChildByTag(kTagTileMap), "TMXTiledMap") - -- local layer = map:getLayer("Layer 0") + local map = ret:getChildByTag(kTagTileMap) + local layer = map:getLayer("Layer 0") + + local tileCoord = cc.p(1, 10) + local flags = 0 + local GID, flags = layer:getTileGIDAt(tileCoord, flags) + if 0 ~= bit._and(flags, cc.TMX_TILE_VERTICAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_VERTICAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_VERTICAL_FLAG) + end + layer:setTileGID(GID, tileCoord, flags) - -- --blue diamond - -- local tileCoord = cc.p(1,10) - -- local flags = 0 - -- local GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Vertical - -- if( flags & kcc.TMXTileVerticalFlag ) - -- flags &= ~kcc.TMXTileVerticalFlag - -- else - -- flags |= kcc.TMXTileVerticalFlag - -- layer:setTileGID(GID ,tileCoord, (ccTMXTileFlags)flags) + tileCoord = cc.p(1,8) + GID, flags = layer:getTileGIDAt(tileCoord, flags) + if 0 ~= bit._and(flags, cc.TMX_TILE_VERTICAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_VERTICAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_VERTICAL_FLAG) + end + layer:setTileGID(GID ,tileCoord, flags) - - -- tileCoord = cc.p(1,8) - -- GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Vertical - -- if( flags & kcc.TMXTileVerticalFlag ) - -- flags &= ~kcc.TMXTileVerticalFlag - -- else - -- flags |= kcc.TMXTileVerticalFlag - -- layer:setTileGID(GID ,tileCoord, (ccTMXTileFlags)flags) - - - -- tileCoord = cc.p(2,8) - -- GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Horizontal - -- if( flags & kcc.TMXTileHorizontalFlag ) - -- flags &= ~kcc.TMXTileHorizontalFlag - -- else - -- flags |= kcc.TMXTileHorizontalFlag - -- layer:setTileGID(GID, tileCoord, (ccTMXTileFlags)flags) + tileCoord = cc.p(2,8) + GID, flags = layer:getTileGIDAt(tileCoord, flags) + -- Horizontal + if 0~= bit._and(flags, cc.TMX_TILE_HORIZONTAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_HORIZONTAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_HORIZONTAL_FLAG) + end + layer:setTileGID(GID, tileCoord, flags) end local schedulerEntry = nil local function onNodeEvent(event) @@ -1054,6 +1052,9 @@ local function TMXOrthoFlipRunTimeTest() scheduler:unscheduleScriptEntry(schedulerEntry) end end + + ret:registerScriptHandler(onNodeEvent) + return ret end @@ -1075,7 +1076,7 @@ local function TMXOrthoFromXMLTest() cclog("Unable to open file") end - local map = cc.FastTMXTiledMap:createWithXML(str ,resources) + local map = ccexp.TMXTiledMap:createWithXML(str ,resources) ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -1095,7 +1096,7 @@ end local function TMXOrthoXMLFormatTest() local ret = createTileDemoLayer("you should see blue, green and yellow in console.") - local map = cc.FastTMXTiledMap:create("TileMaps/xml-test.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/xml-test.tmx") ret:addChild(map, 0, kTagTileMap) local s = map:getContentSize() @@ -1117,7 +1118,7 @@ end -------------------------------------------------------------------- local function TMXBug987() local ret = createTileDemoLayer("TMX Bug 987", "You should see an square") - local map = cc.FastTMXTiledMap:create("TileMaps/orthogonal-test6.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/orthogonal-test6.tmx") ret:addChild(map, 0, kTagTileMap) local s1 = map:getContentSize() @@ -1136,7 +1137,7 @@ end -------------------------------------------------------------------- local function TMXBug787() local ret = createTileDemoLayer("TMX Bug 787", "You should see a map") - local map = cc.FastTMXTiledMap:create("TileMaps/iso-test-bug787.tmx") + local map = ccexp.TMXTiledMap:create("TileMaps/iso-test-bug787.tmx") ret:addChild(map, 0, kTagTileMap) map:setScale(0.25) return ret diff --git a/tests/lua-tests/src/LabelTestNew/LabelTestNew.lua b/tests/lua-tests/src/LabelTestNew/LabelTestNew.lua index dd01031fa1..74ccbb576f 100644 --- a/tests/lua-tests/src/LabelTestNew/LabelTestNew.lua +++ b/tests/lua-tests/src/LabelTestNew/LabelTestNew.lua @@ -531,7 +531,7 @@ function LabelTTFUnicodeChinese.create() local s = cc.Director:getInstance():getWinSize() local ttfConfig = {} - ttfConfig.fontFilePath="fonts/wt021.ttf" + ttfConfig.fontFilePath="fonts/HKYuanMini.ttf" ttfConfig.fontSize=28 ttfConfig.glyphs=cc.GLYPHCOLLECTION_CUSTOM ttfConfig.customGlyphs="美好的一天啊" @@ -858,7 +858,7 @@ function LabelTTFUnicodeNew.create() layer:addChild(label2) label2:setPosition(cc.p(s.width/2, vSize - vStep * 5.5)) - ttfConfig.fontFilePath = "fonts/wt021.ttf" + ttfConfig.fontFilePath = "fonts/HKYuanMini.ttf" ttfConfig.glyphs = cc.GLYPHCOLLECTION_CUSTOM ttfConfig.customGlyphs = "美好的一天" local label3 = cc.Label:createWithTTF(ttfConfig, "美好的一天", cc.TEXT_ALIGNMENT_CENTER, s.width) @@ -1022,7 +1022,7 @@ function LabelTTFCJKWrappingTest.create() local size = cc.Director:getInstance():getVisibleSize() local ttfConfig = {} - ttfConfig.fontFilePath = "fonts/wt021.ttf" + ttfConfig.fontFilePath = "fonts/HKYuanMini.ttf" ttfConfig.fontSize = 25 ttfConfig.glyphs = cc.GLYPHCOLLECTION_DYNAMIC ttfConfig.customGlyphs = nil @@ -1296,32 +1296,6 @@ function LabelCrashTest.create() return layer end - - - --------------------------------------------------------- ------ LabelTTFLargeText --------------------------------------------------------- -local LabelTTFLargeText = {} -function LabelTTFLargeText.create() - local layer = cc.Layer:create() - Helper.initWithLayer(layer) - Helper.titleLabel:setString("New Label + .TTF") - Helper.subtitleLabel:setString("Uses the new Label with TTF. Testing large text") - - local ttfConfig = {} - ttfConfig.fontFilePath = "fonts/wt021.ttf" - ttfConfig.fontSize = 18 - ttfConfig.glyphs = cc.GLYPHCOLLECTION_DYNAMIC - local s = cc.Director:getInstance():getWinSize() - local text = cc.FileUtils:getInstance():getStringFromFile("commonly_used_words.txt") - local label = cc.Label:createWithTTF(ttfConfig, text, cc.TEXT_ALIGNMENT_CENTER, s.width) - label:setPosition( cc.p(s.width/2, s.height/2) ) - layer:addChild(label) - - return layer -end - -------------------------------------------------------- ----- LabelShadowTest -------------------------------------------------------- @@ -1751,7 +1725,6 @@ function LabelTestNew() LabelFNTOffset.create, LabelFNTColor.create, LabelTTFLongLineWrapping.create, - LabelTTFLargeText.create, LabelTTFColor.create, LabelFNTHundredLabels.create, LabelFNTMultiLine.create, diff --git a/tests/lua-tests/src/OpenGLTest/OpenGLTest.lua b/tests/lua-tests/src/OpenGLTest/OpenGLTest.lua index f6c6860efb..428ba1d3aa 100644 --- a/tests/lua-tests/src/OpenGLTest/OpenGLTest.lua +++ b/tests/lua-tests/src/OpenGLTest/OpenGLTest.lua @@ -20,6 +20,8 @@ local vertDefaultSource = "\n".."\n" .. " v_texCoord = a_texCoord;\n" .. "} \n" +local scaleFactor = cc.Director:getInstance():getContentScaleFactor() + local function OpenGLTestMainLayer() local kItemTagBasic = 1000 local testCount = 16 @@ -231,6 +233,8 @@ local function OpenGLTestMainLayer() time = 0 majorLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return majorLayer end @@ -272,6 +276,8 @@ local function OpenGLTestMainLayer() time = 0 mandelbrotLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return mandelbrotLayer end @@ -314,6 +320,8 @@ local function OpenGLTestMainLayer() time = 0 heartLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return heartLayer end @@ -357,6 +365,8 @@ local function OpenGLTestMainLayer() time = 0 plasmaLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return plasmaLayer end @@ -399,6 +409,8 @@ local function OpenGLTestMainLayer() time = 0 flowerLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return flowerLayer end @@ -441,6 +453,8 @@ local function OpenGLTestMainLayer() time = 0 juliaLayer:addChild(glNode,-10) glNode:setPosition( size.width/2, size.height/2) + local center = cc.p( size.width / 2 * scaleFactor, size.height / 2 * scaleFactor) + glNode:getGLProgramState():setUniformVec2("center", center) return juliaLayer end @@ -545,7 +559,7 @@ local function OpenGLTestMainLayer() shader:setUniformsForBuiltins(transform) gl.bindTexture(gl.TEXTURE_2D, texture.texture_id) - gl.glEnableVertexAttribs(cc.VERTEX_ATTRIB_FLAG_TEX_COORDS or cc.VERTEX_ATTRIB_FLAG_POSITION) + gl.glEnableVertexAttribs(bit._or(cc.VERTEX_ATTRIB_FLAG_TEX_COORDS, cc.VERTEX_ATTRIB_FLAG_POSITION)) gl.bindBuffer(gl.ARRAY_BUFFER, squareVertexPositionBuffer.buffer_id) gl.vertexAttribPointer(cc.VERTEX_ATTRIB_POSITION,2,gl.FLOAT,false,0,0) diff --git a/tests/lua-tests/src/PhysicsTest/PhysicsTest.lua b/tests/lua-tests/src/PhysicsTest/PhysicsTest.lua index 9043a42c8d..725744fe5d 100644 --- a/tests/lua-tests/src/PhysicsTest/PhysicsTest.lua +++ b/tests/lua-tests/src/PhysicsTest/PhysicsTest.lua @@ -16,89 +16,6 @@ local function range(from, to, step) end, nil, from - step end --- bit operation - -bit = bit or {} -bit.data32 = {} -for i=1,32 do - bit.data32[i]=2^(32-i) -end - -function bit._b2d(arg) - local nr=0 - for i=1,32 do - if arg[i] ==1 then - nr=nr+bit.data32[i] - end - end - return nr -end - -function bit._d2b(arg) - arg = arg >= 0 and arg or (0xFFFFFFFF + arg + 1) - local tr={} - for i=1,32 do - if arg >= bit.data32[i] then - tr[i]=1 - arg=arg-bit.data32[i] - else - tr[i]=0 - end - end - return tr -end - -function bit._and(a,b) - local op1=bit._d2b(a) - local op2=bit._d2b(b) - local r={} - - for i=1,32 do - if op1[i]==1 and op2[i]==1 then - r[i]=1 - else - r[i]=0 - end - end - return bit._b2d(r) - -end - -function bit._rshift(a,n) - local op1=bit._d2b(a) - n = n <= 32 and n or 32 - n = n >= 0 and n or 0 - - for i=32, n+1, -1 do - op1[i] = op1[i-n] - end - for i=1, n do - op1[i] = 0 - end - - return bit._b2d(op1) -end - -function bit._not(a) - local op1=bit._d2b(a) - local r={} - - for i=1,32 do - if op1[i]==1 then - r[i]=0 - else - r[i]=1 - end - end - return bit._b2d(r) -end - -bit.band = bit.band or bit._and -bit.rshift = bit.rshift or bit._rshift -bit.bnot = bit.bnot or bit._not - --- bit operation end - local function initWithLayer(layer, callback) curLayer = layer layer.spriteTexture = cc.SpriteBatchNode:create("Images/grossini_dance_atlas.png", 100):getTexture() diff --git a/tests/lua-tests/src/Sprite3DTest/Sprite3DTest.lua b/tests/lua-tests/src/Sprite3DTest/Sprite3DTest.lua index 19298ad2e2..6e41219035 100644 --- a/tests/lua-tests/src/Sprite3DTest/Sprite3DTest.lua +++ b/tests/lua-tests/src/Sprite3DTest/Sprite3DTest.lua @@ -79,18 +79,27 @@ function Sprite3DWithSkinTest.addNewSpriteWithCoords(parent,x,y) sprite:setPosition(cc.p(x, y)) parent:addChild(sprite) - local animation = cc.Animation3D:getOrCreate("Sprite3DTest/orc.c3b") + local animation = cc.Animation3D:create("Sprite3DTest/orc.c3b") if nil ~= animation then local animate = cc.Animate3D:create(animation) - if math.random() < (1/3) then - animate:setPlayBack(true) + local inverse = false + if math.random() == 0 then + inverse = true end local rand2 = math.random() + local speed = 1.0 + if rand2 < 1/3 then - animate:setSpeed(animate:getSpeed() + math.random()) + speed = animate:getSpeed() + math.random() elseif rand2 < 2/3 then - animate:setSpeed(animate:getSpeed() - 0.5 * math.random()) + speed = animate:getSpeed() - 0.5 * math.random() + end + + if inverse then + animate:setSpeed(-speed) + else + animate:setSpeed(speed) end sprite:runAction(cc.RepeatForever:create(animate)) @@ -226,7 +235,7 @@ function Animate3DTest:addSprite3D() self._sprite = sprite - local animation = cc.Animation3D:getOrCreate(fileName) + local animation = cc.Animation3D:create(fileName) if nil ~= animation then local animate = cc.Animate3D:create(animation, 0.0, 1.933) sprite:runAction(cc.RepeatForever:create(animate)) diff --git a/tests/lua-tests/src/Texture2dTest/Texture2dTest.lua b/tests/lua-tests/src/Texture2dTest/Texture2dTest.lua index 680d3e77b1..c54fc74691 100644 --- a/tests/lua-tests/src/Texture2dTest/Texture2dTest.lua +++ b/tests/lua-tests/src/Texture2dTest/Texture2dTest.lua @@ -969,23 +969,16 @@ local function TextureAsync() local seq = cc.Sequence:create(scale, scale_back) label:runAction(cc.RepeatForever:create(seq)) - local function imageLoaded(pObj) - local tex = pObj + local function imageLoaded(texture) local director = cc.Director:getInstance() - --cc.ASSERT( [NSThread currentThread] == [director runningThread], @"FAIL. Callback should be on cocos2d thread") - - -- IMPORTANT: The order on the callback is not guaranteed. Don't depend on the callback - - -- This test just creates a sprite based on the Texture - - local sprite = cc.Sprite:createWithTexture(tex) + local sprite = cc.Sprite:createWithTexture(texture) sprite:setAnchorPoint(cc.p(0,0)) ret:addChild(sprite, -1) local size = director:getWinSize() local i = m_nImageOffset * 32 - sprite:setPosition(cc.p( i % size.width, (i / size.width) * 32 )) + sprite:setPosition(cc.p( i % size.width, math.floor((i / size.width)) * 32 )) m_nImageOffset = m_nImageOffset + 1 cclog("Image loaded:...")-- %p", tex) @@ -1008,14 +1001,15 @@ local function TextureAsync() cc.Director:getInstance():getTextureCache():addImageAsync("Images/background.png", imageLoaded) cc.Director:getInstance():getTextureCache():addImageAsync("Images/atlastest.png", imageLoaded) cc.Director:getInstance():getTextureCache():addImageAsync("Images/grossini_dance_atlas.png",imageLoaded) + + ret:unscheduleUpdate() end - local schedulerEntry = nil local function onNodeEvent(event) if event == "enter" then - schedulerEntry = scheduler:scheduleScriptFunc(loadImages, 1.0, false) + ret:scheduleUpdateWithPriorityLua(loadImages,0) elseif event == "exit" then - scheduler:unscheduleScriptEntry(schedulerEntry) + ret:unscheduleUpdate() cc.Director:getInstance():getTextureCache():removeAllTextures() end end @@ -1266,31 +1260,17 @@ local function TextureMemoryAlloc() local targetPlatform = cc.Application:getInstance():getTargetPlatform() local file = "" - if targetPlatform == cc.PLATFORM_OS_ANDROID then - if tag == 0 then - file = "Images/background.png" + if tag == 0 then + file = "Images/test_image.png" elseif tag == 1 then - file = "Images/fire_rgba8888.pvr" + file = "Images/test_image_rgba8888.pvr" elseif tag == 2 then - file = "Images/grossini_pvr_rgba8888.pvr" + file = "Images/test_image_rgb888.pvr" elseif tag == 3 then - file = "Images/grossini_pvr_rgba4444.pvr" + file = "Images/test_image_rgba4444.pvr" elseif tag == 4 then file = "Images/test_image_a8.pvr" end - else - if tag == 0 then - file = "Images/background.png" - elseif tag == 1 then - file = "Images/test_image_rgba4444.pvr.gz" - elseif tag == 2 then - file = "Images/test_image_rgba4444.pvr.gz" - elseif tag == 3 then - file = "Images/test_image_rgba4444.pvr.gz" - elseif tag == 4 then - file = "Images/test_image_rgba4444.pvr.gz" - end - end m_pBackground = cc.Sprite:create(file) ret:addChild(m_pBackground, -10) diff --git a/tests/lua-tests/src/TileMapTest/TileMapTest.lua b/tests/lua-tests/src/TileMapTest/TileMapTest.lua index b356b7cdf9..54c138e87c 100644 --- a/tests/lua-tests/src/TileMapTest/TileMapTest.lua +++ b/tests/lua-tests/src/TileMapTest/TileMapTest.lua @@ -1106,41 +1106,40 @@ local function TMXOrthoFlipRunTimeTest() local action = cc.ScaleBy:create(2, 0.5) map:runAction(action) local function flipIt(dt) + local map = ret:getChildByTag(kTagTileMap) + local layer = map:getLayer("Layer 0") - -- local map = tolua.cast(ret:getChildByTag(kTagTileMap), "TMXTiledMap") - -- local layer = map:getLayer("Layer 0") + local tileCoord = cc.p(1, 10) + local flags = 0 + local GID, flags = layer:getTileGIDAt(tileCoord, flags) - -- --blue diamond - -- local tileCoord = cc.p(1,10) - -- local flags = 0 - -- local GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Vertical - -- if( flags & kcc.TMXTileVerticalFlag ) - -- flags &= ~kcc.TMXTileVerticalFlag - -- else - -- flags |= kcc.TMXTileVerticalFlag - -- layer:setTileGID(GID ,tileCoord, (ccTMXTileFlags)flags) + if 0 ~= bit._and(flags, cc.TMX_TILE_VERTICAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_VERTICAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_VERTICAL_FLAG) + end + layer:setTileGID(GID, tileCoord, flags) + tileCoord = cc.p(1,8) + GID, flags = layer:getTileGIDAt(tileCoord, flags) + if 0 ~= bit._and(flags, cc.TMX_TILE_VERTICAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_VERTICAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_VERTICAL_FLAG) + end + layer:setTileGID(GID ,tileCoord, flags) - -- tileCoord = cc.p(1,8) - -- GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Vertical - -- if( flags & kcc.TMXTileVerticalFlag ) - -- flags &= ~kcc.TMXTileVerticalFlag - -- else - -- flags |= kcc.TMXTileVerticalFlag - -- layer:setTileGID(GID ,tileCoord, (ccTMXTileFlags)flags) - - - -- tileCoord = cc.p(2,8) - -- GID = layer:getTileGIDAt(tileCoord, (ccTMXTileFlags*)&flags) - -- -- Horizontal - -- if( flags & kcc.TMXTileHorizontalFlag ) - -- flags &= ~kcc.TMXTileHorizontalFlag - -- else - -- flags |= kcc.TMXTileHorizontalFlag - -- layer:setTileGID(GID, tileCoord, (ccTMXTileFlags)flags) + tileCoord = cc.p(2,8) + GID, flags = layer:getTileGIDAt(tileCoord, flags) + -- Horizontal + if 0~= bit._and(flags, cc.TMX_TILE_HORIZONTAL_FLAG) then + flags = bit._and(flags, bit._not(cc.TMX_TILE_HORIZONTAL_FLAG)) + else + flags = bit._or(flags, cc.TMX_TILE_HORIZONTAL_FLAG) + end + layer:setTileGID(GID, tileCoord, flags) end + local schedulerEntry = nil local function onNodeEvent(event) if event == "enter" then @@ -1149,6 +1148,9 @@ local function TMXOrthoFlipRunTimeTest() scheduler:unscheduleScriptEntry(schedulerEntry) end end + + ret:registerScriptHandler(onNodeEvent) + return ret end diff --git a/tests/lua-tests/src/VideoPlayerTest/VideoPlayerTest.lua b/tests/lua-tests/src/VideoPlayerTest/VideoPlayerTest.lua index 022745d079..41ec6834eb 100644 --- a/tests/lua-tests/src/VideoPlayerTest/VideoPlayerTest.lua +++ b/tests/lua-tests/src/VideoPlayerTest/VideoPlayerTest.lua @@ -21,18 +21,18 @@ local function VideoPlayerTest() layer:addChild(videoStateLabel) local function onVideoEventCallback(sener, eventType) - if eventType == ccexprimental.VideoPlayerEvent.PLAYING then + if eventType == ccexp.VideoPlayerEvent.PLAYING then videoStateLabel:setString("PLAYING") - elseif eventType == ccexprimental.VideoPlayerEvent.PAUSED then + elseif eventType == ccexp.VideoPlayerEvent.PAUSED then videoStateLabel:setString("PAUSED") - elseif eventType == ccexprimental.VideoPlayerEvent.STOPPED then + elseif eventType == ccexp.VideoPlayerEvent.STOPPED then videoStateLabel:setString("STOPPED") - elseif eventType == ccexprimental.VideoPlayerEvent.COMPLETED then + elseif eventType == ccexp.VideoPlayerEvent.COMPLETED then videoStateLabel:setString("COMPLETED") end end local widgetSize = widget:getContentSize() - local videoPlayer = ccexprimental.VideoPlayer:create() + local videoPlayer = ccexp.VideoPlayer:create() videoPlayer:setPosition(centerPos) videoPlayer:setAnchorPoint(cc.p(0.5, 0.5)) videoPlayer:setContentSize(cc.size(widgetSize.width * 0.4,widgetSize.height * 0.4)) diff --git a/tests/lua-tests/src/mainMenu.lua b/tests/lua-tests/src/mainMenu.lua index 7aea67ebbb..858aad51b9 100644 --- a/tests/lua-tests/src/mainMenu.lua +++ b/tests/lua-tests/src/mainMenu.lua @@ -4,6 +4,7 @@ require "Opengl" require "OpenglConstants" require "StudioConstants" require "GuiConstants" +require "bitExtend" require "src/helper" require "src/testResource" require "src/VisibleRect" diff --git a/tools/bindings-generator b/tools/bindings-generator index 132282d67a..6fcfc80c68 160000 --- a/tools/bindings-generator +++ b/tools/bindings-generator @@ -1 +1 @@ -Subproject commit 132282d67aff8da7113f4a00596aac75e7b4528d +Subproject commit 6fcfc80c68b22de00342cc3fa8e0f3168bcf5e06 diff --git a/tools/cocos2d-console b/tools/cocos2d-console index ce3e25bcd2..751afb6fb1 160000 --- a/tools/cocos2d-console +++ b/tools/cocos2d-console @@ -1 +1 @@ -Subproject commit ce3e25bcd273eaacd516d179587997ce8f62df70 +Subproject commit 751afb6fb1cc20665990157530890a6f3200e0d7 diff --git a/tools/jenkins-scripts/pull-request-builder.py b/tools/jenkins-scripts/pull-request-builder.py index eb36154c49..7402a2a425 100755 --- a/tools/jenkins-scripts/pull-request-builder.py +++ b/tools/jenkins-scripts/pull-request-builder.py @@ -13,6 +13,7 @@ import platform import subprocess import codecs from shutil import copy +import MySQLdb #set Jenkins build description using submitDescription to mock browser behavior #TODO: need to set parent build description @@ -61,10 +62,25 @@ def check_current_3rd_libs(branch): current_file = current_files[i] copy(current_file, backup_file) +def save_build_stats(pr_num, key, value): + db_host = os.environ['db_host'] + db_user = os.environ['db_user'] + db_pw = os.environ['db_pw'] + db = MySQLdb.connect(db_host, db_user, db_pw, "jenkins" ) + cursor = db.cursor() + sql = '''INSERT INTO PullRequestBuild (pr_number, %s) + VALUES(%d, %d) ON DUPLICATE KEY UPDATE pr_number=VALUES(pr_number), + %s=VALUES(%s)''' % (key, pr_num, value, key, key) + print sql + cursor.execute(sql) + db.commit() + db.close() + http_proxy = '' if(os.environ.has_key('HTTP_PROXY')): http_proxy = os.environ['HTTP_PROXY'] proxyDict = {'http':http_proxy,'https':http_proxy} + def main(): #get payload from os env payload_str = os.environ['payload'] @@ -201,6 +217,13 @@ def main(): local_apk = sample_dir + 'bin/CppTests-debug.apk' backup_apk = os.environ['BACKUP_PATH'] + 'CppTests_' + str(pr_num) + '.apk' os.system('cp ' + local_apk + ' ' + backup_apk) + ret = os.system("python build/android-build.py -p 10 -b release cpp-empty-test") + if(ret == 0): + _path = 'tests/cpp-empty-test/proj.android/libs/armeabi/libcpp_empty_test.so' + filesize = os.path.getsize(_path) + pr_desc = pr_desc + '

size of libcpp_empty_test.so is:' + str(filesize/1024) + 'kb

' + set_description(pr_desc, target_url) + save_build_stats(pr_num, 'cpp_empty_test_so', filesize/1024) elif(node_name == 'win32_win7'): ret = subprocess.call('"%VS110COMNTOOLS%..\IDE\devenv.com" "build\cocos2d-win32.vc2012.sln" /Build "Debug|Win32"', shell=True) elif(node_name == 'ios_mac'): diff --git a/tools/tolua/cocos2dx.ini b/tools/tolua/cocos2dx.ini index 7828472fc1..5a81a03b9a 100644 --- a/tools/tolua/cocos2dx.ini +++ b/tools/tolua/cocos2dx.ini @@ -35,7 +35,7 @@ classes = New.* Sprite.* Scene Node.* Director Layer.* Menu.* Touch .*Action.* M # will apply to all class names. This is a convenience wildcard to be able to skip similar named # functions from all classes. -skip = Node::[setGLServerState description getUserObject .*UserData getGLServerState .*schedule getPosition$ setContentSize setAnchorPoint enumerateChildren], +skip = Node::[setGLServerState description getUserObject .*UserData getGLServerState .*schedule getPosition$ setContentSize setAnchorPoint enumerateChildren getonEnterTransitionDidFinishCallback getOnEnterCallback getOnExitCallback getonExitTransitionDidStartCallback], Sprite::[getQuad getBlendFunc ^setPosition$ setBlendFunc], SpriteBatchNode::[getBlendFunc setBlendFunc getDescendants], MotionStreak::[getBlendFunc setBlendFunc draw update], @@ -131,8 +131,7 @@ skip = Node::[setGLServerState description getUserObject .*UserData getGLServerS Animation3D::[getBoneCurveByName], Animation3DCache::[*], Sprite3DMaterialCache::[*], - Bone3D::[*], - FastTMXLayer::[(g|s)etTiles getTileGIDAt] + Bone3D::[*] rename_functions = SpriteFrameCache::[addSpriteFramesWithFile=addSpriteFrames getSpriteFrameByName=getSpriteFrame], ProgressTimer::[setReverseProgress=setReverseDirection], diff --git a/tools/tolua/cocos2dx_experimental.ini b/tools/tolua/cocos2dx_experimental.ini new file mode 100644 index 0000000000..97d890abf1 --- /dev/null +++ b/tools/tolua/cocos2dx_experimental.ini @@ -0,0 +1,60 @@ +[cocos2dx_experimental] +# the prefix to be added to the generated functions. You might or might not use this in your own +# templates +prefix = cocos2dx_experimental + +# create a target namespace (in javascript, this would create some code like the equiv. to `ns = ns || {}`) +# all classes will be embedded in that namespace +target_namespace = ccexp + +android_headers = -I%(androidndkdir)s/platforms/android-14/arch-arm/usr/include -I%(androidndkdir)s/sources/cxx-stl/gnu-libstdc++/4.7/libs/armeabi-v7a/include -I%(androidndkdir)s/sources/cxx-stl/gnu-libstdc++/4.7/include -I%(androidndkdir)s/sources/cxx-stl/gnu-libstdc++/4.8/libs/armeabi-v7a/include -I%(androidndkdir)s/sources/cxx-stl/gnu-libstdc++/4.8/include +android_flags = -D_SIZE_T_DEFINED_ + +clang_headers = -I%(clangllvmdir)s/lib/clang/3.3/include +clang_flags = -nostdinc -x c++ -std=c++11 + +cocos_headers = -I%(cocosdir)s/cocos -I%(cocosdir)s/cocos/editor-support -I%(cocosdir)s/cocos/platform/android + +cocos_flags = -DANDROID + +cxxgenerator_headers = + +# extra arguments for clang +extra_arguments = %(android_headers)s %(clang_headers)s %(cxxgenerator_headers)s %(cocos_headers)s %(android_flags)s %(clang_flags)s %(cocos_flags)s %(extra_flags)s + +# what headers to parse +headers = %(cocosdir)s/cocos/2d/CCFastTMXLayer.h %(cocosdir)s/cocos/2d/CCFastTMXTiledMap.h + +# what classes to produce code for. You can use regular expressions here. When testing the regular +# expression, it will be enclosed in "^$", like this: "^Menu*$". +classes = TMXLayer TMXTiledMap + +# what should we skip? in the format ClassName::[function function] +# ClassName is a regular expression, but will be used like this: "^ClassName$" functions are also +# regular expressions, they will not be surrounded by "^$". If you want to skip a whole class, just +# add a single "*" as functions. See bellow for several examples. A special class name is "*", which +# will apply to all class names. This is a convenience wildcard to be able to skip similar named +# functions from all classes. + +skip = TMXLayer::[(g|s)etTiles getTileGIDAt] + +rename_functions = + +rename_classes = + +# for all class names, should we remove something when registering in the target VM? +remove_prefix = + +# classes for which there will be no "parent" lookup +classes_have_no_parents = + +# base classes which will be skipped when their sub-classes found them. +base_classes_to_skip = + +# classes that create no constructor +# Set is special and we will use a hand-written constructor +abstract_classes = + +# Determining whether to use script object(js object) to control the lifecycle of native(cpp) object or the other way around. Supported values are 'yes' or 'no'. +script_control_cpp = no + diff --git a/tools/tolua/cocos2dx_experimental_video.ini b/tools/tolua/cocos2dx_experimental_video.ini index 80bf9a254a..e0c343b56e 100644 --- a/tools/tolua/cocos2dx_experimental_video.ini +++ b/tools/tolua/cocos2dx_experimental_video.ini @@ -5,7 +5,7 @@ prefix = cocos2dx_experimental_video # create a target namespace (in javascript, this would create some code like the equiv. to `ns = ns || {}`) # all classes will be embedded in that namespace -target_namespace = ccexprimental +target_namespace = ccexp macro_judgement = #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID || CC_TARGET_PLATFORM == CC_PLATFORM_IOS) @@ -29,7 +29,7 @@ headers = %(cocosdir)s/cocos/ui/UIVideoPlayer.h # what classes to produce code for. You can use regular expressions here. When testing the regular # expression, it will be enclosed in "^$", like this: "^Menu*$". -classes = VideoPlayer +classes = VideoPlayer FastTMXLayer FastTMXTiledMap # what should we skip? in the format ClassName::[function function] # ClassName is a regular expression, but will be used like this: "^ClassName$" functions are also diff --git a/tools/tolua/cocos2dx_spine.ini b/tools/tolua/cocos2dx_spine.ini index 5d1e6743c0..9ab910e8a2 100644 --- a/tools/tolua/cocos2dx_spine.ini +++ b/tools/tolua/cocos2dx_spine.ini @@ -37,7 +37,7 @@ classes = Skeleton SkeletonAnimation # functions from all classes. skip = Skeleton::[findBone findSlot getAttachment setAttachment update draw createWith.*], - SkeletonAnimation::[addAnimationState setAnimationStateData update createWith.* (s|g)etBlendFunc addAnimation getCurrent setAnimation] + SkeletonAnimation::[addAnimationState setAnimationStateData update createWith.* (s|g)etBlendFunc addAnimation getCurrent setAnimation onAnimationStateEvent] rename_functions = diff --git a/tools/tolua/cocos2dx_studio.ini b/tools/tolua/cocos2dx_studio.ini index ca654b59ad..32baa60dae 100644 --- a/tools/tolua/cocos2dx_studio.ini +++ b/tools/tolua/cocos2dx_studio.ini @@ -45,13 +45,12 @@ skip = *::[^visit$ copyWith.* onEnter.* onExit.* ^description$ getObjectType .* Skin::[(s|g)etSkinData], ArmatureAnimation::[updateHandler updateFrameData frameEvent setMovementEventCallFunc setFrameEventCallFunc], Bone::[(s|g)etIgnoreMovementBoneData], - ActionManagerEx::[initWithDictionary], - ActionObject::[initWithDictionary], + ActionManagerEx::[initWithDictionary initWithBinary], DisplayManager::[initDisplayList (s|g)etCurrentDecorativeDisplay getDecorativeDisplayByIndex], Tween::[(s|g)etMovementBoneData], GUIReader::[storeFileDesignSize getFileDesignSize getParseCallBackMap getParseObjectMap], ActionNode::[initWithDictionary], - ActionObject::[initWithDictionary], + ActionObject::[initWithDictionary initWithBinary], BaseData::[copy subtract], NodeReader::[getInstance], ActionTimelineCache::[getInstance] diff --git a/tools/tolua/genbindings.py b/tools/tolua/genbindings.py index 1c72481ff5..72fa4824bd 100755 --- a/tools/tolua/genbindings.py +++ b/tools/tolua/genbindings.py @@ -133,6 +133,7 @@ def main(): 'cocos2dx_spine.ini' : ('cocos2dx_spine', 'lua_cocos2dx_spine_auto'), \ 'cocos2dx_physics.ini' : ('cocos2dx_physics', 'lua_cocos2dx_physics_auto'), \ 'cocos2dx_experimental_video.ini' : ('cocos2dx_experimental_video', 'lua_cocos2dx_experimental_video_auto'), \ + 'cocos2dx_experimental.ini' : ('cocos2dx_experimental', 'lua_cocos2dx_experimental_auto'), \ 'cocos2dx_controller.ini' : ('cocos2dx_controller', 'lua_cocos2dx_controller_auto'), \ } target = 'lua'