tile_web_mouse_control = false ###################################################################### # Auto Exclude # ###################################################################### ## dangerous monsters ## auto_exclude += ancient lich, death drake, hydra, ice statue, orb of fire ## paralysing monsters and uniques ## auto_exclude += [^c] wizard, ancient lich, Ereshkigal, Erolcha, eyeball, Grinder, Jory, lich auto_exclude += ogre-mage, orb of eyes, orc sorcerer, Rupert, sphinx, vampire knight ## other uniques and unique followers ## auto_exclude += Agnes, Aizul, Arachne, Asterion, Blork, Boris, Crazy Yiuf, Donald, Dowan auto_exclude += Duvessa, Edmund, Erica, Eustachio, Fannar, Frances, Frederick, Gastronok auto_exclude += Grum, Harold, Ijyb, Jessica, Jorgrun, Joseph, Kirke, Louise, Maggie, Mara, Maud auto_exclude += Maurice, Menkaure, Mennas, Natasha, Nergalle, Nessos, Nikola, Pikel auto_exclude += Polyphemus, Prince Ribbit, Psyche, Robin, Roxanne, Saint Roka, Sigmund, Snorg auto_exclude += Sojobo, Sonja, Terence, Urug, Wiglaf, Xtahua, slave ################# ### Interface ### ################# easy_confirm = all default_manual_training = true equip_unequip = true sort_menus = true:equipped,identified,>qty,basename,art,ego,glowing,qualname ################## ### Autopickup ### ################## ae := autopickup_exceptions ae += scrolls? of silence ################# ### PASTA ### ################# travel_delay = -1 explore_delay = -1 rest_delay = -1 view_delay = 3 show_travel_trail = true use_animations = false show_more = false # try to prevent autopick from being interrupted during zig cleanup? travel_key_stop = false # re-set travel_open_doors = false, this was set in my old rc but removed -.- travel_open_doors = avoid explore_stop = artefacts,greedy_pickup_smart explore_stop += stairs,shops explore_stop += altars,portals,branches,runed_doors view_delay = 200 # try to reduce keyboard delay for realtime games # here we use 3 ms to try to stay inside of a 280hz redraw window tile_runrest_rate = 3 tile_key_repeat_delay = 3 # prevent autofight from changing behavior at arbitrary HP threshold autofight_stop = 0 # try to prevent movement key tapping deaths due to disabled mores # note: you need to force_more for this to work with show_more = false hp_warning = 60 # allow specific force_mores through show_more = false force_more_message = force_more_message += LOW HITPOINT WARNING flash_screen_message += Ashenzari invites you to partake more += distortion flash_screen_message += wielding.*distortion force_more_message += transformation, weakening force_more_message += toss it runrest_stop_message += friend_action: runrest_stop_message += melt, evaporates, transformation, flicker, weakening # since we're clearing default force_mores, re-enable portal and zot clock announcements, as not to miss them ## Zot is coming! force_more_message += You have lingered too long force_more_message += Zot draws nearer force_more_message += Zot has nearly found you force_more_message += Zot already knows force_more_message += Zot's attention fixes on you # Announcements of timed portal vaults: force_more_message += interdimensional caravan force_more_message += distant snort force_more_message += roar of battle force_more_message += wave of frost force_more_message += hiss of flowing sand force_more_message += sound of rushing water force_more_message += oppressive heat about you force_more_message += crackle of arcane power force_more_message += hear a distant wind # Arriving Unexpectedly more += appears in a shower of sparks more += appears out of thin air more += comes (up|down) the stairs more += Something appears in a flash of light more += The.*is a mimic more += You sense the presence of something unfriendly more += The.*answers the.*call more += Wisps of shadow swirl around more += Shadows whirl around # Item Use more += drinks a potion more += evokes.*(amulet|ring) more += reads a scroll more += zaps a (wand|rod) # Terrible Monsters more += 's ghost.*(comes? into view|opens the) more += A player ghost.*(comes? into view|opens the) more += boggarts?.*(comes? into view|opens the) more += curse skull.*comes? into view more += .*fiend.*(comes? into view|opens the) more += flayed ghost.*(comes? into view|opens the) more += giant eyeball.*comes? into view more += giant orange brains?.*(comes? into view|opens the) more += giant spore.*comes? into view more += hellion.*(comes? into view|opens the) more += tzitzimitl.*(comes? into view|opens the) more += Lich.*(comes? into view|opens the) more += Ancient Lich.*(comes? into view|opens the) more += orange crystal statue.*comes? into view more += shadow demons?.*(comes? into view|opens the) more += silver statue.*comes? into view more += tormentor.*(comes? into view|opens the) more += .*shrike.* comes? into view more += curse toe.*comes? into view more += entropy weaver.*(comes? into view|opens the) more += goliath frog.*comes? into view more += bloated husk.*comes? into view more += fenstrider witch.*(comes? into view|opens the) more += moth of wrath.*comes? into view more += .*orbs? of fire.*comes? into view more += .*hell sentinel.*(comes? into view|opens the) more += .*neqoxec.*(comes? into view|opens the) more += .*cacodemon.*(comes? into view|opens the) more += .*greater mummy.*(comes? into view|opens the) more += .*mummy priest.*(comes? into view|opens the) more += .*lurking horror.*(comes? into view|opens the) more += .*ogre mage.*(comes? into view|opens the) more += .*a wizard.*(comes? into view|opens the) more += .*orc sorcerer.*(comes? into view|opens the) more += .*sphinx.*(comes? into view|opens the) more += .*great orb of eyes.*comes? into view more += ((floating|shining) eye|dream sheep|death drake).*into view more += (wretched star|apocalypse crab).*into view more += torpor snail.*comes? into view more += spriggan druid.*(comes? into view|opens the) more += (vault (warden|sentinel)|merfolk (avatar|siren)).*(comes? into view|opens the) more += (guardian serpent|draconian (shifter|scorcher|annihilator)|convoker|death cob).*(comes? into view|opens the) more += (phantasmal warrior|air elemental).*(comes? into view|opens the) more += (vampire knight|basilisk|deep elf (sorcerer|demonologist|high priest|annihilator)).*(comes? into view|opens the) more += tengu reaver.*(comes? into view|opens the) more += juggernaut.*(comes? into view|opens the) # Uniques # This line is supposed to do them all (including pan lords) more += (?-i:[A-Z]).* comes? into view more += 27-headed.*(comes? into view|opens the) more += Agnes.*(comes? into view|opens the) more += Aizul.*(comes? into view|opens the) more += Antaeus.*(comes? into view|opens the) more += Arachne.*(comes? into view|opens the) more += Asmodeus.*(comes? into view|opens the) more += Asterion.*(comes? into view|opens the) more += Azrael.*(comes? into view|opens the) more += Blork the orc.*(comes? into view|opens the) more += Boris.*(comes? into view|opens the) more += Cerebov.*(comes? into view|opens the) more += Crazy Yiuf.*(comes? into view|opens the) more += Dispater.*(comes? into view|opens the) more += Dissolution.*(comes? into view|opens the) more += Donald.*(comes? into view|opens the) more += Dowan.*(comes? into view|opens the) more += Duvessa.*(comes? into view|opens the) more += Edmund.*(comes? into view|opens the) more += Ereshkigal.*(comes? into view|opens the) more += Erica.*(comes? into view|opens the) more += Erolcha.*(comes? into view|opens the) more += Eustachio.*(comes? into view|opens the) more += Fannar.*(comes? into view|opens the) more += Frances.*(comes? into view|opens the) more += Frederick.*(comes? into view|opens the) more += Gastronok.*(comes? into view|opens the) more += Geryon.*(comes? into view|opens the) more += Gloorx Vloq.*(comes? into view|opens the) more += Grinder.*(comes? into view|opens the) more += Grum.*(comes? into view|opens the) more += Harold.*(comes? into view|opens the) more += Ignacio.*(comes? into view|opens the) more += Ijyb.*(comes? into view|opens the) more += Ilsuiw.*(comes? into view|opens the) more += Jessica.*(comes? into view|opens the) more += Jorgrun.*(comes? into view|opens the) more += Jory.*(comes? into view|opens the) more += Joseph.*(comes? into view|opens the) more += Josephine.*(comes? into view|opens the) more += Khufu.*(comes? into view|opens the) more += Kirke.*(comes? into view|opens the) more += Lom Lobon.*(comes? into view|opens the) more += Louise.*(comes? into view|opens the) more += Maggie.*(comes? into view|opens the) more += Mara.*(comes? into view|opens the) more += Margery.*(comes? into view|opens the) more += Maurice.*(comes? into view|opens the) more += Menkaure.*(comes? into view|opens the) more += Mennas.*(comes? into view|opens the) more += Mnoleg.*(comes? into view|opens the) more += Murray.*(comes? into view|opens the) more += Natasha.*(comes? into view|opens the) more += Nergalle.*(comes? into view|opens the) more += Nessos.*(comes? into view|opens the) more += Nikola.*(comes? into view|opens the) more += Pikel.*(comes? into view|opens the) more += Polyphemus.*(comes? into view|opens the) more += Prince Ribbit.*(comes? into view|opens the) more += Psyche.*(comes? into view|opens the) more += Purgy.*(comes? into view|opens the) more += Robin.*(comes? into view|opens the) more += Roxanne.*(comes? into view|opens the) more += Rupert.*(comes? into view|opens the) more += Saint Roka.*(comes? into view|opens the) more += Sigmund.*(comes? into view|opens the) more += Snorg.*(comes? into view|opens the) more += Sojobo.*(comes? into view|opens the) more += Sonja.*(comes? into view|opens the) more += Terence.*(comes? into view|opens the) more += The Lernaean hydra.*(comes? into view|opens the) more += The royal jelly.*(comes? into view|opens the) more += The Serpent of Hell.*(comes? into view|opens the) more += Tiamat.*(comes? into view|opens the) more += Urug.*(comes? into view|opens the) more += Vashnia.*(comes? into view|opens the) more += Xtahua.*(comes? into view|opens the) ########### # Failure # ########### more += sense of stasis more += Something interferes with your magic more += The spell fizzles more += The writing blurs in front of your eyes more += The.*is unaffected more += This potion can/'t work under stasis more += You are held in a net more += You are too injured to fight blindly more += You can't gag anything down more += You can't unwield more += when .*silenced more += You cannot .* while unable to breathe more += You cannot .* in your current state more += You don't have any such object more += You don't have enough magic more += You don't.* that spell more += You fail to use your ability more += You have no appropriate body parts free more += no means to grasp more += You haven't enough magic at the moment more += You miscast more += Your amulet of stasis more += Your attempt to break free more += Your body armour is too heavy more += You miscast.*(Blink|Borgnjor|Door|Invisibility) more += You can't (read|drink|do) more += There's something in the way more += There's nothing to (close|open) nearby more += not good enough to have a special ability more += You are too berserk more += That item cannot be evoked more += You don't have the energy to cast that spell more += You are unable to access your magic ############################# # Bad and Unexpected Things # ############################# #Bad things more += corrodes your equipment more += Your corrosive artefact corrodes you more += are blown away by the wind more += dispelling energy hits you more += infuriates you more += lose consciousness more += mark forms upon you more += MASSIVE DAMAGE more += Ouch! That really hurt! more += silver sears you more += Space bends around you more += Space warps.*around you more += hits you.*distortion more += (?!.*(Here|Aim):)^.*wielding.*of distortion more += surroundings become eerily quiet more += Terrible wounds (open|spread) all over you more += The acid corrodes your more += The air around.*erupts in flames more += The air twists around and violently strikes you in flight more += You shudder from the earth-shattering force more += The arrow of dispersal hits you[^r] more += The barbed spikes become lodged in your body more += The barbed spikes dig painfully into your body as you move more += The blast of calcifying dust hits you[^r] more += The poison in your body grows stronger more += The pull of.*song draws you forwards more += The.*engulfs you in water more += The.*grabs you[^r] more += You (are|feel) drained more += You are (blasted|electrocuted) more += You are blown backwards more += You are burned terribly more += You are encased in ice more += You are engulfed in calcifying dust more += You are engulfed in dark miasma more += You are engulfed in mutagenic fog more += You are knocked back more += You are mesmerised more += You are slowing down more += You are trampled more += You convulse more += You feel a (horrible|terrible) chill more += You feel haunted more += You feel less vulnerable to poison more += You feel your attacks grow feeble more += You feel your flesh.*rot more += You feel your power drain away more += You feel your power leaking away more += You feel yourself grow more vulnerable to poison more += You stumble backwards more += You.*re (confused|more confused|too confused) more += You.*re (poisoned|more poisoned|lethally poisoned) more += Your body is wracked with pain more += Your damage is reflected back at you more += Your limbs are stiffening more += Your magical defenses are stripped away more += Your?.*suddenly stops? moving more += A sentinel's mark forms upon you more += Your magical effects are unravelling # Monsters doing bad things more += A tree reaches out and hits you! more += Agitated ravens fly out from beneath the more += begins to recite a word of recall more += Being near the torpor snail leaves you feeling lethargic more += blows on a signal horn more += cast banishment more += cast paralyse more += cast Torment more += goes berserk more += The moth of wrath goads something on more += is duplicated more += is no longer invulnerable more += Its appearance distorts for a moment more += Mara seems to draw the.*out of itself more += Mara shimmers more += Miasma billows from the more += shoots a curare more += stands defiantly in death's doorway more += steals.*your more += swoops through the air toward you more += The forest starts to sway and rumble more += The jumping spider pounces on you [^but] more += The octopode crusher throws you more += The shadow imp is revulsed by your support of nature more += The water nymph flows with the water more += The.*offers itself to Yredelemnul more += The.*seems to speed up more += The.*shudders more += There is a horrible\, sudden wrenching feeling in your soul more += Vines fly forth from the trees! more += You are hit by a branch more += watched by something more += Your magical defenses are stripped away more += \'s.*reflects more += is wielding.*of more += zaps a wand more += (He|She|It) is.*carrying a wand of # Unexpected situations more += A magical barricade bars your way #more += Done waiting more += doors? slams? shut more += It doesn't seem very happy more += Mutagenic energies flood into your body more += Some monsters swap places more += devoid of blood more += (The|Your).*falls away! more += The divine light dispels your darkness! more += The walls disappear more += There is a sealed passage more += You are wearing\: #more += You can now more += You cannot afford.*fee more += You feel (dopey|clumsy|weak) more += You feel a genetic drift more += You feel monstrous more += You feel your rage building more += You have disarmed more += You have finished your manual more += You have reached level more += You need to eat something NOW more += You smell decay. (^Yuck!) more += You stop (a|de)scending the stairs more += You turn into a fleshy mushroom more += Your body shudders with the violent release of wild energies more += Your guardian golem overheats more += your magic stops regenerating more += Your scales start more += your.*devoured #more += Your?.*can no longer more += Green shoots are pushing up through the earth more += Deactivating autopickup more += Gained mutation stop += flesh start stop += Wait a moment # Things getting better stop += contamination has completely more += You can move again more += You slip out of the net more += You.*and break free more += Your fit of retching subsides more += seems mollified #more += as sick as possible more += You now have enough gold to buy more += skill increases to more += .*falls from the air # tiles-specific options tile_show_threat_levels = tough, nasty cloud_status = true ########################### ###BEGIN LUA BLACK MAGIC### ########################### < function ready() AnnounceDamage() --SpoilerAlert() OpenSkills() end > ############### # Damage Calc # ############### < local previous_hp = 0 local previous_mp = 0 local previous_form = "" local was_berserk_last_turn = false function AnnounceDamage() local current_hp, max_hp = you.hp() local current_mp, max_mp = you.mp() --Things that increase hp/mp temporarily really mess with this local current_form = you.transform() local you_are_berserk = you.berserk() local max_hp_increased = false local max_hp_decreased = false if (current_form ~= previous_form) then if (previous_form:find("dragon") or previous_form:find("statue") or previous_form:find("tree") or previous_form:find("ice")) or previous_form:find("hydra")then max_hp_decreased = true elseif (current_form:find("dragon") or current_form:find("statue") or current_form:find("tree") or previous_form:find("ice")) or previous_form:find("hydra")then max_hp_increased = true end end if (was_berserk_last_turn and not you_are_berserk) then max_hp_decreased = true elseif (you_are_berserk and not was_berserk_last_turn) then max_hp_increased = true end --crawl.mpr(string.format("previous_form is: %s", previous_form)) --crawl.mpr(string.format("current_form is: %s", current_form)) --crawl.mpr(string.format("max_hp_increased is: %s", max_hp_increased and "True" or "False")) --crawl.mpr(string.format("max_hp_decreased is: %s", max_hp_decreased and "True" or "False")) --crawl.mpr(string:format("you_are_berserk is: %s", you_are_berserk and "True" or "False")) --crawl.mpr(string:format("was_berserk_last_turn is: %s", was_berserk_last_turn and "True" or "False")) --Skips message on initializing game if previous_hp > 0 then local hp_difference = previous_hp - current_hp local mp_difference = previous_mp - current_mp if max_hp_increased or max_hp_decreased then if max_hp_increased then crawl.mpr("You now have " .. current_hp .. "/" .. max_hp .. " hp.") else crawl.mpr("You now have " .. current_hp .. "/" .. max_hp .. " hp.") end else --On losing health if (current_hp < previous_hp) then if current_hp <= (max_hp * 0.30) then crawl.mpr("You take " .. hp_difference .. " damage, and have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.50) then crawl.mpr("You take " .. hp_difference .. " damage, and have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.70) then crawl.mpr("You take " .. hp_difference .. " damage, and have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.90) then crawl.mpr("You take " .. hp_difference .. " damage, and have " .. current_hp .. "/" .. max_hp .. " hp.") else crawl.mpr("You take " .. hp_difference .. " damage, and have " .. current_hp .. "/" .. max_hp .. " hp.") end if hp_difference > (max_hp * 0.20) then crawl.mpr("MASSIVE DAMAGE!!") end end --On gaining more than 1 health if (current_hp > previous_hp) then --Removes the negative sign local health_inturn = (0 - hp_difference) if (health_inturn > 1) and not (current_hp == max_hp) then if current_hp <= (max_hp * 0.30) then crawl.mpr("You regained " .. health_inturn .. " hp, and now have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.50) then crawl.mpr("You regained " .. health_inturn .. " hp, and now have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.70) then crawl.mpr("You regained " .. health_inturn .. " hp, and now have " .. current_hp .. "/" .. max_hp .. " hp.") elseif current_hp <= (max_hp * 0.90) then crawl.mpr("You regained " .. health_inturn .. " hp, and now have " .. current_hp .. "/" .. max_hp .. " hp.") else crawl.mpr("You regained " .. health_inturn .. " hp, and now have " .. current_hp .. "/" .. max_hp .. " hp.") end end if (current_hp == max_hp) then crawl.mpr("Health restored: " .. current_hp .. "") end end --On gaining more than 1 magic if (current_mp > previous_mp) then --Removes the negative sign local mp_inturn = (0 - mp_difference) if (mp_inturn > 1) and not (current_mp == max_mp) then if current_mp < (max_mp * 0.25) then crawl.mpr("You regained " .. mp_inturn .. " mp, and now have " .. current_mp .. "/" .. max_mp .. " mp.") elseif current_mp < (max_mp * 0.50) then crawl.mpr("You regained " .. mp_inturn .. " mp, and now have " .. current_mp .. "/" .. max_mp .. " mp.") else crawl.mpr("You regained " .. mp_inturn .. " mp, and now have " .. current_mp .. "/" .. max_mp .. " mp.") end end if (current_mp == max_mp) then crawl.mpr("MP restored: " .. current_mp .. "") end end --On losing magic if current_mp < previous_mp then if current_mp <= (max_mp / 5) then crawl.mpr("You now have " .. current_mp .. "/" ..max_mp .." mp.") elseif current_mp <= (max_mp / 2) then crawl.mpr("You now have " .. current_mp .. "/" ..max_mp .." mp.") else crawl.mpr("You now have " .. current_mp .. "/" ..max_mp .." mp.") end end end end --Set previous hp/mp and form at end of turn previous_hp = current_hp previous_mp = current_mp previous_form = current_form was_berserk_last_turn = you_are_berserk end > #################### # Opens skill menu # #################### < local need_skills_opened = true function OpenSkills() if you.turns() == 0 and need_skills_opened then need_skills_opened = false crawl.sendkeys("m") end end > ########### ### Lua ### ########### { -- Equipment autopickup (by Medar and various others) local function pickup_equipment(it, name) if it.is_useless then return end local class = it.class(true) if class == "armour" then local good_slots = {cloak="Cloak", helmet="Helmet", gloves="Gloves", boots="Boots"} st, _ = it.subtype() -- Autopickup found aux armour if 1) we don't have any or 2) it's artefact, -- or 3) if we don't have artefact or ego armour, and the found armour is -- ego. if good_slots[st] ~= nil then if good_slots[st] == "Gloves" and you.has_claws() > 0 then return end if it.artefact then return true end local cur = items.equipped_at(good_slots[st]) if cur == nil then return true end if cur.branded or cur.artefact then return end if it.branded then return true end -- Autopickup found body armour of the same kind we're wearing, according -- to conditions (2) and (3) above used for aux slots. elseif st == "body" then local cur = items.equipped_at("armour") if cur == nil then return end if cur.name("qual") ~= it.name("qual") then return end if it.artefact then return true end if cur.branded or cur.artefact then return end if it.branded then return true end end end return end add_autopickup_func(pickup_equipment) -- Spellcasting spam reduction by monqy local function generic_cast_spell(cmd) crawl.mpr('Cast which spell?') crawl.flush_prev_message() crawl.process_keys(cmd) end function cast_spell() generic_cast_spell('z') end function force_cast_spell() generic_cast_spell('Z') end } # Note: My final RC file has code from lua files found at: # https://github.com/gammafunk/dcss-rc/blob/master/README.md # starting from the line below. { ---------------------------- ---- Begin load_message ---- ---------------------------- -- See README.md for documentation. message_color = "white" -- Wrapper of crawl.mpr() that prints text in white by default. if not mpr then mpr = function (msg, color) if not color then color = "white" end crawl.mpr("<" .. color .. ">" .. msg .. "") end end function save_with_message() if you.turns() == 0 then crawl.sendkeys("S") return end crawl.formatted_mpr("Save game and exit?", "prompt") local res = crawl.getch() if not (string.char(res) == "y" or string.char(res) == "Y") then crawl.formatted_mpr("Okay, then.", "prompt") return end crawl.formatted_mpr("Leave a message: ", "prompt") local res = crawl.c_input_line() c_persist.message = res crawl.sendkeys(control("s")) end function load_message() if c_persist.message and c_persist.message ~= "nil" and c_persist.message ~= "" then mpr("MESSAGE: " .. c_persist.message, message_color) c_persist.message = nil end end ----------------------------------- ---- End leave message on save ---- ----------------------------------- } flash_screen_message += Vehumet offers you knowledge note_messages += Saving game note_messages += Your magical essence is drained by the effort! # travel_key_stop = false ###This should be for safe walking### { safe = you.feel_safe() function update_safe() local old_safe = safe safe = you.feel_safe() if not safe and old_safe then crawl.mpr("Danger!", "warning") crawl.more() end end function ready() update_safe() end }