As your CFI said, you did great. You had the "airmanshipness" (if that is even a word) to understand the use of flaps and gliding awareness. Lots of pilots don't get it with the flaps and you knew and felt that dispite being an extra sustentation device, also will get you down sooner.
As for the emergency, you won't have one on every flight. Heck, it's a very rare situation. But that shows how important training is and how important it is to check the airplane on the ground and when in-flight. Checklists are your friends.
Regarding your career, this shouldn't bring you down at all. If you like it and feel passion for it, keep going. Of course this will put some doubts in your skull but be patient, talk to your CFI, he will come up with good advices and will tell you about his own experiences. Also, get in touch with seasoned pilots in your area, drink a beer with them (remember from bottle to throttle, eight hours), just hear their experiences ( don't need to ask, thy will come with them while having a chat, it's the law of all pilots lol). This is the best way to learn IMHO, not only about stressing situations but also about normal procedures and comical stories.
I'm very sorry of your dad's friend. It is a shame when a fellow pilot falls, but he gave his last advice with his crash and you already know it. Remember, learn for other pilot's mistakes or stressing situations. You'll make a good use of those experiences.
But I want to make this straight, if you really like flying, and you have that strange feeling in your belly everytime you take off, and if someone ask you WHY you like so much flying and you do NOT know how to answer, then you are surely headed to the sky. I imagine myself working in a factory or in an office from 9 to 5...and I tell you, I will chose the sky everytime, even if it's low pay. And I had my share of emergencies and always try to learn from them, if you do it right you will be ok.
Best landings!
Santiago