diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-31 17:44:23 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-05-31 17:44:23 +0000 |
commit | 8d620e1509fe04db564a5f46e32046d0ed61d714 (patch) | |
tree | dafee486172262a4aeb69878e0f290df62cdad69 /crawl-ref/settings | |
parent | 84dcd8dbdcbdbbcb08794426c634dce42d98e935 (diff) | |
download | crawl-ref-8d620e1509fe04db564a5f46e32046d0ed61d714.tar.gz crawl-ref-8d620e1509fe04db564a5f46e32046d0ed61d714.zip |
Modify menu_colour_item_prefix() to also handle stuff like contaminated
or poisonous chunks.
Throw out all those special cases in food_colouring.txt and
replace them with logic. I sure hope I got all special cases, but if
not they should be easy enough to add. The functions are currently all
in food.cc but they could easily be moved over to clua.cc and adapted
accordingly if needed.
New prefix shortcuts:
* inedible (full herbi/carnivorousness, rotten food for non-saprovores)
* preferred (respects foovorousness, rotten for ghouls, royal jelly for
everyone)
* poisonous
* contaminated
* mutagenic
* rot-inducing
(I also added one-liners to the descriptions of chunks of those types.)
The changes apply to all menu types, but they don't handle messages.
This is problematic in that you'd have to check the pickup menu to see
which corpses are worth butchering, but I'm still against keeping all
those manual checks for (currently) poisonous/mutagenic/... corpses,
esp. as information like this can date quickly.
Instead the butchering interface should be improved to somehow handle
that, possibly by overriding the prompt colour with the specified
colour if necessary. I don't think there are any other cases where
this is important.
Also add a prefix for equipped items and artefacts, so they can be
easily checked for as well. I really think the identified/unidentified
prefix should become default (and the option removed) - this allows
for easy differentiation between identified and non-identified
artefacts. The "known" prefix (for known wand charges or enchantments)
is a bit less interesting but wouldn't hurt any (I think).
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5373 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/settings')
-rw-r--r-- | crawl-ref/settings/food_colouring.txt | 124 | ||||
-rw-r--r-- | crawl-ref/settings/init.txt | 2 | ||||
-rw-r--r-- | crawl-ref/settings/menu_colours.txt | 55 |
3 files changed, 23 insertions, 158 deletions
diff --git a/crawl-ref/settings/food_colouring.txt b/crawl-ref/settings/food_colouring.txt index edf8ec99a9..ebdea7fd35 100644 --- a/crawl-ref/settings/food_colouring.txt +++ b/crawl-ref/settings/food_colouring.txt @@ -7,124 +7,26 @@ inv := menu_colour # Spriggans don't care for corpses and chunks. # -: if you.race() == "Spriggan" then -msg = darkgrey:.*corpse -msg = darkgrey:.*chunk -inv = darkgrey:.*chunks? of -inv = darkgrey:.*corpse -inv = yellow:.*food.*(bread ration|snozzcumber|slice of pizza) -inv = yellow:.*food.*(orange|banana|lemon|pear|apple|apricot|choko) -inv = yellow:.*food.*(rambutan|lychee|strawberry|grape|sultana) -: end -# Mummies don't care for food at all. -# -: if you.race() == "Mummy" then -msg = darkgrey:.*corpse -msg = darkgrey:.*chunk -inv = darkgrey:.*food.* -: end +msg = darkgrey:.*inedible.* +inv = darkgrey:.*inedible.* -# Rotten chunks eaters: Ghouls, Ogres, Kobolds, Trolls, Hill Orcs -# -: if you.race() == "Ghoul" then -msg = yellow:rot.*chunks? of -msg = yellow:rot.*corpse -inv = yellow:.*rot.*chunks? of -< elseif you.race() == "Ogre" or - you.race() == "Kobold" or - you.race() == "Troll" or - you.race() == "Hill Orc" then > -# color rotten chunks as normal chunks -: else -msg = lightred:rot.*chunks? of -msg = lightred:rot.*corpse -inv = lightred:.*rot.*chunks? of -inv = lightred:.*rot.*corpse -autopickup_exceptions = >rot.*chunks? of -: end +msg = yellow:.*preferred.* +inv = yellow:.*preferred.* -# Kobolds don't want fruits but meat. -# -: if you.race() == "Kobold" then -inv = darkgrey:.*food.*(bread ration|snozzcumber|slice of pizza) -inv = darkgrey:.*food.*(orange|banana|lemon|pear|apple|apricot) -inv = darkgrey:.*food.*(rambutan|lychee|strawberry|grape|sultana) -inv = yellow:.*chunks? of -: end - -# Undead corpses/chunks -# -msg = lightred:chunks? of.*(ghoul|necrophage|death drake) -msg = lightred:(ghoul | necrophage|death drake).*corpse -inv = lightred:.*chunks? of.*(ghoul|necrophage|death drake) +# Corpses of undead (necrophages etc.) +msg = lightred:.*rot-inducing.* +inv = lightred:.*rot-inducing.* # Mutagenic corpses/chunks -# -msg = magenta:chunks? of.*(draining|orange brain|great orb) -msg = magenta:chunks? of.*(guardian naga|shapeshifter|very ugly) -msg = magenta:(draining|orange brain|great orb).*corpse -msg = magenta:(guardian naga|shapeshifter|very ugly).*corpse -inv = magenta:.*chunks? of.*(draining|orange brain|great orb) -inv = magenta:.*chunks? of.*(guardian naga|shapeshifter|very ugly) +msg = magenta:.*mutagenic.* +inv = magenta:.*mutagenic.* # Poisonous corpses/chunks -# -msg = lightgreen:chunks? of.*(ant larva|kobold|beetle) -msg = lightgreen:chunks? of.*(brain worm|green draconian) -msg = lightgreen:chunks? of.*((black|brown|yellow) snake) -msg = lightgreen:chunks? of.*(bee|death yak|slug|amoeba) -msg = lightgreen:chunks? of.*(centipede|mite|snail|gila|hydra) -msg = lightgreen:chunks? of.*(iron troll|naga|queen|wasp) -msg = lightgreen:chunks? of.*(redback|(golden|mottled) dragon) -msg = lightgreen:chunks? of.*((orange|green) rat) -msg = lightgreen:chunks? of.*(scorpion|soldier ant|spiny|spider) -msg = lightgreen:(ant larva|kobold|beetle).*corpse -msg = lightgreen:(brain worm|green draconian).*corpse -msg = lightgreen:((black|brown|yellow) snake).*corpse -msg = lightgreen:(bee|death yak|slug|amoeba).*corpse -msg = lightgreen:(centipede|mite|snail|gila|hydra).*corpse -msg = lightgreen:(iron troll|naga|queen|wasp).*corpse -msg = lightgreen:(redback|(golden|mottled) dragon).*corpse -msg = lightgreen:((orange|green) rat).*corpse -msg = lightgreen:(scorpion|soldier ant|spiny|spider).*corpse -inv = lightgreen:.*chunks? of.*(ant larva|kobold|beetle) -inv = lightgreen:.*chunks? of.*(brain worm|green draconian) -inv = lightgreen:.*chunks? of.*((black|brown|yellow) snake) -inv = lightgreen:.*chunks? of.*(bee|death yak|slug|amoeba) -inv = lightgreen:.*chunks? of.*(centipede|mite|snail|gila|hydra) -inv = lightgreen:.*chunks? of.*(iron troll|naga|queen|wasp) -inv = lightgreen:.*chunks? of.*(redback|(golden|mottled) dragon) -inv = lightgreen:.*chunks? of.*((orange|green) rat) -inv = lightgreen:.*chunks? of.*(scorpion|soldier ant|spiny|spider) +msg = lightgreen:.*poisonous.* +inv = lightgreen:.*poisonous.* # Contaminated corpses/chunks -# -msg = brown:chunks? of.*(elf|human|drake|blowfly|cockroach) -msg = brown:chunks? of.*((fire|hill|frost|stone) giant) -msg = brown:chunks? of.*(mosquito|gnoll|goblin|jackal) -msg = brown:chunks? of.*(manticore|minotaur|ogre|orc) -msg = brown:chunks? of.*(war dog|warg|((rock|deep) )?troll) -msg = brown:chunks? of.*(grey rat|ugly thing|draconian) -msg = brown:chunks? of.*((quicksilver|iron|swamp|komodo) dragon) -msg = brown:chunks? of.*(mer(folk|maid)) -msg = brown:(elf|human|drake|blowfly|cockroach).*corpse -msg = brown:((fire|hill|frost|stone) giant).*corpse -msg = brown:(mosquito|gnoll|goblin|jackal).*corpse -msg = brown:(manticore|minotaur|ogre|orc).*corpse -msg = brown:(war dog|warg|((rock|deep) )?troll).*corpse -msg = brown:(grey rat|ugly thing|draconian).*corpse -msg = brown:((quicksilver|iron|swamp|komodo) dragon).*corpse -msg = brown:(mer(folk|maid)).*corpse -inv = brown:.*chunks? of.*(elf|human|drake|blowfly|cockroach) -inv = brown:.*chunks? of.*((fire|hill|frost|stone) giant) -inv = brown:.*chunks? of.*(mosquito|gnoll|goblin|jackal) -inv = brown:.*chunks? of.*(manticore|minotaur|ogre|orc) -inv = brown:.*chunks? of.*(war dog|warg|((rock|deep) )?troll) -inv = brown:.*chunks? of.*(grey rat|ugly thing|draconian) -inv = brown:.*chunks? of.*((quicksilver|iron|swamp|komodo) dragon) -inv = brown:.*chunks? of.*(mer(folk|maid)) +msg = brown:.*contaminated.* +inv = brown:.*contaminated.* -# Other food -# -inv = lightgrey:^food
\ No newline at end of file diff --git a/crawl-ref/settings/init.txt b/crawl-ref/settings/init.txt index 60851d5681..92cf07cab0 100644 --- a/crawl-ref/settings/init.txt +++ b/crawl-ref/settings/init.txt @@ -239,7 +239,7 @@ menu_colour_prefix_class = true # # yellow = preferred food # lightgrey = normal food -# darkgey = cannot be eaten at all +# darkgrey = cannot be eaten at all # lightred = extremely dangerous # magenta = mutagenic # lightgreen = poisonous diff --git a/crawl-ref/settings/menu_colours.txt b/crawl-ref/settings/menu_colours.txt index 01f5718212..cc6ef2b685 100644 --- a/crawl-ref/settings/menu_colours.txt +++ b/crawl-ref/settings/menu_colours.txt @@ -8,49 +8,13 @@ ae := autopickup_exceptions menu = lightmagenta:.*misc.*rune( of Zot)? menu = lightmagenta:.*orb.*Zot -# Identified artefacts -# -menu = magenta:.*(weapon|armour|jewellery|staff).*[+-] the - -# Unidentified weapon artefacts -# -menu = magenta:.*weapon.* ((brightly|faintly) glowing|smoking|twisted) -menu = magenta:.*weapon.* (bloodstained|shimmering|warped|crystal) -menu = magenta:.*weapon.* (jewelled|transparent|encrusted|pitted|slimy) -menu = magenta:.*weapon.* (polished|fine|crude|ancient|ichor-stained) -menu = magenta:.*weapon.* (steaming|shiny|polka-dotted) -menu = magenta:.*weapon.* (golden|purple|bone|serpentine|ruby|chunky) -menu = magenta:.*weapon.* (thin|green|ivory|ephemeral|blackened) -menu = magenta:.*weapon.* (sapphire|rusty|blue|brutal|adamantine|ebony) -menu = magenta:.*weapon.* (mangy|mithril|black|very long|steel|tiny) -menu = magenta:.*weapon.* flaming crossbow - -# Unidentified armour artefacts -# -menu = lightgrey:.*armour.* jewelled helm(et)? -menu = magenta:.*armour.* ((brightly|faintly) glowing|smoking|twisted) -menu = magenta:.*armour.* (bloodstained|shimmering|warped|heavily runed) -menu = magenta:.*armour.* (jewelled|transparent|encrusted|pitted|slimy) -menu = magenta:.*armour.* (polished|fine|crude|ancient|ichor-stained) -menu = magenta:.*armour.* (steaming|distressingly furry|plaid|tie-dyed) -menu = magenta:.*armour.* (dull|golden|silk|tattered|round|bronze) -menu = magenta:.*armour.* (fabulously|vibrating|soft|smelly|red|thick) -menu = magenta:.*armour.* (weird-looking|blue|black|dirty|paisley) -menu = magenta:.*armour.* (chartreuse) - -# Unidentified jewellery artefacts -# -menu = magenta:.*jewellery.* ((brightly|faintly) glowing|smoking) -menu = magenta:.*jewellery.* (shimmering|warped|crystal|diamond) -menu = magenta:.*jewellery.* (transparent|pitted|slimy|polished|fine) -menu = magenta:.*jewellery.* (crude|ancient|steaming|scintillating) -menu = magenta:.*jewellery.* (sparkling|flickering|glittering) -menu = magenta:.*jewellery.* (black |blood-stained|cast-iron) -menu = magenta:.*jewellery.* (phosphorescent) -menu = magenta:.*jewellery.* an (encrusted|emerald) (ring|amulet) -menu = magenta:.*jewellery.* a (runed|twisted|shiny|ruby) (ring|amulet) -menu = magenta:.*jewellery.* a (sapphire) ring -menu = magenta:.*jewellery.* a (jade) amulet +# Artefacts +menu = white:.*artefact.* + +# If Options.menu_colour_prefix_id is set to true, you can +# differentiate further. +#menu = white:.*identified.*artefact.* +#menu = magenta:.*unidentified.*artefact.* # Possible ego items # @@ -137,9 +101,8 @@ menu = yellow:.*potion.*(porridge|gluggy white) # Defaults for normal items # -menu = lightgreen:uncursed.*\(.*(worn|neck|hand|weapon).*\) -menu = lightred:cursed.*\(.*(worn|neck|hand|weapon).*\) -menu = white:\(.*(worn|neck|hand|weapon).*\) +menu = lightred:.*equipped.*cursed +menu = lightgreen:.*equipped.* menu = green:uncursed menu = red:cursed menu = lightgrey:^(scroll|potion|ring|amulet) |