From cf5039554e583aabbaa53ec493480051e078d3bf Mon Sep 17 00:00:00 2001 From: Nat Quayle Nelson Date: Wed, 27 Aug 2025 16:15:39 -0500 Subject: [PATCH] townperson picker show name if has one --- src/scenedit/scen.keydlgs.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/scenedit/scen.keydlgs.cpp b/src/scenedit/scen.keydlgs.cpp index 7137b912..005d4e1a 100644 --- a/src/scenedit/scen.keydlgs.cpp +++ b/src/scenedit/scen.keydlgs.cpp @@ -1586,7 +1586,12 @@ static bool edit_spec_enc_value(cDialog& me, std::string item_hit, node_stack_t& }else{ const cMonster& monst = scenario.scen_monsters[person.number]; pics.push_back(monst.picture_num); - labels.push_back(fmt::format("{} at {}", monst.m_name, boost::lexical_cast(person.start_loc))); + std::string name = monst.m_name; + if(person.personality >= 0){ + int pers_town_num = person.personality / 10; + name = scenario.towns[pers_town_num]->talking.people[person.personality % 10].title; + } + labels.push_back(fmt::format("{} at {}", name, boost::lexical_cast(person.start_loc))); } } size_t sel = val < 0 ? town->creatures.size() + val : val;