Depending on the situation (i.e. surgery, ER visit etc) pain meds are always done on a pain scale. I'd start with tylenol, ibuprofen or naproxen every 4 to 6 hours.
If that doesnt help after 4 hours go to percocet every 4 to 6 hours (or however it was prescribed).
Then for severe pain go with dilaudid (not sure if they prescribed 2mg, 4mg etc) but never take percocet and dilaudid together (min 4 hrs between those two meds). If you're going with percocet keep in mind to not go over 3,000mg of tylenol. (In the past the limit has been 4,000mg, but some literature now states 3,000mg just to be safe).
Take any pain med with food and prepare for some constipation and possibly nausea, so have some dramamine and colace/miralax on hand just in case.