We had a basement bedroom flood on new years in the exact same way
Came through the bedroom window after pooling. We got a sump pump to get it out of the window well and then extended the downspout away from the house.
We’ve since done some landscaping work, but extending the downspout was a great temporary bandaid