Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.
Sign upFollower / Faction camp summary menu and migrate to overmap #28498
Conversation
Night-Pryanik
reviewed
Mar 4, 2019
src/basecamp.cpp Outdated
Night-Pryanik
reviewed
Mar 4, 2019
|
|
Night-Pryanik
reviewed
Mar 4, 2019
src/game.cpp Outdated
mlangsdorf
reviewed
Mar 4, 2019
|
It looks like a good start, but you're complicating the tracking of the omt_pos quite a bit and I don't get the two stage tracking of camps in the overmap. |
src/basecamp.cpp Outdated
src/faction.cpp Outdated
src/faction_camp.cpp Outdated
src/faction_camp.cpp Outdated
src/overmapbuffer.h Outdated
src/overmapbuffer.h Outdated
src/overmapbuffer.h Outdated
src/overmapbuffer.cpp Outdated
mlangsdorf
added
NPC / Factions
Info / User Interface
[C++]
Player Faction Base / Camp
0.D Freeze
labels
Mar 4, 2019
davidpwbrown
force-pushed the
davidpwbrown:factionmenu
branch
from
bfcb9d2
to
20a733f
Mar 5, 2019
AMurkin
reviewed
Mar 5, 2019
|
No need to include trailing spaces. |
src/basecamp.cpp Outdated
src/basecamp.cpp Outdated
Night-Pryanik
reviewed
Mar 6, 2019
src/character.cpp Outdated
This comment has been minimized.
This comment has been minimized.
|
Consider adding a [WIP] tag if you're actively working on the PR. |
This comment has been minimized.
This comment has been minimized.
Not currently actively adding stuff to it, the recent addition |
ifreund
removed
the
0.D Freeze
label
Mar 8, 2019
davidpwbrown
force-pushed the
davidpwbrown:factionmenu
branch
2 times, most recently
from
83f3a12
to
ab85e50
Mar 9, 2019
davidpwbrown
changed the base branch from
development
to
master
Mar 9, 2019
davidpwbrown
force-pushed the
davidpwbrown:factionmenu
branch
5 times, most recently
from
4740c92
to
9e8572d
Mar 9, 2019
mlangsdorf
reviewed
Mar 13, 2019
|
Looks pretty good. The only thing I want to change is basecamp::pos should go away. Change it to pos_deprecated, remove it from the savegame_json. Now that camps are going to be tracked via the overmap buffer, they should have an omt_pos and a board_pos. |
davidpwbrown
added some commits
Feb 23, 2019
davidpwbrown
force-pushed the
davidpwbrown:factionmenu
branch
from
5e04721
to
78fd364
Mar 13, 2019
kevingranade
merged commit 46e2ec7
into
CleverRaven:master
Mar 14, 2019
This comment has been minimized.
This comment has been minimized.
|
This pull request has been mentioned on Cataclysm: Dark Days Ahead. There might be relevant details there: https://discourse.cataclysmdda.org/t/new-menu-functionality-for-npcs-and-factions/19282/1 |
davidpwbrown commentedMar 4, 2019
•
edited
Summary
SUMMARY: Features "Follower / Faction camp summary menu and migrate to overmap"Purpose of change
fixes #24360
Created a menu that uses the
#key ( that the old faction menu used )In this menu, a list of your followers will be on one tab, with a summary of their information.
On another tab, a list of your faction camps and a summary of their info.
On another tab, a list of other factions ( these don't really exist yet )
Describe the solution
There is a new list being tracked for NPC followers.
follower_idsused with the following functions in game.cpp/h
Validate is called on load to ensure that existing NPC followers are added to this new list from older saves.
Other NPC functions would determine if NPCs were friendly or were guarding,but only in reality bubble, there was no "master list" of followers you had obtained, even if they were miles away.
This remedies that. ( and opens the door to future remote contact via radio and so on )
For the faction camps - there was some work required to move some of their information to the overmap buffer.
You can now name the camp when creating it.
There is now an overmap_ui label like the city labels, but for camps.
The camp summary will show what is required for the next upgrade and total calories stored.
The validation for older saves with existing camps was tricky, what I've done for the moment is when the menu is opened nearby an existing camp, it adds it to the list straight away.
Players with many existing camps in a save wont see them in the menu until they visit each one and "check in" by opening the menu near them.
Various other things have been done that I hope are self-evident in the code to support the goals of this PR I had to change a lot of little things.
The code is obviously very ugly, and I expect a brutal review, this was a bit of a stretch for me.
Describe alternatives you've considered
This will be improved once #28481 is merged, that will have descriptive map of strings for the mission name.
Will want to improve functionality of this in steps.
Additional context
( that is just the default name )