| 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!
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
64-bit luajit doesn't support lua_newstate or custom allocators, so don't
try to use one there. However, give a warning if this happens with a
webtiles or dgamelaunch build, because servers probably do want the
memory throttling.
|
| |
|
| |
|
|
|
|
|
| |
map or set.count() can test the presence of a given key and return 0 or 1
outright.
|
| |
|
|
|
|
|
|
| |
This might be portability for portability sake (Solaris is so dead), but
come on, we can't disappoint Igor Pashev by porting our stuff later than
several hours after the first installable build of Dyson is released :)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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 is incomplete, partially because of me getting bored, partially because
of doubts about the point of leaving simple addition/etc in parentheses.
|
| |
|
| |
|
|
|
|
| |
For way too paranoid and underinclusive values of "simple".
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
You are free to not use their functionality, load a private modified
version, etc, leaving the default version dormant -- and harmless.
This removes the need to manually update your config whenever such a lua
file is removed or added. They are a part of the game itself now, being
written in lua is a hidden implementation detail.
There is one file left: lua/kills.lua, it produces spammy dumps not everyone
wants. Perhaps it should be always loaded, but disabled unless someone uses
an option?
|
|
|
|
| |
Also, it's not vulnerable to changes to the underlying types.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
util/gen_luatags.py will now generate dat/dlua/tags.lua. It's pretty
simplistic at the minute -- just mapping the relevant TAG_MINOR_XXX to a
numeric value. This is obviously not automated, and will need to be run
whenever you update tag-version.h /and/ wish to be able to access one of
those tags from Lua.
It could do more fancy things, I suppose, but having it simple for now
solves a relatively minor issue which could, in theory, become more
prevalent if or when we start modifying markers more regularly. At the
very least, it means we don't need to bump the major version every time
I change a fog machine parameter.
|
|
|
|
|
| |
There might be places where dlua is referred to as clua internally,
and in many places "clua" means "lua in general".
|
| |
|
| |
|
|\
| |
| |
| | |
Conflicts galore...
|
| |
| |
| |
| |
| | |
ASSERT("...") never fails, but let's pretend that in these cases, a failure (as
produced by die()) is intended.
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
REGRESSION: errors say:
Lua error: [string "/home/kilobyte/crawl/crawl-ref/source/meow"]:2: moo
rather than
Lua error: /home/kilobyte/crawl-0.7/crawl-ref/source/meow:2: moo
|
|\| |
|
| |
| |
| |
| |
| |
| | |
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.
|
|/
|
|
|
| |
Only iostreams functions are left; on Windows they don't support Unicode
so a workaround will be needed.
|
|\ |
|
| | |
|
|/ |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and recompiled by new Crawl processes while older processes are running.
When mapdef.cc detects that a .dsc file is out of sync, it throws an exception
that dungeon.cc catches. dungeon.cc then discards all loaded maps and reloads
then from the map index (.idx) files.
The old behaviour was to create a panic save and exit for out-of-sync .dsc
files, which is not ideal since the panic save code is rarely used and tends to
bitrot.
When regenerating text database files in DGL installs, the game no longer
unlinks the old .db file, and will instead update the old file with the
new db keys.
None of this code should be relevant to single-user installs.
|
|
|
|
| |
considerably reduces heap use in the first Crawl process to run in a fresh install.
|
|
|
|
|
|
|
|
|
|
|
| |
We were only setting it to "\r\n" on DOS, but according to commens
in #1045, DOS will translate "\n" to "\r\n" automatically for
text output.
Also, the DOS EOL handling was likely broken anyway looking at how
a lot of the linebreaking code only considered "\n".
Fixes issue #1045.
|
|
|
|
| |
These are marked as 'I'.
|
|
|
|
| |
The pickup code was pushing item_defs as lightuserdata instead of a wrapped item userdata, and item.can_cut_meat() should have been written item.can_cut_meat.
|
|
|
|
| |
known matching clua (this can happen when coroutines are involved).
|
|
|
|
| |
only on the same turn the items were wrapped for Lua by the core C++ code.
|
|
|
|
|
|
| |
immediately cast
to std::string.
|
| |
|
| |
|
|
|
|
| |
This allows Lua hooks to say they don't have an opinion.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently only includes:
rectangle_iterator: iterates points between two corners.
los_iterator: iterates over currently visible points in LOS.
adjacent_iterator: iterates over adjacent points to the center.
Most iterators accept a "filter" parameter that is a function which
should either return true if the point is acceptable for the iteration,
or false if it is not.
los_iterator is currently restricted to player LOS rather than actor or
monster LOS, but could be expanded at a later date.
All of the iterators seem to work as intended: hopefully I haven't made
too many mistakes with them.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
simultaneously.
synchronized_markers() takes a marker, and a list of method names to override,
and returns a set of markers that fire simultaneously, to allow, say, fog
machines that fire at random intervals, but always fire in unison. lm_mslav.lua
has details. volcano.des has an example volcano entry vault that uses this.
Allow fetching a list of Lua markers/marker positions by property value.
Renamed dgn.find_marker_prop -> dgn.find_marker_position_by_prop.
s/helper/listener/ for fog machine listeners.
|
| |
|