CleverRaven / Cataclysm-DDA

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

Common crafting queue for Characters #74494

Open Brambor opened 2 months ago

Brambor commented 2 months ago

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

I have 3 NPCs, and we all will be doing tempered steel wires for a while (I guess 48 h crafting time each of us). I have to set recipes for each of them individually. I prefer doing it without batches, so it is more recipes.

Currently, I set a queue (already implemented) for each of them. I prepared the crafts with 0% competition. It is a bit confusing to see which are already taken, but waiting a turn fixes that.

Sometimes I come back with tainted skins that need priority, so I set everyone's queue to cure skin (in batches of 50) and then pick up the wire again.

Solution you would like.

I want a common crafting queue. A group of Characters registered in it will all look at the queue and take the first recipe they can craft. A Character finishes once they go through the entire queue and find nothing they can craft. The others carry on.

When some more urgent recipes appear, I simply add them to the top and tell everyone "Retake from queue". Then every one of them will stop their craft, preferably put it back into the queue (at the right index) and try to make the cured skin from tainted skin that just arrived. Once finished, they will go back to tempered steel wire.

Optimally, but that is a different issue. Let them sleep, wake up and get back to it, not stand next to my bed waiting for me to wake up and tell them "Carry on.".

Describe alternatives you have considered.

No response

Additional context

No response

github-actions[bot] commented 1 month ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not bump or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered.