People in pain, whether physically or psychologically, have to work harder than most people to be pleasant or friendly. Understand that.
Think about yourself in pain, when you stubbed your toe, when you cut your finger, when you got shot or stabbed: was it as easy to be pleasant and happy as it normally is?
Think about when you’re being yelled at, accused, or denigrated: was it easy to smile and respond pleasantly or to do a task happily for that person?
How can you expect someone who’s having a bad day to be pleasant? someone with PTSD? someone with depression? someone with neuropathy? Do you think hospital staff deal with happy people typically?