The Queen would have consulted with her advisors and others and invited someone to form a Government.
No, the Queen would do what she always does, to whit, wait until there was someone who could clearly command a majority in the Commons and then summon them.
Labour Party rules are that if this happens when the party is in government the Cabinet will liase with the NEC and appoint an interim leader until either the next party conference or a leadership contest can be arranged. In an emergency situation this wouldn't take more than a day or two, maybe less depending on how severe things are. The appointed leader would then be summoned by the Queen.
There's nothing, incidentally, that neccesitates that this person be the deputy leader, (Unlike when the party is in opposition, when the deputy leader automatically becomes acting leader on the death of the incumbent, as Margaret Beckett did in 1994 when John Smith died) so Prescott doesn't neccessarily have to get it.