Убран компонент Метрики

This commit is contained in:
2019-08-30 12:19:54 +03:00
parent 62ce5a4591
commit 59c040a52c
3 changed files with 0 additions and 41 deletions

View File

@ -40,9 +40,7 @@
<script>
import Predictor from './Predictor';
import Metrika from '../common/metrika';
const PREDICTOR_GAME_END_GOAL = 'PREDICTOR_GAME_END';
const MAX_SCORE = 50;
function make_predictor() {
@ -92,18 +90,6 @@ export default {
}
/* const prediction = */ this.predictor.pass(value);
const score = this.predictor.score;
const absScore = Math.abs(score);
// Game over
if (absScore === MAX_SCORE) {
Metrika.goal(PREDICTOR_GAME_END_GOAL, {
winner: score > 0 ? 'human' : 'robot',
step_count: this.predictor.stepCount(),
score: score,
});
}
},
restart() {
this.predictor = make_predictor();