summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/files.cc
Commit message (Collapse)AuthorAgeFilesLines
* Trim unnecessary #includes.Adam Borowski2010-01-131-1/+0
|
* Don't create name.tdl files in non-tiles builds.Enne Walker2009-12-291-7/+0
| | | | | There is no reason to create this file if it doesn't exist. This should prevent extraneous files being created on servers.
* Only inform wizmode players about lack of ghosts if they want to load one.Johanna Ploog2009-12-201-2/+2
|
* Replace long debug message calls with dprf(), except for cases where a dumb ↵Adam Borowski2009-12-201-3/+1
| | | | | | compiler could call unnecessary functions. For paranoia, I left even any uses of std::string.
* Replace static snprintf() with make_sprintf() where the result is ↵Adam Borowski2009-12-171-3/+1
| | | | | | immediately cast to std::string.
* tiles: only include tiledef-*.h in files where they're neededSteven Noonan2009-12-121-0/+3
| | | | | | | This eliminates the annoying full rebuild that happens when the tiledefs are modified. Signed-off-by: Steven Noonan <steven@uplinklabs.net>
* add a --save-version option for checking a player's save file versionJesse Luehrs2009-12-121-8/+18
|
* Add brackets.Johanna Ploog2009-12-081-2/+3
|
* Make death effects unaffected by polymorph.Jude Brown2009-11-281-2/+12
| | | | | | | | | Polymorphing either Pikel, Kirke or Duvessa/Dowan rendered their death effects useless, as it checked monster->type and not the original monster (ie, monster->mname). Instead of checking monster->mname, though, store the name in monster->props, to stop sorear complaining.
* Remove header includes from mon-place.h.Robert Vollmert2009-11-271-0/+1
|
* Remove further header-include. env.h now always directly included.Robert Vollmert2009-11-271-0/+1
|
* Remove unportable hacks from the invocation of tar.Adam Borowski2009-11-251-3/+32
|
* Quiet save-and-quit Valgrind leak warningsMatthew Cline2009-11-251-10/+27
| | | | | | | Split save_game() code which allocates std::string's on the stack out into seperate functions, so they'll go out of scope and be free'd before end() is called, thus getting rid of the spurious complaints Valgrind gives.
* Name the file of an invalid save (http://bugs.debian.org/498080)Adam Borowski2009-11-251-1/+1
| | | | | | Really, we'd want to ask the player whether to discard the save, but at that point the interface is not yet initialized, and I'm not sure how to do this to make tiles happy.
* Remove a save compat hack for major tag 6 (we're in tag 8 already).Adam Borowski2009-11-251-18/+0
|
* Redraw view window earlier when entering a new level.Robert Vollmert2009-11-211-1/+4
| | | | | In particular, before update_level is called. This prevents monsters being shown acting on the previous level.
* player ghosts: bugfix, debugging/diagnosticsMatthew Cline2009-11-211-23/+136
| | | | | | | | | | | | * Fixed bug where the player's ghost was never being placed in the dungeon, even though the file was being properly loaded. * The wizard command &^G can now both save and load bones files, so you don't have to quit/restart/go-to-level multiple times to get a bones file to load. * All possible failure points for both loading and creating bones files now generate diagnostic messages (when diagnostics is turned on).
* Flatten header dependencies a bit.Robert Vollmert2009-11-171-0/+1
| | | | | | This removes a couple of unnecessary includes from header files. I may have missed adding some tiles includes.
* Fix a few whitespace errors.Adam Borowski2009-11-151-1/+1
|
* Duvessa and Dowan death effect changes (dpeg).Jude Brown2009-11-151-0/+29
| | | | | | As suggested by dpeg, they will now only climb the stairs as a pair, or if one of them is already dead. This is slightly scummable, but they still get a free turn against you.
* Remove #include <conio.h> from all over the place. Convert COLORS to an enum.Adam Borowski2009-11-141-1/+0
|
* Move mtransit to mon-transit.Vsevolod Kozlov2009-11-141-1/+1
|
* Make level_excursion clear and load exclusionsCharles Otto2009-11-131-0/+3
| | | | | | | | | | Make level_excursions::go_to clear and load exclusions. This avoids exclusions leaking across levels when using apply_to_all_dungeons with a function that can set exclusions. Also when applying an auto-exclusion to an out of sight stationary monster you have seen before (oklob plants after renouncing Fedhas) associate the monster species with the exclusion.
* Remove obsoleted los.h includes.Robert Vollmert2009-11-131-1/+0
|
* Replace calc_show_los by you.update_los.Robert Vollmert2009-11-131-1/+1
|
* Rename monspeak/monplace/monstuff to mon-speak/place/stuff.Jude Brown2009-11-121-2/+2
| | | | | I'm pretty sure I've managed to replace every instance of a reference to these files, so I hopefully haven't missed anything.
* Remove a few obsolete includes.Robert Vollmert2009-11-101-1/+0
| | | | Also add a few previously indirect includes.
* Split shouting and stealth code from view.cc.Robert Vollmert2009-11-101-0/+1
|
* tags: Store minorVersion in reader classMatthew Cline2009-11-101-7/+7
| | | | | | Store the minor version of a savefile being read into the reader class, so that it doesn't need to be passed around as a method/function parameter everywhere.
* Remove option draw_it from viewwindow.Robert Vollmert2009-11-091-1/+1
| | | | | | The only use was just removed. Also move the draw check closer to where it's used.
* Replace mons_wont_attack with monsters::wont_attack.Vsevolod Kozlov2009-11-091-1/+1
|
* Split map knowledge and FPROPs.Robert Vollmert2009-11-081-1/+1
| | | | | | | | map_cell no longer has the field "properties", which has been replaced by the unsigned long array env.pgrid. env.map has been renamed to env.map_knowledge. It should really be moved into player.
* Remove player.h dependency from coordit.h.Robert Vollmert2009-11-081-1/+1
| | | | | | | | | adjacent_iterator had a default center of you.pos(), which is now gone (also the uses of). I was running into circular header dependencies with actor.h including los_def.h including coordit.h including player.h including actor.h.
* Get rid of env.show_los.Robert Vollmert2009-11-071-4/+0
|
* Rename is_valid_item to item_def::is_valid.Vsevolod Kozlov2009-11-061-1/+1
| | | | Signed-off-by: Jude Brown <bookofjude@users.sourceforge.net>
* Split up view.cc.Robert Vollmert2009-11-041-0/+1
|
* Get rid of multiple-meaning "int object" in env.show.Robert Vollmert2009-11-041-1/+1
| | | | | | | | | | | | | env.show is now a class show_def that stores tagged unions of type show_type. For the moment, there's also env.show_los for use in LOS determination, but that should become an array of boolean at some point. This breaks save compatibility. Tiles and console version build and appear to work fine, but this kind of change is likely to have some side-effects.
* Split game_options from externs.h into options.h.Robert Vollmert2009-11-041-0/+1
|
* Support for X map multi-level viewing on tiles.Enne Walker2009-11-031-0/+2
| | | | | Fixes seeing in-LOS squares on incorrect levels. Fixes the minimap not updating. Fixes the player dot appearing on the minimap on wrong levels.
* Factor a visitor object out of apply_to_levelStefan O'Rear2009-11-021-37/+32
|
* Split up monstuff.ccMatthew Cline2009-11-011-1/+1
| | | | | | | A lot of monstuff.cc was moved into mon-abil.cc (monster abilities), mon-act.cc (the main monster loop), mon-behv.cc (monster behaviour) and mon-cast.cc (monster spells). mstuff2.cc was completely merged into other files.
* loadmaps.lua auto-loads .des files in dat.Darshan Shaligram2009-11-011-3/+4
|
* Splitting up stuff.cc.Robert Vollmert2009-10-301-0/+1
| | | | New: colour.cc, coord.cc, coordit.cc, random.cc, rng.cc.
* Pre- and post-savefile callbacks.Matthew Cline2009-10-291-0/+69
| | | | | | | | | | | | | The constructor of class SavefileCallback can be used to add a callback which is called before a game is saved and after it's restored. This is useful to move data in and out of you.props, or after a restore if there's data not stored in the savefile which can be easily regenerated. NOTE: I experienced some weirdness with C++ global constructors, and since global constructors probably differ with compiler and system, until this has been tested on all compiler/system combinations, any code which uses the callbacks should fail gracefully if the callbacks aren't called.
* files.cc: eliminate 'shadowed declaration' warningSteven Noonan2009-10-251-2/+1
| | | | Signed-off-by: Steven Noonan <steven@uplinklabs.net>
* Convert player::your_name to std::string.Robert Vollmert2009-10-241-9/+9
| | | | Doesn't seem to break anything...
* files.cc: use proper data type for get_class_by_nameSteven Noonan2009-10-231-1/+2
| | | | | | Whoops, apparently it was declared, but not with the correct prototype. Signed-off-by: Steven Noonan <steven@uplinklabs.net>
* Removed 0.5 savefile minor versions, renumberedMatthew Cline2009-10-231-9/+23
| | | | | | | | | Removed the savefile minor versions which were introducded in 0.5, since bumping the major version from 5 to 6 breaks compatibility with 0.5 savefiles. Renumbered the 0.6 minor versions to start with 0. This contains a hack to maintain compatibility with 0.6 savefiles before the renumbering, a hack which should be removed before 0.6 is released.
* 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.
* win32: eliminate need for WIN32TILES/WIN32CONSOLE macrosSteven Noonan2009-10-191-1/+1
| | | | | | | | | | | | | | Instead of defined(WIN32CONSOLE) we should use: defined(TARGET_OS_WINDOWS) && !defined(USE_TILE) As well as replace defined(WIN32TILES) with: defined(TARGET_OS_WINDOWS) && defined(USE_TILE) Signed-off-by: Steven Noonan <steven@uplinklabs.net>