For consistency, it is advisable to have the same settings on all your devices.
On iOS go to Settings > Messages > Send & Receive and check:
Under the "You can be reached by iMessage at", how many addresses are there and which are activated (whit a check to the left).
Under "Start new conversations from" check to see if your phone number is selected, and if it is not, what email address is.
If you have more than one iOS device, check that they are set the same way.
Then go to OS X, and on the Messages app, go to Preferences > Accounts; under iMessage > Settings check that the information coincides with those of your iOS device(s).
If you are sending and receiving from different email addresses or an email on one device and a phone number on another, your recipients will actually have multiple separate conversations with you and when replying to one or another will be sending messages to the device associated with that address.
If the device is offline, you won't receive the message. If all are configured the same way you eliminate this problem.
All the conversations you have with a contact look the same, independent of the address they used to send.
It's not easy to know to which address you're talking to; on iOS you have to tap details, then on the the (i) to the right of the name, and see which of the contact addresses or numbers is highlighted in blue.