Law and Doflamingo | One Piece Amino
Luffy seems to have developed a positive relationship with Trafalgar Law defeating Donquixote Doflamingo outright when the plan was leaving him for When Luffy agrees to help the Mink tribe and the Kozuki clan take down Kaido, Law. When Doflamingo was about to attack Nami, Chopper and Brook, Law showed Because of his willingness to help Luffy during his time of need, Hancock put. Law has also performed the gesture to Donquixote Doflamingo to display his Due to his compassion, Law would even help his future rivals, which is seen.
Such occasions include when Ivankov asked if Law was a friend of Luffy, to which he replied no, and even offered to make an excuse so as to make Ivankov feel better about him saving Luffy. Soon after, a wounded Jinbe went to thank him, only for Law to reply that Jinbe would die if he did not sleep. Later when Jinbe asked what would happen to Luffy if he was allowed to run rampant while still wounded, Law replied that the outcome was simple: Luffy's wounds would open up and he would die.
He also has no qualms explaining to other people on how he accomplished nullifying their attacks with his abilities, and before that, even stated to Tashigi that weaklings do not get the right to choose the manner in which they die, a statement that he took from Doflamingo.
Plagued by the Amber Lead Disease, he was condemned to die in three years, but he has overcomed it.
Donquixote Doflamingo/Personality and Relationships | One Piece Wiki | FANDOM powered by Wikia
The lost boy blinded by anger and despair to follow the Mad Pirate is no more! There is nothing he can learn from a monster hungering for destruction like you!!
Despite Law's terse and rather cruel demeanor towards others, Law still retains strong compassion and kindness, which he originally had as a boy, while regaining them due to Rosinante's influence, such as how he decided to help the Straw Hats find a cure for the children affected by Caesar's drugseven though he originally did not want to have anything to do with them, and later voluntarily curing the children of their deadly poisoning and addiction for NHC10 in a similar fashion to how Rosinate saved him from dying of Amber Lead Syndrome.
He also warned the Straw Hats to be careful of Caesar's abilityand told those who did not have the ability to engage Logias to stay away. Another aspect of his kindness is that he despised wickedness, as he was disgusted when he heard that Caesar subjected the kids on Punk Hazard to addictive drugs.
During his discussion with Luffy about their future battle against Kaido, he expressed strong concern for the Mink Tribe as he feared that their presence in Zou would cause the Beast Pirates to ruthlessly destroy the Mokomo Dukedom and its mink citizens, who were already brutally devastated by Jack. Many minks were even tearfully moved by Law's kindness. He is also honorable, as he refuses to take credit that is due to others, as seen when he replied to Jean Bart that his thanks is deserved by Luffy when the former slave offered his gratitude to the pirate captain.
Another example would be that when his crew believed that he defeated Doflamingo, he corrected them by saying that Luffy was the one who took down Doflamingo on Dressrosa. The tide will bring those of unmatched power and the New Age will begin! He also has a habit of sitting in strange positions, like on the back of chairs, on tables,  on barrels,  and even on a pile of bodies in the middle of a war zone  and on top of a wall.
Prior to the timeskip, Doflamingo has a complete and utter lack of fear and doubt, going as far as to rob the World Nobles of their tributes, so he could blackmail the government. Only on rare occasions does he let go of his trademark smile, such as frowning in annoyance at being summoned to Mariejoissurprised when Laffitte arrived unannounced and unnoticed until he made his presence known,  and when Little Oars Jr.
However, these moments were short-lived, as Doflamingo would usually just grin again. Doflamingo learned pain and hunger for the first time in his life and such events have left him suffering from post-traumatic stress disorder even up to age 25, causing him to have nightmares of the torture and waking up in fear and drenched in sweat. To cope with it, he drank copious amounts of alcohol.
Two years after the Battle of Marinefordhe would continue to maintain his confident smile while everything was under control.
Forum:Trafalgar Law and Donquixote Doflamingo | One Piece Wiki | FANDOM powered by Wikia
However, when Law defeated Vergo and threatened the SAD supply, and even mocked him for his lack of fear and doubt as signs of overconfidence, Doflamingo finally expressed true anger and worry. Upon finally losing control over Dressrosa, Doflamingo succumbed to fear, despair, and fury.
While discussing with Law about how his father abandoned the status of the Celestial Dragons and how he was setback from acquiring eternal life, Doflamingo became more and more frustrated as he relived the past. Due to his belief in this "New Age", Doflamingo seems to lose interest in other things easily, as seen with his leadership of the Bellamy Pirates  and the ownership of the Human Auctioning House.
Relationship between Monkey D. Luffy and Trafalgar D. Law
During the battle of Marineford, all of Doflamingo's confrontations had been for the sake of personal amusement, hinting at a sadistic side, such as when he is seen laughing joyfully after severing Oars Jr. He also believes in the existence of an inherent cruelty in all human beings regardless of personality that is brought by the excitement of seeing blood and death.
Doflamingo has proven himself to be an underhanded businessman, as he has no intention of parting with certain goods despite placing them up for sell or prize, such as the Mera Mera no Mi and Goru Goru no Miand would be furious should these goods fall into outside hands.
He does not have much respect for people he considers weak, and desires to only associate himself with the strong, being quick to cast aside the weak. Though he could not care less for weaker people, he does seem to have some interest in improving them if possible, as he will point out their flaws and occasionally give them second chances to please him. Despite his apathy for the weak, he often seems to make alliances with promising rookies.
He adopted Trafalgar Law, Buffalo, and Baby 5 into his crew and apparently did it very early on their journeys, and treated Law and Baby 5 as though they were his younger siblings;  It is extremely difficult to join his crew, as most people, especially children, were chased off.