| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
.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!
|
| |
|
|
|
|
| |
And de-indent l_item_do_subtype() slightly.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This function was misleadingly named (it only provided the skill
used for melee weapons, not ranged weapons), and incomplete;
code along the lines of "is_ranged_weapon(*it) ? range_skill(*it)
: weapon_skill(*it)" was scattered in about half a dozen different
functions. I've corrected both of those problems (renaming weapon_
skill() to melee_skill() and adding item_weapon_skill()), and also
possibly fixed two bugs in the process - an l_you.cc function that
claimed to provide the skill used for the starting weapon (but
actually only gave the melee skill), and unrand creation code that
checked if a potential unrand swap used the same (melee) skill as
the weapon type being generated.
|
|
|
|
|
|
| |
[Committer's note: removed handling of plus2 in lm_trove. This
will need to be reverted if anyone ever wants to make troves ask
for rods.]
|
|
|
|
|
|
|
|
|
|
| |
Phase out ARTP_ACCURACY, rename ARTP_DAMAGE to ARTP_SLAYING which now
combines both Acc+ and Dam+ bonuses.
Bracers of archery are +4 now instead of +5,+3.
[Committer's note: fixed a description and cleaned up various other
small issues.]
|
|
|
|
|
|
| |
The amulet of conservation and cloaks of preservation are no longer
necessary without item destruction. Maxwell's patent armour now has
the resistance ego and grants rF+ and rC+.
|
| |
|
|
|
|
|
|
|
|
| |
This affects porridge for most races and blood for vampires, though since
everything in the actual food class is usually irrelevant as "food" for
vampires, they're probably better off searching for blood anyways.
Expose is_preferred_food to lua for the stash annotation code.
|
| |
|
|
|
|
|
| |
Purpose of this is allow finding for example helmet of see invisible by
searching for "SInv".
|
| |
|
|
|
|
|
|
| |
While this is not explicitly mentioned as a rule in coding_conventions,
all examples listed there apply it as well. The dungeon.cc chunk did
overflow max. columns before already, but could still be looked at.
|
| |
|
| |
|
|
|
|
|
| |
The only reason for this madness was so searching for "ident" doesn't
find identified items.
|
| |
|
|
|
|
|
| |
The perl one-liner I use for this had a bug where it didn't match "else"
at the end of a line (ie, most of the time).
|
|
|
|
|
|
|
|
|
|
| |
For most header files, this only saves on having to recompile a
small number of source files, but there are also a few headers
where small changes would now take significantly less time.
This is most obvious for the Tiles build for which the dependencies
have been greatly reduced, so that the only additional includes
when compared to console are strictly library or tile related.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
| |
Without Evaporate, they lost their last use.
|
|
|
|
|
| |
This is incomplete, partially because of me getting bored, partially because
of doubts about the point of leaving simple addition/etc in parentheses.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Both were scalars compatible with int, and both used the name "reach_range"
is some cases. Thus, let's use 2/5/8 everywhere.
This probably makes the enum obsolete.
|
| |
|
| |
|
|
|
|
| |
Also, it's not vulnerable to changes to the underlying types.
|
|
|
|
|
| |
jewellery_type_name doesn't have an array to expose, would need to fix it
later.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
They have about no overlap, more than both being usable as weapons. A vast
majority of uses immediately checked item_is_rod()/item_is_staff().
I kept them shared for acquirement, for now.
Also, eliminate rods of smiting -- hardly ever used, problematic theme-wise
as they use "divine providence" without worship. Keeping rods of striking
for now, could be used to fix artificer problems. Adding/removing rod enums
is a mess due to tile handling, renaming ROD_SMITING to ROD_LIGHTNING for now.
|
|
|
|
|
| |
It really needs to be ripped out and rewritten, with a stress on making the
formulas sane.
|
|
|
|
| |
We shouldn't return enum values ever anyway.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Like full_describe_view(), we get the extra items from the stash
tracker; on untracked levels we can get only the top.
Difficulties arise because the stash tracker returns item_defs on the
stack where they cannot safely be pointed to. To handle this properly,
item_wrapper gains a new boolean member indicating whether the item_def
is a temporary copy (as opposed to an element of mitm, for example); a
new C function clua_push_item_temp() allocates a copy of an item_def and
creates such a wrapper. If the temporary flag is true, the item_def
will be freed when the wrapper is GCed.
|
| |
| |
| |
| |
| |
| |
| | |
It doesn't actually work for any items but the top yet, but at least the
interface won't change.
This reverts commit 198c943b116acfd9a1997c48073f29e520e7c0c4.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Returns an item or nil. This avoids leaking information about items
at the bottom of an unvisited pile. For the same reason, do not return
anything from an invisible pile (e.g. one at the bottom of deep water
for non-swimmers).
It would be nice to use the stash to return an entire visited pile,
but there doesn't seem to be a way to get a semi-permanent pointer
to an item_def in the stash.
|
| | |
|
|/ |
|
| |
|
|
|
|
|
|
| |
We shouldn't try to fire a melded bow, or reach with a melded polearm.
Fixes #5026.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
The only place that can legitimately have a non-letter is the lua function,
and it'll now return -1 in that case. Most of the others had isaalpha()
already.
It's possible I missed some case and the asserts will now crash, but if so,
they'd re buggy anyway (accepting digits and interpunction as slots).
|
|
|
|
| |
There's no point in using a std::string here at all.
|
|
|
|
|
|
|
| |
Added several Lua-callable functions for enhanced reasoning about items,
monsters, and player state.
Signed-off-by: Jude Brown <bookofjude@users.sourceforge.net>
|
|
|
|
| |
Bug introduced by 294db2cc.
|
|
|
|
|
| |
The keywords are:
cloak helmet gloves boots shield body
|
| |
|
|\ |
|