add a parameter that will be responsible for the number of maximum consecutive offerings that God did not accept. Those. say, after 10 offerings when God did not accept them, he may get angry and give a curse and lower his attitude towards you)) So that players do not try to give out the simplest items. And if God has not accepted 7 times already, then it is better to give him something more worthwhile with a high chance - after all, if the max parameter is exceeded. Unaccepted offerings in a row - God will reduce your reputation.
To do this, you need to store the number of negative attempts at offerings in storage. If God accepted the offering, reset this parameter.
add a parameter that will be responsible for the number of maximum consecutive offerings that God did not accept. Those. say, after 10 offerings when God did not accept them, he may get angry and give a curse and lower his attitude towards you)) So that players do not try to give out the simplest items. And if God has not accepted 7 times already, then it is better to give him something more worthwhile with a high chance - after all, if the max parameter is exceeded. Unaccepted offerings in a row - God will reduce your reputation. To do this, you need to store the number of negative attempts at offerings in storage. If God accepted the offering, reset this parameter.