remove hack (#3614)

This commit is contained in:
Leslie Leigh
2018-12-10 17:02:30 +08:00
committed by pandamicro
parent 0e08768802
commit d69ab0b3ee
2 changed files with 3 additions and 10 deletions
+2 -2
View File
@@ -28,12 +28,12 @@ import CameraComponent from './camera-component';
import AnimationComponent from './animation-component';
import LightComponent from './light-component';
import ModelComponent from './model-component';
import SkinnedModelComponent from './skinning-model-component';
import SkinningModelComponent from './skinning-model-component';
import SkyboxComponent from './skybox-component';
cc.CameraComponent = CameraComponent;
cc.AnimationComponent = AnimationComponent;
cc.LightComponent = LightComponent;
cc.ModelComponent = ModelComponent;
cc.SkinnedModelComponent = SkinnedModelComponent;
cc.SkinningModelComponent = SkinningModelComponent;
cc.SkyboxComponent = SkyboxComponent;
+1 -8
View File
@@ -275,13 +275,6 @@ export default class ModelComponent extends RenderableComponent {
_getBuiltinMaterial() {
// classic ugly pink indicating missing material
//return cc.BuiltinResMgr['default-material'];
if (ModelComponent._m === null) {
ModelComponent._m = new cc.Material();
ModelComponent._m.effectName = 'builtin-effect-phong';
}
return ModelComponent._m;
return cc.BuiltinResMgr['default-material'];
}
static _m = null;
}