You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
func (a*AI) Search() grid.Direction {
var (
bestDire=grid.NONEbestScorefloat64
)
// depth value depending on grid's max value.dept:=a.deptSelect()
for_, dire:=rangedirections {
newGrid:=a.Grid.Clone()
ifnewGrid.Move(dire) {. **//It No Caculate score generated by Move.**// Could move.// Active is false represent computer should fill number to grid now.newAI:=&AI{Grid: newGrid, Active: false}
ifnewScore:=newAI.expectSearch(dept); newScore>bestScore {
bestDire=direbestScore=newScore
}
}
}
returnbestDire
}
// 这种情况会返回None结果,其实也差不多快要结束了。
AI.go
The text was updated successfully, but these errors were encountered: