I'm generous if you like me,
but if you don't like me,
I will become greedyA pirate might hate me,
yet we share a common goal
What am I?
Edit: This one was probably a little too broad, with 13 answers.
The intended answer is probably not as good as the answer I currently accepted.