Commit a70fb9c9 authored by 杨一航's avatar 杨一航

fix

parent 176c93f5
...@@ -422,7 +422,7 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -422,7 +422,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
async _startCourseware() { async _startCourseware() {
this._coursewareDone = false; this._coursewareDone = false;
if (window["courseware"]?.startTest) { if (!cc.sys.isBrowser && window["courseware"]?.startTest) {
console.log("模拟录音开始 单词:" + this._nowData.text); console.log("模拟录音开始 单词:" + this._nowData.text);
window["courseware"]?.startTest(this._nowData.text); window["courseware"]?.startTest(this._nowData.text);
...@@ -456,7 +456,7 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -456,7 +456,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
cc.tween(this.cover).to(0.5, { opacity: 255 }).start(); cc.tween(this.cover).to(0.5, { opacity: 255 }).start();
await asyncDelay(0.5); await asyncDelay(0.5);
if (window["courseware"]?.stopTest) { if (!cc.sys.isBrowser && window["courseware"]?.stopTest) {
window["courseware"]?.stopTest((res, b) => { window["courseware"]?.stopTest((res, b) => {
if (typeof res == "string") { if (typeof res == "string") {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment