Commit 3c232eb1 authored by 李维's avatar 李维

dev commit

parent 37e3b3c8
import {Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef} from '@angular/core'; import {Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef} from '@angular/core';
const defaultData = { const defaultData: any = {
version: "1.1", version: "1.1",
bgmusic: "", bgmusic: "",
dataArray:[ dataArray:[]
{
audio_url:"sm-choice-timeup-3",
options: [
{type:"Text", image_url:"default-image", text:"Demo_1", audio_url:"", isCorrect:true},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:false},
{type:"Text", image_url:"default-image", text:"Demo_1", audio_url:"", isCorrect:false},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:false}
]
},
{
audio_url:"sm-choice-timeup-3",
options: [
{type:"Text", image_url:"default-image", text:"Demo_2", audio_url:"", isCorrect:false},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:true},
{type:"Text", image_url:"default-image", text:"Demo_2", audio_url:"", isCorrect:false},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:false}
]
},
{
audio_url:"sm-choice-timeup-3",
options: [
{type:"Text", image_url:"default-image", text:"Demo_3", audio_url:"", isCorrect:false},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:false},
{type:"Text", image_url:"default-image", text:"Demo_3", audio_url:"", isCorrect:false},
{type:"Image", image_url:"default-image", text:"", audio_url:"", isCorrect:true}
]
},
]
} }
@Component({ @Component({
...@@ -43,19 +15,9 @@ const defaultData = { ...@@ -43,19 +15,9 @@ const defaultData = {
export class FormComponent implements OnInit, OnChanges, OnDestroy { export class FormComponent implements OnInit, OnChanges, OnDestroy {
_item: any; _item: any;
contentObj = { contentObj: any = {
bgMusic:String, bgMusic:String,
dataArray:[ dataArray:[]
{
audio_url: String,
options: [
{type:String, image_url:String, text:String, audio_url:String, isCorrect:Boolean},
{type:String, image_url:String, text:String, audio_url:String, isCorrect:Boolean},
{type:String, image_url:String, text:String, audio_url:String, isCorrect:Boolean},
{type:String, image_url:String, text:String, audio_url:String, isCorrect:Boolean}
]
}
]
} }
hotZoneItemArr: Array<Object> = []; hotZoneItemArr: Array<Object> = [];
bgItem: Object; bgItem: Object;
......
...@@ -229,6 +229,7 @@ export class PlayComponent implements OnInit, OnDestroy { ...@@ -229,6 +229,7 @@ export class PlayComponent implements OnInit, OnDestroy {
} }
cleanGameVar(){ cleanGameVar(){
this.stopEndPatal()
this.m_currentQuestion = 0; this.m_currentQuestion = 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