Trousers (pants) are very popular: most people own a pair.
The person who first comes up with an idea (these days) usually gets a patent on the idea, to allow them time to recoup their investment in developing the idea into a product.
If you have a patent on something that means no-one else can make it without paying you for the rights to do so.
If the person who invented trousers had a patent on them, given their popularity, they would have an exclusive and very lucrative business.
So "the guy who invented pants" would have a lot of money.
Deadpool is saying the original film made a lot of money.
It's hyperbole, if for no other reason than trousers have been around longer than recorded history, so the person who "invented" trousers wouldn't have made any money.