Planning ahead: eliciting intentions and beliefs in a public goods game