Commit c58b3a1c authored by 李维's avatar 李维

bug fix

parent 31a85359
...@@ -122,7 +122,10 @@ ...@@ -122,7 +122,10 @@
</div> </div>
</div> </div>
</div> </div>
<button *ngIf="item.correct.length>1" style="margin-top: 10px; position: absolute; bottom: 10px; right: 10px;;" nz-button nzType="danger" (click)="deleteChoice(item.correct, choiceIndex)" > <button [disabled]="(item.correct.length + item.incorrect.length)>=30" style="margin-top: 10px; position: absolute; bottom: 10px; right: 100px;" nz-button (click)="copyItem(item.correct, choiceIndex)" >
<span>复制此项</span>
</button>
<button [disabled]="item.correct.length==1" style="margin-top: 10px; position: absolute; bottom: 10px; right: 10px;;" nz-button nzType="danger" (click)="deleteChoice(item.correct, choiceIndex)" >
<span>删除此选项</span> <span>删除此选项</span>
</button> </button>
</div> </div>
...@@ -170,6 +173,9 @@ ...@@ -170,6 +173,9 @@
</div> </div>
</div> </div>
</div> </div>
<button [disabled]="(item.correct.length + item.incorrect.length)>=30" style="margin-top: 10px; position: absolute; bottom: 10px; right: 100px;" nz-button (click)="copyItem(item.incorrect, choiceIndex)" >
<span>复制此项</span>
</button>
<button style="margin-top: 10px; position: absolute; bottom: 10px; right: 10px;;" nz-button nzType="danger" (click)="deleteChoice(item.incorrect, choiceIndex)" > <button style="margin-top: 10px; position: absolute; bottom: 10px; right: 10px;;" nz-button nzType="danger" (click)="deleteChoice(item.incorrect, choiceIndex)" >
<span>删除此选项</span> <span>删除此选项</span>
</button> </button>
......
...@@ -126,6 +126,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -126,6 +126,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
this.save() this.save()
} }
copyItem(items, index) {
let copy = JSON.parse(JSON.stringify(items[index]))
items.push(copy)
this.save()
}
getDefaultPicArr() { getDefaultPicArr() {
let arr = []; let arr = [];
return arr; return arr;
......
...@@ -210,7 +210,7 @@ ...@@ -210,7 +210,7 @@
"array": [ "array": [
0, 0,
0, 0,
342.2532501472093, 497.96460717605225,
0, 0,
0, 0,
0, 0,
...@@ -1889,7 +1889,7 @@ ...@@ -1889,7 +1889,7 @@
"__type__": "TypedArray", "__type__": "TypedArray",
"ctor": "Float64Array", "ctor": "Float64Array",
"array": [ "array": [
620, 590,
280, 280,
0, 0,
0, 0,
...@@ -1958,7 +1958,7 @@ ...@@ -1958,7 +1958,7 @@
"_target": null, "_target": null,
"_alignFlags": 33, "_alignFlags": 33,
"_left": 0, "_left": 0,
"_right": 20, "_right": 50,
"_top": 80, "_top": 80,
"_bottom": 0, "_bottom": 0,
"_verticalCenter": 0, "_verticalCenter": 0,
......
...@@ -101,7 +101,7 @@ export default class GameLogic { ...@@ -101,7 +101,7 @@ export default class GameLogic {
// }}) // }})
node = this.g_cartoon.getNodeByPath(`Canvas/lion`) node = this.g_cartoon.getNodeByPath(`Canvas/lion`)
node.x = cc.winSize.width / 2 - 140 node.x = cc.winSize.width / 2 - 170
node.y = -cc.winSize.height / 2 + 120 node.y = -cc.winSize.height / 2 + 120
this.m_bubblesAll.push({node: node, move: { this.m_bubblesAll.push({node: node, move: {
r: 90, x: node.x, y: node.y, vX: 0, vY: 0, enable: true, fix: true, scale: 1, id: 997, lastId: null r: 90, x: node.x, y: node.y, vX: 0, vY: 0, enable: true, fix: true, scale: 1, id: 997, lastId: null
...@@ -774,6 +774,8 @@ export default class GameLogic { ...@@ -774,6 +774,8 @@ export default class GameLogic {
} }
return return
} }
this.g_cartoon.playAudio("大星");
if (!currentStarIdx) { if (!currentStarIdx) {
currentStarIdx = 0; currentStarIdx = 0;
} }
...@@ -820,6 +822,7 @@ export default class GameLogic { ...@@ -820,6 +822,7 @@ export default class GameLogic {
.to(0.8, { scale: 0 }, { easing: 'quadOut' }) .to(0.8, { scale: 0 }, { easing: 'quadOut' })
.call(() => { .call(() => {
// this.checkGameEnd(); // this.checkGameEnd();
this.g_cartoon.playAudio("题数");
if(callback) { if(callback) {
callback() callback()
} }
......
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