When people feel their resources are scarce, they make reasonable decisions to meet their most important needs, study finds