mirror of
https://github.com/prosolis/gogobee.git
synced 2026-09-14 10:51:09 +00:00
adventure: name the zone the treasure actually came from
Every Tier 5 treasure line said the Abyssal Maw, whichever zone the drop
came from. A find in Dragon's Lair announced itself as the Maw while
Pete's dispatch, which reads the real location off the fact, named the
Lair. Two tellings of one moment that disagreed about where it happened.
Substitute the location instead, in the room announce and the discovery
DM both. {location_mid} lowercases the leading article so a line reads
"found in the Abyssal Maw" after a preposition; {location} keeps the
display form for sentence-initial and "The {location}" positions, which
the T1-T4 pools already rely on.
This commit is contained in:
@@ -70,6 +70,18 @@ func advClearFlavorHistory() {
|
||||
})
|
||||
}
|
||||
|
||||
// advLocationMidSentence renders a location display name for use after a
|
||||
// preposition: "The Abyssal Maw" becomes "the Abyssal Maw" so a line reads
|
||||
// "found in the Abyssal Maw" rather than "found in The Abyssal Maw".
|
||||
// Templates opt in with {location_mid}; {location} keeps the display form for
|
||||
// sentence-initial and "The {location}" positions.
|
||||
func advLocationMidSentence(name string) string {
|
||||
if strings.HasPrefix(name, "The ") {
|
||||
return "the " + strings.TrimPrefix(name, "The ")
|
||||
}
|
||||
return name
|
||||
}
|
||||
|
||||
// advSubstituteFlavor replaces {var} placeholders in a flavor text string.
|
||||
func advSubstituteFlavor(template string, vars map[string]string) string {
|
||||
pairs := make([]string, 0, len(vars)*2)
|
||||
|
||||
Reference in New Issue
Block a user