|
@@ -250,7 +250,6 @@ export default {
|
|
})
|
|
})
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
Toast.clear()
|
|
Toast.clear()
|
|
- $this.mode_item = {}
|
|
|
|
$this.to_report()
|
|
$this.to_report()
|
|
}, 800)
|
|
}, 800)
|
|
},
|
|
},
|
|
@@ -284,27 +283,8 @@ export default {
|
|
|
|
|
|
//连接玩具
|
|
//连接玩具
|
|
if ($data) {
|
|
if ($data) {
|
|
- console.log($data)
|
|
|
|
- $this.att_list.push($data['att'])
|
|
|
|
- $this.med_list.push($data['med'])
|
|
|
|
- $this.delta_list.push(Math.round($data['delta'] / 10000))
|
|
|
|
- $this.alpha_list.push(Math.round($data['alpha'] / 1000000))
|
|
|
|
- $this.theta_list.push(Math.round($data['theta'] / 10000))
|
|
|
|
- $this.beta_list.push(Math.round($data['beta']) / 1000000)
|
|
|
|
-
|
|
|
|
- if ($this.att_list.length > 50) {
|
|
|
|
- $this.att_list.shift()
|
|
|
|
- $this.med_list.shift()
|
|
|
|
- $this.delta_list.shift()
|
|
|
|
- $this.alpha_list.shift()
|
|
|
|
- $this.theta_list.shift()
|
|
|
|
- $this.beta_list.shift()
|
|
|
|
- }
|
|
|
|
- console.log("专注度列表:", $this.att_list)
|
|
|
|
- console.log("放松度列表:", $this.med_list)
|
|
|
|
|
|
+ $this.do_datas($data)
|
|
|
|
|
|
- $this.attList.push($data['att'])
|
|
|
|
- $this.medList.push($data['med'])
|
|
|
|
|
|
|
|
//通过专注放松度 画图
|
|
//通过专注放松度 画图
|
|
let $option = util.getLineOption($this.att_list, $this.med_list)
|
|
let $option = util.getLineOption($this.att_list, $this.med_list)
|
|
@@ -407,7 +387,26 @@ export default {
|
|
},
|
|
},
|
|
// 处理游戏中数据的方法
|
|
// 处理游戏中数据的方法
|
|
do_datas($data) {
|
|
do_datas($data) {
|
|
|
|
+ $this.att_list.push($data['att'])
|
|
|
|
+ $this.med_list.push($data['med'])
|
|
|
|
+ $this.delta_list.push(Math.round($data['delta'] / 10000))
|
|
|
|
+ $this.alpha_list.push(Math.round($data['alpha'] / 1000000))
|
|
|
|
+ $this.theta_list.push(Math.round($data['theta'] / 10000))
|
|
|
|
+ $this.beta_list.push(Math.round($data['beta']) / 1000000)
|
|
|
|
+
|
|
|
|
+ if ($this.att_list.length > 50) {
|
|
|
|
+ $this.att_list.shift()
|
|
|
|
+ $this.med_list.shift()
|
|
|
|
+ $this.delta_list.shift()
|
|
|
|
+ $this.alpha_list.shift()
|
|
|
|
+ $this.theta_list.shift()
|
|
|
|
+ $this.beta_list.shift()
|
|
|
|
+ }
|
|
|
|
+ console.log("专注度列表:", $this.att_list)
|
|
|
|
+ console.log("放松度列表:", $this.med_list)
|
|
|
|
|
|
|
|
+ $this.attList.push($data['att'])
|
|
|
|
+ $this.medList.push($data['med'])
|
|
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -450,6 +449,7 @@ export default {
|
|
let $play_time = $this.play_time = game_store.getters.getPlayTime()
|
|
let $play_time = $this.play_time = game_store.getters.getPlayTime()
|
|
//已经完了多长时间
|
|
//已经完了多长时间
|
|
let $played_time = $this.played_time = game_store.getters.getPlayedTime() ? game_store.getters.getPlayedTime() : 0
|
|
let $played_time = $this.played_time = game_store.getters.getPlayedTime() ? game_store.getters.getPlayedTime() : 0
|
|
|
|
+ $this.mode_item = {}
|
|
$this.mode_item = mode_list[$this.mode - 1]
|
|
$this.mode_item = mode_list[$this.mode - 1]
|
|
let $origin_time = $play_time * 1000
|
|
let $origin_time = $play_time * 1000
|
|
$this.mode_item['time'] = $origin_time - ($played_time * 1000)
|
|
$this.mode_item['time'] = $origin_time - ($played_time * 1000)
|