diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 52aabec8b..dd47759d9 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -535,90 +535,15 @@ add_executable( zdoom WIN32
 	x86.cpp
 	zstrformat.cpp
 	zstring.cpp
-	g_doom/a_arachnotron.cpp
-	g_doom/a_archvile.cpp
-	g_doom/a_bossbrain.cpp
-	g_doom/a_bruiser.cpp
-	g_doom/a_cacodemon.cpp
-	g_doom/a_cyberdemon.cpp
-	g_doom/a_demon.cpp
-	g_doom/a_doomimp.cpp
 	g_doom/a_doommisc.cpp
-	g_doom/a_doomweaps.cpp
-	g_doom/a_fatso.cpp
-	g_doom/a_keen.cpp
-	g_doom/a_lostsoul.cpp
-	g_doom/a_painelemental.cpp
-	g_doom/a_possessed.cpp
-	g_doom/a_revenant.cpp
-	g_doom/a_scriptedmarine.cpp
-	g_doom/a_spidermaster.cpp
 	g_doom/doom_sbar.cpp
-	g_heretic/a_chicken.cpp
-	g_heretic/a_dsparil.cpp
-	g_heretic/a_hereticartifacts.cpp
-	g_heretic/a_hereticimp.cpp
 	g_heretic/a_hereticmisc.cpp
-	g_heretic/a_hereticweaps.cpp
-	g_heretic/a_ironlich.cpp
-	g_heretic/a_knight.cpp
-	g_heretic/a_wizard.cpp
 	g_heretic/heretic_sbar.cpp
-	g_hexen/a_bats.cpp
-	g_hexen/a_bishop.cpp
-	g_hexen/a_blastradius.cpp
-	g_hexen/a_boostarmor.cpp
-	g_hexen/a_centaur.cpp
-	g_hexen/a_clericflame.cpp
-	g_hexen/a_clericholy.cpp
-	g_hexen/a_clericmace.cpp
-	g_hexen/a_clericstaff.cpp
-	g_hexen/a_dragon.cpp
-	g_hexen/a_fighteraxe.cpp
-	g_hexen/a_fighterhammer.cpp
-	g_hexen/a_fighterplayer.cpp
-	g_hexen/a_fighterquietus.cpp
-	g_hexen/a_firedemon.cpp
-	g_hexen/a_flechette.cpp
-	g_hexen/a_fog.cpp
-	g_hexen/a_healingradius.cpp
-	g_hexen/a_heresiarch.cpp
-	g_hexen/a_hexenspecialdecs.cpp
-	g_hexen/a_iceguy.cpp
-	g_hexen/a_korax.cpp
-	g_hexen/a_magecone.cpp
-	g_hexen/a_magelightning.cpp
-	g_hexen/a_magestaff.cpp
-	g_hexen/a_magewand.cpp
-	g_hexen/a_pig.cpp
-	g_hexen/a_serpent.cpp
-	g_hexen/a_spike.cpp
-	g_hexen/a_summon.cpp
-	g_hexen/a_teleportother.cpp
-	g_hexen/a_wraith.cpp
+	g_hexen/a_hexenmisc.cpp
 	g_hexen/hexen_sbar.cpp
 	g_raven/a_artitele.cpp
 	g_raven/a_minotaur.cpp
-	g_strife/a_acolyte.cpp
-	g_strife/a_alienspectres.cpp
-	g_strife/a_coin.cpp
-	g_strife/a_crusader.cpp
-	g_strife/a_entityboss.cpp
-	g_strife/a_inquisitor.cpp
-	g_strife/a_loremaster.cpp
-	g_strife/a_macil.cpp
-	g_strife/a_oracle.cpp
-	g_strife/a_programmer.cpp
-	g_strife/a_reaver.cpp
-	g_strife/a_rebels.cpp
-	g_strife/a_sentinel.cpp
-	g_strife/a_spectral.cpp
-	g_strife/a_stalker.cpp
-	g_strife/a_strifeitems.cpp
 	g_strife/a_strifestuff.cpp
-	g_strife/a_strifeweapons.cpp
-	g_strife/a_templar.cpp
-	g_strife/a_thingstoblowup.cpp
 	g_strife/strife_sbar.cpp
 	g_shared/a_action.cpp
 	g_shared/a_armor.cpp
diff --git a/src/am_map.cpp b/src/am_map.cpp
index 6b0c33a9d..2476d93a6 100644
--- a/src/am_map.cpp
+++ b/src/am_map.cpp
@@ -44,6 +44,7 @@
 
 // Needs access to LFB.
 #include "v_video.h"
+#include "v_palette.h"
 
 #include "v_text.h"
 
diff --git a/src/ct_chat.cpp b/src/ct_chat.cpp
index f728995ac..f527ac1b3 100644
--- a/src/ct_chat.cpp
+++ b/src/ct_chat.cpp
@@ -22,6 +22,7 @@
 #include "c_console.h"
 #include "c_dispatch.h"
 #include "c_cvars.h"
+#include "d_player.h"
 #include "v_text.h"
 #include "v_video.h"
 #include "gi.h"
diff --git a/src/d_main.cpp b/src/d_main.cpp
index b59324d9f..257650d61 100644
--- a/src/d_main.cpp
+++ b/src/d_main.cpp
@@ -98,6 +98,7 @@
 #include "g_level.h"
 #include "d_event.h"
 #include "d_netinf.h"
+#include "v_palette.h"
 
 EXTERN_CVAR(Bool, hud_althud)
 void DrawHUD();
diff --git a/src/doomstat.cpp b/src/doomstat.cpp
index 4018b7e43..0fe988a92 100644
--- a/src/doomstat.cpp
+++ b/src/doomstat.cpp
@@ -29,7 +29,6 @@
 #include "i_system.h"
 #include "g_level.h"
 #include "p_local.h"
-#include "p_acs.h"
 
 int SaveVersion;
 
diff --git a/src/f_finale.cpp b/src/f_finale.cpp
index 49d37b3ae..6037af503 100644
--- a/src/f_finale.cpp
+++ b/src/f_finale.cpp
@@ -48,6 +48,7 @@
 #include "r_translate.h"
 #include "g_level.h"
 #include "d_event.h"
+#include "v_palette.h"
 
 static void FadePic ();
 static void GetFinaleText (const char *msgLumpName);
diff --git a/src/farchive.h b/src/farchive.h
index fefc3200b..9af7d25ba 100644
--- a/src/farchive.h
+++ b/src/farchive.h
@@ -283,6 +283,14 @@ inline FArchive &operator<< (FArchive &arc, T* &object)
 
 FArchive &operator<< (FArchive &arc, const PClass * &info);
 
+class FFont;
+FArchive &SerializeFFontPtr (FArchive &arc, FFont* &font);
+template<> inline FArchive &operator<< <FFont> (FArchive &arc, FFont* &font)
+{
+	return SerializeFFontPtr (arc, font);
+}
+
+
 template<class T,class TT>
 inline FArchive &operator<< (FArchive &arc, TArray<T,TT> &self)
 {
diff --git a/src/g_doom/a_arachnotron.cpp b/src/g_doom/a_arachnotron.cpp
index d92d0acba..19c3bb63a 100644
--- a/src/g_doom/a_arachnotron.cpp
+++ b/src/g_doom/a_arachnotron.cpp
@@ -1,9 +1,11 @@
+/*
 #include "actor.h"
 #include "s_sound.h"
 #include "p_local.h"
 #include "p_enemy.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 DEFINE_ACTION_FUNCTION(AActor, A_BspiAttack)
 {		
diff --git a/src/g_doom/a_archvile.cpp b/src/g_doom/a_archvile.cpp
index 620e57260..25df2087e 100644
--- a/src/g_doom/a_archvile.cpp
+++ b/src/g_doom/a_archvile.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -6,6 +7,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 //
 // PIT_VileCheck
diff --git a/src/g_doom/a_bossbrain.cpp b/src/g_doom/a_bossbrain.cpp
index 77bfc3935..6cf9146cb 100644
--- a/src/g_doom/a_bossbrain.cpp
+++ b/src/g_doom/a_bossbrain.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -9,6 +10,7 @@
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_brainscream ("BrainScream");
 static FRandom pr_brainexplode ("BrainExplode");
diff --git a/src/g_doom/a_bruiser.cpp b/src/g_doom/a_bruiser.cpp
index 948e6016e..24c6c48eb 100644
--- a/src/g_doom/a_bruiser.cpp
+++ b/src/g_doom/a_bruiser.cpp
@@ -1,14 +1,3 @@
-#include "actor.h"
-#include "info.h"
-#include "m_random.h"
-#include "s_sound.h"
-#include "p_local.h"
-#include "p_enemy.h"
-#include "doomstat.h"
-#include "gstrings.h"
-#include "a_action.h"
-#include "thingdef/thingdef.h"
-
 static FRandom pr_bruisattack ("BruisAttack");
 
 
diff --git a/src/g_doom/a_cacodemon.cpp b/src/g_doom/a_cacodemon.cpp
index e594ec7ed..0eb923890 100644
--- a/src/g_doom/a_cacodemon.cpp
+++ b/src/g_doom/a_cacodemon.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "a_action.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_headattack ("HeadAttack");
 
diff --git a/src/g_doom/a_cyberdemon.cpp b/src/g_doom/a_cyberdemon.cpp
index a01709595..f13728e48 100644
--- a/src/g_doom/a_cyberdemon.cpp
+++ b/src/g_doom/a_cyberdemon.cpp
@@ -1,9 +1,11 @@
+/*
 #include "actor.h"
 #include "p_local.h"
 #include "s_sound.h"
 #include "p_enemy.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 DEFINE_ACTION_FUNCTION(AActor, A_CyberAttack)
 {
diff --git a/src/g_doom/a_demon.cpp b/src/g_doom/a_demon.cpp
index 7f6bc0cdf..c890c32b0 100644
--- a/src/g_doom/a_demon.cpp
+++ b/src/g_doom/a_demon.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -6,6 +7,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_sargattack ("SargAttack");
 
diff --git a/src/g_doom/a_doomimp.cpp b/src/g_doom/a_doomimp.cpp
index bbbb2fe0f..401fa4577 100644
--- a/src/g_doom/a_doomimp.cpp
+++ b/src/g_doom/a_doomimp.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_troopattack ("TroopAttack");
 
diff --git a/src/g_doom/a_doommisc.cpp b/src/g_doom/a_doommisc.cpp
index 230d58a1c..898068d66 100644
--- a/src/g_doom/a_doommisc.cpp
+++ b/src/g_doom/a_doommisc.cpp
@@ -1,6 +1,5 @@
 #include "actor.h"
 #include "info.h"
-#include "p_enemy.h"
 #include "p_local.h"
 #include "a_sharedglobal.h"
 #include "m_random.h"
@@ -8,6 +7,31 @@
 #include "doomstat.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+#include "g_level.h"
+#include "p_enemy.h"
+#include "a_doomglobal.h"
+#include "a_specialspot.h"
+#include "templates.h"
+#include "m_bbox.h"
+
+// Include all the other Doom stuff here to reduce compile time
+#include "a_arachnotron.cpp"
+#include "a_archvile.cpp"
+#include "a_bossbrain.cpp"
+#include "a_bruiser.cpp"
+#include "a_cacodemon.cpp"
+#include "a_cyberdemon.cpp"
+#include "a_demon.cpp"
+#include "a_doomimp.cpp"
+#include "a_doomweaps.cpp"
+#include "a_fatso.cpp"
+#include "a_keen.cpp"
+#include "a_lostsoul.cpp"
+#include "a_painelemental.cpp"
+#include "a_possessed.cpp"
+#include "a_revenant.cpp"
+#include "a_spidermaster.cpp"
+#include "a_scriptedmarine.cpp"
 
 // The barrel of green goop ------------------------------------------------
 
diff --git a/src/g_doom/a_doomweaps.cpp b/src/g_doom/a_doomweaps.cpp
index 1ead3d7dd..ac4e0a0e3 100644
--- a/src/g_doom/a_doomweaps.cpp
+++ b/src/g_doom/a_doomweaps.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "s_sound.h"
@@ -12,6 +13,7 @@
 #include "templates.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_punch ("Punch");
 static FRandom pr_saw ("Saw");
diff --git a/src/g_doom/a_fatso.cpp b/src/g_doom/a_fatso.cpp
index 809eccd0c..b93019a3b 100644
--- a/src/g_doom/a_fatso.cpp
+++ b/src/g_doom/a_fatso.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 //
 // Mancubus attack,
diff --git a/src/g_doom/a_keen.cpp b/src/g_doom/a_keen.cpp
index 6cf495234..7c7be9f48 100644
--- a/src/g_doom/a_keen.cpp
+++ b/src/g_doom/a_keen.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -5,6 +6,7 @@
 #include "p_enemy.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 //
 // A_KeenDie
diff --git a/src/g_doom/a_lostsoul.cpp b/src/g_doom/a_lostsoul.cpp
index 733467473..df7cd743b 100644
--- a/src/g_doom/a_lostsoul.cpp
+++ b/src/g_doom/a_lostsoul.cpp
@@ -1,3 +1,4 @@
+/*
 #include "templates.h"
 #include "actor.h"
 #include "info.h"
@@ -9,6 +10,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
  FRandom pr_lost ("LostMissileRange");
 
diff --git a/src/g_doom/a_painelemental.cpp b/src/g_doom/a_painelemental.cpp
index 23c5d5a6a..ad4237803 100644
--- a/src/g_doom/a_painelemental.cpp
+++ b/src/g_doom/a_painelemental.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_enemy.h"
@@ -7,6 +8,7 @@
 #include "m_bbox.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 DECLARE_ACTION(A_SkullAttack)
 
diff --git a/src/g_doom/a_possessed.cpp b/src/g_doom/a_possessed.cpp
index 395b485d1..e435bff14 100644
--- a/src/g_doom/a_possessed.cpp
+++ b/src/g_doom/a_possessed.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "gstrings.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_posattack ("PosAttack");
 static FRandom pr_sposattack ("SPosAttack");
diff --git a/src/g_doom/a_revenant.cpp b/src/g_doom/a_revenant.cpp
index ae18257a0..9b610ac11 100644
--- a/src/g_doom/a_revenant.cpp
+++ b/src/g_doom/a_revenant.cpp
@@ -1,3 +1,4 @@
+/*
 #include "templates.h"
 #include "actor.h"
 #include "info.h"
@@ -9,6 +10,7 @@
 #include "a_action.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_tracer ("Tracer");
 static FRandom pr_skelfist ("SkelFist");
diff --git a/src/g_doom/a_scriptedmarine.cpp b/src/g_doom/a_scriptedmarine.cpp
index a43f4f637..7ee65bad9 100644
--- a/src/g_doom/a_scriptedmarine.cpp
+++ b/src/g_doom/a_scriptedmarine.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "p_enemy.h"
 #include "a_action.h"
@@ -9,6 +10,7 @@
 #include "r_translate.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 #define MARINE_PAIN_CHANCE 160
 
diff --git a/src/g_doom/a_spidermaster.cpp b/src/g_doom/a_spidermaster.cpp
index cea5fdc04..a29561b56 100644
--- a/src/g_doom/a_spidermaster.cpp
+++ b/src/g_doom/a_spidermaster.cpp
@@ -1,3 +1,4 @@
+/*
 #include "templates.h"
 #include "actor.h"
 #include "m_random.h"
@@ -6,6 +7,7 @@
 #include "p_enemy.h"
 #include "a_action.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_spidrefire ("SpidRefire");
 
diff --git a/src/g_doom/doom_sbar.cpp b/src/g_doom/doom_sbar.cpp
index fb11dd16f..0349182c1 100644
--- a/src/g_doom/doom_sbar.cpp
+++ b/src/g_doom/doom_sbar.cpp
@@ -16,6 +16,7 @@
 #include "r_translate.h"
 #include "sbarinfo.h"
 #include "g_level.h"
+#include "v_palette.h"
 
 
 #define ST_EVILGRINCOUNT		(2*TICRATE)
diff --git a/src/g_game.cpp b/src/g_game.cpp
index 31f29ebb6..18e2b7560 100644
--- a/src/g_game.cpp
+++ b/src/g_game.cpp
@@ -41,9 +41,7 @@
 #include "m_random.h"
 #include "m_crc32.h"
 #include "i_system.h"
-#include "p_setup.h"
 #include "p_saveg.h"
-#include "p_effect.h"
 #include "p_tick.h"
 #include "d_main.h"
 #include "wi_stuff.h"
diff --git a/src/g_heretic/a_chicken.cpp b/src/g_heretic/a_chicken.cpp
index 287bd0820..dd2983afc 100644
--- a/src/g_heretic/a_chicken.cpp
+++ b/src/g_heretic/a_chicken.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -11,6 +12,7 @@
 #include "d_event.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+*/
 
 void P_UpdateBeak (AActor *actor);
 
diff --git a/src/g_heretic/a_dsparil.cpp b/src/g_heretic/a_dsparil.cpp
index a51ac5614..a02e28ed3 100644
--- a/src/g_heretic/a_dsparil.cpp
+++ b/src/g_heretic/a_dsparil.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -10,6 +11,7 @@
 #include "a_specialspot.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_s2fx1 ("S2FX1");
 static FRandom pr_scrc1atk ("Srcr1Attack");
diff --git a/src/g_heretic/a_hereticartifacts.cpp b/src/g_heretic/a_hereticartifacts.cpp
index d19c9713d..32e3ab9e5 100644
--- a/src/g_heretic/a_hereticartifacts.cpp
+++ b/src/g_heretic/a_hereticartifacts.cpp
@@ -1,11 +1,12 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 // Tome of power ------------------------------------------------------------
 
diff --git a/src/g_heretic/a_hereticimp.cpp b/src/g_heretic/a_hereticimp.cpp
index a65d3dcc1..ef586a067 100644
--- a/src/g_heretic/a_hereticimp.cpp
+++ b/src/g_heretic/a_hereticimp.cpp
@@ -1,12 +1,13 @@
+/*
 #include "templates.h"
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
 #include "s_sound.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_imp ("ImpExplode");
 
diff --git a/src/g_heretic/a_hereticmisc.cpp b/src/g_heretic/a_hereticmisc.cpp
index 273403ab3..85c75ca34 100644
--- a/src/g_heretic/a_hereticmisc.cpp
+++ b/src/g_heretic/a_hereticmisc.cpp
@@ -1,6 +1,5 @@
 #include "actor.h"
 #include "info.h"
-#include "p_enemy.h"
 #include "a_pickups.h"
 #include "a_action.h"
 #include "m_random.h"
@@ -8,6 +7,24 @@
 #include "s_sound.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+#include "p_enemy.h"
+#include "a_specialspot.h"
+#include "g_level.h"
+#include "a_sharedglobal.h"
+#include "templates.h"
+#include "r_translate.h"
+#include "doomstat.h"
+
+// Include all the other Heretic stuff here to reduce compile time
+#include "a_chicken.cpp"
+#include "a_dsparil.cpp"
+#include "a_hereticartifacts.cpp"
+#include "a_hereticimp.cpp"
+#include "a_hereticweaps.cpp"
+#include "a_ironlich.cpp"
+#include "a_knight.cpp"
+#include "a_wizard.cpp"
+
 
 static FRandom pr_podpain ("PodPain");
 static FRandom pr_makepod ("MakePod");
@@ -15,7 +32,7 @@ static FRandom pr_teleg ("TeleGlitter");
 static FRandom pr_teleg2 ("TeleGlitter2");
 static FRandom pr_volcano ("VolcanoSet");
 static FRandom pr_blast ("VolcanoBlast");
-static FRandom pr_impact ("VolcBallImpact");
+static FRandom pr_volcimpact ("VolcBallImpact");
 
 //----------------------------------------------------------------------------
 //
@@ -184,7 +201,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_VolcBallImpact)
 		angle >>= ANGLETOFINESHIFT;
 		tiny->momx = FixedMul (FRACUNIT*7/10, finecosine[angle]);
 		tiny->momy = FixedMul (FRACUNIT*7/10, finesine[angle]);
-		tiny->momz = FRACUNIT + (pr_impact() << 9);
+		tiny->momz = FRACUNIT + (pr_volcimpact() << 9);
 		P_CheckMissileSpawn (tiny);
 	}
 }
diff --git a/src/g_heretic/a_hereticweaps.cpp b/src/g_heretic/a_hereticweaps.cpp
index 3c2b09e25..c7aa8b9e0 100644
--- a/src/g_heretic/a_hereticweaps.cpp
+++ b/src/g_heretic/a_hereticweaps.cpp
@@ -1,3 +1,4 @@
+/*
 #include "templates.h"
 #include "actor.h"
 #include "info.h"
@@ -8,13 +9,11 @@
 #include "p_pspr.h"
 #include "p_local.h"
 #include "gstrings.h"
-#include "p_effect.h"
-#include "gstrings.h"
-#include "p_enemy.h"
 #include "gi.h"
 #include "r_translate.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_sap ("StaffAtkPL1");
 static FRandom pr_sap2 ("StaffAtkPL2");
diff --git a/src/g_heretic/a_ironlich.cpp b/src/g_heretic/a_ironlich.cpp
index b77fdf4eb..db4fa270b 100644
--- a/src/g_heretic/a_ironlich.cpp
+++ b/src/g_heretic/a_ironlich.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -8,6 +9,7 @@
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_foo ("WhirlwindDamage");
 static FRandom pr_atk ("LichAttack");
diff --git a/src/g_heretic/a_knight.cpp b/src/g_heretic/a_knight.cpp
index 41e95dd70..bc830b398 100644
--- a/src/g_heretic/a_knight.cpp
+++ b/src/g_heretic/a_knight.cpp
@@ -1,13 +1,14 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
 #include "s_sound.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "a_sharedglobal.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_dripblood ("DripBlood");
 static FRandom pr_knightatk ("KnightAttack");
diff --git a/src/g_heretic/a_wizard.cpp b/src/g_heretic/a_wizard.cpp
index 16cb8269f..df1429849 100644
--- a/src/g_heretic/a_wizard.cpp
+++ b/src/g_heretic/a_wizard.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "a_action.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_wizatk3 ("WizAtk3");
 
diff --git a/src/g_heretic/heretic_sbar.cpp b/src/g_heretic/heretic_sbar.cpp
index d4ed61aaf..4583189f9 100644
--- a/src/g_heretic/heretic_sbar.cpp
+++ b/src/g_heretic/heretic_sbar.cpp
@@ -15,6 +15,7 @@
 #include "a_keys.h"
 #include "r_translate.h"
 #include "g_level.h"
+#include "v_palette.h"
 
 
 static FRandom pr_chainwiggle;
diff --git a/src/g_hexen/a_bats.cpp b/src/g_hexen/a_bats.cpp
index ebb653227..89802fd43 100644
--- a/src/g_hexen/a_bats.cpp
+++ b/src/g_hexen/a_bats.cpp
@@ -1,9 +1,11 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
 #include "p_local.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_batspawn ("BatSpawn");
 static FRandom pr_batmove ("BatMove");
diff --git a/src/g_hexen/a_bishop.cpp b/src/g_hexen/a_bishop.cpp
index 73b158730..33ae5dd97 100644
--- a/src/g_hexen/a_bishop.cpp
+++ b/src/g_hexen/a_bishop.cpp
@@ -1,12 +1,13 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
 #include "s_sound.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "m_random.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_boom ("BishopBoom");
 static FRandom pr_atk ("BishopAttack");
diff --git a/src/g_hexen/a_blastradius.cpp b/src/g_hexen/a_blastradius.cpp
index 26dc707b1..53ed19635 100644
--- a/src/g_hexen/a_blastradius.cpp
+++ b/src/g_hexen/a_blastradius.cpp
@@ -1,3 +1,4 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
@@ -5,6 +6,7 @@
 #include "p_local.h"
 #include "p_enemy.h"
 #include "s_sound.h"
+*/
 
 #define BLAST_RADIUS_DIST	255*FRACUNIT
 #define BLAST_SPEED			20*FRACUNIT
diff --git a/src/g_hexen/a_boostarmor.cpp b/src/g_hexen/a_boostarmor.cpp
index ca7c6c9dc..9a386569f 100644
--- a/src/g_hexen/a_boostarmor.cpp
+++ b/src/g_hexen/a_boostarmor.cpp
@@ -1,3 +1,4 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
@@ -5,6 +6,7 @@
 #include "p_local.h"
 #include "gi.h"
 #include "s_sound.h"
+*/
 
 // Boost Armor Artifact (Dragonskin Bracers) --------------------------------
 
diff --git a/src/g_hexen/a_centaur.cpp b/src/g_hexen/a_centaur.cpp
index e16ed2e06..f7ba3b99f 100644
--- a/src/g_hexen/a_centaur.cpp
+++ b/src/g_hexen/a_centaur.cpp
@@ -1,8 +1,10 @@
+/*
 #include "actor.h"
 #include "p_enemy.h"
 #include "a_action.h"
 #include "m_random.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_centaurdefend ("CentaurDefend");
 
diff --git a/src/g_hexen/a_clericflame.cpp b/src/g_hexen/a_clericflame.cpp
index d7975edea..22e8e3fce 100644
--- a/src/g_hexen/a_clericflame.cpp
+++ b/src/g_hexen/a_clericflame.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,12 +6,12 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 const fixed_t FLAMESPEED	= fixed_t(0.45*FRACUNIT);
 const fixed_t CFLAMERANGE	= 12*64*FRACUNIT;
diff --git a/src/g_hexen/a_clericholy.cpp b/src/g_hexen/a_clericholy.cpp
index d76f5b031..9573cadfa 100644
--- a/src/g_hexen/a_clericholy.cpp
+++ b/src/g_hexen/a_clericholy.cpp
@@ -1,15 +1,16 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
 #include "m_random.h"
 #include "s_sound.h"
-#include "p_enemy.h"
 #include "a_hexenglobal.h"
 #include "gstrings.h"
 #include "a_weaponpiece.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
 #include "doomstat.h"
+*/
 
 #define BLAST_FULLSTRENGTH	255
 
diff --git a/src/g_hexen/a_clericmace.cpp b/src/g_hexen/a_clericmace.cpp
index cfdf58829..d834dcd1b 100644
--- a/src/g_hexen/a_clericmace.cpp
+++ b/src/g_hexen/a_clericmace.cpp
@@ -1,11 +1,13 @@
+/*
 #include "m_random.h"
 #include "p_local.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 extern void AdjustPlayerAngle (AActor *pmo, AActor *linetarget);
 
-static FRandom pr_atk ("CMaceAttack");
+static FRandom pr_maceatk ("CMaceAttack");
 
 //===========================================================================
 //
@@ -27,7 +29,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_CMaceAttack)
 		return;
 	}
 
-	damage = 25+(pr_atk()&15);
+	damage = 25+(pr_maceatk()&15);
 	for (i = 0; i < 16; i++)
 	{
 		angle = player->mo->angle+i*(ANG45/16);
diff --git a/src/g_hexen/a_clericstaff.cpp b/src/g_hexen/a_clericstaff.cpp
index 87b469121..09067aaf7 100644
--- a/src/g_hexen/a_clericstaff.cpp
+++ b/src/g_hexen/a_clericstaff.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,12 +6,12 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_staffcheck ("CStaffCheck");
 static FRandom pr_blink ("CStaffBlink");
diff --git a/src/g_hexen/a_dragon.cpp b/src/g_hexen/a_dragon.cpp
index 7d9a37607..569aff6b8 100644
--- a/src/g_hexen/a_dragon.cpp
+++ b/src/g_hexen/a_dragon.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_enemy.h"
@@ -6,7 +7,7 @@
 #include "m_random.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
-
+*/
 
 static FRandom pr_dragonseek ("DragonSeek");
 static FRandom pr_dragonflight ("DragonFlight");
diff --git a/src/g_hexen/a_fighteraxe.cpp b/src/g_hexen/a_fighteraxe.cpp
index f6ac7e68f..9e2e36963 100644
--- a/src/g_hexen/a_fighteraxe.cpp
+++ b/src/g_hexen/a_fighteraxe.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,17 +6,16 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
-#include "p_effect.h"
 #include "thingdef/thingdef.h"
+*/
 
 #define AXERANGE	((fixed_t)(2.25*MELEERANGE))
 
-static FRandom pr_atk ("FAxeAtk");
+static FRandom pr_axeatk ("FAxeAtk");
 
 void A_FAxeCheckReady (AActor *actor);
 void A_FAxeCheckUp (AActor *actor);
@@ -203,8 +203,8 @@ DEFINE_ACTION_FUNCTION(AActor, A_FAxeAttack)
 	}
 	AActor *pmo=player->mo;
 
-	damage = 40+(pr_atk()&15);
-	damage += pr_atk()&7;
+	damage = 40+(pr_axeatk()&15);
+	damage += pr_axeatk()&7;
 	power = 0;
 	weapon = player->ReadyWeapon;
 	if (player->ReadyWeapon->Ammo1->Amount > 0)
diff --git a/src/g_hexen/a_fighterhammer.cpp b/src/g_hexen/a_fighterhammer.cpp
index 649b5961b..2de5e6189 100644
--- a/src/g_hexen/a_fighterhammer.cpp
+++ b/src/g_hexen/a_fighterhammer.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,16 +6,16 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 const fixed_t HAMMER_RANGE = MELEERANGE+MELEERANGE/2;
 
-static FRandom pr_atk ("FHammerAtk");
+static FRandom pr_hammeratk ("FHammerAtk");
 
 extern void AdjustPlayerAngle (AActor *pmo, AActor *linetarget);
 
@@ -40,7 +41,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_FHammerAttack)
 	}
 	AActor *pmo=player->mo;
 
-	damage = 60+(pr_atk()&63);
+	damage = 60+(pr_hammeratk()&63);
 	power = 10*FRACUNIT;
 	for (i = 0; i < 16; i++)
 	{
diff --git a/src/g_hexen/a_fighterplayer.cpp b/src/g_hexen/a_fighterplayer.cpp
index 014b159bf..ba1bc9e82 100644
--- a/src/g_hexen/a_fighterplayer.cpp
+++ b/src/g_hexen/a_fighterplayer.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,11 +6,10 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
-
+*/
 
 // Fighter Weapon Base Class ------------------------------------------------
 
diff --git a/src/g_hexen/a_fighterquietus.cpp b/src/g_hexen/a_fighterquietus.cpp
index e5b2d880b..3012913a6 100644
--- a/src/g_hexen/a_fighterquietus.cpp
+++ b/src/g_hexen/a_fighterquietus.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,12 +6,12 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "a_weaponpiece.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_quietusdrop ("QuietusDrop");
 static FRandom pr_fswordflame ("FSwordFlame");
diff --git a/src/g_hexen/a_firedemon.cpp b/src/g_hexen/a_firedemon.cpp
index b9d24bec8..bf26dbcd0 100644
--- a/src/g_hexen/a_firedemon.cpp
+++ b/src/g_hexen/a_firedemon.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -6,6 +7,7 @@
 #include "a_action.h"
 #include "m_random.h"
 #include "thingdef/thingdef.h"
+*/
 
 #define FIREDEMON_ATTACK_RANGE	64*8*FRACUNIT
 
diff --git a/src/g_hexen/a_flechette.cpp b/src/g_hexen/a_flechette.cpp
index a1ea8339b..496390a78 100644
--- a/src/g_hexen/a_flechette.cpp
+++ b/src/g_hexen/a_flechette.cpp
@@ -1,10 +1,10 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -12,6 +12,7 @@
 #include "w_wad.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_poisonbag ("PoisonBag");
 static FRandom pr_poisoncloud ("PoisonCloud");
diff --git a/src/g_hexen/a_fog.cpp b/src/g_hexen/a_fog.cpp
index df7280712..ea4864fff 100644
--- a/src/g_hexen/a_fog.cpp
+++ b/src/g_hexen/a_fog.cpp
@@ -1,6 +1,8 @@
+/*
 #include "m_random.h"
 #include "p_local.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_fogspawn ("FogSpawn");
 
diff --git a/src/g_hexen/a_healingradius.cpp b/src/g_hexen/a_healingradius.cpp
index 8a8ad17bc..b827f666b 100644
--- a/src/g_hexen/a_healingradius.cpp
+++ b/src/g_hexen/a_healingradius.cpp
@@ -1,15 +1,16 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "m_random.h"
 #include "a_action.h"
 #include "a_hexenglobal.h"
 #include "gi.h"
 #include "doomstat.h"
+*/
 
 #define HEAL_RADIUS_DIST	255*FRACUNIT
 
diff --git a/src/g_hexen/a_heresiarch.cpp b/src/g_hexen/a_heresiarch.cpp
index e4274a126..6ce8bf6db 100644
--- a/src/g_hexen/a_heresiarch.cpp
+++ b/src/g_hexen/a_heresiarch.cpp
@@ -1,15 +1,15 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
 #include "s_sound.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "m_random.h"
 #include "a_hexenglobal.h"
 #include "i_system.h"
-#include "p_acs.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 //============================================================================
 //
diff --git a/src/g_hexen/a_hexenmisc.cpp b/src/g_hexen/a_hexenmisc.cpp
new file mode 100644
index 000000000..ff6b56202
--- /dev/null
+++ b/src/g_hexen/a_hexenmisc.cpp
@@ -0,0 +1,53 @@
+#include "actor.h"
+#include "info.h"
+#include "p_local.h"
+#include "s_sound.h"
+#include "a_action.h"
+#include "m_random.h"
+#include "a_sharedglobal.h"
+#include "a_hexenglobal.h"
+#include "i_system.h"
+#include "thingdef/thingdef.h"
+#include "gi.h"
+#include "g_level.h"
+#include "p_enemy.h"
+#include "a_weaponpiece.h"
+#include "doomstat.h"
+#include "p_lnspec.h"
+#include "p_terrain.h"
+#include "m_bbox.h"
+#include "ravenshared.h"
+
+// Include all the Hexen stuff here to reduce compile time
+#include "a_bats.cpp"
+#include "a_bishop.cpp"
+#include "a_blastradius.cpp"
+#include "a_boostarmor.cpp"
+#include "a_centaur.cpp"
+#include "a_clericflame.cpp"
+#include "a_clericholy.cpp"
+#include "a_clericmace.cpp"
+#include "a_clericstaff.cpp"
+#include "a_dragon.cpp"
+#include "a_fighteraxe.cpp"
+#include "a_fighterhammer.cpp"
+#include "a_fighterplayer.cpp"
+#include "a_fighterquietus.cpp"
+#include "a_firedemon.cpp"
+#include "a_flechette.cpp"
+#include "a_fog.cpp"
+#include "a_healingradius.cpp"
+#include "a_heresiarch.cpp"
+#include "a_hexenspecialdecs.cpp"
+#include "a_iceguy.cpp"
+#include "a_korax.cpp"
+#include "a_magecone.cpp"
+#include "a_magelightning.cpp"
+#include "a_magestaff.cpp"
+#include "a_magewand.cpp"
+#include "a_pig.cpp"
+#include "a_serpent.cpp"
+#include "a_spike.cpp"
+#include "a_summon.cpp"
+#include "a_teleportother.cpp"
+#include "a_wraith.cpp"
diff --git a/src/g_hexen/a_hexenspecialdecs.cpp b/src/g_hexen/a_hexenspecialdecs.cpp
index 8c65ba34f..fca9badec 100644
--- a/src/g_hexen/a_hexenspecialdecs.cpp
+++ b/src/g_hexen/a_hexenspecialdecs.cpp
@@ -2,10 +2,10 @@
 ** Decorations that do special things
 */
 
+/*
 #include "actor.h"
 #include "info.h"
 #include "a_action.h"
-#include "p_enemy.h"
 #include "m_random.h"
 #include "s_sound.h"
 #include "p_local.h"
@@ -14,6 +14,7 @@
 #include "thingdef/thingdef.h"
 #include "g_level.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_pottery ("PotteryExplode");
 static FRandom pr_bit ("PotteryChooseBit");
diff --git a/src/g_hexen/a_iceguy.cpp b/src/g_hexen/a_iceguy.cpp
index e3c751a7a..cbc9a54af 100644
--- a/src/g_hexen/a_iceguy.cpp
+++ b/src/g_hexen/a_iceguy.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -6,6 +7,7 @@
 #include "a_action.h"
 #include "m_random.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_iceguylook ("IceGuyLook");
 static FRandom pr_iceguychase ("IceGuyChase");
diff --git a/src/g_hexen/a_korax.cpp b/src/g_hexen/a_korax.cpp
index 9a30850c5..242c39066 100644
--- a/src/g_hexen/a_korax.cpp
+++ b/src/g_hexen/a_korax.cpp
@@ -16,17 +16,18 @@
 //	255		For use in death script (spawn spots)
 //===========================================================================
 
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
 #include "p_spec.h"
 #include "s_sound.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "m_random.h"
 #include "i_system.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 const int KORAX_SPIRIT_LIFETIME = 5*TICRATE/5;	// 5 seconds
 const int KORAX_COMMAND_HEIGHT	= 120;
@@ -60,7 +61,7 @@ static FRandom pr_koraxcommand ("KoraxCommand");
 static FRandom pr_kspiritweave ("KSpiritWeave");
 static FRandom pr_kspiritseek ("KSpiritSeek");
 static FRandom pr_kspiritroam ("KSpiritRoam");
-static FRandom pr_missile ("SKoraxMissile");
+static FRandom pr_kmissile ("SKoraxMissile");
 
 void A_KoraxChase (AActor *);
 void A_KoraxStep (AActor *);
@@ -511,7 +512,7 @@ AActor *P_SpawnKoraxMissile (fixed_t x, fixed_t y, fixed_t z,
 	an = R_PointToAngle2(x, y, dest->x, dest->y);
 	if (dest->flags & MF_SHADOW)
 	{ // Invisible target
-		an += pr_missile.Random2()<<21;
+		an += pr_kmissile.Random2()<<21;
 	}
 	th->angle = an;
 	an >>= ANGLETOFINESHIFT;
diff --git a/src/g_hexen/a_magecone.cpp b/src/g_hexen/a_magecone.cpp
index 36caa65d9..97bee7302 100644
--- a/src/g_hexen/a_magecone.cpp
+++ b/src/g_hexen/a_magecone.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,12 +6,12 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 const int SHARDSPAWN_LEFT	= 1;
 const int SHARDSPAWN_RIGHT	= 2;
diff --git a/src/g_hexen/a_magelightning.cpp b/src/g_hexen/a_magelightning.cpp
index df369798d..88d0d3c1c 100644
--- a/src/g_hexen/a_magelightning.cpp
+++ b/src/g_hexen/a_magelightning.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,13 +6,13 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 #define ZAGSPEED	FRACUNIT
 
diff --git a/src/g_hexen/a_magestaff.cpp b/src/g_hexen/a_magestaff.cpp
index 00072210b..2eb15c730 100644
--- a/src/g_hexen/a_magestaff.cpp
+++ b/src/g_hexen/a_magestaff.cpp
@@ -1,14 +1,15 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
 #include "m_random.h"
 #include "s_sound.h"
-#include "p_enemy.h"
 #include "a_hexenglobal.h"
 #include "gstrings.h"
 #include "a_weaponpiece.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_mstafftrack ("MStaffTrack");
 static FRandom pr_bloodscourgedrop ("BloodScourgeDrop");
diff --git a/src/g_hexen/a_magewand.cpp b/src/g_hexen/a_magewand.cpp
index 82f7a0168..aadbb154d 100644
--- a/src/g_hexen/a_magewand.cpp
+++ b/src/g_hexen/a_magewand.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -5,12 +6,12 @@
 #include "d_player.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "p_pspr.h"
 #include "gstrings.h"
 #include "a_hexenglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_smoke ("MWandSmoke");
 
diff --git a/src/g_hexen/a_pig.cpp b/src/g_hexen/a_pig.cpp
index 2ff019b99..e86efffb5 100644
--- a/src/g_hexen/a_pig.cpp
+++ b/src/g_hexen/a_pig.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "gi.h"
 #include "m_random.h"
@@ -11,6 +12,7 @@
 #include "d_event.h"
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_snoutattack ("SnoutAttack");
 static FRandom pr_pigattack ("PigAttack");
diff --git a/src/g_hexen/a_serpent.cpp b/src/g_hexen/a_serpent.cpp
index 9e2d6624d..bf4f8be63 100644
--- a/src/g_hexen/a_serpent.cpp
+++ b/src/g_hexen/a_serpent.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -7,6 +8,7 @@
 #include "m_random.h"
 #include "p_terrain.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_serpentchase ("SerpentChase");
 static FRandom pr_serpenthump ("SerpentHump");
diff --git a/src/g_hexen/a_spike.cpp b/src/g_hexen/a_spike.cpp
index 1e9d7f9d8..ea9d7c3d2 100644
--- a/src/g_hexen/a_spike.cpp
+++ b/src/g_hexen/a_spike.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "s_sound.h"
 #include "m_bbox.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_thrustraise ("ThrustRaise");
 
diff --git a/src/g_hexen/a_summon.cpp b/src/g_hexen/a_summon.cpp
index 74644d27c..4335abed0 100644
--- a/src/g_hexen/a_summon.cpp
+++ b/src/g_hexen/a_summon.cpp
@@ -1,13 +1,14 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "ravenshared.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 void A_Summon (AActor *);
 
diff --git a/src/g_hexen/a_teleportother.cpp b/src/g_hexen/a_teleportother.cpp
index 887887a83..2b1bbcc55 100644
--- a/src/g_hexen/a_teleportother.cpp
+++ b/src/g_hexen/a_teleportother.cpp
@@ -1,15 +1,16 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "p_lnspec.h"
 #include "m_random.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
 #include "doomstat.h"
+*/
 
 #define TELEPORT_LIFE 1
 
diff --git a/src/g_hexen/a_wraith.cpp b/src/g_hexen/a_wraith.cpp
index 976f27ccb..3cf4b987d 100644
--- a/src/g_hexen/a_wraith.cpp
+++ b/src/g_hexen/a_wraith.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "info.h"
 #include "p_local.h"
@@ -7,6 +8,7 @@
 #include "m_random.h"
 #include "a_sharedglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_stealhealth ("StealHealth");
 static FRandom pr_wraithfx2 ("WraithFX2");
diff --git a/src/g_hexen/hexen_sbar.cpp b/src/g_hexen/hexen_sbar.cpp
index ca8869973..75dc0f230 100644
--- a/src/g_hexen/hexen_sbar.cpp
+++ b/src/g_hexen/hexen_sbar.cpp
@@ -16,6 +16,7 @@
 #include "a_keys.h"
 #include "r_translate.h"
 #include "a_weaponpiece.h"
+#include "v_palette.h"
 
 
 class FManaBar : public FTexture
diff --git a/src/g_level.cpp b/src/g_level.cpp
index ddeaec6c7..9b4a48235 100644
--- a/src/g_level.cpp
+++ b/src/g_level.cpp
@@ -77,6 +77,7 @@
 #include "cmdlib.h"
 #include "d_net.h"
 #include "d_netinf.h"
+#include "v_palette.h"
 
 #include "gi.h"
 
diff --git a/src/g_level.h b/src/g_level.h
index 39feead28..b288cc06e 100644
--- a/src/g_level.h
+++ b/src/g_level.h
@@ -122,7 +122,7 @@
 #define LEVEL_SMOOTHLIGHTING		UCONST64(0x100000000000000)	// Level uses the smooth lighting feature.
 
 
-struct acsdefered_s;
+struct acsdefered_t;
 
 struct FSpecialAction
 {
@@ -171,7 +171,7 @@ struct level_info_t
 	int			musicorder;
 	FCompressedMemFile	*snapshot;
 	DWORD		snapshotVer;
-	struct acsdefered_s *defered;
+	struct acsdefered_t *defered;
 	char		skypic2[9];
 	float		skyspeed1;
 	float		skyspeed2;
diff --git a/src/g_shared/a_artifacts.cpp b/src/g_shared/a_artifacts.cpp
index b79162970..74c7f5303 100644
--- a/src/g_shared/a_artifacts.cpp
+++ b/src/g_shared/a_artifacts.cpp
@@ -8,7 +8,6 @@
 #include "p_local.h"
 #include "p_spec.h"
 #include "p_lnspec.h"
-#include "p_enemy.h"
 #include "p_effect.h"
 #include "a_artifacts.h"
 #include "sbar.h"
@@ -19,6 +18,7 @@
 #include "a_morph.h"
 #include "g_level.h"
 #include "doomstat.h"
+#include "v_palette.h"
 
 static FRandom pr_torch ("Torch");
 
diff --git a/src/g_shared/a_decals.cpp b/src/g_shared/a_decals.cpp
index d6f56a1bd..e77e352b3 100644
--- a/src/g_shared/a_decals.cpp
+++ b/src/g_shared/a_decals.cpp
@@ -43,6 +43,7 @@
 #include "c_dispatch.h"
 #include "d_net.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 static fixed_t DecalWidth, DecalLeft, DecalRight;
 static fixed_t SpreadZ;
@@ -301,7 +302,7 @@ fixed_t DBaseDecal::GetRealZ (const side_t *wall) const
 	default:
 		return Z;
 	case RF_RELUPPER:
-		if (curline->linedef->flags & ML_DONTPEGTOP)
+		if (line->flags & ML_DONTPEGTOP)
 		{
 			return Z + front->GetPlaneTexZ(sector_t::ceiling);
 		}
@@ -310,7 +311,7 @@ fixed_t DBaseDecal::GetRealZ (const side_t *wall) const
 			return Z + back->GetPlaneTexZ(sector_t::ceiling);
 		}
 	case RF_RELLOWER:
-		if (curline->linedef->flags & ML_DONTPEGBOTTOM)
+		if (line->flags & ML_DONTPEGBOTTOM)
 		{
 			return Z + front->GetPlaneTexZ(sector_t::ceiling);
 		}
@@ -319,7 +320,7 @@ fixed_t DBaseDecal::GetRealZ (const side_t *wall) const
 			return Z + back->GetPlaneTexZ(sector_t::floor);
 		}
 	case RF_RELMID:
-		if (curline->linedef->flags & ML_DONTPEGBOTTOM)
+		if (line->flags & ML_DONTPEGBOTTOM)
 		{
 			return Z + front->GetPlaneTexZ(sector_t::floor);
 		}
diff --git a/src/g_shared/a_morph.cpp b/src/g_shared/a_morph.cpp
index 24e466a38..825fed500 100644
--- a/src/g_shared/a_morph.cpp
+++ b/src/g_shared/a_morph.cpp
@@ -4,7 +4,6 @@
 #include "gstrings.h"
 #include "p_local.h"
 #include "gi.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "m_random.h"
 #include "a_sharedglobal.h"
diff --git a/src/g_shared/a_puzzleitems.cpp b/src/g_shared/a_puzzleitems.cpp
index b7ab3bc1a..68bca31fb 100644
--- a/src/g_shared/a_puzzleitems.cpp
+++ b/src/g_shared/a_puzzleitems.cpp
@@ -3,7 +3,6 @@
 #include "a_artifacts.h"
 #include "gstrings.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "c_console.h"
 #include "doomstat.h"
diff --git a/src/g_shared/a_soundsequence.cpp b/src/g_shared/a_soundsequence.cpp
index 52f587ea2..94e8e1e60 100644
--- a/src/g_shared/a_soundsequence.cpp
+++ b/src/g_shared/a_soundsequence.cpp
@@ -65,6 +65,7 @@
 #include "s_sound.h"
 #include "m_random.h"
 #include "s_sndseq.h"
+#include "farchive.h"
 
 // SoundSequenceSlot --------------------------------------------------------
 
diff --git a/src/g_shared/sbar.h b/src/g_shared/sbar.h
index 99453cdde..00f471c1e 100644
--- a/src/g_shared/sbar.h
+++ b/src/g_shared/sbar.h
@@ -36,7 +36,6 @@
 #include "v_collection.h"
 #include "v_text.h"
 
-struct patch_t;
 class player_t;
 struct FRemapTable;
 
diff --git a/src/g_shared/sbarinfo_display.cpp b/src/g_shared/sbarinfo_display.cpp
index 66e58ec50..63dc55a88 100644
--- a/src/g_shared/sbarinfo_display.cpp
+++ b/src/g_shared/sbarinfo_display.cpp
@@ -55,6 +55,7 @@
 #include "a_weaponpiece.h"
 #include "a_strifeglobal.h"
 #include "g_level.h"
+#include "v_palette.h"
 
 static FRandom pr_chainwiggle; //use the same method of chain wiggling as heretic.
 
diff --git a/src/g_shared/shared_sbar.cpp b/src/g_shared/shared_sbar.cpp
index c019d4150..f72ef0958 100644
--- a/src/g_shared/shared_sbar.cpp
+++ b/src/g_shared/shared_sbar.cpp
@@ -46,11 +46,12 @@
 #include "v_text.h"
 #include "s_sound.h"
 #include "gi.h"
-#include "p_effect.h"
 #include "doomstat.h"
 #include "g_level.h"
 #include "d_net.h"
 #include "colormatcher.h"
+#include "v_palette.h"
+
 #include "../version.h"
 
 #define XHAIRSHRINKSIZE		(FRACUNIT/18)
diff --git a/src/g_strife/a_acolyte.cpp b/src/g_strife/a_acolyte.cpp
index f46109dfe..72f1cd0d1 100644
--- a/src/g_strife/a_acolyte.cpp
+++ b/src/g_strife/a_acolyte.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -8,6 +9,7 @@
 #include "doomdata.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 //============================================================================
 //
diff --git a/src/g_strife/a_alienspectres.cpp b/src/g_strife/a_alienspectres.cpp
index d77a99065..085113f9f 100644
--- a/src/g_strife/a_alienspectres.cpp
+++ b/src/g_strife/a_alienspectres.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -10,6 +11,7 @@
 #include "gstrings.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_spectrespawn ("AlienSpectreSpawn");
 static FRandom pr_spectrechunk ("212e4");
diff --git a/src/g_strife/a_coin.cpp b/src/g_strife/a_coin.cpp
index 3a4605b05..dd3610039 100644
--- a/src/g_strife/a_coin.cpp
+++ b/src/g_strife/a_coin.cpp
@@ -1,6 +1,8 @@
+/*
 #include "a_pickups.h"
 #include "a_strifeglobal.h"
 #include "gstrings.h"
+*/
 
 // Coin ---------------------------------------------------------------------
 
diff --git a/src/g_strife/a_crusader.cpp b/src/g_strife/a_crusader.cpp
index bcab75493..cd0a14ea5 100644
--- a/src/g_strife/a_crusader.cpp
+++ b/src/g_strife/a_crusader.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -6,6 +7,7 @@
 #include "s_sound.h"
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 bool Sys_1ed64 (AActor *self)
 {
diff --git a/src/g_strife/a_entityboss.cpp b/src/g_strife/a_entityboss.cpp
index 0d6156248..b221c7c2d 100644
--- a/src/g_strife/a_entityboss.cpp
+++ b/src/g_strife/a_entityboss.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -7,6 +8,7 @@
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
+*/
 
 static FRandom pr_entity ("Entity");
 
diff --git a/src/g_strife/a_inquisitor.cpp b/src/g_strife/a_inquisitor.cpp
index c2beb7fcb..e6aabff16 100644
--- a/src/g_strife/a_inquisitor.cpp
+++ b/src/g_strife/a_inquisitor.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -5,6 +6,7 @@
 #include "p_enemy.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_inq ("Inquisitor");
 
diff --git a/src/g_strife/a_loremaster.cpp b/src/g_strife/a_loremaster.cpp
index 731a75dc0..ebe5c6a6d 100644
--- a/src/g_strife/a_loremaster.cpp
+++ b/src/g_strife/a_loremaster.cpp
@@ -1,11 +1,12 @@
+/*
 #include "actor.h"
 #include "a_action.h"
 #include "a_strifeglobal.h"
 #include "m_random.h"
-#include "p_enemy.h"
 #include "p_local.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 // Loremaster (aka Priest) --------------------------------------------------
 
diff --git a/src/g_strife/a_macil.cpp b/src/g_strife/a_macil.cpp
index 76f6333d6..6557ef7cf 100644
--- a/src/g_strife/a_macil.cpp
+++ b/src/g_strife/a_macil.cpp
@@ -1,10 +1,11 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "a_strifeglobal.h"
+*/
 
 // Macil (version 2) ---------------------------------------------------------
 
diff --git a/src/g_strife/a_oracle.cpp b/src/g_strife/a_oracle.cpp
index 50cf78f8e..11a9a52e4 100644
--- a/src/g_strife/a_oracle.cpp
+++ b/src/g_strife/a_oracle.cpp
@@ -1,8 +1,11 @@
+/*
 #include "actor.h"
 #include "a_action.h"
 #include "a_strifeglobal.h"
 #include "p_enemy.h"
+#include "r_defs.h"
 #include "thingdef/thingdef.h"
+*/
 
 class AOracle : public AActor
 {
diff --git a/src/g_strife/a_programmer.cpp b/src/g_strife/a_programmer.cpp
index 2eee0aa8d..a8bcf42ec 100644
--- a/src/g_strife/a_programmer.cpp
+++ b/src/g_strife/a_programmer.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -9,7 +10,7 @@
 #include "thingdef/thingdef.h"
 #include "g_level.h"
 #include "doomstat.h"
-
+*/
 static FRandom pr_prog ("Programmer");
 
 // The Programmer level ending thing ----------------------------------------
diff --git a/src/g_strife/a_reaver.cpp b/src/g_strife/a_reaver.cpp
index 08042c653..893386534 100644
--- a/src/g_strife/a_reaver.cpp
+++ b/src/g_strife/a_reaver.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "p_enemy.h"
 #include "a_action.h"
@@ -6,6 +7,7 @@
 #include "p_local.h"
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_reaverattack ("ReaverAttack");
 
diff --git a/src/g_strife/a_rebels.cpp b/src/g_strife/a_rebels.cpp
index 4519b26cf..2625ca173 100644
--- a/src/g_strife/a_rebels.cpp
+++ b/src/g_strife/a_rebels.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -9,6 +10,7 @@
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_shootgun ("ShootGun");
 
diff --git a/src/g_strife/a_sentinel.cpp b/src/g_strife/a_sentinel.cpp
index c957ac2c2..141ad2b8b 100644
--- a/src/g_strife/a_sentinel.cpp
+++ b/src/g_strife/a_sentinel.cpp
@@ -1,9 +1,11 @@
+/*
 #include "actor.h"
 #include "p_enemy.h"
 #include "a_action.h"
 #include "p_local.h"
 #include "m_random.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_sentinelrefire ("SentinelRefire");
 
diff --git a/src/g_strife/a_spectral.cpp b/src/g_strife/a_spectral.cpp
index 92c96b18c..5ec8a4fa0 100644
--- a/src/g_strife/a_spectral.cpp
+++ b/src/g_strife/a_spectral.cpp
@@ -1,12 +1,13 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_enemy.h"
 #include "s_sound.h"
 #include "m_random.h"
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 AActor *P_SpawnSubMissile (AActor *source, const PClass *type, AActor *target);
 
diff --git a/src/g_strife/a_stalker.cpp b/src/g_strife/a_stalker.cpp
index f49bf42cd..67cbd3282 100644
--- a/src/g_strife/a_stalker.cpp
+++ b/src/g_strife/a_stalker.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -5,6 +6,7 @@
 #include "p_enemy.h"
 #include "s_sound.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_stalker ("Stalker");
 
diff --git a/src/g_strife/a_strifeitems.cpp b/src/g_strife/a_strifeitems.cpp
index 9e65dbfee..b8f28d8ae 100644
--- a/src/g_strife/a_strifeitems.cpp
+++ b/src/g_strife/a_strifeitems.cpp
@@ -1,3 +1,4 @@
+/*
 #include "info.h"
 #include "a_pickups.h"
 #include "d_player.h"
@@ -15,7 +16,7 @@
 #include "thingdef/thingdef.h"
 #include "g_level.h"
 #include "doomstat.h"
-
+*/
 // Degnin Ore ---------------------------------------------------------------
 
 IMPLEMENT_CLASS(ADegninOre)
diff --git a/src/g_strife/a_strifestuff.cpp b/src/g_strife/a_strifestuff.cpp
index 2bd4685ff..a65cc91b4 100644
--- a/src/g_strife/a_strifestuff.cpp
+++ b/src/g_strife/a_strifestuff.cpp
@@ -12,6 +12,32 @@
 #include "c_console.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+#include "gstrings.h"
+#include "a_keys.h"
+#include "a_sharedglobal.h"
+#include "templates.h"
+#include "d_event.h"
+
+// Include all the other Strife stuff here to reduce compile time
+#include "a_acolyte.cpp"
+#include "a_alienspectres.cpp"
+#include "a_coin.cpp"
+#include "a_crusader.cpp"
+#include "a_entityboss.cpp"
+#include "a_inquisitor.cpp"
+#include "a_loremaster.cpp"
+#include "a_macil.cpp"
+#include "a_oracle.cpp"
+#include "a_programmer.cpp"
+#include "a_reaver.cpp"
+#include "a_rebels.cpp"
+#include "a_sentinel.cpp"
+#include "a_spectral.cpp"
+#include "a_stalker.cpp"
+#include "a_strifeitems.cpp"
+#include "a_strifeweapons.cpp"
+#include "a_templar.cpp"
+#include "a_thingstoblowup.cpp"
 
 // Notes so I don't forget them:
 // Strife does some extra stuff in A_Explode if a player caused the explosion. (probably NoiseAlert)
@@ -521,7 +547,7 @@ void APowerCoupling::Die (AActor *source, AActor *inflictor)
 	players[i].mo->GiveInventoryType (QuestItemClasses[5]);
 	S_Sound (CHAN_VOICE, "svox/voc13", 1, ATTN_NORM);
 	players[i].SetLogNumber (13);
-	P_DropItem (this, "BrokenPowerCoupling", -1, 256);
+	P_DropItem (this, PClass::FindClass("BrokenPowerCoupling"), -1, 256);
 	Destroy ();
 }
 
diff --git a/src/g_strife/a_strifeweapons.cpp b/src/g_strife/a_strifeweapons.cpp
index c9382fa28..72b49e900 100644
--- a/src/g_strife/a_strifeweapons.cpp
+++ b/src/g_strife/a_strifeweapons.cpp
@@ -1,3 +1,4 @@
+/*
 #include "a_pickups.h"
 #include "p_local.h"
 #include "m_random.h"
@@ -7,6 +8,7 @@
 #include "templates.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 // Note: Strife missiles do 1-4 times their damage amount.
 // Doom missiles do 1-8 times their damage amount, so to
diff --git a/src/g_strife/a_templar.cpp b/src/g_strife/a_templar.cpp
index 79ea9960b..afdac2e15 100644
--- a/src/g_strife/a_templar.cpp
+++ b/src/g_strife/a_templar.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "a_action.h"
@@ -6,6 +7,7 @@
 #include "s_sound.h"
 #include "a_strifeglobal.h"
 #include "thingdef/thingdef.h"
+*/
 
 static FRandom pr_templar ("Templar");
 
diff --git a/src/g_strife/a_thingstoblowup.cpp b/src/g_strife/a_thingstoblowup.cpp
index be167e383..8c68f2600 100644
--- a/src/g_strife/a_thingstoblowup.cpp
+++ b/src/g_strife/a_thingstoblowup.cpp
@@ -1,3 +1,4 @@
+/*
 #include "actor.h"
 #include "m_random.h"
 #include "p_local.h"
@@ -8,6 +9,7 @@
 #include "thingdef/thingdef.h"
 #include "thingdef/thingdef.h"
 #include "doomstat.h"
+*/
 
 static FRandom pr_bang4cloud ("Bang4Cloud");
 static FRandom pr_lightout ("LightOut");
diff --git a/src/g_strife/strife_sbar.cpp b/src/g_strife/strife_sbar.cpp
index d0fd3ad27..782eec96d 100644
--- a/src/g_strife/strife_sbar.cpp
+++ b/src/g_strife/strife_sbar.cpp
@@ -16,6 +16,7 @@
 #include "gi.h"
 #include "g_level.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 // Number of tics to move the popscreen up and down.
 #define POP_TIME (TICRATE/8)
diff --git a/src/hu_scores.cpp b/src/hu_scores.cpp
index eaf667862..2366c924f 100644
--- a/src/hu_scores.cpp
+++ b/src/hu_scores.cpp
@@ -43,6 +43,9 @@
 #include "doomstat.h"
 #include "g_level.h"
 #include "d_netinf.h"
+#include "v_font.h"
+#include "v_palette.h"
+#include "d_player.h"
 
 // MACROS ------------------------------------------------------------------
 
diff --git a/src/m_cheat.cpp b/src/m_cheat.cpp
index cac837b6e..10ae08d55 100644
--- a/src/m_cheat.cpp
+++ b/src/m_cheat.cpp
@@ -39,7 +39,6 @@
 #include "w_wad.h"
 #include "a_keys.h"
 #include "templates.h"
-#include "p_lnspec.h"
 #include "c_console.h"
 #include "r_translate.h"
 #include "g_level.h"
diff --git a/src/m_menu.cpp b/src/m_menu.cpp
index e7d97544f..a6f2411af 100644
--- a/src/m_menu.cpp
+++ b/src/m_menu.cpp
@@ -45,6 +45,7 @@
 #include "i_system.h"
 #include "i_video.h"
 #include "v_video.h"
+#include "v_palette.h"
 #include "w_wad.h"
 #include "r_local.h"
 #include "hu_stuff.h"
diff --git a/src/m_misc.cpp b/src/m_misc.cpp
index 5a9656004..381656e03 100644
--- a/src/m_misc.cpp
+++ b/src/m_misc.cpp
@@ -57,6 +57,7 @@
 #include "i_system.h"
 #include "i_video.h"
 #include "v_video.h"
+#include "r_defs.h"
 
 #include "hu_stuff.h"
 
diff --git a/src/m_options.cpp b/src/m_options.cpp
index 82d84b178..09b9af641 100644
--- a/src/m_options.cpp
+++ b/src/m_options.cpp
@@ -60,6 +60,7 @@
 #include "gi.h"
 
 #include "r_local.h"
+#include "v_palette.h"
 #include "gameconfigfile.h"
 
 #include "hu_stuff.h"
diff --git a/src/m_png.cpp b/src/m_png.cpp
index 0405caef1..1a33221e2 100644
--- a/src/m_png.cpp
+++ b/src/m_png.cpp
@@ -44,6 +44,7 @@
 #include "m_crc32.h"
 #include "m_swap.h"
 #include "c_cvars.h"
+#include "r_defs.h"
 #include "v_video.h"
 #include "m_png.h"
 #include "templates.h"
diff --git a/src/p_3dmidtex.cpp b/src/p_3dmidtex.cpp
index 039e9871d..ef449ecd3 100644
--- a/src/p_3dmidtex.cpp
+++ b/src/p_3dmidtex.cpp
@@ -37,7 +37,6 @@
 
 #include "templates.h"
 #include "p_local.h"
-#include "p_lnspec.h"
 
 
 //============================================================================
diff --git a/src/p_3dmidtex.h b/src/p_3dmidtex.h
index 6b7201b7b..278a19177 100644
--- a/src/p_3dmidtex.h
+++ b/src/p_3dmidtex.h
@@ -3,8 +3,10 @@
 #define __3DMIDTEX_H
 
 #include "doomtype.h"
-#include "r_defs.h"
 
+class DInterpolation;
+struct sector_t;
+struct line_t;
 class AActor;
 
 bool P_Scroll3dMidtex(sector_t *sector, int crush, fixed_t move, bool ceiling);
diff --git a/src/p_acs.cpp b/src/p_acs.cpp
index 11c86b6c6..b64ce92a6 100644
--- a/src/p_acs.cpp
+++ b/src/p_acs.cpp
@@ -5705,7 +5705,7 @@ static void addDefered (level_info_t *i, acsdefered_t::EType type, int script, i
 {
 	if (i)
 	{
-		acsdefered_t *def = new acsdefered_s;
+		acsdefered_t *def = new acsdefered_t;
 
 		def->next = i->defered;
 		def->type = type;
@@ -5795,13 +5795,13 @@ void P_TerminateScript (int script, char *map)
 		SetScriptState (script, DLevelScript::SCRIPT_PleaseRemove);
 }
 
-FArchive &operator<< (FArchive &arc, acsdefered_s *&defertop)
+FArchive &operator<< (FArchive &arc, acsdefered_t *&defertop)
 {
 	BYTE more;
 
 	if (arc.IsStoring ())
 	{
-		acsdefered_s *defer = defertop;
+		acsdefered_t *defer = defertop;
 		more = 1;
 		while (defer)
 		{
@@ -5817,14 +5817,14 @@ FArchive &operator<< (FArchive &arc, acsdefered_s *&defertop)
 	}
 	else
 	{
-		acsdefered_s **defer = &defertop;
+		acsdefered_t **defer = &defertop;
 
 		arc << more;
 		while (more)
 		{
-			*defer = new acsdefered_s;
+			*defer = new acsdefered_t;
 			arc << more;
-			(*defer)->type = (acsdefered_s::EType)more;
+			(*defer)->type = (acsdefered_t::EType)more;
 			arc << (*defer)->script << (*defer)->playernum
 				<< (*defer)->arg0 << (*defer)->arg1 << (*defer)->arg2;
 			defer = &((*defer)->next);
diff --git a/src/p_acs.h b/src/p_acs.h
index 630dc408f..19457ed6e 100644
--- a/src/p_acs.h
+++ b/src/p_acs.h
@@ -731,9 +731,9 @@ private:
 };
 
 // The structure used to control scripts between maps
-struct acsdefered_s
+struct acsdefered_t
 {
-	struct acsdefered_s *next;
+	struct acsdefered_t *next;
 
 	enum EType
 	{
@@ -746,8 +746,7 @@ struct acsdefered_s
 	int arg0, arg1, arg2;
 	int playernum;
 };
-typedef struct acsdefered_s acsdefered_t;
 
-FArchive &operator<< (FArchive &arc, acsdefered_s *&defer);
+FArchive &operator<< (FArchive &arc, acsdefered_t *&defer);
 
 #endif //__P_ACS_H__
diff --git a/src/p_conversation.cpp b/src/p_conversation.cpp
index 72b8257a3..444601a2a 100644
--- a/src/p_conversation.cpp
+++ b/src/p_conversation.cpp
@@ -36,6 +36,7 @@
 
 #include "actor.h"
 #include "r_data.h"
+#include "r_main.h"
 #include "p_conversation.h"
 #include "w_wad.h"
 #include "cmdlib.h"
diff --git a/src/p_effect.cpp b/src/p_effect.cpp
index 535f1877e..48a2bdd3e 100644
--- a/src/p_effect.cpp
+++ b/src/p_effect.cpp
@@ -48,6 +48,7 @@
 #include "s_sound.h"
 #include "templates.h"
 #include "gi.h"
+#include "v_palette.h"
 #include "colormatcher.h"
 
 CVAR (Int, cl_rockettrails, 1, CVAR_ARCHIVE);
diff --git a/src/p_effect.h b/src/p_effect.h
index 4f1dbf0d8..1ca18e340 100644
--- a/src/p_effect.h
+++ b/src/p_effect.h
@@ -50,6 +50,7 @@
 #define FX_WHITEFOUNTAIN	0x00070000
 
 struct particle_t;
+class AActor;
 
 particle_t *JitterParticle (int ttl);
 
diff --git a/src/p_enemy.cpp b/src/p_enemy.cpp
index 951fd1669..8584f4e23 100644
--- a/src/p_enemy.cpp
+++ b/src/p_enemy.cpp
@@ -33,7 +33,6 @@
 #include "p_local.h"
 #include "m_bbox.h"
 #include "p_lnspec.h"
-#include "p_effect.h"
 #include "s_sound.h"
 #include "g_game.h"
 #include "doomstat.h"
diff --git a/src/p_enemy.h b/src/p_enemy.h
index 7bb11faec..a994fe518 100644
--- a/src/p_enemy.h
+++ b/src/p_enemy.h
@@ -1,9 +1,14 @@
 #ifndef __P_ENEMY_H__
 #define __P_ENEMY_H__
 
-#include "r_defs.h"
 #include "thingdef/thingdef.h"
 
+struct sector_t;
+class AActor;
+class AInventory;
+struct PClass;
+
+
 enum dirtype_t
 {
 	DI_EAST,
@@ -29,10 +34,6 @@ bool P_TryWalk (AActor *actor);
 void P_NewChaseDir (AActor *actor);
 bool P_LookForPlayers (AActor *actor, INTBOOL allaround);
 AInventory *P_DropItem (AActor *source, const PClass *type, int special, int chance);
-inline AInventory *P_DropItem (AActor *source, const char *type, int special, int chance)
-{
-	return P_DropItem (source, PClass::FindClass (type), special, chance);
-}
 void P_TossItem (AActor *item);
 
 DECLARE_ACTION(A_Look)
diff --git a/src/p_enemy_a_lookex.cpp b/src/p_enemy_a_lookex.cpp
index fadf3ffd3..2e580eb45 100644
--- a/src/p_enemy_a_lookex.cpp
+++ b/src/p_enemy_a_lookex.cpp
@@ -6,7 +6,6 @@
 #include "doomdef.h"
 #include "p_local.h"
 #include "p_lnspec.h"
-#include "p_effect.h"
 #include "s_sound.h"
 #include "g_game.h"
 #include "doomstat.h"
diff --git a/src/p_mobj.cpp b/src/p_mobj.cpp
index 39c556d3d..ccd2b8560 100644
--- a/src/p_mobj.cpp
+++ b/src/p_mobj.cpp
@@ -58,6 +58,7 @@
 #include "g_level.h"
 #include "d_event.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
 
diff --git a/src/p_pspr.cpp b/src/p_pspr.cpp
index 47d9f54ed..dae12a868 100644
--- a/src/p_pspr.cpp
+++ b/src/p_pspr.cpp
@@ -23,7 +23,6 @@
 #include "doomstat.h"
 #include "gi.h"
 #include "p_pspr.h"
-#include "p_effect.h"
 #include "templates.h"
 #include "thingdef/thingdef.h"
 #include "g_level.h"
diff --git a/src/p_pspr.h b/src/p_pspr.h
index 49e6c469a..97533a2ba 100644
--- a/src/p_pspr.h
+++ b/src/p_pspr.h
@@ -28,16 +28,6 @@
 #include "tables.h"
 #include "thingdef/thingdef.h"
 
-
-//
-// Needs to include the precompiled
-//	sprite animation tables.
-// Header generated by multigen utility.
-// This includes all the data for thing animation,
-// i.e. the Thing Atrributes table
-// and the Frame Sequence table.
-#include "info.h"
-
 #define WEAPONBOTTOM			128*FRACUNIT
 
 // [RH] +0x6000 helps it meet the screen bottom
@@ -81,9 +71,13 @@ typedef struct pspdef_s
 
 } pspdef_t;
 
+class FArchive;
+
 FArchive &operator<< (FArchive &, pspdef_t &);
 
 class player_t;
+class AActor;
+struct FState;
 
 void P_SetPsprite (player_t *player, int position, FState *state);
 void P_SetPspriteNF (player_t *player, int position, FState *state);
diff --git a/src/p_saveg.cpp b/src/p_saveg.cpp
index cb19684e1..ac2643af5 100644
--- a/src/p_saveg.cpp
+++ b/src/p_saveg.cpp
@@ -41,7 +41,6 @@
 #include "r_state.h"
 #include "m_random.h"
 #include "p_saveg.h"
-#include "p_acs.h"
 #include "s_sndseq.h"
 #include "v_palette.h"
 #include "a_sharedglobal.h"
diff --git a/src/p_sectors.cpp b/src/p_sectors.cpp
index b7cefb4e3..6f02ea470 100644
--- a/src/p_sectors.cpp
+++ b/src/p_sectors.cpp
@@ -25,6 +25,7 @@
 #include "p_spec.h"
 #include "c_cvars.h"
 #include "doomstat.h"
+#include "v_palette.h"
 
 
 // [RH]
diff --git a/src/p_setup.h b/src/p_setup.h
index 8bb97ea98..abe7dd2a2 100644
--- a/src/p_setup.h
+++ b/src/p_setup.h
@@ -24,7 +24,6 @@
 #define __P_SETUP__
 
 #include "w_wad.h"
-#include "files.h"
 #include "doomdata.h"
 
 
diff --git a/src/p_things.cpp b/src/p_things.cpp
index 30e08ebf1..deaddd233 100644
--- a/src/p_things.cpp
+++ b/src/p_things.cpp
@@ -34,7 +34,6 @@
 
 #include "doomtype.h"
 #include "p_local.h"
-#include "p_effect.h"
 #include "info.h"
 #include "s_sound.h"
 #include "tables.h"
diff --git a/src/p_tick.cpp b/src/p_tick.cpp
index 5561caebd..56506bbb7 100644
--- a/src/p_tick.cpp
+++ b/src/p_tick.cpp
@@ -24,7 +24,6 @@
 
 #include "p_local.h"
 #include "p_effect.h"
-#include "p_acs.h"
 #include "c_console.h"
 #include "b_bot.h"
 #include "s_sound.h"
diff --git a/src/p_trace.h b/src/p_trace.h
index 291a5ecef..be3dda84e 100644
--- a/src/p_trace.h
+++ b/src/p_trace.h
@@ -34,7 +34,12 @@
 #ifndef __P_TRACE_H__
 #define __P_TRACE_H__
 
-#include "r_defs.h"
+#include <stddef.h>
+#include "basictypes.h"
+
+struct sector_t;
+struct line_t;
+class AActor;
 
 enum ETraceResult
 {
diff --git a/src/p_udmf.cpp b/src/p_udmf.cpp
index 2f8232f74..7cfc8ddc0 100644
--- a/src/p_udmf.cpp
+++ b/src/p_udmf.cpp
@@ -42,6 +42,7 @@
 #include "gi.h"
 #include "r_sky.h"
 #include "g_level.h"
+#include "v_palette.h"
 
 //===========================================================================
 //
diff --git a/src/p_user.cpp b/src/p_user.cpp
index 434a77188..7a573baef 100644
--- a/src/p_user.cpp
+++ b/src/p_user.cpp
@@ -35,7 +35,6 @@
 #include "m_random.h"
 #include "p_pspr.h"
 #include "p_enemy.h"
-#include "p_effect.h"
 #include "s_sound.h"
 #include "a_sharedglobal.h"
 #include "a_keys.h"
diff --git a/src/r_data.cpp b/src/r_data.cpp
index 6d4a6fead..f382b9a20 100644
--- a/src/r_data.cpp
+++ b/src/r_data.cpp
@@ -43,6 +43,9 @@
 #include "v_text.h"
 #include "st_start.h"
 #include "doomstat.h"
+#include "r_bsp.h"
+#include "r_segs.h"
+#include "v_palette.h"
 
 
 static int R_CountGroup (const char *start, const char *end);
diff --git a/src/r_draw.cpp b/src/r_draw.cpp
index 764d54338..e26b00048 100644
--- a/src/r_draw.cpp
+++ b/src/r_draw.cpp
@@ -37,6 +37,7 @@
 #include "g_game.h"
 #include "g_level.h"
 #include "r_translate.h"
+#include "v_palette.h"
 
 #include "gi.h"
 #include "stats.h"
diff --git a/src/r_draw.h b/src/r_draw.h
index a8d8367c0..518a7c4f7 100644
--- a/src/r_draw.h
+++ b/src/r_draw.h
@@ -232,7 +232,7 @@ extern "C" const BYTE*		ds_source;
 
 extern "C" int				ds_color;		// [RH] For flat color (no texturing)
 
-extern BYTE shadetables[NUMCOLORMAPS*16*256];
+extern BYTE shadetables[/*NUMCOLORMAPS*16*256*/];
 extern FDynamicColormap ShadeFakeColormap[16];
 extern BYTE identitymap[256];
 extern BYTE *dc_translation;
diff --git a/src/r_local.h b/src/r_local.h
index edff92c4a..b4508a229 100644
--- a/src/r_local.h
+++ b/src/r_local.h
@@ -36,10 +36,6 @@
 // Separate header file for each module.
 //
 #include "r_main.h"
-#include "r_bsp.h"
-#include "r_segs.h"
-#include "r_plane.h"
-#include "r_data.h"
 #include "r_things.h"
 #include "r_draw.h"
 
@@ -49,4 +45,6 @@ void R_InitPicAnims ();
 void R_AddSimpleAnim (FTextureID picnum, int animcount, int animtype, DWORD animspeed /* in ms */, DWORD speedrange=0);
 void R_UpdateAnimations (DWORD mstime);
 
+bool R_AlignFlat (int linenum, int side, int fc);
+
 #endif // __R_LOCAL_H__
diff --git a/src/r_main.cpp b/src/r_main.cpp
index 3f673513d..0698952aa 100644
--- a/src/r_main.cpp
+++ b/src/r_main.cpp
@@ -47,6 +47,9 @@
 #include "r_translate.h"
 #include "p_3dmidtex.h"
 #include "r_interpolate.h"
+#include "r_bsp.h"
+#include "r_plane.h"
+#include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
 
diff --git a/src/r_main.h b/src/r_main.h
index 35517e51c..049f12131 100644
--- a/src/r_main.h
+++ b/src/r_main.h
@@ -29,7 +29,6 @@
 
 #include "d_player.h"
 #include "r_data.h"
-#include "r_bsp.h"
 #include "r_state.h"
 
 
diff --git a/src/r_plane.cpp b/src/r_plane.cpp
index cc465ca39..13221b9e5 100644
--- a/src/r_plane.cpp
+++ b/src/r_plane.cpp
@@ -52,6 +52,10 @@
 #include "cmdlib.h"
 #include "d_net.h"
 #include "g_level.h"
+#include "r_bsp.h"
+#include "r_plane.h"
+#include "r_segs.h"
+#include "v_palette.h"
 
 //EXTERN_CVAR (Int, tx)
 //EXTERN_CVAR (Int, ty)
diff --git a/src/r_plane.h b/src/r_plane.h
index 2960a98bd..d52fc6db2 100644
--- a/src/r_plane.h
+++ b/src/r_plane.h
@@ -102,7 +102,6 @@ visplane_t *R_FindPlane
 
 visplane_t *R_CheckPlane (visplane_t *pl, int start, int stop);
 
-bool R_AlignFlat (int linenum, int side, int fc);
 
 // [RH] Added for multires support
 bool R_PlaneInitData (void);
diff --git a/src/r_polymost.cpp b/src/r_polymost.cpp
index 0c55773e3..e143b98bd 100644
--- a/src/r_polymost.cpp
+++ b/src/r_polymost.cpp
@@ -78,6 +78,9 @@ Low priority:
 #include "templates.h"
 #include "r_sky.h"
 #include "g_level.h"
+#include "r_bsp.h"
+#include "v_palette.h"
+#include "v_font.h"
 
 EXTERN_CVAR (Int, r_polymost)
 
diff --git a/src/r_segs.cpp b/src/r_segs.cpp
index e7f40d7ab..3087e0c96 100644
--- a/src/r_segs.cpp
+++ b/src/r_segs.cpp
@@ -46,6 +46,10 @@
 #include "a_sharedglobal.h"
 #include "d_net.h"
 #include "g_level.h"
+#include "r_bsp.h"
+#include "r_plane.h"
+#include "r_segs.h"
+#include "v_palette.h"
 
 #define WALLYREPEAT 8
 
diff --git a/src/r_segs.h b/src/r_segs.h
index f92663ee0..60bc031d1 100644
--- a/src/r_segs.h
+++ b/src/r_segs.h
@@ -23,6 +23,8 @@
 #ifndef __R_SEGS_H__
 #define __R_SEGS_H__
 
+struct drawseg_t;
+
 void R_RenderMaskedSegRange (drawseg_t *ds, int x1, int x2);
 
 extern short *openings;
diff --git a/src/r_things.cpp b/src/r_things.cpp
index c558d788b..de1e794c1 100644
--- a/src/r_things.cpp
+++ b/src/r_things.cpp
@@ -32,7 +32,6 @@
 #include "i_system.h"
 #include "w_wad.h"
 #include "r_local.h"
-#include "p_effect.h"
 #include "c_console.h"
 #include "c_cvars.h"
 #include "c_dispatch.h"
@@ -48,6 +47,11 @@
 #include "d_net.h"
 #include "colormatcher.h"
 #include "d_netinf.h"
+#include "r_bsp.h"
+#include "r_plane.h"
+#include "r_segs.h"
+#include "v_palette.h"
+
 
 extern FTexture *CrosshairImage;
 extern fixed_t globaluclip, globaldclip;
diff --git a/src/r_translate.cpp b/src/r_translate.cpp
index 9e060f83a..f6ec46c27 100644
--- a/src/r_translate.cpp
+++ b/src/r_translate.cpp
@@ -36,11 +36,13 @@
 
 #include "templates.h"
 #include "r_draw.h"
+#include "r_main.h"
 #include "r_translate.h"
 #include "v_video.h"
 #include "g_game.h"
 #include "colormatcher.h"
 #include "d_netinf.h"
+#include "v_palette.h"
 
 #include "gi.h"
 #include "stats.h"
diff --git a/src/s_sndseq.h b/src/s_sndseq.h
index 35d407413..b80e3e817 100644
--- a/src/s_sndseq.h
+++ b/src/s_sndseq.h
@@ -2,9 +2,8 @@
 #define __S_SNDSEQ_H__
 
 #include <stddef.h>
-//#include "actor.h"
+#include "dobject.h"
 #include "s_sound.h"
-#include "r_defs.h"
 
 typedef enum {
 	SEQ_PLATFORM,
diff --git a/src/sound/fmodsound.cpp b/src/sound/fmodsound.cpp
index 434fc10a1..6b4882550 100644
--- a/src/sound/fmodsound.cpp
+++ b/src/sound/fmodsound.cpp
@@ -52,6 +52,7 @@ extern HWND Window;
 #include "w_wad.h"
 #include "i_music.h"
 #include "v_text.h"
+#include "v_video.h"
 #include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
@@ -2147,7 +2148,6 @@ float F_CALLBACK FMODSoundRenderer::RolloffCallback(FMOD_CHANNEL *channel, float
 void FMODSoundRenderer::DrawWaveDebug(int mode)
 {
 	const int window_height = 100;
-	float wavearray[MAXWIDTH];
 	int window_size;
 	int numoutchans;
 	int y;
@@ -2161,6 +2161,8 @@ void FMODSoundRenderer::DrawWaveDebug(int mode)
 	// 16 pixels of padding between each window.
 	window_size = (screen->GetWidth() - 16) / numoutchans - 16;
 
+	float *wavearray = (float*)alloca(window_size*sizeof(float));
+
 	y = 16;
 	y = DrawChannelGroupOutput(SfxGroup, wavearray, window_size, window_height, y, mode);
 	y = DrawChannelGroupOutput(MusicGroup, wavearray, window_size, window_height, y, mode >> 2);
diff --git a/src/teaminfo.cpp b/src/teaminfo.cpp
index fa7316c0d..0e6e3da95 100644
--- a/src/teaminfo.cpp
+++ b/src/teaminfo.cpp
@@ -37,7 +37,9 @@
 #include "i_system.h"
 #include "sc_man.h"
 #include "teaminfo.h"
+#include "v_video.h"
 #include "v_palette.h"
+#include "v_font.h"
 #include "w_wad.h"
 
 // MACROS ------------------------------------------------------------------
diff --git a/src/textures/canvastexture.cpp b/src/textures/canvastexture.cpp
index 53a62810c..278145b04 100644
--- a/src/textures/canvastexture.cpp
+++ b/src/textures/canvastexture.cpp
@@ -36,6 +36,7 @@
 #include "doomtype.h"
 #include "files.h"
 #include "r_local.h"
+#include "v_palette.h"
 
 extern float LastFOV;
 
diff --git a/src/textures/flattexture.cpp b/src/textures/flattexture.cpp
index b63823979..2d3327078 100644
--- a/src/textures/flattexture.cpp
+++ b/src/textures/flattexture.cpp
@@ -37,6 +37,7 @@
 #include "files.h"
 #include "r_data.h"
 #include "w_wad.h"
+#include "v_palette.h"
 
 //==========================================================================
 //
diff --git a/src/textures/multipatchtexture.cpp b/src/textures/multipatchtexture.cpp
index 09a70bc17..907a7aea8 100644
--- a/src/textures/multipatchtexture.cpp
+++ b/src/textures/multipatchtexture.cpp
@@ -46,6 +46,7 @@
 #include "r_translate.h"
 #include "bitmap.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 // On the Alpha, accessing the shorts directly if they aren't aligned on a
 // 4-byte boundary causes unaligned access warnings. Why it does this at
diff --git a/src/textures/patchtexture.cpp b/src/textures/patchtexture.cpp
index 4369e5ad0..4a8c93b8a 100644
--- a/src/textures/patchtexture.cpp
+++ b/src/textures/patchtexture.cpp
@@ -38,6 +38,7 @@
 #include "r_data.h"
 #include "w_wad.h"
 #include "templates.h"
+#include "v_palette.h"
 
 
 //==========================================================================
diff --git a/src/textures/pngtexture.cpp b/src/textures/pngtexture.cpp
index 34351a752..b1168fe57 100644
--- a/src/textures/pngtexture.cpp
+++ b/src/textures/pngtexture.cpp
@@ -40,6 +40,7 @@
 #include "templates.h"
 #include "m_png.h"
 #include "bitmap.h"
+#include "v_palette.h"
 
 //==========================================================================
 //
diff --git a/src/textures/rawpagetexture.cpp b/src/textures/rawpagetexture.cpp
index 04f3c1793..c4d3bb646 100644
--- a/src/textures/rawpagetexture.cpp
+++ b/src/textures/rawpagetexture.cpp
@@ -37,6 +37,7 @@
 #include "files.h"
 #include "r_data.h"
 #include "w_wad.h"
+#include "v_palette.h"
 
 
 //==========================================================================
diff --git a/src/textures/warptexture.cpp b/src/textures/warptexture.cpp
index 8f6a1eecd..82ad00d31 100644
--- a/src/textures/warptexture.cpp
+++ b/src/textures/warptexture.cpp
@@ -36,6 +36,7 @@
 #include "doomtype.h"
 #include "files.h"
 #include "r_data.h"
+#include "r_main.h"
 #include "templates.h"
 
 
diff --git a/src/thingdef/olddecorations.cpp b/src/thingdef/olddecorations.cpp
index 80fe983cd..8e25f7641 100644
--- a/src/thingdef/olddecorations.cpp
+++ b/src/thingdef/olddecorations.cpp
@@ -45,7 +45,6 @@
 #include "s_sound.h"
 #include "cmdlib.h"
 #include "p_lnspec.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "decallib.h"
 #include "i_system.h"
diff --git a/src/thingdef/thingdef.cpp b/src/thingdef/thingdef.cpp
index 72e4d5bdd..42b82c100 100644
--- a/src/thingdef/thingdef.cpp
+++ b/src/thingdef/thingdef.cpp
@@ -51,13 +51,11 @@
 #include "s_sound.h"
 #include "cmdlib.h"
 #include "p_lnspec.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "decallib.h"
 #include "m_random.h"
 #include "i_system.h"
 #include "p_local.h"
-#include "p_effect.h"
 #include "v_palette.h"
 #include "doomerrors.h"
 #include "a_hexenglobal.h"
diff --git a/src/thingdef/thingdef.h b/src/thingdef/thingdef.h
index 0010cce96..fc14386cf 100644
--- a/src/thingdef/thingdef.h
+++ b/src/thingdef/thingdef.h
@@ -1,6 +1,8 @@
 #ifndef __THINGDEF_H
 #define __THINGDEF_H
 
+#include "doomtype.h"
+
 class FScanner;
 
 //==========================================================================
diff --git a/src/thingdef/thingdef_codeptr.cpp b/src/thingdef/thingdef_codeptr.cpp
index 45145a5fb..7a9799d12 100644
--- a/src/thingdef/thingdef_codeptr.cpp
+++ b/src/thingdef/thingdef_codeptr.cpp
@@ -63,7 +63,9 @@
 #include "a_sharedglobal.h"
 #include "thingdef/thingdef.h"
 #include "v_video.h"
+#include "v_font.h"
 #include "doomstat.h"
+#include "v_palette.h"
 
 
 static FRandom pr_camissile ("CustomActorfire");
diff --git a/src/thingdef/thingdef_properties.cpp b/src/thingdef/thingdef_properties.cpp
index 6213aa61d..5c355f803 100644
--- a/src/thingdef/thingdef_properties.cpp
+++ b/src/thingdef/thingdef_properties.cpp
@@ -51,7 +51,6 @@
 #include "s_sound.h"
 #include "cmdlib.h"
 #include "p_lnspec.h"
-#include "p_enemy.h"
 #include "a_action.h"
 #include "decallib.h"
 #include "m_random.h"
diff --git a/src/thingdef/thingdef_states.cpp b/src/thingdef/thingdef_states.cpp
index 66e8f7d3d..e814afde9 100644
--- a/src/thingdef/thingdef_states.cpp
+++ b/src/thingdef/thingdef_states.cpp
@@ -48,7 +48,6 @@
 #include "p_lnspec.h"
 #include "a_action.h"
 #include "p_local.h"
-#include "p_effect.h"
 #include "v_palette.h"
 #include "doomerrors.h"
 #include "thingdef.h"
diff --git a/src/v_draw.cpp b/src/v_draw.cpp
index 62d8a12ee..27c8bcf43 100644
--- a/src/v_draw.cpp
+++ b/src/v_draw.cpp
@@ -40,9 +40,11 @@
 #include "m_swap.h"
 #include "r_defs.h"
 #include "r_draw.h"
+#include "r_main.h"
 #include "r_things.h"
 #include "r_translate.h"
 #include "doomstat.h"
+#include "v_palette.h"
 
 #include "i_system.h"
 #include "i_video.h"
diff --git a/src/v_font.cpp b/src/v_font.cpp
index 14150d05a..3e3490310 100644
--- a/src/v_font.cpp
+++ b/src/v_font.cpp
@@ -94,12 +94,14 @@ The FON2 header is followed by variable length data:
 #include "r_draw.h"
 #include "r_translate.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
 
 #define DEFAULT_LOG_COLOR	PalEntry(223,223,223)
 
 // TYPES -------------------------------------------------------------------
+void RecordTextureColors (FTexture *pic, BYTE *colorsused);
 
 // This structure is used by BuildTranslations() to hold color information.
 struct TranslationParm
@@ -116,6 +118,34 @@ struct TranslationMap
 	int Number;
 };
 
+class FSingleLumpFont : public FFont
+{
+public:
+	FSingleLumpFont (const char *fontname, int lump);
+
+protected:
+	void CheckFON1Chars (int lump, const BYTE *data, double *luminosity);
+	void BuildTranslations2 ();
+	void FixupPalette (BYTE *identity, double *luminosity, const BYTE *palette,
+		bool rescale, PalEntry *out_palette);
+	void LoadFON1 (int lump, const BYTE *data);
+	void LoadFON2 (int lump, const BYTE *data);
+	void CreateFontFromPic (FTextureID picnum);
+};
+
+class FSinglePicFont : public FFont
+{
+public:
+	FSinglePicFont(const char *picname);
+
+	// FFont interface
+	FTexture *GetChar (int code, int *const width) const;
+	int GetCharWidth (int code) const;
+
+protected:
+	FTextureID PicNum;
+};
+
 // This is a font character that loads a texture and recolors it.
 class FFontChar1 : public FTexture
 {
diff --git a/src/v_font.h b/src/v_font.h
index 3db032c23..14cf1391e 100644
--- a/src/v_font.h
+++ b/src/v_font.h
@@ -35,11 +35,11 @@
 #define __V_FONT_H__
 
 #include "doomtype.h"
-#include "farchive.h"
-#include "textures/textures.h"
 
 class DCanvas;
 struct FRemapTable;
+class FTexture;
+class FArchive;
 
 enum EColorRange
 {
@@ -71,6 +71,7 @@ enum EColorRange
 
 extern int NumTextColors;
 
+
 class FFont
 {
 public:
@@ -124,40 +125,6 @@ protected:
 	friend FArchive &SerializeFFontPtr (FArchive &arc, FFont* &font);
 };
 
-template<> inline FArchive &operator<< <FFont> (FArchive &arc, FFont* &font)
-{
-	return SerializeFFontPtr (arc, font);
-}
-
-class FSingleLumpFont : public FFont
-{
-public:
-	FSingleLumpFont (const char *fontname, int lump);
-
-protected:
-	void CheckFON1Chars (int lump, const BYTE *data, double *luminosity);
-	void BuildTranslations2 ();
-	void FixupPalette (BYTE *identity, double *luminosity, const BYTE *palette,
-		bool rescale, PalEntry *out_palette);
-	void LoadFON1 (int lump, const BYTE *data);
-	void LoadFON2 (int lump, const BYTE *data);
-	void CreateFontFromPic (FTextureID picnum);
-};
-
-class FSinglePicFont : public FFont
-{
-public:
-	FSinglePicFont(const char *picname);
-
-	// FFont interface
-	FTexture *GetChar (int code, int *const width) const;
-	int GetCharWidth (int code) const;
-
-protected:
-	FTextureID PicNum;
-};
-
-void RecordTextureColors (FTexture *pic, BYTE *colorsused);
 
 extern FFont *SmallFont, *SmallFont2, *BigFont, *ConFont;
 
diff --git a/src/v_palette.cpp b/src/v_palette.cpp
index dd0141aea..39a2001cd 100644
--- a/src/v_palette.cpp
+++ b/src/v_palette.cpp
@@ -55,6 +55,7 @@
 #include "gi.h"
 #include "x86.h"
 #include "colormatcher.h"
+#include "v_palette.h"
 
 extern "C" {
 FDynamicColormap NormalLight;
diff --git a/src/v_palette.h b/src/v_palette.h
index c8236a385..71c2cd047 100644
--- a/src/v_palette.h
+++ b/src/v_palette.h
@@ -34,8 +34,7 @@
 #ifndef __V_PALETTE_H__
 #define __V_PALETTE_H__
 
-#include "doomtype.h"
-#include "r_main.h"
+#include "basictypes.h"
 
 #define MAKERGB(r,g,b)		DWORD(((r)<<16)|((g)<<8)|(b))
 #define MAKEARGB(a,r,g,b)	DWORD(((a)<<24)|((r)<<16)|((g)<<8)|(b))
diff --git a/src/v_video.cpp b/src/v_video.cpp
index 955aa0606..839381b42 100644
--- a/src/v_video.cpp
+++ b/src/v_video.cpp
@@ -30,7 +30,6 @@
 #include "i_video.h"
 #include "r_local.h"
 #include "r_draw.h"
-#include "r_plane.h"
 #include "r_state.h"
 
 #include "doomdef.h"
@@ -62,6 +61,8 @@
 #include "f_wipe.h"
 #include "m_png.h"
 #include "colormatcher.h"
+#include "v_palette.h"
+
 
 IMPLEMENT_ABSTRACT_CLASS (DCanvas)
 IMPLEMENT_ABSTRACT_CLASS (DFrameBuffer)
diff --git a/src/v_video.h b/src/v_video.h
index a84fc9c7d..b02e4ea18 100644
--- a/src/v_video.h
+++ b/src/v_video.h
@@ -36,13 +36,10 @@
 
 #include "doomtype.h"
 
-#include "v_palette.h"
-#include "v_font.h"
-
 #include "doomdef.h"
-
-// Needed because we are refering to patches.
-#include "r_data.h"
+#include "dobject.h"
+#include "r_blend.h"
+#include "c_cvars.h"
 
 extern int CleanWidth, CleanHeight, CleanXfac, CleanYfac;
 extern int DisplayWidth, DisplayHeight, DisplayBits;
@@ -125,6 +122,10 @@ enum ESSType
 	SS_BGRA
 };
 
+class FFont;
+struct FRemapTable;
+class player_t;
+
 //
 // VIDEO
 //
diff --git a/src/win32/fb_d3d9.cpp b/src/win32/fb_d3d9.cpp
index aa61b8c44..89aa64226 100644
--- a/src/win32/fb_d3d9.cpp
+++ b/src/win32/fb_d3d9.cpp
@@ -67,6 +67,7 @@
 #include "st_stuff.h"
 #include "win32iface.h"
 #include "doomstat.h"
+#include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
 
diff --git a/src/win32/fb_ddraw.cpp b/src/win32/fb_ddraw.cpp
index dfd12ba3c..006288d5e 100644
--- a/src/win32/fb_ddraw.cpp
+++ b/src/win32/fb_ddraw.cpp
@@ -55,6 +55,7 @@
 #include "doomerrors.h"
 
 #include "win32iface.h"
+#include "v_palette.h"
 
 // MACROS ------------------------------------------------------------------
 
diff --git a/src/win32/i_main.cpp b/src/win32/i_main.cpp
index f16dfcfd3..c6daae849 100644
--- a/src/win32/i_main.cpp
+++ b/src/win32/i_main.cpp
@@ -75,6 +75,7 @@
 #include "cmdlib.h"
 #include "g_level.h"
 #include "doomstat.h"
+#include "r_main.h"
 
 #include "stats.h"
 #include "st_start.h"
diff --git a/src/win32/win32video.cpp b/src/win32/win32video.cpp
index c6cc23b3d..2753c0aeb 100644
--- a/src/win32/win32video.cpp
+++ b/src/win32/win32video.cpp
@@ -64,6 +64,7 @@
 #include "stats.h"
 #include "doomerrors.h"
 #include "m_argv.h"
+#include "r_defs.h"
 
 #include "win32iface.h"
 
diff --git a/src/xlat/parse_xlat.cpp b/src/xlat/parse_xlat.cpp
index c1c71a28b..75f2d3d27 100644
--- a/src/xlat/parse_xlat.cpp
+++ b/src/xlat/parse_xlat.cpp
@@ -35,10 +35,8 @@
 
 
 #include "doomtype.h"
-#include "tarray.h"
 #include "w_wad.h"
 #include "c_console.h"
-#include "p_lnspec.h"
 #include "info.h"
 #include "gi.h"
 #include "parsecontext.h"
diff --git a/zdoom.vcproj b/zdoom.vcproj
index 223218810..2de46e716 100644
--- a/zdoom.vcproj
+++ b/zdoom.vcproj
@@ -2188,30 +2188,142 @@
 			<File
 				RelativePath=".\src\g_doom\a_arachnotron.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_archvile.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_bossbrain.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_bruiser.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_cacodemon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_cyberdemon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_demon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_doomglobal.h"
@@ -2220,6 +2332,22 @@
 			<File
 				RelativePath=".\src\g_doom\a_doomimp.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_doommisc.cpp"
@@ -2228,38 +2356,182 @@
 			<File
 				RelativePath=".\src\g_doom\a_doomweaps.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_fatso.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_keen.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_lostsoul.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_painelemental.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_possessed.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_revenant.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_scriptedmarine.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\a_spidermaster.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_doom\doom_sbar.cpp"
@@ -2288,18 +2560,82 @@
 			<File
 				RelativePath=".\src\g_heretic\a_chicken.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_dsparil.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_hereticartifacts.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_hereticimp.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_hereticmisc.cpp"
@@ -2308,18 +2644,82 @@
 			<File
 				RelativePath=".\src\g_heretic\a_hereticweaps.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_ironlich.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_knight.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\a_wizard.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_heretic\heretic_sbar.cpp"
@@ -2332,134 +2732,650 @@
 			<File
 				RelativePath=".\src\g_hexen\a_bats.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_bishop.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_blastradius.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_boostarmor.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_centaur.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_clericflame.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_clericholy.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_clericmace.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_clericstaff.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_dragon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_fighteraxe.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_fighterhammer.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath="src\g_hexen\a_fighterplayer.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath="src\g_hexen\a_fighterquietus.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_firedemon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_flechette.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_fog.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath="src\g_hexen\a_healingradius.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_heresiarch.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_hexenglobal.h"
 				>
 			</File>
+			<File
+				RelativePath=".\src\g_hexen\a_hexenmisc.cpp"
+				>
+			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_hexenspecialdecs.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_iceguy.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_korax.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_magecone.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_magelightning.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_magestaff.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_magewand.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath="src\g_hexen\a_pig.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_serpent.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_spike.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_summon.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_teleportother.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_hexen\a_wraith.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath="src\g_hexen\hexen_sbar.cpp"
@@ -2472,62 +3388,302 @@
 			<File
 				RelativePath=".\src\g_strife\a_acolyte.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_alienspectres.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_coin.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_crusader.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_entityboss.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_inquisitor.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_loremaster.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_macil.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_oracle.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_programmer.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_reaver.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_rebels.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_sentinel.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_spectral.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_stalker.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_strifeglobal.h"
@@ -2536,6 +3692,22 @@
 			<File
 				RelativePath=".\src\g_strife\a_strifeitems.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_strifestuff.cpp"
@@ -2544,8 +3716,17 @@
 			<File
 				RelativePath=".\src\g_strife\a_strifeweapons.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 				<FileConfiguration
 					Name="Debug|Win32"
+					ExcludedFromBuild="true"
 					>
 					<Tool
 						Name="VCCLCompilerTool"
@@ -2564,10 +3745,42 @@
 			<File
 				RelativePath=".\src\g_strife\a_templar.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\a_thingstoblowup.cpp"
 				>
+				<FileConfiguration
+					Name="Release|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
+				<FileConfiguration
+					Name="Debug|Win32"
+					ExcludedFromBuild="true"
+					>
+					<Tool
+						Name="VCCLCompilerTool"
+					/>
+				</FileConfiguration>
 			</File>
 			<File
 				RelativePath=".\src\g_strife\strife_sbar.cpp"