【问题标题】:Why Cocos Creator engine file is not called on the browser?为什么浏览器不调用 Cocos Creator 引擎文件?
【发布时间】:2019-09-17 17:23:15
【问题描述】:

非拉丁字符未正确截断,因此我修改了 fragmentText() 函数以在空白处截断。文件在:

"C:\CocosCreator\resources\engine\cocos2d\core\label\CCTextUtils.js"

fragmentText: function (stringToken, allWidth, maxWidth, measureText) {
    return "function called";
}

问题是我在 Cocos Creator 编辑器中看到了更改,并且文本被截断了,但我看不到对浏览器的影响,因为该函数从未被调用。

为什么我构建时没有调用该函数?

P.S:我使用的是 Cocos Creator 1.10,但也有 2.1.1 安装在 C:\CocosCreator_2.1.1

【问题讨论】:

    标签: cocos2d-js cocoscreator


    【解决方案1】:

    我猜你忘记重新编译引擎了。

    检查网站上的步骤1.3,然后重试。
    1.3 Change and Build

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-03-24
      • 2018-02-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2010-12-21
      • 2010-12-15
      相关资源
      最近更新 更多