Skip to content

Commit

Permalink
remove ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
ksthicke committed May 17, 2024
1 parent dcbbe1f commit 7e7ea3e
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/renderer/engine/driver.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export default class EngineDriver {
*/
constructor (input, output) {
this.events = new EventEmitter()
this.ignore = false
this.ready = false
this.pendingReady = false
this.info = {
Expand Down Expand Up @@ -67,12 +66,6 @@ export default class EngineDriver {
_parseLine (line) {
this.events.emit('line', line)
line = line.trim()
if (this.ignore) {
if (line.startsWith('bestmove')) {
this.ignore = false
}
return
}
switch (line.split(/\s/)[0].trim()) {
case 'uciok':
this.events.emit('initialized')
Expand Down Expand Up @@ -122,6 +115,7 @@ export default class EngineDriver {
break
}
case 'bestmove':
console.log('emit bestmove')
const words = line.split(' ')
const ucimove = words[1]
this.events.emit('bestmove', ucimove)
Expand Down Expand Up @@ -160,7 +154,6 @@ export default class EngineDriver {
case 'quit':
return await this.quit()
case 'stop':
this.ignore = true
this._write(cmd)
break
case 'setoption':
Expand Down

0 comments on commit 7e7ea3e

Please sign in to comment.