mirror of https://github.com/axmolengine/axmol.git
Merge pull request #4222 from HoGarfield/Scale9SpriteLoader
[ci skip]To set anchor point to 0,0 when created by loader
This commit is contained in:
commit
f56cf9b8bf
|
@ -28,7 +28,13 @@ protected:
|
|||
* @js NA
|
||||
* @lua NA
|
||||
*/
|
||||
CCB_VIRTUAL_NEW_AUTORELEASE_CREATECCNODE_METHOD(cocos2d::extension::Scale9Sprite);
|
||||
virtual cocos2d::extension::Scale9Sprite * createNode(cocos2d::Node * pParent, cocosbuilder::CCBReader * ccbReader) {
|
||||
cocos2d::extension::Scale9Sprite* pNode = cocos2d::extension::Scale9Sprite::create();
|
||||
|
||||
pNode->setAnchorPoint(cocos2d::Point(0,0));
|
||||
|
||||
return pNode;
|
||||
};
|
||||
/**
|
||||
* @js NA
|
||||
* @lua NA
|
||||
|
|
Loading…
Reference in New Issue