horizontal and vertical win logic complete