Until a few years ago, chocolates, nuts and fatty foods were considered taboo if you had pimples. That's not the case now. If you wish to check out, run a little experiment yourself. Put this food item off the menu and see if it helps. In case it does, keep it that way.
Some medications worsen pimples.
This should not worry you too much, because the disease condition for which they are prescribed always takes the precedence. In case the flare-ups get out of hand, you should talk to your doctor. Take it easy. Stay off stress. Do regular exercise and keep yourself physically and mentally fit.