Merge pull request #1736 from pandamicro/develop-3.0

Issue #4589: Make engine classes extendable directly via ctor pack 1
Fixed #4670: Add null callback check in cc.textureCache.addImage