Skip to content
Commit e7e05ad4 authored by Jaime Torres Amate's avatar Jaime Torres Amate
Browse files

always return a valid move to avoid the game freeze

When Controller::finalizeShot receives an Illegal move, it just does
not know what to do next, and the game freeze.
This patch implements the last option to return a valid move, searching
for a free cell one by one, therefore it becomes impossible to return
an Illegal move because or the computer wins or the opponen wins before
the board is empty of free cells.

Another solution for dummyAI could be to implement a list of
free cells and choose on them randomly.

BUG: 246382
FIXED-IN: KDE/4.12
REVIEW: 113854
parent 606fa13e
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment