From dd0d8ac4cc2a0aa774f25c8a1a774f7358acfae7 Mon Sep 17 00:00:00 2001 From: Ketmar Dark Date: Thu, 17 Aug 2017 08:48:15 +0300 Subject: [PATCH] moved compiler options to shared/a_modes.inc; turned on advanced records --- src/engine/e_fixedbuffer.pas | 2 +- src/engine/e_graphics.pas | 2 +- src/engine/e_input.pas | 2 +- src/engine/e_log.pas | 2 +- src/engine/e_sound.pas | 2 +- src/engine/e_textures.pas | 2 +- src/game/g_amodes.inc | 14 -------------- src/game/g_basic.pas | 2 +- src/game/g_console.pas | 2 +- src/game/g_game.pas | 2 +- src/game/g_gfx.pas | 2 +- src/game/g_grid.pas | 2 +- src/game/g_gui.pas | 2 +- src/game/g_items.pas | 2 +- src/game/g_language.pas | 2 +- src/game/g_main.pas | 2 +- src/game/g_map.pas | 2 +- src/game/g_menu.pas | 2 +- src/game/g_monsters.pas | 2 +- src/game/g_net.pas | 2 +- src/game/g_nethandler.pas | 2 +- src/game/g_netmaster.pas | 2 +- src/game/g_netmsg.pas | 2 +- src/game/g_options.pas | 2 +- src/game/g_panel.pas | 2 +- src/game/g_phys.pas | 2 +- src/game/g_player.pas | 2 +- src/game/g_playermodel.pas | 2 +- src/game/g_res_downloader.pas | 2 +- src/game/g_saveload.pas | 2 +- src/game/g_sound.pas | 2 +- src/game/g_textures.pas | 2 +- src/game/g_triggers.pas | 2 +- src/game/g_weapons.pas | 2 +- src/game/g_window.pas | 2 +- src/sfs/sfs.pas | 4 ++-- src/sfs/sfsPlainFS.pas | 4 ++-- src/sfs/sfsZipFS.pas | 4 ++-- src/shared/BinEditor.pas | 2 +- src/shared/CONFIG.pas | 2 +- src/shared/CONFIGSIMPLE.pas | 2 +- src/shared/MAPDEF.pas | 2 +- src/shared/MAPREADER.pas | 2 +- src/shared/MAPSTRUCT.pas | 2 +- .../e_amodes.inc => shared/a_modes.inc} | 8 ++++++++ src/shared/conbuf.pas | 3 ++- src/shared/envvars.pas | 3 ++- src/shared/utils.pas | 2 +- src/shared/wadreader.pas | 18 +++++++++--------- src/shared/xstreams.pas | 4 ++-- 50 files changed, 70 insertions(+), 74 deletions(-) delete mode 100644 src/game/g_amodes.inc rename src/{engine/e_amodes.inc => shared/a_modes.inc} (59%) diff --git a/src/engine/e_fixedbuffer.pas b/src/engine/e_fixedbuffer.pas index c593021..5b80d7f 100644 --- a/src/engine/e_fixedbuffer.pas +++ b/src/engine/e_fixedbuffer.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit e_fixedbuffer; interface diff --git a/src/engine/e_graphics.pas b/src/engine/e_graphics.pas index 39b6e43..51d6cc3 100644 --- a/src/engine/e_graphics.pas +++ b/src/engine/e_graphics.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit e_graphics; interface diff --git a/src/engine/e_input.pas b/src/engine/e_input.pas index deded67..021c3dd 100644 --- a/src/engine/e_input.pas +++ b/src/engine/e_input.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit e_input; interface diff --git a/src/engine/e_log.pas b/src/engine/e_log.pas index dade4e3..ebdd646 100644 --- a/src/engine/e_log.pas +++ b/src/engine/e_log.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} {$R-} { $DEFINE CBLOG} unit e_log; diff --git a/src/engine/e_sound.pas b/src/engine/e_sound.pas index d4d13b8..7616afd 100644 --- a/src/engine/e_sound.pas +++ b/src/engine/e_sound.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit e_sound; {$IFDEF USE_SDLMIXER} diff --git a/src/engine/e_textures.pas b/src/engine/e_textures.pas index ae5cea4..dd2a535 100644 --- a/src/engine/e_textures.pas +++ b/src/engine/e_textures.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE e_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit e_textures; { This unit provides interface to load 24-bit and 32-bit uncompressed images diff --git a/src/game/g_amodes.inc b/src/game/g_amodes.inc deleted file mode 100644 index e3a4e67..0000000 --- a/src/game/g_amodes.inc +++ /dev/null @@ -1,14 +0,0 @@ -{$MODE DELPHI} -{$MODESWITCH NESTEDPROCVARS+} -{$MODESWITCH DUPLICATELOCALS-} -{.$MODESWITCH CBLOCKS+} -{$ASSERTIONS ON} -{$LONGSTRINGS ON} -{$OVERFLOWCHECKS OFF} -{$RANGECHECKS OFF} -{.$STATIC ON} -{$TYPEDADDRESS OFF} -{$VARSTRINGCHECKS OFF} -{$EXTENDEDSYNTAX ON} -{$B-} -{$S-} diff --git a/src/game/g_basic.pas b/src/game/g_basic.pas index 40b8e4e..67285ca 100644 --- a/src/game/g_basic.pas +++ b/src/game/g_basic.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_basic; interface diff --git a/src/game/g_console.pas b/src/game/g_console.pas index ec4ce69..6a5c9a4 100644 --- a/src/game/g_console.pas +++ b/src/game/g_console.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_console; interface diff --git a/src/game/g_game.pas b/src/game/g_game.pas index 18f5639..4a9bfbe 100644 --- a/src/game/g_game.pas +++ b/src/game/g_game.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_game; interface diff --git a/src/game/g_gfx.pas b/src/game/g_gfx.pas index e24db1f..17bbe92 100644 --- a/src/game/g_gfx.pas +++ b/src/game/g_gfx.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_gfx; interface diff --git a/src/game/g_grid.pas b/src/game/g_grid.pas index a56c670..0ffc5bc 100644 --- a/src/game/g_grid.pas +++ b/src/game/g_grid.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_grid; interface diff --git a/src/game/g_gui.pas b/src/game/g_gui.pas index ca49c71..eb06810 100644 --- a/src/game/g_gui.pas +++ b/src/game/g_gui.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_gui; interface diff --git a/src/game/g_items.pas b/src/game/g_items.pas index 2b7008e..9e6e2e0 100644 --- a/src/game/g_items.pas +++ b/src/game/g_items.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_items; interface diff --git a/src/game/g_language.pas b/src/game/g_language.pas index a3e7aa7..f2a3958 100644 --- a/src/game/g_language.pas +++ b/src/game/g_language.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_language; interface diff --git a/src/game/g_main.pas b/src/game/g_main.pas index d5a5a83..7864bed 100644 --- a/src/game/g_main.pas +++ b/src/game/g_main.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_main; interface diff --git a/src/game/g_map.pas b/src/game/g_map.pas index d56ed47..54d3763 100644 --- a/src/game/g_map.pas +++ b/src/game/g_map.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_map; interface diff --git a/src/game/g_menu.pas b/src/game/g_menu.pas index 7c51f80..298fab8 100644 --- a/src/game/g_menu.pas +++ b/src/game/g_menu.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_menu; interface diff --git a/src/game/g_monsters.pas b/src/game/g_monsters.pas index 27846f4..5ad20cc 100644 --- a/src/game/g_monsters.pas +++ b/src/game/g_monsters.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_monsters; interface diff --git a/src/game/g_net.pas b/src/game/g_net.pas index 3596849..1de6e98 100644 --- a/src/game/g_net.pas +++ b/src/game/g_net.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_net; interface diff --git a/src/game/g_nethandler.pas b/src/game/g_nethandler.pas index a4711af..ca75483 100644 --- a/src/game/g_nethandler.pas +++ b/src/game/g_nethandler.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_nethandler; interface diff --git a/src/game/g_netmaster.pas b/src/game/g_netmaster.pas index 64681c3..86d727e 100644 --- a/src/game/g_netmaster.pas +++ b/src/game/g_netmaster.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_netmaster; interface diff --git a/src/game/g_netmsg.pas b/src/game/g_netmsg.pas index 3049838..a0fb6ed 100644 --- a/src/game/g_netmsg.pas +++ b/src/game/g_netmsg.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_netmsg; interface diff --git a/src/game/g_options.pas b/src/game/g_options.pas index a262439..2efcb17 100644 --- a/src/game/g_options.pas +++ b/src/game/g_options.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_options; interface diff --git a/src/game/g_panel.pas b/src/game/g_panel.pas index 39c1b10..4374cf1 100644 --- a/src/game/g_panel.pas +++ b/src/game/g_panel.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_panel; interface diff --git a/src/game/g_phys.pas b/src/game/g_phys.pas index d581eb3..a3e790d 100644 --- a/src/game/g_phys.pas +++ b/src/game/g_phys.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_phys; interface diff --git a/src/game/g_player.pas b/src/game/g_player.pas index d5b318f..b25ef0c 100644 --- a/src/game/g_player.pas +++ b/src/game/g_player.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_player; interface diff --git a/src/game/g_playermodel.pas b/src/game/g_playermodel.pas index 0392cc4..0d696ee 100644 --- a/src/game/g_playermodel.pas +++ b/src/game/g_playermodel.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_playermodel; interface diff --git a/src/game/g_res_downloader.pas b/src/game/g_res_downloader.pas index 471268e..c24e6f8 100644 --- a/src/game/g_res_downloader.pas +++ b/src/game/g_res_downloader.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_res_downloader; interface diff --git a/src/game/g_saveload.pas b/src/game/g_saveload.pas index 039883d..40cf5cc 100644 --- a/src/game/g_saveload.pas +++ b/src/game/g_saveload.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_saveload; interface diff --git a/src/game/g_sound.pas b/src/game/g_sound.pas index a3ef547..d7d97d2 100644 --- a/src/game/g_sound.pas +++ b/src/game/g_sound.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_sound; interface diff --git a/src/game/g_textures.pas b/src/game/g_textures.pas index 21b33ae..45ae37f 100644 --- a/src/game/g_textures.pas +++ b/src/game/g_textures.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_textures; interface diff --git a/src/game/g_triggers.pas b/src/game/g_triggers.pas index 278e92a..3950718 100644 --- a/src/game/g_triggers.pas +++ b/src/game/g_triggers.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_triggers; interface diff --git a/src/game/g_weapons.pas b/src/game/g_weapons.pas index a008366..81db803 100644 --- a/src/game/g_weapons.pas +++ b/src/game/g_weapons.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_weapons; interface diff --git a/src/game/g_window.pas b/src/game/g_window.pas index 89511af..045a49f 100644 --- a/src/game/g_window.pas +++ b/src/game/g_window.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$INCLUDE g_amodes.inc} +{$INCLUDE ../shared/a_modes.inc} unit g_window; interface diff --git a/src/sfs/sfs.pas b/src/sfs/sfs.pas index 8437034..a18ad73 100644 --- a/src/sfs/sfs.pas +++ b/src/sfs/sfs.pas @@ -14,8 +14,8 @@ * along with this program. If not, see . *) // streaming file system (virtual) -{$MODE DELPHI} -{$R+} +{$INCLUDE ../shared/a_modes.inc} +{.$R+} {.$DEFINE SFS_VOLDEBUG} unit sfs; diff --git a/src/sfs/sfsPlainFS.pas b/src/sfs/sfsPlainFS.pas index 9a58e83..e116d93 100644 --- a/src/sfs/sfsPlainFS.pas +++ b/src/sfs/sfsPlainFS.pas @@ -17,8 +17,8 @@ // Quake I/II .PAK (PACK) // SiN .SIN (SPAK) // -{$MODE DELPHI} -{$R+} +{$INCLUDE ../shared/a_modes.inc} +{.$R+} unit sfsPlainFS; interface diff --git a/src/sfs/sfsZipFS.pas b/src/sfs/sfsZipFS.pas index 9db434e..ae17ba1 100644 --- a/src/sfs/sfsZipFS.pas +++ b/src/sfs/sfsZipFS.pas @@ -18,8 +18,8 @@ // dfwad : D2D:F wad archives // {.$DEFINE SFS_DEBUG_ZIPFS} -{$MODE DELPHI} -{$R+} +{$INCLUDE ../shared/a_modes.inc} +{.$R+} unit sfsZipFS; interface diff --git a/src/shared/BinEditor.pas b/src/shared/BinEditor.pas index a414309..1f53456 100644 --- a/src/shared/BinEditor.pas +++ b/src/shared/BinEditor.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} Unit BinEditor; Interface diff --git a/src/shared/CONFIG.pas b/src/shared/CONFIG.pas index 2d1a5f2..3dfd736 100644 --- a/src/shared/CONFIG.pas +++ b/src/shared/CONFIG.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit CONFIG; { diff --git a/src/shared/CONFIGSIMPLE.pas b/src/shared/CONFIGSIMPLE.pas index 7e0617e..8e6cd2e 100644 --- a/src/shared/CONFIGSIMPLE.pas +++ b/src/shared/CONFIGSIMPLE.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit CONFIGSIMPLE; interface diff --git a/src/shared/MAPDEF.pas b/src/shared/MAPDEF.pas index ef4eaf6..05c5101 100644 --- a/src/shared/MAPDEF.pas +++ b/src/shared/MAPDEF.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit MAPDEF; { diff --git a/src/shared/MAPREADER.pas b/src/shared/MAPREADER.pas index 93de6b0..4ea7beb 100644 --- a/src/shared/MAPREADER.pas +++ b/src/shared/MAPREADER.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit MAPREADER; { diff --git a/src/shared/MAPSTRUCT.pas b/src/shared/MAPSTRUCT.pas index b72499d..d9913a4 100644 --- a/src/shared/MAPSTRUCT.pas +++ b/src/shared/MAPSTRUCT.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit MAPSTRUCT; { diff --git a/src/engine/e_amodes.inc b/src/shared/a_modes.inc similarity index 59% rename from src/engine/e_amodes.inc rename to src/shared/a_modes.inc index e3a4e67..35e29d6 100644 --- a/src/engine/e_amodes.inc +++ b/src/shared/a_modes.inc @@ -1,7 +1,9 @@ +// compiler options, common for all game modules {$MODE DELPHI} {$MODESWITCH NESTEDPROCVARS+} {$MODESWITCH DUPLICATELOCALS-} {.$MODESWITCH CBLOCKS+} +{$MODESWITCH ADVANCEDRECORDS+} {$ASSERTIONS ON} {$LONGSTRINGS ON} {$OVERFLOWCHECKS OFF} @@ -12,3 +14,9 @@ {$EXTENDEDSYNTAX ON} {$B-} {$S-} + +{$IFDEF MSWINDOWS} + {$IFNDEF WINDOWS} + {$DEFINE WINDOWS} + {$ENDIF WINDOWS} +{$ENDIF MSWINDOWS} diff --git a/src/shared/conbuf.pas b/src/shared/conbuf.pas index 1be01b2..42f85a5 100644 --- a/src/shared/conbuf.pas +++ b/src/shared/conbuf.pas @@ -13,7 +13,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE OBJFPC} +{$INCLUDE a_modes.inc} +{.$MODE OBJFPC} unit conbuf; interface diff --git a/src/shared/envvars.pas b/src/shared/envvars.pas index 6f92b40..a7d3293 100644 --- a/src/shared/envvars.pas +++ b/src/shared/envvars.pas @@ -13,7 +13,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE OBJFPC} +{$INCLUDE a_modes.inc} +{.$MODE OBJFPC} unit envvars; interface diff --git a/src/shared/utils.pas b/src/shared/utils.pas index 253e838..f673178 100644 --- a/src/shared/utils.pas +++ b/src/shared/utils.pas @@ -13,7 +13,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit utils; interface diff --git a/src/shared/wadreader.pas b/src/shared/wadreader.pas index 2997bce..df0de0f 100644 --- a/src/shared/wadreader.pas +++ b/src/shared/wadreader.pas @@ -13,10 +13,10 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . *) -{$MODE DELPHI} +{$INCLUDE a_modes.inc} unit wadreader; -{$DEFINE SFS_DWFAD_DEBUG} +{$DEFINE SFS_DFWAD_DEBUG} {$DEFINE SFS_MAPDETECT_FX} interface @@ -387,7 +387,7 @@ begin end; {$ENDIF} result := true; - {$IFDEF SFS_DWFAD_DEBUG} + {$IFDEF SFS_DFWAD_DEBUG} if wadoptDebug then e_WriteLog(Format('DFWAD: file [%s] FOUND in [%s]; size is %d bytes', [name, fFileName, Len]), MSG_NOTIFY); {$ENDIF} @@ -455,7 +455,7 @@ begin e_WriteLog(Format('TWADFile.ReadFile: error looking for [%s]', [FileName]), MSG_NOTIFY); exit; end; - {$IFDEF SFS_DWFAD_DEBUG} + {$IFDEF SFS_DFWAD_DEBUG} if wadoptDebug then e_WriteLog(Format('TWADFile.ReadFile: FOUND [%s]', [rfn]), MSG_NOTIFY); {$ENDIF} // cache this wad @@ -474,7 +474,7 @@ begin fIter := SFSFileList(rfn); if fIter = nil then Exit; fFileName := rfn; - {$IFDEF SFS_DWFAD_DEBUG} + {$IFDEF SFS_DFWAD_DEBUG} if wadoptDebug then e_WriteLog(Format('TWADFile.ReadFile: [%s] opened', [fFileName]), MSG_NOTIFY); {$ENDIF} Result := True; @@ -501,8 +501,8 @@ begin fn := Format(' -- memwad %d -- ', [uniqueCounter]); Inc(uniqueCounter); - {$IFDEF SFS_DWFAD_DEBUG} - e_WriteLog(Format('TWADFile.ReadMemory: [%s]', [fn]), MSG_NOTIFY); + {$IFDEF SFS_DFWAD_DEBUG} + if wadoptDebug then e_WriteLog(Format('TWADFile.ReadMemory: [%s]', [fn]), MSG_NOTIFY); {$ENDIF} try @@ -521,8 +521,8 @@ begin if fIter = nil then Exit; fFileName := fn; - {$IFDEF SFS_DWFAD_DEBUG} - e_WriteLog(Format('TWADFile.ReadMemory: [%s] opened', [fFileName]), MSG_NOTIFY); + {$IFDEF SFS_DFWAD_DEBUG} + if wadoptDebug then e_WriteLog(Format('TWADFile.ReadMemory: [%s] opened', [fFileName]), MSG_NOTIFY); {$ENDIF} { diff --git a/src/shared/xstreams.pas b/src/shared/xstreams.pas index 17a575b..81a104c 100644 --- a/src/shared/xstreams.pas +++ b/src/shared/xstreams.pas @@ -14,8 +14,8 @@ * along with this program. If not, see . *) // special stream classes -{$MODE DELPHI} -{$R+} +{$INCLUDE a_modes.inc} +{.$R+} unit xstreams; interface -- 2.29.2