Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refugee center adds food you sell/give them to their camp storage #76105

Merged
merged 1 commit into from
Sep 2, 2024

Conversation

RenechCDDA
Copy link
Member

@RenechCDDA RenechCDDA commented Sep 1, 2024

Summary

None

Purpose of change

Further work towards enabling the refugee center storyline.

Describe the solution

Talk function so that food you sell/transfer to Smokes is added to the larder. Right now it's just been added to Smokes, but it's generic and json so it can be added to anyone. Probably most shopkeepers should get this once NPC factions aren't magicking their food out of thin air.

Describe alternatives you've considered

It might be better to make an alternate route to add these items directly to the larder instead of still using zones. Still, using the existing infrastructure isn't a terrible idea, and I think I've guarded responsibly against any possible serious errors (i.e. infinite NPC zones which are never deleted)

While troubleshooting some errors I discovered distribute_items_to_npc_zones(). Maybe I should just hijack that, instead of reinventing the wheel (but that means placing the zones during mapgen, which means old saves are SOL once we turn the food lever on)

Testing

2024-09-01.07-59-25.mp4

Additional context

@github-actions github-actions bot added NPC / Factions NPCs, AI, Speech, Factions, Ownership [C++] Changes (can be) made in C++. Previously named `Code` Player Faction Base / Camp All about the player faction base/camp/site json-styled JSON lint passed, label assigned by github actions labels Sep 1, 2024
@github-actions github-actions bot added <Documentation> Design documents, internal info, guides and help. [JSON] Changes (can be) made in JSON [Markdown] Markdown issues and PRs labels Sep 1, 2024
@RenechCDDA RenechCDDA marked this pull request as ready for review September 1, 2024 12:00
@github-actions github-actions bot added the astyled astyled PR, label is assigned by github actions label Sep 1, 2024
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Sep 1, 2024
@Maleclypse Maleclypse merged commit 050fa50 into CleverRaven:master Sep 2, 2024
22 of 27 checks passed
@Maleclypse
Copy link
Member

So refugee camp uses it's calorie larder now or it needs an amount they gain per day vs the amount they lose so that they are slowly starving to death unless specific things happen like 1. player sells them tons of food every month. 2. The amount they generate per day increases from certain activities like setting up the bakery or tacoma ranch? Eventually with fully maxed tacoma maybe they are now food indepent?

@RenechCDDA
Copy link
Member Author

No they still don't consume from the larder, but things are being added to it. Food can go in, but food is never actually taken out, even when they eat meals 'from it' (the food just appears for free, as before).

@RenechCDDA RenechCDDA deleted the NPC_camps_buy_food branch September 2, 2024 01:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions [C++] Changes (can be) made in C++. Previously named `Code` <Documentation> Design documents, internal info, guides and help. [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions [Markdown] Markdown issues and PRs NPC / Factions NPCs, AI, Speech, Factions, Ownership Player Faction Base / Camp All about the player faction base/camp/site
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants