1) I have done a lot of bad things to them, so now I have to make amends to them.

2) I have been depraved for a while, drinking, smoking ect, so now I have to make amends.

it seems to me that " to make amends" has two meanings: first to make up for/ to compensate eg in the #1

and Second to bettter oneselft and turn into a new leaf like # 2 ( try to become a good person).

What is the real meaning of " to make amends"? please give some example sentences.

Thank alot for your time and efforts.
'To make up for/ to compensate'. 'To better oneself' is just one way to accomplish this. There are plenty of examples available if you google the phrase.
The usual phrase in the meaning of "to repay, or compensate for) is:
make amends for (what I did wrong) with (the party that was hurt)
I must make amends for my spreading lies with my friend.
Although "with" is more frequent, sometimes "to" is used.