summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/spl-cast.cc
Commit message (Collapse)AuthorAgeFilesLines
* Remove stuffNicholas Feinberg2014-07-291-1/+3
| | | | | | | .cc, moving its contents into the new stepdown.cc and strings.cc. (The latter also got many donations from libutil.h.) Down with stuff! Up the new flesh!
* Move redraw functions from stuff.cc -> output.ccNicholas Feinberg2014-07-281-0/+1
|
* Create prompt.ccNicholas Feinberg2014-07-271-0/+1
|
* Separate 'permanent' and 'temporary' monster hit diceNicholas Feinberg2014-07-131-1/+1
| | | | As part of a wider scheme to make draining temporary.
* Partially refactor cast_healing()Nicholas Feinberg2014-06-261-6/+2
|
* Rename 'mesclr()' to 'clear_messages()'reaverb2014-06-221-2/+2
|
* The great mon-stuff migration.Shmuale Mark2014-06-221-1/+1
| | | | | | | | | A good deal of functions move to the two new files, mon-poly and mon-message. Of the others, some go to where they are used, some to mon-util, and a few are made member methods of monster. This probably breaks Xcode compilation, and I'm not able to test the changes I made to MSVC that will (hopefully) keep it working.
* Adjust the Contemplative mutationNicholas Feinberg2014-06-201-2/+2
| | | | | Make it a badmut (since it is!), and give it a new name better suiting its new status.
* Add parenthesesreaverb2014-06-121-2/+2
|
* Mutation: ContemplativeBrendan Hickey2014-06-121-1/+2
| | | | | | | Add Contemplative, the inverse of Wild Magic. Makes spells easier to cast, but with lower power. I've flagged it as a badmut for now. Perhaps Wild Magic should also be flagged as bad.
* Don't cycle through corpses with Apportation (#8622)Neil Moore2014-06-091-4/+4
| | | | | | | | | | But still allow x* to cycle through all object stacks. For now * and + do the same thing when targetting apportation, but maybe it makes sense to have * keep the old behaviour. Note that SPFLAG_TARG_OBJ now uses the new DIR_MOVABLE_OBJECT targeting_type. If we add a new object-targetting spell that *can* affect corpses, we'll have to separate SPFLAG_TARG_OBJ into two flags.
* Make Doxygen @returns "@return" for consistancy.reaverb2014-06-051-1/+1
|
* Change Tukima to be a targeted spellJeekaroose2014-05-271-7/+2
| | | | | | | | (Committer's note: The old Tukima's Dance was fiddly and not well-liked. Changing it into something hexier seemed like a popular & reasonable idea. I refactored the spell code & fixed a few small issues.)
* Remove an unused parameter.Nicholas Feinberg2014-05-271-8/+6
| | | | | | With 4ad890b14, check_range was unused again. It can easily be re-added with needed, though I'm not fond of the duplication with the checks in cast_a_spell().
* Revert "Don't waste time casting Animate Dead, usually."Shmuale Mark2014-05-271-7/+0
| | | | | | | Because it's very common that corpses will be hidden by items above them, especially now that that's guaranteed if there are any items above them, the 'z' behaviour it made was too restrictive. This reverts commit f040398a199a9f2bda755c0802287558edecba2e.
* Remove an unused parameter & update commentsNicholas Feinberg2014-05-261-4/+3
|
* Add the Majin-Bo, a new fixedart that offers power atNicholas Feinberg2014-05-251-12/+61
| | | | a terrible price. (It's not that terrible!)
* Don't waste time casting Animate Dead, usually.Shmuale Mark2014-05-231-0/+7
| | | | | | | | | | If there's a visible corpse nearby, the behaviour is the same. If there are no items, 'z' should not waste time/MP, while you can still force a cast with 'Z', so that you can animate corpses that are below other items and you can't see with ^X. Sadly, this doesn't really work for Yred since there's no way to force a use of an ability the way there is with a spell.
* Rename percent_chance() decimal_chance() (|amethyst)reaverb2014-05-181-1/+1
|
* Melt away lava orcs.Steve Melenchuk2014-05-141-0/+6
| | | | | | | | | | | | | | | | When you strip away the fundamentally broken tension mechanic, you're left with a species that is essentially "Hill Orcs WITH FIRE". No effort has come forward with code to fix either aspect of them despite the length of time they've been around in trunk, and the code is littered with a very large number of special cases in their presence. Current lava orcs should be able to finish their games fine, but new starts are disallowed. There are a couple of bits I've left present but which will have no function for the moment, mostly related to interactions with lava (as there are a couple of species proposals floating around that benefit from having those interactions).
* New function: percent_chance()reaverb2014-05-101-3/+1
| | | | | | | Designed to make sure things like no god protecting you from miscasts won't happen again. Lua could use it in a couple places, if the function was made accessible from that environment.
* Update a comment and formatting.Neil Moore2014-05-101-3/+3
|
* Correct Sif Muna miscast protection probability (|amethyst)reaverb2014-05-101-1/+1
| | | | | Before, there was a one in a few billion chance that Sif Muna would not protect you even at max piety.
* Quickly fix no god protecting people from miscastsreaverb2014-05-101-1/+1
|
* Staticify.Steve Melenchuk2014-05-091-5/+5
|
* Use Sif miscast protection when coloring spell fail chancesdrachereborn2014-05-091-5/+27
| | | | (I have pretty severely edited this patch. #8301 on mantis) -reaverb
* Don't make rain clouds act as negative fire enhancersChris Campbell2014-05-081-6/+0
|
* Remove the Summon Elemental spellChris Campbell2014-05-061-1/+4
| | | | | | | | It was fairly fiddly and unclear in its mechanics, and elemental summoning is now covered by the elemental evokers (and possibly the storm god at some point in the future too)· Moved Summon Forest from the book of the Warp to replace it in the book of Summonings, and added Dispersal to replace it in the book of Wizardry.
* Refactor _spellcasting_side_effects()Nicholas Feinberg2014-05-051-17/+38
| | | | | Committer's note: Adapted to apply to Trunk and corrected a flipped conditional. -reaverb
* Improved messages when Sif or Kiku prevents miscasts. Also improved ↵drachereborn2014-04-291-1/+1
| | | | | | | descriptions of Sif and Kiku miscast protection. Sif prevents both the miscast and associated contam ("effects of miscast") Kiku prevents Necro miscasts and also death curses
* Remove the low-level weapon branding spells.Shmuale Mark2014-04-271-8/+5
| | | | | | | | | | | | | For the most part they were optimal to cast before every fight, making them hugely annoying but too useful to simply ignore. They also encouraged being casted before reading an unidentified scroll, just in case it might be brand weapon. Warp Weapon and Excruciating Wounds obviously do not have the latter problem, and since the spells have noticeable drawbacks they do not have the second problem as much either. The books of Ice, Fire, and Necromancy don't get replacements; they are pretty good anyway. Alchemy and Envenomations get Alistair's.
* Remove some more djinn code.Shmuale Mark2014-04-101-7/+2
| | | | | | | Nothing that changes functionality or that makes the interface looks too weird. In several of the instances the code would be weird after moving to TAG_MAJOR_VERSION 35, so it seems worth it to remove now rather than leaving it around.
* Remove the unused jelly formChris Campbell2014-04-101-1/+1
|
* Rework the icemail mutation.Shmuale Mark2014-03-251-5/+0
| | | | | | | | | | | | | | | | It's been said that the main effect is to turn your AC permanently red. Although in a branch without fire attacks this wouldn't be as true, the fact remained that it made optimal play waiting around for 300 (!) turns after dissipation, the only cost being hunger. Icemail is now binary, turning off when hit by fire, and after 300 aut (a reasonable rest time after a fight) coming back again with all 10 AC. While active, it turns the AC display blue, and when dissipated, normal; displaying like that seems to work well for Lava Orcs. Casting fire spells will not disrupt it, or Condensation Shield or Ozocubu's Armour; for the latter two, having to train both fire and ice is enough of a deterrent to make it not a "no-brainer" (as the comment called it).
* Fix various tracer issues with the Rod of DestructionDracoOmega2014-03-221-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Tracer attack prompts were being printed for the actual beam the rod produced, rather than the range of beams the rod COULD produce. For example, if you tried to fire it at a friendly iron golem, you would get a warning prompt only for quicksilver bolt (which would then let you abort without spending time or mp, allowing you to reroll a new beam type from the rod). This was similarly true with bouncing beams prompting for self-harm in confined spaces and letting you cancel to make sure you got something else. Now the tracer should consider the beam both irresistable and bouncing (since it can be either), independant of whether the type you actually roll ends up being so (and thus no more free beam rerolls). The method to do this feels slightly involved, but I'm not sure a simpler way, given that no existing damage type both bounces and is irresistable. (It will also still technically prompt you for harming rF+++ rC+++ rElec+++ allies you could hit only if the bolt bounced, which is a situation that can never occur, but this seems a far less important problem than the one being fixed here - and rather hard to resolve).
* Allow the player to memorize a spell regardless of fail rate (Lasty).gammafunk2014-03-131-5/+10
| | | | | Resolves #8265. This commit also cleans up and documents a few spell miscast rate calculation functions.
* Remove `auto_list` optionChris Oelmueller2014-03-111-2/+0
| | | | | | | | | | | | | It has been defaulting to `true` for a while now. That setting provides a nicer interface overall and there is little reason to support alter- nate input methods. Some prompts asking for a letter have not been adjusted, for example evoking a rod with multiple spells. Those are hopefully gone soon anyways. [Committer's note: The option had no known uses except by bots, and those could work without it. And, of course, multi-spell rods are gone.]
* Allow ghost casting of dazzling spray (Grunt).gammafunk2014-03-061-1/+1
| | | | | | | | | Player ghosts can now have dazzling spray, which sets confusion based on an XL check that's the same as used when blinding monsters. This commit is mostly based on Grunt's commit 0d12a004 in the glaciate-testing branch and cleaned up some for trunk, with some aspects reorganized.
* Rename Summon Menagerie to Monstrous Menagerie.Steve Melenchuk2014-03-061-2/+2
| | | | Less boring, at least.
* New spell: Summon Mana ViperDracoOmega2014-03-061-0/+3
| | | | | | | | | | | | | | | | | | With the aim of creating summons that have more differentiated uses from each other, this spell summons something that can provide good anti-caster support while being less directly mighty than other higher level summons, particularly against enemies where its antimagic bite contributes little. It is a level 6 summoning/hexes spell which summons a mana viper (with a cap of 2) whose antimagic effect scales noticably with spellpower, but its hp and damage do not. The general idea is that it is less good at killing many things on its own (and spellpower alone cannot turn it into something very tanky) but an investment in the relevant skills can provide a very strong augment against vulnerable enemies. (It IS still pretty strong even against non-casters, I admit, but also a level 6 dual-school spell with a less common secondary school, so maybe is fine as-is).
* New spell: Forceful DismissalDracoOmega2014-03-061-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | In the spirit of adding more dynamic options to summon play besides 'make more creatures to throw at things', Forceful Dismissal is a level 6 summonings spell which violently unsummons all of your nearby summoned creatures, causing magical explosions around where each of them were. The explosion damage is based both on spellpower as well as the HD of the creature being unsummoned (so imps make much less effective 'bombs' than a hell sentinel would). Damage numbers are even more provisional than usual, since it's somewhat hard to know how this will play outside a real game. The aim is not to make immediately detonating summons in melee range the generally optimal thing to do, as the full damage over a summon's lifetime ought to exceed it in many cases, but rather something you might use in cases where burst damage was especially important, or your defensive line looked about to crumble anyway, and so on. I considered adding a drawback that casting it would temporarily prevent RE-summoning anything for several turns, making it more desireable to get further value out of the living summon before exploding it, but I'm not certain that's necessary, and would like to see how this version plays out first.
* New spell: Spellforged ServitorDracoOmega2014-03-061-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | With the idea of introducing more summoning spells that a bit unique in some way, this is a level 7 Summoning/Conjurations spell which summons a single golem-like being that possesses a subset of the caster's own conjurations. The spell list is assembled deterministically, somewhat similar to player ghosts (though different in a number of regards). The first 3 spell slots draw from a 'primary' list containing direct conjurations like bolt of cold or poison arrow, while the next 2 are from a 'secondary' list which tends to contain AoE effects and cloud spells, as well as things like airstrike. Spells are selected roughly in order of level and power, with the player's higher spell skills having a small effect. In practice, I think the servitor will fairly transparently possess a selection of the player's better spells, without anyone needing to think much on how it arrived at this list. Many of the highest level spells (like fire storm and shatter) are excluded not only for power reasons, but also because a servitor using these could be downright dangerous to its caster. The main exception I made here was CBL, which is allowed (being both lower-level and often similarly dangerous when the player uses it, though I open to changing this).
* Replace Summon Ugly Thing with Summon Menagerie (pending a better name)DracoOmega2014-03-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Summon Ugly Thing was never a particularly impressive spell and the summon cap changes have left it even more underwhelming these days. Still, there is a need for a solid midrange summon available to good god worshipers, and this is a shot at assembling one that might be more interesting than the ubiquitous ugly things. The spell can summon either a manticore, lindwurm, harpy (multiples at higher power), or a sphinx (much rarer except at high power), which I feel are solid midrange creatures with a shared mythological theme and some relatively unobtrusive gimmicks (and more of an emphasis on ranged combat than its immediate 'upgrade' in Summon Hydra). Somewhat similarly to Shadow Creatures, multiple harpies count as a single creature for the purposes of the spell's cap, and the creatures also receive a modest HD boost based on high spellpower (I'm still somewhat divided on this, unlike with Ice Beast, but it does help the spell scale more strongly with spellpower that it otherwise would; perhaps there is some higher-tier creature accessible with high power that could help bridge this gap on its own?) As a natural consequence of Summon Ugly Thing being replaced, Kirke also acquires this spell. This is effectively a buff for her, but as one of the least dangerous midgame uniques, I am sure she can handle it, and a selection of Greek mythological beasts are surely at least as suitable things for her to summon as... whatever ugly things are.
* Replace Mass Abjuration with Aura of AbjurationDracoOmega2014-03-061-2/+2
| | | | | | | | | | | | | | | | | Mass Abjuration was never an especially popular spell at level 6, but the recent changes which cause summons to be automatically abjured upon their caster's death renders its usefulness considerably lower. This experimental change is aimed at making the spell more appealing given how readily available this faux-mass-abjuration already is to everyone. Aura of Abjuration causes the caster to continuously perform a lower power version of Mass Abjuration each turn for a reasonably long duration, sending new summons away shortly after they arrive (given sufficient power). This version could even be a useful pre-cast option for battles with summon-focused enemies and provides tactical options which old Mass Abjuration did not, and might give the spell some play in the current environment.
* Remove Demonic HordeDracoOmega2014-03-061-1/+4
| | | | | | | | This was neither a popular nor powerful nor especially interesting spell, which was basically 'Call Imp, except a lot more of them'. Making the demons more individually powerful only further steps on the toes of the many other demon summoning spells that already exist, so I think it is fine to simply trim it.
* Overhaul Summon Dragon for playersDracoOmega2014-03-061-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summon Dragon was hit extremely hard by the summon cap, as the effective strength of a summoned monster is superlinear with their quantity, and 2 dragons simply does not provide even remote offensive or defensive parity with equal level spells in other schools, such as tornado or shatter (since killing groups of monsters quickly is a pretty good form of defense). It is true that it could be used in consort with other summon spells to increase its impact, but the same is equally true of pairing tornado with other conjurations. A level 9 spell is a huge investment and its impact should be equally huge, which does not seem at all the case at present. When testing it against other equal-level spells in a range of realistic combat scenarios, Summon Dragon takes more time to defeat even modest encounters than its peers (often much more), while generally exposing the player to more danger in the process (both due to its delay in killing ranged threats and also that you can no longer form an effective screen of dragons with only 2 of them lasting more than a couple turns). In many cases, the difference is extreme. And the fact that the dragons last forever is of limited practical advantage (except in resisting monster abjuration). Raising its summon cap might address this somewhat, but rather than simply making it more spammable in the old sense, I have decided to give it behavior which further distinguishes it from common summon spells while making it suitably impactful for its spell level and the investment that represents. Summon Dragon is replaced by Dragon's Call, which gives the player a temporary status that will continuously summon in dragons adjacent to and attacking random hostiles within the player's LoS. These dragons have an individually short duration and will appear only while hostiles are present (so you cannot build up an army while outside of battle, nor carry your previous army from battle to battle unless they occur with only short delay between them). The delay between summoning each new dragon is proportional to how many you already have, meaning that they will arrive more quickly when you have none, and much more slowly while several are already active. Each new dragon summoned costs the caster a small amount of mp, and the effect will end if you run out. Also, it generates a continuous amount of noise while the status lasts. Finally, there is a somewhat lengthly cooldown between times the effect can be activated. The effect is definitely strong, as befits a level 9 spell, but interestingly it also excells at slightly different situations than other level 9 spells do. It is distinctly less powerful against massed groups of foes, but potentially stronger against a series of moderate to small encounters back-to-back due to its duration. And it definitely (to me, anyway) feels splashy in a way that a level 9 spell ought to. Of course, numbers are still provisional, as always. (For now I have retained the original Summon Dragon as a monster spell, as much of the additional complexity of Dragon's Call does not add much to a monster version over just summoning a couple more dragons in the usual manner)
* Don't print spell enhancer messages for aborted Summon ForestDracoOmega2014-03-061-0/+6
| | | | If you attempt to cast it while the spell is already active.
* Rod of demonology -> Rod of shadows.Steve Melenchuk2014-02-261-1/+8
| | | | | Weaves shadow creatures roughly from D:<evocations power> (including out-of-depth D depths).
* Rod of frigid destruction -> Rod of clouds.Steve Melenchuk2014-02-261-0/+4
| | | | | | | | | | | Sprays clouds over a cone-shaped area in front of the caster. At low power it gives rain, mist, or noxious fumes; mid-tier gives flames, freezing vapour, or poison gas; high-tier gives one of three new cloud types - acidic fog, negative energy, or storm clouds. The targeter is from an experimental implementation of a spell called "Scattershot", hence the name and some of the functionality it provides which goes unused here.
* Glaciate.Steve Melenchuk2014-02-251-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Level 9 Conjuration/Ice; generates a cone-shaped great blast of ice around a specified target. The minimum range of the cone is 3, and the maximum is LOS at maximum spellpower; damage within a minimum-range cone is equivalent to Ice Storm, and falls off with the square of the distance for larger cones. Leaves freezing clouds over the affected area, like Ice Storm; they dissipate really quickly over large areas, though. Targets hit with Glaciate are flash-frozen; they are subject to slow movement for three turns. Targets killed with Glaciate have a 3/5 chance of becoming a block of ice (similar to a pillar of salt). Also contains a monster-castable version of the spell. Replaces Ice Storm; most of Ice Storm's code disappears (ZAP_ICE_STORM is TAG_MAJOR_VERSION == 34'd out). Go fight Lom Lobon to see the monster version. Large chunks of this either originate from a patch from Keanan Smith (Siegurt), seen at https://crawl.develz.org/mantis/view.php?id=7760, or from the following discussion on Tavern: https://crawl.develz.org/tavern/viewtopic.php?f=8&t=9854