mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-01 07:42:38 +08:00
Merge branch 'v1.0' of github.com:cocos-creator/engine into v1.0
This commit is contained in:
@@ -57,8 +57,12 @@ var RendererInSG = cc.Class({
|
||||
|
||||
onLoad: function () {
|
||||
this._initSgNode();
|
||||
if ( !this._sgNode.getContentSize().equals(cc.Size.ZERO) && CC_EDITOR ) {
|
||||
cc.error('Renderer error: Size of the cc._RendererInSG._sgNode must be zero');
|
||||
if (CC_EDITOR) {
|
||||
var sgSize = this._sgNode.getContentSize();
|
||||
// sgSize is not a Vec2 in JSB
|
||||
if (sgSize.x !== 0 || sgSize.y !== 0) {
|
||||
cc.error('Renderer error: Size of the cc._RendererInSG._sgNode must be zero');
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -41,6 +41,7 @@ var SpriteDistortion = cc.Class({
|
||||
editor: CC_EDITOR && {
|
||||
menu: 'i18n:MAIN_MENU.component.renderers/SpriteDistortion',
|
||||
executeInEditMode: true,
|
||||
requireComponent: cc.Sprite,
|
||||
},
|
||||
|
||||
ctor: function() {
|
||||
|
||||
Reference in New Issue
Block a user