fixed some errors with the win conditional