summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/state.cc
Commit message (Collapse)AuthorAgeFilesLines
* Trim unnecessary #includes.Adam Borowski2010-01-131-1/+0
|
* Add general formatted_string::add_glyph, remove others.Robert Vollmert2009-12-011-1/+2
|
* Remove multi-purpose Options.mlist_targetting.Robert Vollmert2009-11-231-0/+4
| | | | | | | | The option is now just a boolean option, and whether we're actively targetting with the mlist is stored in crawl_state.mlist_targetting. Also remove some duplication of mlist logic from direction().
* Rename tutorial_first_monster to tutorial_monster_seen.Robert Vollmert2009-11-231-1/+1
| | | | It's not just used for the first monster.
* Add an option, -builddb, to build the database and exit.Adam Borowski2009-11-221-1/+1
|
* Add formatting fixes.David Lawrence Ramsey2009-11-211-2/+2
| | | | This mostly puts && and || on the proper lines, per the style guide.
* Move tutorial state out of Options.Robert Vollmert2009-11-161-1/+1
|
* Simplify out-of-range darkening.Robert Vollmert2009-11-161-1/+2
| | | | | | | | | | | | | | | Also fixes the range_view_annotator destructor clobbering option "darken_beyond_range". Options.target_range is now really an option, and called Options.darken_beyond_range. Current darkening range is now stored in crawl_state.darken_range. I can't reproduce SIGHUP retaining darkened range (BR 2151183) (why would it be saved?), so range_view_annotator is not a crawl_exit_hook anymore. crawl_exit_hook is not used anymore, but still present.
* Remove obsoleted los.h includes.Robert Vollmert2009-11-131-1/+0
|
* Replace observe_cell by you.see_cell.Robert Vollmert2009-11-131-1/+1
|
* Remove a few obsolete includes.Robert Vollmert2009-11-101-1/+0
| | | | Also add a few previously indirect includes.
* Remove some obsolete view.h-includes.Robert Vollmert2009-11-101-1/+0
|
* Split shouting and stealth code from view.cc.Robert Vollmert2009-11-101-0/+1
|
* Split up debug.ccMatthew Cline2009-11-061-0/+1
|
* Replace global see_cell by observe_cell and disambiguate old uses.Robert Vollmert2009-11-061-1/+1
| | | | | | | Calls to plain see_cell(pos) were replaced with either observe_cell(pos) or you.see_cell(pos). observe_cell where related to drawing the interface and messaging, you.see_cell for game mechanics, and one or the other in less clear cases (targetting, say).
* Split game_options from externs.h into options.h.Robert Vollmert2009-11-041-0/+1
|
* Interrupt less often when repeating wiz commandsMatthew Cline2009-10-301-0/+17
| | | | | Interrupt/cancel command repetition less often when repeating a wizard command.
* Fix missing include (caught by BuildBot).Robert Vollmert2009-10-271-0/+1
|
* Rename actor::visible to actor::observable.Robert Vollmert2009-10-221-1/+1
| | | | | | This should reduce potential for confusion -- compare mon->visible() and mon->invisible(). The uses of actor::visible for messaging are replaced by actor::observable, others by you.can_see(...) or actor::visible_to(&you).
* Get rid of player_monster_visible.Robert Vollmert2009-10-221-1/+1
| | | | | | The special casing for drowning monsters appears to have been obsoloted by checking ENCH_SUBMERGED instead of calling mons_is_submerged.
* versioning: remove SVN-specific revision data, add Git versioningSteven Noonan2009-10-181-1/+0
| | | | Signed-off-by: Steven Noonan <steven@uplinklabs.net>
* Globally replace see_grid by see_cell.Robert Vollmert2009-10-171-2/+2
|
* Remove a lot of unneccessary includes.Robert Vollmert2009-10-091-1/+0
| | | | | | | The console version still compiles on Linux; both console and tiles version compile in OS X. I haven't been able to test the DOS and Windows compiles -- please fix or tell me about any errors that show up.
* Split LOS code from view.cc.Robert Vollmert2009-10-081-0/+1
| | | | | | | | | los.cc: basic raycasting algorithm; losight(), see_grid() etc. ray.cc: ray_def implementation. mon-los.cc: monster_los This includes adding a bunch of #includes; there's probably some obsolete includes of view.h now.
* Drop obsolete CVS last-committed headers ($Author$).Adam Borowski2009-10-061-2/+0
|
* * More steps on the path to reintroducing player doll customization.j-p-e-g2009-06-171-0/+3
| | | | | | | Also apply my two previous commits to trunk. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9995 c06c8d41-db1a-0410-9941-cceddc491573
* * Rarely, allow randart books to use entirely random names.j-p-e-g2009-03-081-1/+1
| | | | | | | | | * Use monsters' 'x' descriptions as inf.title when hovering your mouse over monster tiles. * A bit of code cleanup. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9385 c06c8d41-db1a-0410-9941-cceddc491573
* Don't pass number of columns to print_formatted_paragraph(), since it alwaysharanp2009-02-041-1/+1
| | | | | | | | uses the width of the screen anyway. Have print_formatted_paragraph() respect delay_message_clear. Fixes [2492045]. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8894 c06c8d41-db1a-0410-9941-cceddc491573
* When crashing, dump information about the player.zelgadis2009-01-281-0/+5
| | | | | | | | When crashing, dump information about the current level, and if the crash happens during level generation dump which vaults were placed. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8838 c06c8d41-db1a-0410-9941-cceddc491573
* Move the monster dumping code from state.cc to debug.cc, and dump to stderr tozelgadis2009-01-281-242/+36
| | | | | | | reduce the need to pass a file pointer all over the place. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8837 c06c8d41-db1a-0410-9941-cceddc491573
* If a crash happens with a currently acting monster then dump information on thezelgadis2009-01-271-7/+216
| | | | | | | monster, its foe and its target. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8815 c06c8d41-db1a-0410-9941-cceddc491573
* Fix repeated messages when getting HP/MP restored interrupts withharanp2009-01-251-2/+2
| | | | | | | | | | | multiple delays queued (e.g., when butchering several items.) However, this fix means that Lua can't suppress the "HP restored" message on the relevant interrupt. If this is a problem it should be changed. Fixes [2494104]. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8749 c06c8d41-db1a-0410-9941-cceddc491573
* Include the Lua stack trace and currently acting monsters in the crash report.zelgadis2009-01-221-0/+15
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8694 c06c8d41-db1a-0410-9941-cceddc491573
* Was using wrong method to get the last element of a vector.zelgadis2009-01-201-2/+3
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8624 c06c8d41-db1a-0410-9941-cceddc491573
* Make extra-sure that a monster won't be announced to have come into view, onlyzelgadis2009-01-201-0/+55
| | | | | | | | | | | | to immediately move out of view, by introducing the notion of the currently acting monster to crawl_state, and only flushing out the "comes into view" message in mpr() for the currently acting monster. Not sure if it's worth it just for the sake of avoiding doing a "has this monster just now come into view" check in every place that a monster might issue a message, but at least this way we won't miss any places such a check should be placed. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8623 c06c8d41-db1a-0410-9941-cceddc491573
* Add whitespace fix.dolorous2009-01-191-1/+1
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8584 c06c8d41-db1a-0410-9941-cceddc491573
* When dumping info upon a crash:zelgadis2009-01-181-20/+21
| | | | | | | | | | | | * For Unix builds, shut down curses in case the crash reporter can't open up a file and has to dump the crash directly to stderr. * Include all saved messages in the crash report. * Use EOL instead of \n or \r\n. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8535 c06c8d41-db1a-0410-9941-cceddc491573
* Implemented crash data reporting, though it's only some stubs on Windows andzelgadis2009-01-181-1/+75
| | | | | | | | | | | | | | | | | | | | | | | DOS. On UNIX with USE_UNIX_SIGNALS defined, when any crash causing signal happens it will dump to a file the current crawl_state, anything caught by the items and monsters scans, and level building info if the crash happened during level generation. Also, if crawl is linked against the GNU C library (and the exectuable is in ELF format) it will dump the stack trace. The code attempts to automatically detect the presence of glibc, but that might not work on all systems. This should work on OS X, since there's an OS X man page for the glibc functions that get the stack trace. Don't know if it would work with MinGW. Actually getting function names for the stack trace requires the use of the "-rdynamic" linker option, which increases the size of the stripped executable by 27% (yikes!), but still prints the function names even when stripped. All of the function names in the stack trace are mangled C++ ones, but that shouldn't be too much of a problem. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8532 c06c8d41-db1a-0410-9941-cceddc491573
* A limited set of commands are now available to use during arena mode:zelgadis2009-01-111-7/+7
| | | | | | | look around ('x'), message history (Control-P) and suspend game (Control-Z). git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8408 c06c8d41-db1a-0410-9941-cceddc491573
* Adding REVISION() macro to all source files.ennewalker2009-01-041-0/+2
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8217 c06c8d41-db1a-0410-9941-cceddc491573
* Add arena mode, activated on the command-line by 'crawl -arena "monster v ↵dshaligram2008-12-311-1/+1
| | | | | | monster"' (eg: crawl -arena "Sigmund v Jessica") to let monsters fight each other undisturbed by the player. Good to examine monster AI and monster behaviour when the player is AWOL. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8059 c06c8d41-db1a-0410-9941-cceddc491573
* Fix re-do/repeat command not working with commands that targetted a monster.zelgadis2008-12-241-0/+12
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@7926 c06c8d41-db1a-0410-9941-cceddc491573
* Fix the ASSERT when undetected traps run out of ammo and display "Youj-p-e-g2008-11-091-1/+0
| | | | | | | | hear a click" instead of "The trap is out of ammo". Also, fix the miscolouring of the lua eating prompt. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@7428 c06c8d41-db1a-0410-9941-cceddc491573
* So many files? That's probably some debugging messages included,j-p-e-g2008-11-091-0/+1
| | | | | | | | | | | | | | | | | | again... Anyway, I added a check to make sure that monsters that somehow end up in deep water (confusion!) can get out of it again if not aquatic. Monsters that can drown, will still do so, of course. I also removed the drowning conditional for zombies and skeletons. They'll now slog invisibly underwater and eventually reappear in shallow water or dry land. I think this is more interesting than making them drown. That, and they've seen a lot of nerfs lately. Oh, right, and I replaced some ENCH_SUBMERGED with mons_is_submerged(), that might explain the number of modified files... git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@7427 c06c8d41-db1a-0410-9941-cceddc491573
* Remove pre-Stone Soup change history from source files, and push it allj-p-e-g2008-09-141-4/+0
| | | | | | | | | | into a file crawlhistory.txt in docs/obsolete. I used a perl script to do this under the assumption that all these change logs used the same system following the keyword "Change History". git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6930 c06c8d41-db1a-0410-9941-cceddc491573
* Massive overhaul to move towards coord_def().haranp2008-07-301-2/+2
| | | | | | | | | | This might have introduced some bugs: I now get intermittent crashes on startup (this might have to do with the changes to special_room.) Sorry about that - committing before I need to do any more big conflict resolutions. Fixes coming later. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6732 c06c8d41-db1a-0410-9941-cceddc491573
* Misc. minor cleanups. (Yes, a huge amount of them but still...)j-p-e-g2008-06-261-17/+18
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6146 c06c8d41-db1a-0410-9941-cceddc491573
* Twelve new tutorial events, plus examining a square with a cloud orzelgadis2008-05-291-5/+0
| | | | | | | | | | | | | | | | | | | a monster submerged in shallow water will give extra info during turorial mode. Might be giving too many spoilers, especially the tips on surviving in the Abyss and saying exactly what each god likes and dislikes when covnerting. There's a bug in non-tiles build where the tutorial note on branch entrances shows the '>' symbol as light-grey instead of yellow; don't know what's causing that. Also, made player::backlit() used _get_contamination_level() to stay in sync with the rest of the code. Breaks savefile compatibilty. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@5320 c06c8d41-db1a-0410-9941-cceddc491573
* Add whitespace fix.dolorous2008-04-271-1/+1
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4707 c06c8d41-db1a-0410-9941-cceddc491573
* Add whitespace fix.dolorous2008-04-251-1/+1
| | | | git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@4613 c06c8d41-db1a-0410-9941-cceddc491573