CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.25k stars 4.11k forks source link

Unhardcode `water_source` to allow arbitrary liquid fields #75786

Open NetSysFire opened 3 weeks ago

NetSysFire commented 3 weeks ago

Is your feature request related to a problem? Please describe.

Right now only sewage, liquid cacao(?!), water and salt water have working liquid sources because they are hardcoded:

https://github.com/CleverRaven/Cataclysm-DDA/blob/711754cea17d523ac5b05e2b0882a39e297b3dea/src/map.cpp#L5772-L5795

Solution you would like.

Rename water_source into liquid_source. Do mind the compatibility as some things do use water_source and must be adapted for the new thing. Make it an examine actor and allow an argument to specify the liquid item to be dispensed. Also handle finite liquid sources appropriately.

Describe alternatives you have considered.

No response

Additional context

No response

Standing-Storm commented 3 weeks ago

This is what's stopping me from letting people take the black liquid from the MoM map special pools