cocos / cocos-engine

Cocos simplifies game creation and distribution with Cocos Creator, a free, open-source, cross-platform game engine. Empowering millions of developers to create high-performance, engaging 2D/3D games and instant web entertainment.
https://www.cocos.com/en/creator
Other
7.79k stars 1.89k forks source link

error 3408 #5655

Closed fsm2018 closed 4 years ago

fsm2018 commented 4 years ago

image

Marssssssss commented 4 years ago

您好,您是否在脚本中调用了非节点对象的 getComponent 函数或者 getComponent 参数写错了? image

fsm2018 commented 4 years ago

是分包加载的问题   把脚本变成子包了 

------------------ 原始邮件 ------------------ 发件人: "YuanJie"<notifications@github.com>; 发送时间: 2019年10月31日(星期四) 中午11:24 收件人: "cocos-creator/engine"<engine@noreply.github.com>; 抄送: "1365064385"<1365064385@qq.com>; "Author"<author@noreply.github.com>; 主题: Re: [cocos-creator/engine] error 3408 (#5655)

您好,您是否在脚本中调用了非节点对象的 getComponent 函数或者 getComponent 参数写错了?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

Marssssssss commented 4 years ago

是分包加载的问题   把脚本变成子包了  ------------------ 原始邮件 ------------------ 发件人: "YuanJie"<notifications@github.com>; 发送时间: 2019年10月31日(星期四) 中午11:24 收件人: "cocos-creator/engine"<engine@noreply.github.com>; 抄送: "1365064385"<1365064385@qq.com>; "Author"<author@noreply.github.com>; 主题: Re: [cocos-creator/engine] error 3408 (#5655) 您好,您是否在脚本中调用了非节点对象的 getComponent 函数或者 getComponent 参数写错了? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

噢噢,那现在是已经解决了吗?

fsm2018 commented 4 years ago

已经解决了 把脚本放到主包 就好了 ps:h5 启动速度 要怎么优化啊  感觉加载好慢啊

------------------ 原始邮件 ------------------ 发件人: "YuanJie"<notifications@github.com>; 发送时间: 2019年10月31日(星期四) 中午11:40 收件人: "cocos-creator/engine"<engine@noreply.github.com>; 抄送: "1365064385"<1365064385@qq.com>; "Author"<author@noreply.github.com>; 主题: Re: [cocos-creator/engine] error 3408 (#5655)

是分包加载的问题   把脚本变成子包了  … ------------------ 原始邮件 ------------------ 发件人: "YuanJie"<notifications@github.com>; 发送时间: 2019年10月31日(星期四) 中午11:24 收件人: "cocos-creator/engine"<engine@noreply.github.com>; 抄送: "1365064385"<1365064385@qq.com>; "Author"<author@noreply.github.com>; 主题: Re: [cocos-creator/engine] error 3408 (#5655) 您好,您是否在脚本中调用了非节点对象的 getComponent 函数或者 getComponent 参数写错了? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

噢噢,那现在是已经解决了吗?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

SantyWang commented 4 years ago

自动图集,json合并,都可以提升一定的加载速度