| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
If a monster is constricting a victim, don't allow it to use a spell
or ability that would knock the victim back, thus breaking the
constriction.
I made this commit when I was considering giving op crushers primal
wave, an idea that I dropped, but the check should still be there, and
this does move otherwise duplicated code to a single method.
|
| |
|
|
|
|
| |
and also change a temporary variable name to avoid overshadowing
|
|
|
|
|
|
|
|
| |
It's an antimagic enchantment, borrowing the code from melee antimagic
(which now internally refers to the new beam type).
I have a vague notion that this might remove antimagic effects from the
caster at some point, but that's for later.
|
|
|
|
|
| |
...which turned them into "do you have a wand of disintegration" check
and nothing more.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Poisoned needles deal more poison damage; curare has its effect
amplified; duration-based needles have their durations extended (except
frenzy, possibly for now).
The needle of paralysis hits the stone giant in a vulnerable spot!!!!
This code might have some side effects based on the dur paramater of
enchant_monster_with_flavour being meaningful for the duration-base
needle enchantment types; if so, that'll need fixing.
|
|
|
|
|
|
|
|
|
|
|
| |
Launchers use the equivalent melee brand effects if the missile isn't an
elemental brand (or the attacker is Nessos).
Missiles have their own set of effects; flame, frost, and poison use
effects basically identical to weapon brands, and everything else has
its old effect back.
The lajatang of Order works again. Hooray!
|
|
|
|
|
|
|
|
|
|
| |
Moves a lot of code from melee_attack to attack to be shared with ranged
weapons.
Handles the entire basic attack process - checks to-hit, calculates
damage, prints messages as necessary.
TODO: attack delay, brands.
|
|
|
|
|
|
|
|
|
| |
Adds bolt_parent_init() which copies the most useful set of properties
from a "parent" beam to a "child" beam. Use this in three relevant
places in beam.cc where lots of individual property copying was done.
I've also moved the enchant power setting bits for teleport self and
sleep to a more reasonable place.
|
| |
|
|
|
|
|
|
| |
If the monster wasn't valid or was too close to dead.
It's still possible to waste turns if you fail the check for success,
though.
|
|
|
|
|
|
|
|
| |
Thus, bolts of penetration (and arrows of penetration from Piercer), but
not large rocks.
In my brief testing this is not extremely noticeable, but the times when
it is should make all the difference.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Make Zhor have rC+++ (as it is it has some trouble competing with a robe of
resistance)
* Make Leech drain hp on all hits, rather than 3/5ths like other vampiric
weapons
* Bring back Sniper: it's a +15 vorpal crossbow with slower fire (ranged dark maul)
* Bring back Snakebite: it's a +5 venom dwhip that curares the defender on 1
out of 5 hits
* Make the Singing Sword a bastard sword (this is fairly big buff, but it still
has no brand)
* Remove Bullseye, give Gong 21 more SH and 5 less EV (remaining a normal-sized shield)
|
|
|
|
|
| |
Sometimes, they're there to emphasize a break between two sections of code,
which is good. In a majority of cases, though, they're just inconsistent.
|
|
|
|
| |
See Mantis for discussion.
|
|
|
|
|
|
|
|
|
|
| |
Being able to awaken trees and pull you next to them is a strong
combination on its own, it's not necessary for them to also hide in the
trees while doing so.
Removes a lot of code for handling wall movement since rock worms are gone
too, but leaves HT_ROCK - it appears that spatial maelstroms sort-of-use
it (not sure if they actually need it, though).
|
|
|
|
|
|
|
|
|
| |
Also simplify quite a few cases.
It turns out in >90% cases of non-literals the argument had .c_str(),
which meant it was pointlessly malloc()ed and converted from and to
std::string. I believe a sprintf is faster, so even the argument of
miniscule speed-up doesn't apply.
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the effect was unpredictable but the source was known to be
unpredictable, set beam.effect_wanton, and use that instead of just
effect_known to determine whether gods should assign blame.
There are only a few remaining direct uses of effect_known; perhaps
they are no longer needed?
Also, don't treat contamination from haste or invis as intentional
unless it was the player who cast the spell.
|
|
|
|
|
|
| |
We were checking the weapon of the beam's agent(), but reflected beams
returned the reflector, not the original agent. Add a new parameter
to bolt::agent() to handle this.
|
|
|
|
|
|
|
|
| |
This updates the beam code to check for the impact of a cloud forming at
the beam's endpoint, and updates the player implementations of the cloud
spells to fire a tracer cloud at that endpoint; thus players will be
warned for targetting themself and/or allies, and monsters will take
allies into consideration when using cloud spells.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Previously there was no way for beam targeters to know that they could never
hit certain things, such as orbs of destruction or plants under Fedhas and
would imply that explosion spells would terminate upon them, if the player was
trying to aim through them. Now they should properly match the path the beam
will actually take.
|
|
|
|
|
|
|
|
| |
Since 1f7c9b4d, if you know even a couple beam spells, you need to go
through several --More--s every time a spell list is shown.
These tracers are not really useful for debug purposes as you can get a
regular tracer if you want, so there's no reason to show them all.
|
|
|
|
|
| |
The result was almost always 0, and even if it was not, its value was not
meaningful in any way, due to floorings.
|
|
|
|
| |
No functionality changes here, as melee always use regular AC rules.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I had to rename distance() (in coord.h) to distance2() because it conflicts
with the STL function to compare 2 iterators. Not a bad change given how it
returns the square of the distance anyway.
I also had to rename the message global variable (in message.cc) to buffer.
I tried to fix and improve the coding style has much as I could, but I
probably missed a few given how huge and tedious it is.
I also didn't touch crawl-gdb.py, and the stuff in prebuilt, rltiles/tool
and util/levcomp.*, because I have no clue about those.
|
|
|
|
|
|
|
|
|
| |
This involves a substantial overhaul of targetter_beam to retain more
information about the beam, and changes to tracers to allow that
information to reach all the way into the relevant depths of the beam
code.
Fixes #6020.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The old system merely added a bonus range square for certain spells,
which led to issues in some edge cases.
The new check employs tracers to see if targetting anything within range
will actually harm an enemy.
Cloud spells (other than Mephitic Cloud, which is more akin to a
Fireball in its implementation) aren't handled by either the new or the
old system, but they probably could be worked in with some additional
effort.
Fixes #2068.
|
|
|
|
|
|
|
|
|
|
|
|
| |
If you aimed a beam targetter (including IMB and Fireball) past a
statue, every move of the targetting cursor would prompt about whether
you really want to shoot when your fire is blocked. The code checks for
thing like BEAM_VISUAL, but we use the real beam type to properly
resolve bouncing etc. Instead, add a new flag is_targetting and use
that for the beam targetters.
The smite and LRD targetters don't set is_tracer and is_targetting;
perhaps they should for consistency.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
IMB tracers now account for the possible explosion, so that the player
will get appropriate warnings and IMB-wielding monsters will consider
the affect that the spell could have on allies. Thus, this fixes
0005823.
There's also now a dedicated targetter for IMB, employing the same code
to determine what squares can be affected as the tracer, which has been
split out from the relevant section of the beam code.
Finally, on account of the above split, the IMB explosion code itself is
now a bit cleaner.
|
|
|
|
|
|
|
|
|
| |
Bugs fixed:
* white draconian breath worked differently vs players and monsters
* tracers didn't know about triple AC reduction
* AC was queried many times (needs to scan all armour, etc)
Bugs added:
* ook? I bet there's something :p
|
|
|
|
|
| |
This also reveals how bad the beam blaming code is, need to rewrite that soon
-- mostly because of problems with reflection.
|
|
|
|
| |
It's a no-brainer to read-id unknown scrolls next to a kobold.
|
|
|
|
| |
And makes it harder to get rid of cleanup_dead = false.
|
|
|
|
|
| |
Fixing it is possible -- if you want that, please revert this commit and do
the work, using the new melee design.
|
|
|
|
| |
It still a bit slow, but it works.
|
|
|
|
|
|
|
| |
Also remove the teleport and change behaviour. Speed is reduced to 8 so they
are still easy to escape.
They start being generated at dungeon level 7. Any item has 1 chance in 500 of
being a mimic.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Profane servitor: An angel twisted into an undead monster by
Yredelemnul. He gifts these as a new tier above bone dragons. They are
in Yred's elemental colors, generated wielding a demon whip, probably
slightly better than a bone dragon in melee, and have res holy instead
of holy vuln like most undead. It also generates an umbra. Only Yred
gifts spawn them currently though they'd be great for some vaults.
umbra: An 'antihalo' composed of flickering darkness, which is the
opposite of a halo. Creatures in an umbra are harder to hit with both
ranged/melee, but get a stealth bonus. Currently only profane servitors
generate an umbra. Demons, undead, and worshipers of Yredelemnul
(at **+ for players, but all monsters) aren't harmed by an umbra but
still get the stealth boost.
The patch also changes the "Glow" status light to "Contam", and displays
"Glow" when actually backlit (for whatever reason: halo, sticky flame,
corona).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a significant refactoring. All the spells now return a spret_type and
take a boolean which tells if the spell has actually failed.
Also some code clean up in _do_cast(). All spells have their own function now.
Also fix the following bugs:
* Properly abort fire storm if forced casting on a wall with '!'.
Also put a message for forced out of range casting (like cloud spells).
* Casting summon elemental on an invisible monster aborted with no cost.
* if a summoning spell aborts because create_monster fails, you don't lose a
turn. You still get a chance of miscast in this rare case.
* s2s, tukima and branding spells abort properly instead of consuming turn and
MP when player is not wielding appropriate object.
* s2s abort message when wielding a non-snakable.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
The physics works well in other cases, and here it works realistically.
Too bad, this leads to quirky play where players spend too much time lining
up shots into corridor entrances. How to hit someone twice is intuitive,
how to do that thrice is not.
A surprise one-turn death from a wand or an elf mage is not that fun either,
double hits keep staying out of bounces vital while putting a cap on deadliness.
It does nerf early AEs, we may want to compensate them somehow.
|
|
|
|
|
|
|
| |
"File:" is shown in your editor's status bar.
"Written by:" was used only for the first person who changed a file. We got
git for that now, and pre-DCSS history is so woefully inaccurate it doesn't
really matter.
|
|
|
|
|
|
| |
This fixes Injury Mirror not working for delayed damage, kills done
by undead/demon allies not counting as such, damage tracking not handling
ench damage, etc.
|
|
|
|
| |
oklob plants will use ranged attacks on high-AC targets.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
I did review it manually to find places where they made sense (like some
tables), but for a massive sed job like this there might be places that
I missed.
|