quickspot ( ) { if ( this . blockFrequent) return this . blockFrequent = true let evt = window. event || evt; let e = document. querySelector ( "#img" ) let a = 680 / e. clientWidth let b = 400 / e. clientHeight let d = evt. offsetX; let c = evt. offsetY; console. log ( a, b) let aaX = 0 let aaY = 0 let rangX = 100 / a let rangY = 100 / b let zhi= 0 for ( let i = 0 ; i < this . different_point. length; i++ ) { aaX = Number ( this . different_point[ i] . x / a) aaY = Number ( this . different_point[ i] . y / b) if ( ( aaX - rangX < d && d < aaX + rangX) && ( aaY - rangY < c && c < aaY + rangY) ) { this . spotStatus = 2 ; zhi= i break } else { this . spotStatus = 1 } } ; if ( this . spotStatus == 2 ) { let box = document. getElementById ( "box" ) ; let divparent = document. createElement ( 'div' ) ; divparent. style. position = 'absolute' divparent. style. zIndex = 10 divparent. style. top = this . different_point[ zhi] . y / 40 - 2.5 + 'rem' divparent. style. left = this . different_point[ zhi] . x / 40 - 2.5 + 'rem' divparent. style. width = '5rem' divparent. style. height = '5rem' box. appendChild ( divparent) let div = document. createElement ( "img" ) ; div. src = this . tick; div. style. zIndex = 10 div. style. width = '3.5rem' div. style. height = '3.5rem' div. style. position = 'absolute' divparent. appendChild ( div) ; div. style. top = '0.75rem' div. style. left = '0.75rem' let box1 = document. getElementById ( "box1" ) ; let divparent1 = document. createElement ( 'div' ) ; divparent1. style. position = 'absolute' divparent1. style. zIndex = 10 divparent1. style. top = this . different_point[ zhi] . y / 40 - 2.5 + 'rem' divparent1. style. left = this . different_point[ zhi] . x / 40 - 2.5 + 'rem' divparent1. style. width = '5rem' divparent1. style. height = '5rem' box1. appendChild ( divparent1) let div1 = document. createElement ( "img" ) ; div1. src = this . tick; div1. style. zIndex = 10 div1. style. width = '3.5rem' div1. style. height = '3.5rem' div1. style. position = 'absolute' divparent1. appendChild ( div1) ; div1. style. top = '0.75rem' div1. style. left = '0.75rem' this . lightUp++ this . difficult_level-- this . blockFrequent = false if ( this . lightUp == this . different_point. length) { this . isShowCount = false this . limit_time = 1 this . isShowBtn = true this . gameState = 2 this . FindDiffTaskStatus ( this . gameState) } } else { this . isShowFork = true setTimeout ( ( ) => { this . isShowFork = false this . blockFrequent = false } , 500 ) ; if ( this . limit_time > 10 ) { this . limit_time = this . limit_time - 10 } else { this . isShowFork = false this . isShowCount = false this . limit_time = 1 if ( this . lightUp == this . different_point. length) { this . isShowBtn = true this . gameState = 2 this . FindDiffTaskStatus ( 2 ) } else { this . isShowBtn = true this . gameState = 3 this . FindDiffTaskStatus ( 1 ) } } } console. log ( d, c) } ,