A stalemate occurs when a player has no legal move. In your game, the pawn could not move because it was stuck. The King could not move because any square open to him would put him in check - an illegal move. Thus, since your opponent could not legally make a move and the game ended in stalemate, which is considered a draw. You could have avoided this by not promoting to a queen right away. If you had wasted a move (say you moved your c-pawn instead of promoting your d-pawn), then the King would have had to move back to the 8th rank. Then, when you promoted your pawn, it would not be a draw because the King would have somewhere to go. Check the moves list below to see the winning variation.
im bambuzzled, i gets this opponant king into a corner, i us my pawn to move up the board to change it to a queen, wile hes going back and fro in the corner.when i gets my queen, thats it hes done for, then this message comes up drawn game stalemate. couldnt believe it he only had a pawn stuck in the far off corner with my pawn blocking it. i spent hours getting him, i had 5 pawns,bishop,knight, all on the board , still cant believe it check it out if you want, muddler54= baz30 someone tell me whats going on cheers mick