Ben Affleck has issued a heartfelt tribute to his friend and mentor Robin Williams, thanking his Good Will Hunting costar for "everything."

"Heartbroken. Thanks chief – for your friendship and for what you gave the world. Robin had a ton of love in him. He personally did so much for so many people. He made Matt and my dreams come true," he wrote on Facebook Tuesday.

"What do you owe a guy who does that? Everything," he added. May you find peace my friend. #Robin Williams."

Williams, who died Monday of an apparent suicide at age 63, helped launch the careers of Affleck and Matt Damon, childhood friends who co-wrote the screenplay for the film set in their native Boston.

Williams signed on to play psychotherapist Sean Maguire in the 1997 film, which earned him a Best Supporting Actor Oscar at the Academy Awards.

During his acceptance speech, Williams jokingly thanked his young screenwriters and costars, quipping that he "still want[ed] to see some I.D." from the rising stars, who also earned an Oscar for Best Screenplay.

Affleck joins a slew of stars who have paid tribute to the iconic actor.

For more on Robin Williams's tragic death and his legacy of comic genius, pick up the latest issue of PEOPLE, on newsstands Friday