Since the events of the play occur after Hamlet's father has died, we do not have direct evidence about what sort of person he was at that time. There is, however, some indirect evidence.
First, we know that Hamlet was a student at university. Thus we have a sense that he was intelligent and educated. He apparently had several friends and thus we can imagine that he was sociable and pleasant. We know from Act 2, Scene 2 that Hamlet's personality has been changed by his father's death and mother's marriage. Claudius states:
Something have you heardOf Hamlet’s “transformation”—so call itSince nor th' exterior nor the inward manResembles that it was....
In the William Shakespeare play, Hamlet, the reader learns much about Hamlet’s character. Hamlet did not become king when his father died. The regency in most countries passes the crown down to the oldest son. This was not done in Hamlet’s case. Clearly, he had been away studying, but as a young man we must wonder why he was not heir to the throne. He was easily persuaded to abandon his studies at the request of Claudius. He was quick to judge Gertrude for remarrying so quickly, when he would have known in that day and age, women had few rights. He was hesitant to avenge his father’s death, and every time he came to a decision about this, he second guessed himself. He seemed weak and ineffectual, and much of the tragedy in this play stemmed from his poor decision making. Oedipus seemed, at times, to be unwillingly and unknowingly caught up in the actions of others. Therefore, Hamlet is not as heroic as Oedipus.
Enotes has some great resources.