major game logics fixes