Hunger and pregnancy

Everytime you get hunger pangs, is it okay to wait a little before eating or do you have to eat then and there? Not for yourself, but for the baby... Does it affect them?