I recently had surgery on my right foot and my cast is really painful. Is there anything that would help?

Have it replaced. If your surgeon feels the need to keep you in a cast, it has to be reasonably comfortable. A "really painful" cast needs to be removed and replaced.
Cast pain. Yes - get it off and a new one to replace it. See your surgeon asap.