Commit 3091b000 authored by Tt's avatar Tt

修改bug

parent 4e7ae557
...@@ -2063,8 +2063,8 @@ ...@@ -2063,8 +2063,8 @@
}, },
"_contentSize": { "_contentSize": {
"__type__": "cc.Size", "__type__": "cc.Size",
"width": 1864, "width": 1861,
"height": 1731 "height": 1729
}, },
"_anchorPoint": { "_anchorPoint": {
"__type__": "cc.Vec2", "__type__": "cc.Vec2",
......
...@@ -40,7 +40,9 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -40,7 +40,9 @@ export default class SceneComponent extends MyCocosSceneComponent {
GameNGT14.getIns().reset(); GameNGT14.getIns().reset();
let data = GameNGT14.getIns().getCurrent(); let data = GameNGT14.getIns().getCurrent();
console.log('gamestart', data) console.log('gamestart', data)
this.scheduleOnce(() => {
pg.event.emit('mouse_14_num', GameNGT14.getIns().getLen()) pg.event.emit('mouse_14_num', GameNGT14.getIns().getLen())
}, .03)
} }
private layout_start: cc.Node; private layout_start: cc.Node;
...@@ -51,6 +53,7 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -51,6 +53,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
this.initBlocks(); this.initBlocks();
} }
onDestory() { onDestory() {
this.unscheduleAllCallbacks();
pg.event.clear(); pg.event.clear();
} }
initListener() { initListener() {
...@@ -70,7 +73,9 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -70,7 +73,9 @@ export default class SceneComponent extends MyCocosSceneComponent {
let data = GameNGT14.getIns().nextQuestion(); let data = GameNGT14.getIns().nextQuestion();
if (!data) { if (!data) {
//游戏结束 //游戏结束
this.scheduleOnce(() => {
this.showFinal(); this.showFinal();
}, 1)
} else { } else {
this.gameStart(); this.gameStart();
} }
...@@ -91,9 +96,11 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -91,9 +96,11 @@ export default class SceneComponent extends MyCocosSceneComponent {
btn_next.active = false; btn_next.active = false;
finish_db.getComponent(dragonBones.ArmatureDisplay).playAnimation("newAnimation", 1); finish_db.getComponent(dragonBones.ArmatureDisplay).playAnimation("newAnimation", 1);
this.playLocalAudio("finish").then(() => { this.playLocalAudio("finish").then(() => {
this.scheduleOnce(() => {
finish_db.active = false; finish_db.active = false;
btn_again.active = true; btn_again.active = true;
btn_next.active = true; btn_next.active = true;
}, .1)
}); });
} }
......
export const defaultData = { export const defaultData = {
"questions": [{ "questions": [{
"parts": [ "parts": [
{
"id": "166668702213640281", "answer": "freedom", "options": [{
"blocks": [
{
"type": "img", "txt": "", "line": "", "img": "", "tag": "", "image": "http://staging-teach.cdn.ireadabc.com/19ac75d2de5455d268eaef8184bf805b.png"
}]
}, { "blocks": [{ "type": "txt", "txt": "", "line": "", "img": "", "tag": "", "text": "_____ do you go to the park?" }] }, { "blocks": [{ "type": "txt", "txt": "", "line": "", "img": "", "tag": "", "text": "On saturdays freedow" }] }]
},
{ {
"id": "1666687632465177361", "answer": "want", "options": [{ "blocks": [{ "type": "txt", "txt": "", "line": "", "img": "", "tag": "", "text": "Dave _____ want?" }] }] "id": "1666687632465177361", "answer": "want", "options": [{ "blocks": [{ "type": "txt", "txt": "", "line": "", "img": "", "tag": "", "text": "Dave _____ want?" }] }]
},
{
"id": "1666687612725869271", "answer": "fish", "options": [{ "blocks": [{ "type": "img", "txt": "", "line": "", "img": "", "tag": "", "image": "http://staging-teach.cdn.ireadabc.com/3f0f2572da257eedbec51f8d05e2a7d8.png" }] }]
},
{
"id": "1666687646496548891", "answer": "red", "options": [{ "blocks": [{ "type": "txt", "txt": "", "line": "", "img": "", "tag": "", "text": "The fish color is _____ answer red." }] }]
}] }]
}], }],
"title": "单词填空", "imgAni": { "ske": { "url": "http://staging-teach.cdn.ireadabc.com/4ec3da85d888ad3c5c57e10fca728499.json", "name": "鱼1_ske.json" }, "tex": { "url": "http://staging-teach.cdn.ireadabc.com/2c52380a3f3cdd3f5d38870bee2c9ffd.json", "name": "鱼1_tex.json" }, "png": { "url": "http://staging-teach.cdn.ireadabc.com/3ca112e3bb312d5e9b7182bbb97c616d.png", "name": "鱼1_tex.png" } }, "startAudio": "http://staging-teach.cdn.ireadabc.com/e587cf79c91d1cc4339540bb04b2aad0_l.mp3", "blockStruct": [{ "pId": "1666687632465177361", "point": { "x": 2, "y": 2 }, "answer": "want" }, { "pId": "1666687646496548891", "point": { "x": 3, "y": 4 }, "answer": "red" }, { "pId": "1666687612725869271", "point": { "x": 1, "y": 1 }, "answer": "fish" }, { "pId": "166668702213640281", "point": { "x": 0, "y": 0 }, "answer": "freedom" }], "blocks": [[{ "val": "f" }, { "val": "r" }, { "val": "e" }, { "val": "e" }, { "val": "d" }, { "val": "o" }, { "val": "m" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "f" }, { "val": "i" }, { "val": "s" }, { "val": "h" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "w" }, { "val": "a" }, { "val": "n" }, { "val": "t" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "r" }, { "val": "e" }, { "val": "d" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }]], "audioName": "" "title": "单词填空", "imgAni": { "ske": { "url": "http://staging-teach.cdn.ireadabc.com/4ec3da85d888ad3c5c57e10fca728499.json", "name": "鱼1_ske.json" }, "tex": { "url": "http://staging-teach.cdn.ireadabc.com/2c52380a3f3cdd3f5d38870bee2c9ffd.json", "name": "鱼1_tex.json" }, "png": { "url": "http://staging-teach.cdn.ireadabc.com/3ca112e3bb312d5e9b7182bbb97c616d.png", "name": "鱼1_tex.png" } }, "startAudio": "http://staging-teach.cdn.ireadabc.com/e587cf79c91d1cc4339540bb04b2aad0_l.mp3", "blockStruct": [{ "pId": "1666687632465177361", "point": { "x": 2, "y": 2 }, "answer": "want" }, { "pId": "1666687646496548891", "point": { "x": 3, "y": 4 }, "answer": "red" }, { "pId": "1666687612725869271", "point": { "x": 1, "y": 1 }, "answer": "fish" }, { "pId": "166668702213640281", "point": { "x": 0, "y": 0 }, "answer": "freedom" }], "blocks": [[{ "val": "f" }, { "val": "r" }, { "val": "e" }, { "val": "e" }, { "val": "d" }, { "val": "o" }, { "val": "m" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "f" }, { "val": "i" }, { "val": "s" }, { "val": "h" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "w" }, { "val": "a" }, { "val": "n" }, { "val": "t" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "r" }, { "val": "e" }, { "val": "d" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }], [{ "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }, { "val": "" }]], "audioName": ""
......
...@@ -18,12 +18,12 @@ ...@@ -18,12 +18,12 @@
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": 0, "offsetX": -1.5,
"offsetY": 0, "offsetY": -1,
"trimX": 0, "trimX": 0,
"trimY": 0, "trimY": 2,
"width": 1864, "width": 1861,
"height": 1731, "height": 1729,
"rawWidth": 1864, "rawWidth": 1864,
"rawHeight": 1731, "rawHeight": 1731,
"borderTop": 0, "borderTop": 0,
......
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