Use your ego for motivation but try to not let it affect your outward personality, difficult to do in a community of strong egos. Sometimes our community even rewards those whose brag about themselves, if they can do so convincingly.
Egos vary dramatically. There must be scientists out there who work purely for the love of science, but I have yet to meet one. And then there are those on the other end of the spectrum. Several years ago, Stephen Wolfram came to Chicago to introduce Mathematica 2 and said "First there was Euclid, then there was Gödel and then there was Mathematica."