diff --git a/Makefile b/Makefile index 09f92ed6..4dd28e2d 100644 --- a/Makefile +++ b/Makefile @@ -554,6 +554,7 @@ $(INSTALLDIR)/q3map2.$(EXE): \ tools/quake3/q3map2/exportents.o \ tools/quake3/q3map2/facebsp.o \ tools/quake3/q3map2/fog.o \ + tools/quake3/q3map2/games.o \ tools/quake3/q3map2/help.o \ tools/quake3/q3map2/image.o \ tools/quake3/q3map2/leakfile.o \ diff --git a/tools/quake3/q3map2/bspfile_abstract.cpp b/tools/quake3/q3map2/bspfile_abstract.cpp index 2f0b63c4..819f71f1 100644 --- a/tools/quake3/q3map2/bspfile_abstract.cpp +++ b/tools/quake3/q3map2/bspfile_abstract.cpp @@ -30,6 +30,7 @@ /* dependencies */ #include "q3map2.h" +#include "bspfile_ibsp.h" diff --git a/tools/quake3/q3map2/bspfile_ibsp.h b/tools/quake3/q3map2/bspfile_ibsp.h new file mode 100644 index 00000000..e5fd384c --- /dev/null +++ b/tools/quake3/q3map2/bspfile_ibsp.h @@ -0,0 +1,6 @@ + +#pragma once + +void LoadIBSPFile( const char *filename ); +void WriteIBSPFile( const char *filename ); +void PartialLoadIBSPFile( const char *filename ); diff --git a/tools/quake3/q3map2/bspfile_rbsp.h b/tools/quake3/q3map2/bspfile_rbsp.h new file mode 100644 index 00000000..460d616d --- /dev/null +++ b/tools/quake3/q3map2/bspfile_rbsp.h @@ -0,0 +1,5 @@ + +#pragma once + +void LoadRBSPFile( const char *filename ); +void WriteRBSPFile( const char *filename ); diff --git a/tools/quake3/q3map2/convert_bsp.cpp b/tools/quake3/q3map2/convert_bsp.cpp index f18e21b2..cce78ed9 100644 --- a/tools/quake3/q3map2/convert_bsp.cpp +++ b/tools/quake3/q3map2/convert_bsp.cpp @@ -810,7 +810,7 @@ void PseudoCompileBSP( bool need_tree ){ int ConvertBSPMain( int argc, char **argv ){ int i; int ( *convertFunc )( char * ); - game_t *convertGame; + const game_t *convertGame; bool map_allowed, force_bsp, force_map; diff --git a/tools/quake3/q3map2/game__null.h b/tools/quake3/q3map2/game__null.h deleted file mode 100644 index 23f1dc26..00000000 --- a/tools/quake3/q3map2/game__null.h +++ /dev/null @@ -1,102 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME__NULL_H -#define GAME__NULL_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - are in game_quake3.h - - ------------------------------------------------------------------------------- */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - NULL, /* -game x */ - NULL, /* default base game data dir */ - NULL, /* unix home sub-dir */ - NULL, /* magic path word */ - NULL, /* shader directory */ - 0, /* max lightmapped surface verts */ - 0, /* max surface verts */ - 0, /* max surface indexes */ - false, /* flares */ - NULL, /* default flare shader */ - false, /* wolf lighting model? */ - 0, /* lightmap width/height */ - 0, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0, /* lightmap exposure */ - 0, /* lightmap compensate */ - 0, /* lightgrid scale */ - 0, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 0, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 0, /* minimap size */ - 0, /* minimap sharpener */ - 0, /* minimap border */ - false, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - NULL, /* minimap name format */ - NULL, /* bsp file prefix */ - 0, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - NULL, /* bsp load function */ - NULL, /* bsp write function */ - - { - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - 0 -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_darkplaces.h b/tools/quake3/q3map2/game_darkplaces.h deleted file mode 100644 index 4b72ee31..00000000 --- a/tools/quake3/q3map2/game_darkplaces.h +++ /dev/null @@ -1,154 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2006 Id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_DARKPLACES_H -#define GAME_DARKPLACES_H - -/* content and surface flags get form quake3 */ - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "darkplaces", /* -game x */ - "id1", /* default base game data dir */ - ".darkplaces ", /* unix home sub-dir */ - "darkplaces", /* magic path word */ - "scripts", /* shader directory */ - 999, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 200.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 0.3f, /* lightgrid scale */ - 0.6f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 4, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_dq.h b/tools/quake3/q3map2/game_dq.h deleted file mode 100644 index 1dbcbafe..00000000 --- a/tools/quake3/q3map2/game_dq.h +++ /dev/null @@ -1,154 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2006 Id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_DQ_H -#define GAME_DQ_H - -/* content and surface flags get form quake3 */ - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "dq", /* -game x */ - "basedq", /* default base game data dir */ - ".dq", /* unix home sub-dir */ - "dq", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.2f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 200.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 0.3f, /* lightgrid scale */ - 0.6f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 4, /* default patchMeta subdivisions tolerance */ - true, /* patch casting enabled */ - true, /* compile deluxemaps */ - 1, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_ef.h b/tools/quake3/q3map2/game_ef.h deleted file mode 100644 index 53d2f503..00000000 --- a/tools/quake3/q3map2/game_ef.h +++ /dev/null @@ -1,215 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_EF_H -#define GAME_EF_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define E_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define E_CONT_LAVA 8 -#define E_CONT_SLIME 16 -#define E_CONT_WATER 32 -#define E_CONT_FOG 64 -#define E_CONT_LADDER 128 /* elite force ladder contents */ - -#define E_CONT_AREAPORTAL 0x8000 - -#define E_CONT_PLAYERCLIP 0x10000 -#define E_CONT_MONSTERCLIP 0x20000 -#define E_CONT_SHOTCLIP 0x40000 /* elite force shot clip */ -#define E_CONT_ITEM 0x80000 -#define E_CONT_CLUSTERPORTAL 0x100000 -#define E_CONT_DONOTENTER 0x200000 -#define E_CONT_BOTCLIP 0x400000 - -#define E_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define E_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define E_CONT_CORPSE 0x4000000 -#define E_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define E_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define E_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define E_CONT_TRIGGER 0x40000000 -#define E_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define E_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define E_SURF_SLICK 0x2 /* effects game physics */ -#define E_SURF_SKY 0x4 /* lighting from environment map */ -#define E_SURF_LADDER 0x8 -#define E_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define E_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define E_SURF_FLESH 0x40 /* make flesh sounds and effects */ -#define E_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define E_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define E_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define E_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define E_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define E_SURF_METALSTEPS 0x1000 /* clanking footsteps */ -#define E_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define E_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define E_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define E_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define E_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define E_SURF_FORCEFIELD 0x40000 /* elite force forcefield brushes */ - -/* ydnar flags */ -#define E_SURF_VERTEXLIT ( E_SURF_POINTLIGHT | E_SURF_NOLIGHTMAP ) -#define E_SURF_BEVELSMASK ( E_SURF_NODAMAGE | E_SURF_SLICK | E_SURF_FLESH | E_SURF_METALSTEPS | E_SURF_NOSTEPS ) - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "ef", /* -game x */ - "baseef", /* default base game data dir */ - ".ef", /* unix home sub-dir */ - "elite", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", E_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", E_CONT_ORIGIN, E_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", E_CONT_AREAPORTAL, E_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", E_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", E_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", E_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, E_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, E_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, E_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, E_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, E_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, E_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, E_CONT_SOLID, E_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", E_CONT_TRIGGER, E_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", E_CONT_WATER, E_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", E_CONT_SLIME, E_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", E_CONT_LAVA, E_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", E_CONT_PLAYERCLIP, E_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", E_CONT_MONSTERCLIP, E_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "shotclip", E_CONT_SHOTCLIP, E_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", E_CONT_NODROP, E_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", E_CONT_CLUSTERPORTAL, E_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", E_CONT_DONOTENTER, E_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", E_CONT_BOTCLIP, E_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", E_CONT_FOG, E_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, E_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, E_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, E_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, E_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", E_CONT_LADDER, E_CONT_SOLID, E_SURF_LADDER, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodamage", 0, 0, E_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, E_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, E_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, E_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, E_SURF_NODLIGHT, 0, 0, 0 }, - { "forcefield", 0, 0, E_SURF_FORCEFIELD, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - E_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_etut.h b/tools/quake3/q3map2/game_etut.h deleted file mode 100644 index 969996cd..00000000 --- a/tools/quake3/q3map2/game_etut.h +++ /dev/null @@ -1,285 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_ETUT_H -#define GAME_ETUT_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define U_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define U_CONT_LAVA 8 -#define U_CONT_SLIME 16 -#define U_CONT_WATER 32 -#define U_CONT_FOG 64 - -#define U_CONT_AREAPORTAL 0x8000 - -#define U_CONT_PLAYERCLIP 0x10000 -#define U_CONT_MONSTERCLIP 0x20000 -#define U_CONT_TELEPORTER 0x40000 -#define U_CONT_JUMPPAD 0x80000 -#define U_CONT_CLUSTERPORTAL 0x100000 -#define U_CONT_DONOTENTER 0x200000 -#define U_CONT_BOTCLIP 0x400000 - -#define U_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define U_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define U_CONT_CORPSE 0x4000000 -#define U_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define U_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define U_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define U_CONT_TRIGGER 0x40000000 -#define U_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define U_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define U_SURF_SLICK 0x2 /* effects game physics */ -#define U_SURF_SKY 0x4 /* lighting from environment map */ -#define U_SURF_LADDER 0x8 -#define U_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define U_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define U_SURF_FLESH 0x40 /* make flesh sounds and effects */ -#define U_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define U_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define U_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define U_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define U_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define U_SURF_METALSTEPS 0x1000 /* clanking footsteps */ -#define U_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define U_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define U_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define U_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define U_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define U_SURF_DUST 0x40000 /* leave a dust trail when walking on this surface */ - -/* ydnar flags */ -#define U_SURF_VERTEXLIT ( U_SURF_POINTLIGHT | U_SURF_NOLIGHTMAP ) -#define U_SURF_BEVELSMASK ( U_SURF_NODAMAGE | U_SURF_SLICK | U_SURF_FLESH | U_SURF_METALSTEPS | U_SURF_NOSTEPS | U_SURF_DUST ) - -/* materials */ -#define U_MAT_MASK int(0xFFF00000) /* mask to get the material type */ - -#define U_MAT_NONE 0x00000000 -#define U_MAT_TIN 0x00100000 -#define U_MAT_ALUMINUM 0x00200000 -#define U_MAT_IRON 0x00300000 -#define U_MAT_TITANIUM 0x00400000 -#define U_MAT_STEEL 0x00500000 -#define U_MAT_BRASS 0x00600000 -#define U_MAT_COPPER 0x00700000 -#define U_MAT_CEMENT 0x00800000 -#define U_MAT_ROCK 0x00900000 -#define U_MAT_GRAVEL 0x00A00000 -#define U_MAT_PAVEMENT 0x00B00000 -#define U_MAT_BRICK 0x00C00000 -#define U_MAT_CLAY 0x00D00000 -#define U_MAT_GRASS 0x00E00000 -#define U_MAT_DIRT 0x00F00000 -#define U_MAT_MUD 0x01000000 -#define U_MAT_SNOW 0x01100000 -#define U_MAT_ICE 0x01200000 -#define U_MAT_SAND 0x01300000 -#define U_MAT_CERAMICTILE 0x01400000 -#define U_MAT_LINOLEUM 0x01500000 -#define U_MAT_RUG 0x01600000 -#define U_MAT_PLASTER 0x01700000 -#define U_MAT_PLASTIC 0x01800000 -#define U_MAT_CARDBOARD 0x01900000 -#define U_MAT_HARDWOOD 0x01A00000 -#define U_MAT_SOFTWOOD 0x01B00000 -#define U_MAT_PLANK 0x01C00000 -#define U_MAT_GLASS 0x01D00000 -#define U_MAT_WATER 0x01E00000 -#define U_MAT_STUCCO 0x01F00000 - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "etut", /* -game x */ - "etut", /* default base game data dir */ - ".etwolf", /* unix home sub-dir */ - "et", /* magic path word */ - "scripts", /* shader directory */ - 1024, /* max lightmapped surface verts */ - 1024, /* max surface verts */ - 6144, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - true, /* lightmap sRGB */ - false, /* texture sRGB (yes, this is incorrect, but we better match ET:UT) */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 47, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", U_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", U_CONT_ORIGIN, U_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", U_CONT_AREAPORTAL, U_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", U_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", U_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", U_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, U_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, U_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, U_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, U_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, U_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, U_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, U_CONT_SOLID, U_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", U_CONT_TRIGGER, U_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", U_CONT_WATER, U_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", U_CONT_SLIME, U_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", U_CONT_LAVA, U_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", U_CONT_PLAYERCLIP, U_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", U_CONT_MONSTERCLIP, U_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", U_CONT_NODROP, U_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", U_CONT_CLUSTERPORTAL, U_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", U_CONT_DONOTENTER, U_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", U_CONT_BOTCLIP, U_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", U_CONT_FOG, U_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, U_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, U_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, U_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, U_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, U_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, U_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, U_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, U_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, U_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, U_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, U_SURF_DUST, 0, 0, 0 }, - - - /* materials */ - { "*mat_none", 0, 0, U_MAT_NONE, U_MAT_MASK, 0, 0 }, - { "*mat_tin", 0, 0, U_MAT_TIN, U_MAT_MASK, 0, 0 }, - { "*mat_aluminum", 0, 0, U_MAT_ALUMINUM, U_MAT_MASK, 0, 0 }, - { "*mat_iron", 0, 0, U_MAT_IRON, U_MAT_MASK, 0, 0 }, - { "*mat_titanium", 0, 0, U_MAT_TITANIUM, U_MAT_MASK, 0, 0 }, - { "*mat_steel", 0, 0, U_MAT_STEEL, U_MAT_MASK, 0, 0 }, - { "*mat_brass", 0, 0, U_MAT_BRASS, U_MAT_MASK, 0, 0 }, - { "*mat_copper", 0, 0, U_MAT_COPPER, U_MAT_MASK, 0, 0 }, - { "*mat_cement", 0, 0, U_MAT_CEMENT, U_MAT_MASK, 0, 0 }, - { "*mat_rock", 0, 0, U_MAT_ROCK, U_MAT_MASK, 0, 0 }, - { "*mat_gravel", 0, 0, U_MAT_GRAVEL, U_MAT_MASK, 0, 0 }, - { "*mat_pavement", 0, 0, U_MAT_PAVEMENT, U_MAT_MASK, 0, 0 }, - { "*mat_brick", 0, 0, U_MAT_BRICK, U_MAT_MASK, 0, 0 }, - { "*mat_clay", 0, 0, U_MAT_CLAY, U_MAT_MASK, 0, 0 }, - { "*mat_grass", 0, 0, U_MAT_GRASS, U_MAT_MASK, 0, 0 }, - { "*mat_dirt", 0, 0, U_MAT_DIRT, U_MAT_MASK, 0, 0 }, - { "*mat_mud", 0, 0, U_MAT_MUD, U_MAT_MASK, 0, 0 }, - { "*mat_snow", 0, 0, U_MAT_SNOW, U_MAT_MASK, 0, 0 }, - { "*mat_ice", 0, 0, U_MAT_ICE, U_MAT_MASK, 0, 0 }, - { "*mat_sand", 0, 0, U_MAT_SAND, U_MAT_MASK, 0, 0 }, - { "*mat_ceramic", 0, 0, U_MAT_CERAMICTILE, U_MAT_MASK, 0, 0 }, - { "*mat_ceramictile", 0, 0, U_MAT_CERAMICTILE, U_MAT_MASK, 0, 0 }, - { "*mat_linoleum", 0, 0, U_MAT_LINOLEUM, U_MAT_MASK, 0, 0 }, - { "*mat_rug", 0, 0, U_MAT_RUG, U_MAT_MASK, 0, 0 }, - { "*mat_plaster", 0, 0, U_MAT_PLASTER, U_MAT_MASK, 0, 0 }, - { "*mat_plastic", 0, 0, U_MAT_PLASTIC, U_MAT_MASK, 0, 0 }, - { "*mat_cardboard", 0, 0, U_MAT_CARDBOARD, U_MAT_MASK, 0, 0 }, - { "*mat_hardwood", 0, 0, U_MAT_HARDWOOD, U_MAT_MASK, 0, 0 }, - { "*mat_softwood", 0, 0, U_MAT_SOFTWOOD, U_MAT_MASK, 0, 0 }, - { "*mat_plank", 0, 0, U_MAT_PLANK, U_MAT_MASK, 0, 0 }, - { "*mat_glass", 0, 0, U_MAT_GLASS, U_MAT_MASK, 0, 0 }, - { "*mat_water", 0, 0, U_MAT_WATER, U_MAT_MASK, 0, 0 }, - { "*mat_stucco", 0, 0, U_MAT_STUCCO, U_MAT_MASK, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - U_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_ja.h b/tools/quake3/q3map2/game_ja.h deleted file mode 100644 index 975d99ef..00000000 --- a/tools/quake3/q3map2/game_ja.h +++ /dev/null @@ -1,209 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_JA_H -#define GAME_JA_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* this file must be included *after* game_sof2.h and game_jk2.h because they share defines! */ - -#define JA_CONT_INSIDE 0x10000000 /* jedi academy 'inside' */ -#define JA_SURF_FORCESIGHT 0x02000000 /* jedi academy 'forcesight' */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "ja", /* -game x */ - "base", /* default base game data dir */ - ".ja", /* unix home sub-dir */ - "GameData", /* magic path word */ - "shaders", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - true, /* flares */ - "gfx/misc/flare", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "RBSP", /* bsp file prefix */ - 1, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadRBSPFile, /* bsp load function */ - WriteRBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", S_CONT_SOLID | S_CONT_OPAQUE, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", 0, S_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", S_CONT_TRANSLUCENT, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", S_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", S_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", 0, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, 0, 0, C_HINT, 0 }, - { "nodraw", 0, 0, S_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, 0, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, 0, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, S_CONT_SOLID, 0, 0, 0, C_SOLID }, - { "nonopaque", 0, S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, 0 }, /* setting trans ok? */ - - { "trigger", S_CONT_TRIGGER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", S_CONT_WATER, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", S_CONT_SLIME, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", S_CONT_LAVA, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "shotclip", S_CONT_SHOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* setting trans/detail ok? */ - { "playerclip", S_CONT_PLAYERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", S_CONT_MONSTERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", S_CONT_NODROP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "terrain", S_CONT_TERRAIN, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "ladder", S_CONT_LADDER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "abseil", S_CONT_ABSEIL, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "outside", S_CONT_OUTSIDE, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "botclip", S_CONT_BOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "fog", S_CONT_FOG, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_FOG | C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* nonopaque? */ - { "sky", 0, 0, S_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, S_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, S_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, S_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "nodamage", 0, 0, S_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, S_SURF_METALSTEPS, 0, 0, 0 }, - { "nosteps", 0, 0, S_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, S_SURF_NODLIGHT, 0, 0, 0 }, - { "nomiscents", 0, 0, S_SURF_NOMISCENTS, 0, 0, 0 }, - { "forcefield", 0, 0, S_SURF_FORCEFIELD, 0, 0, 0 }, - - /* jedi academy */ - { "inside", JA_CONT_INSIDE, 0, 0, 0, 0, 0 }, - { "forcesight", 0, 0, JA_SURF_FORCESIGHT, 0, 0, 0 }, - - /* materials */ - { "*mat_none", 0, 0, S_MAT_NONE, S_MAT_MASK, 0, 0 }, - { "*mat_solidwood", 0, 0, S_MAT_SOLIDWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_hollowwood", 0, 0, S_MAT_HOLLOWWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_solidmetal", 0, 0, S_MAT_SOLIDMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_hollowmetal", 0, 0, S_MAT_HOLLOWMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_shortgrass", 0, 0, S_MAT_SHORTGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_longgrass", 0, 0, S_MAT_LONGGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_dirt", 0, 0, S_MAT_DIRT, S_MAT_MASK, 0, 0 }, - { "*mat_sand", 0, 0, S_MAT_SAND, S_MAT_MASK, 0, 0 }, - { "*mat_gravel", 0, 0, S_MAT_GRAVEL, S_MAT_MASK, 0, 0 }, - { "*mat_glass", 0, 0, S_MAT_GLASS, S_MAT_MASK, 0, 0 }, - { "*mat_concrete", 0, 0, S_MAT_CONCRETE, S_MAT_MASK, 0, 0 }, - { "*mat_marble", 0, 0, S_MAT_MARBLE, S_MAT_MASK, 0, 0 }, - { "*mat_water", 0, 0, S_MAT_WATER, S_MAT_MASK, 0, 0 }, - { "*mat_snow", 0, 0, S_MAT_SNOW, S_MAT_MASK, 0, 0 }, - { "*mat_ice", 0, 0, S_MAT_ICE, S_MAT_MASK, 0, 0 }, - { "*mat_flesh", 0, 0, S_MAT_FLESH, S_MAT_MASK, 0, 0 }, - { "*mat_mud", 0, 0, S_MAT_MUD, S_MAT_MASK, 0, 0 }, - { "*mat_bpglass", 0, 0, S_MAT_BPGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_dryleaves", 0, 0, S_MAT_DRYLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_greenleaves", 0, 0, S_MAT_GREENLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_fabric", 0, 0, S_MAT_FABRIC, S_MAT_MASK, 0, 0 }, - { "*mat_canvas", 0, 0, S_MAT_CANVAS, S_MAT_MASK, 0, 0 }, - { "*mat_rock", 0, 0, S_MAT_ROCK, S_MAT_MASK, 0, 0 }, - { "*mat_rubber", 0, 0, S_MAT_RUBBER, S_MAT_MASK, 0, 0 }, - { "*mat_plastic", 0, 0, S_MAT_PLASTIC, S_MAT_MASK, 0, 0 }, - { "*mat_tiles", 0, 0, S_MAT_TILES, S_MAT_MASK, 0, 0 }, - { "*mat_carpet", 0, 0, S_MAT_CARPET, S_MAT_MASK, 0, 0 }, - { "*mat_plaster", 0, 0, S_MAT_PLASTER, S_MAT_MASK, 0, 0 }, - { "*mat_shatterglass", 0, 0, S_MAT_SHATTERGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_armor", 0, 0, S_MAT_ARMOR, S_MAT_MASK, 0, 0 }, - { "*mat_computer", 0, 0, S_MAT_COMPUTER, S_MAT_MASK, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - S_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_jk2.h b/tools/quake3/q3map2/game_jk2.h deleted file mode 100644 index e2c90f2f..00000000 --- a/tools/quake3/q3map2/game_jk2.h +++ /dev/null @@ -1,203 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_JK2_H -#define GAME_JK2_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* this file must be included *after* game_sof2.h because it shares defines! */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "jk2", /* -game x */ - "base", /* default base game data dir */ - ".jk2", /* unix home sub-dir */ - "GameData", /* magic path word */ - "shaders", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - true, /* flares */ - "gfx/misc/flare", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "RBSP", /* bsp file prefix */ - 1, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadRBSPFile, /* bsp load function */ - WriteRBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", S_CONT_SOLID | S_CONT_OPAQUE, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", 0, S_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", S_CONT_TRANSLUCENT, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", S_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", S_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", 0, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, 0, 0, C_HINT, 0 }, - { "nodraw", 0, 0, S_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, 0, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, 0, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, S_CONT_SOLID, 0, 0, 0, C_SOLID }, - { "nonopaque", 0, S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, 0 }, /* setting trans ok? */ - - { "trigger", S_CONT_TRIGGER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", S_CONT_WATER, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", S_CONT_SLIME, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", S_CONT_LAVA, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "shotclip", S_CONT_SHOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* setting trans/detail ok? */ - { "playerclip", S_CONT_PLAYERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", S_CONT_MONSTERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", S_CONT_NODROP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "terrain", S_CONT_TERRAIN, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "ladder", S_CONT_LADDER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "abseil", S_CONT_ABSEIL, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "outside", S_CONT_OUTSIDE, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "botclip", S_CONT_BOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "fog", S_CONT_FOG, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_FOG | C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* nonopaque? */ - { "sky", 0, 0, S_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, S_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, S_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, S_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "nodamage", 0, 0, S_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, S_SURF_METALSTEPS, 0, 0, 0 }, - { "nosteps", 0, 0, S_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, S_SURF_NODLIGHT, 0, 0, 0 }, - { "nomiscents", 0, 0, S_SURF_NOMISCENTS, 0, 0, 0 }, - { "forcefield", 0, 0, S_SURF_FORCEFIELD, 0, 0, 0 }, - - - /* materials */ - { "*mat_none", 0, 0, S_MAT_NONE, S_MAT_MASK, 0, 0 }, - { "*mat_solidwood", 0, 0, S_MAT_SOLIDWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_hollowwood", 0, 0, S_MAT_HOLLOWWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_solidmetal", 0, 0, S_MAT_SOLIDMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_hollowmetal", 0, 0, S_MAT_HOLLOWMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_shortgrass", 0, 0, S_MAT_SHORTGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_longgrass", 0, 0, S_MAT_LONGGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_dirt", 0, 0, S_MAT_DIRT, S_MAT_MASK, 0, 0 }, - { "*mat_sand", 0, 0, S_MAT_SAND, S_MAT_MASK, 0, 0 }, - { "*mat_gravel", 0, 0, S_MAT_GRAVEL, S_MAT_MASK, 0, 0 }, - { "*mat_glass", 0, 0, S_MAT_GLASS, S_MAT_MASK, 0, 0 }, - { "*mat_concrete", 0, 0, S_MAT_CONCRETE, S_MAT_MASK, 0, 0 }, - { "*mat_marble", 0, 0, S_MAT_MARBLE, S_MAT_MASK, 0, 0 }, - { "*mat_water", 0, 0, S_MAT_WATER, S_MAT_MASK, 0, 0 }, - { "*mat_snow", 0, 0, S_MAT_SNOW, S_MAT_MASK, 0, 0 }, - { "*mat_ice", 0, 0, S_MAT_ICE, S_MAT_MASK, 0, 0 }, - { "*mat_flesh", 0, 0, S_MAT_FLESH, S_MAT_MASK, 0, 0 }, - { "*mat_mud", 0, 0, S_MAT_MUD, S_MAT_MASK, 0, 0 }, - { "*mat_bpglass", 0, 0, S_MAT_BPGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_dryleaves", 0, 0, S_MAT_DRYLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_greenleaves", 0, 0, S_MAT_GREENLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_fabric", 0, 0, S_MAT_FABRIC, S_MAT_MASK, 0, 0 }, - { "*mat_canvas", 0, 0, S_MAT_CANVAS, S_MAT_MASK, 0, 0 }, - { "*mat_rock", 0, 0, S_MAT_ROCK, S_MAT_MASK, 0, 0 }, - { "*mat_rubber", 0, 0, S_MAT_RUBBER, S_MAT_MASK, 0, 0 }, - { "*mat_plastic", 0, 0, S_MAT_PLASTIC, S_MAT_MASK, 0, 0 }, - { "*mat_tiles", 0, 0, S_MAT_TILES, S_MAT_MASK, 0, 0 }, - { "*mat_carpet", 0, 0, S_MAT_CARPET, S_MAT_MASK, 0, 0 }, - { "*mat_plaster", 0, 0, S_MAT_PLASTER, S_MAT_MASK, 0, 0 }, - { "*mat_shatterglass", 0, 0, S_MAT_SHATTERGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_armor", 0, 0, S_MAT_ARMOR, S_MAT_MASK, 0, 0 }, - { "*mat_computer", 0, 0, S_MAT_COMPUTER, S_MAT_MASK, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - S_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_nexuiz.h b/tools/quake3/q3map2/game_nexuiz.h deleted file mode 100644 index 8b8f17bb..00000000 --- a/tools/quake3/q3map2/game_nexuiz.h +++ /dev/null @@ -1,163 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_NEXUIZ_H -#define GAME_NEXUIZ_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - are in game_quake3.h - - ------------------------------------------------------------------------------- */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "nexuiz", /* -game x */ - "data", /* default base game data dir */ - ".nexuiz", /* unix home sub-dir */ - "nexuiz", /* magic path word */ - "scripts", /* shader directory */ - 999, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 1.0f / 66.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "../gfx/%s_mini.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_prophecy.h b/tools/quake3/q3map2/game_prophecy.h deleted file mode 100644 index 1514e906..00000000 --- a/tools/quake3/q3map2/game_prophecy.h +++ /dev/null @@ -1,154 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2006 Id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_PROPHECY_H -#define GAME_PROPHECY_H - -/* content and surface flags get form quake3 */ - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "prophecy", /* -game x */ - "base", /* default base game data dir */ - ".prophecy", /* unix home sub-dir */ - "prophecy", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 200.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 0.4f, /* lightgrid scale */ - 0.6f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 4, /* default patchMeta subdivisions tolerance */ - true, /* patch casting enabled */ - true, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_qfusion.h b/tools/quake3/q3map2/game_qfusion.h deleted file mode 100644 index 07f026fc..00000000 --- a/tools/quake3/q3map2/game_qfusion.h +++ /dev/null @@ -1,216 +0,0 @@ -/* ------------------------------------------------------------------------------- - - This code is based on source provided under the terms of the Id Software - LIMITED USE SOFTWARE LICENSE AGREEMENT, a copy of which is included with the - GtkRadiant sources (see LICENSE_ID). If you did not receive a copy of - LICENSE_ID, please contact Id Software immediately at info@idsoftware.com. - - All changes and additions to the original source which have been developed by - other contributors (see CONTRIBUTORS) are provided under the terms of the - license the contributors choose (see LICENSE), to the extent permitted by the - LICENSE_ID. If you did not receive a copy of the contributor license, - please contact the GtkRadiant maintainers at info@gtkradiant.com immediately. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' - AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY - DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_QFUSION_H -#define GAME_QFUSION_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define F_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define F_CONT_LAVA 8 -#define F_CONT_SLIME 16 -#define F_CONT_WATER 32 -#define F_CONT_FOG 64 - -#define F_CONT_AREAPORTAL 0x8000 - -#define F_CONT_PLAYERCLIP 0x10000 -#define F_CONT_MONSTERCLIP 0x20000 -#define F_CONT_TELEPORTER 0x40000 -#define F_CONT_JUMPPAD 0x80000 -#define F_CONT_CLUSTERPORTAL 0x100000 -#define F_CONT_DONOTENTER 0x200000 -#define F_CONT_BOTCLIP 0x400000 - -#define F_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define F_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define F_CONT_CORPSE 0x4000000 -#define F_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define F_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define F_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define F_CONT_TRIGGER 0x40000000 -#define F_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define F_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define F_SURF_SLICK 0x2 /* effects game physics */ -#define F_SURF_SKY 0x4 /* lighting from environment map */ -#define F_SURF_LADDER 0x8 -#define F_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define F_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define F_SURF_FLESH 0x40 /* make flesh sounds and effects */ -#define F_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define F_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define F_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define F_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define F_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define F_SURF_METALSTEPS 0x1000 /* clanking footsteps */ -#define F_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define F_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define F_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define F_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define F_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define F_SURF_DUST 0x40000 /* leave a dust trail when walking on this surface */ - -/* ydnar flags */ -#define F_SURF_VERTEXLIT ( F_SURF_POINTLIGHT | F_SURF_NOLIGHTMAP ) -#define F_SURF_BEVELSMASK ( F_SURF_NODAMAGE | F_SURF_SLICK | F_SURF_FLESH | F_SURF_METALSTEPS | F_SURF_NOSTEPS | F_SURF_DUST ) - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "qfusion", /* -game x */ - "base", /* default base game data dir */ - ".qfusion", /* unix home sub-dir */ - "qfusion", /* magic path word */ - "scripts", /* shader directory */ - 65535, /* max lightmapped surface verts */ - 65535, /* max surface verts */ - 393210, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 512, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - true, /* lightmap sRGB */ - true, /* texture sRGB */ - true, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - true, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 4, /* default patchMeta subdivisions tolerance */ - true, /* patch casting enabled */ - true, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 1.0f / 66.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "../minimaps/%s.tga", /* minimap name format */ - "FBSP", /* bsp file prefix */ - 1, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadRBSPFile, /* bsp load function */ - WriteRBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", F_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", F_CONT_ORIGIN, F_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", F_CONT_AREAPORTAL, F_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", F_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", F_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", F_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, F_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, F_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, F_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, F_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, F_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, F_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, F_CONT_SOLID, F_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", F_CONT_TRIGGER, F_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", F_CONT_WATER, F_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", F_CONT_SLIME, F_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", F_CONT_LAVA, F_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", F_CONT_PLAYERCLIP, F_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", F_CONT_MONSTERCLIP, F_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", F_CONT_NODROP, F_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", F_CONT_CLUSTERPORTAL, F_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", F_CONT_DONOTENTER, F_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", F_CONT_BOTCLIP, F_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", F_CONT_FOG, F_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, F_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, F_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, F_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, F_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, F_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, F_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, F_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, F_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, F_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, F_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, F_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - F_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_quake3.h b/tools/quake3/q3map2/game_quake3.h deleted file mode 100644 index 96acbfa7..00000000 --- a/tools/quake3/q3map2/game_quake3.h +++ /dev/null @@ -1,216 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_QUAKE3_H -#define GAME_QUAKE3_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define Q_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define Q_CONT_LAVA 8 -#define Q_CONT_SLIME 16 -#define Q_CONT_WATER 32 -#define Q_CONT_FOG 64 - -#define Q_CONT_AREAPORTAL 0x8000 - -#define Q_CONT_PLAYERCLIP 0x10000 -#define Q_CONT_MONSTERCLIP 0x20000 -#define Q_CONT_TELEPORTER 0x40000 -#define Q_CONT_JUMPPAD 0x80000 -#define Q_CONT_CLUSTERPORTAL 0x100000 -#define Q_CONT_DONOTENTER 0x200000 -#define Q_CONT_BOTCLIP 0x400000 - -#define Q_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define Q_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define Q_CONT_CORPSE 0x4000000 -#define Q_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define Q_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define Q_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define Q_CONT_TRIGGER 0x40000000 -#define Q_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define Q_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define Q_SURF_SLICK 0x2 /* effects game physics: zero friction on this */ -#define Q_SURF_SKY 0x4 /* lighting from environment map */ -#define Q_SURF_LADDER 0x8 -#define Q_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define Q_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define Q_SURF_FLESH 0x40 /* make flesh sounds and effects */ -#define Q_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define Q_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define Q_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define Q_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define Q_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define Q_SURF_METALSTEPS 0x1000 /* clanking footsteps */ -#define Q_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define Q_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define Q_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define Q_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define Q_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define Q_SURF_DUST 0x40000 /* leave a dust trail when walking on this surface */ -#define Q_SURF_NOOB 0x80000 /* no overbounces on this surface */ - -/* ydnar flags */ -#define Q_SURF_VERTEXLIT ( Q_SURF_POINTLIGHT | Q_SURF_NOLIGHTMAP ) -#define Q_SURF_BEVELSMASK ( Q_SURF_NODAMAGE | Q_SURF_SLICK | Q_SURF_FLESH | Q_SURF_METALSTEPS | Q_SURF_NOSTEPS | Q_SURF_DUST | Q_SURF_NOOB ) - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "quake3", /* -game x */ - "baseq3", /* default base game data dir */ - ".q3a", /* unix home sub-dir */ - "quake", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - { "noob", 0, 0, Q_SURF_NOOB, 0, 0, 0 }, - { "ob", 0, 0, 0, 0, C_OB, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_quakelive.h b/tools/quake3/q3map2/game_quakelive.h deleted file mode 100644 index d41ba6f4..00000000 --- a/tools/quake3/q3map2/game_quakelive.h +++ /dev/null @@ -1,178 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_QUAKELIVE_H -#define GAME_QUAKELIVE_H - - - -/* ------------------------------------------------------------------------------- - - no content and surface flags here - they are the same as Quake 3's - (this file must be included AFTER game_quake3.h) - - ------------------------------------------------------------------------------- */ - - - /* ------------------------------------------------------------------------------- - - Additional surface flags for Quake Live - - ------------------------------------------------------------------------------- */ - -#define Q_SURF_SNOWSTEPS 0x80000 // snow footsteps -#define Q_SURF_WOODSTEPS 0x100000 // wood footsteps -#define Q_SURF_DMGTHROUGH 0x200000 // Missile dmg through surface(?) - // (This is not in use atm, will - // probably be re-purposed some day.) - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "quakelive", /* -game x */ - "baseq3", /* default base game data dir (FIXME what does quake live really use?) */ - ".quakelive/quakelive/home", /* unix home sub-dir (FIXME what does quake live really use?) */ - "quake", /* magic path word (FIXME where does quake live install to?) */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 47, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "snowsteps", 0, 0, Q_SURF_SNOWSTEPS, 0, 0, 0 }, - { "woodsteps", 0, 0, Q_SURF_WOODSTEPS, 0, 0, 0 }, - { "dmgthrough", 0, 0, Q_SURF_DMGTHROUGH, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - ( Q_SURF_BEVELSMASK | Q_SURF_SNOWSTEPS | Q_SURF_WOODSTEPS ) -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_reaction.h b/tools/quake3/q3map2/game_reaction.h deleted file mode 100644 index 3384f677..00000000 --- a/tools/quake3/q3map2/game_reaction.h +++ /dev/null @@ -1,199 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_REACTION_H -#define GAME_REACTION_H - - - -/* ------------------------------------------------------------------------------- - - inherit content and surface flags from game_quake3.h - (this file must be included AFTER game_quake3.h) - - Additional surface flags follow. These were given to me (Rambetter) by TTI from the Reaction team. - Note that some of these values have more than one bit set. I'm not sure how Reaction is using these - bits, but this is what I got from TTI. - - ------------------------------------------------------------------------------- */ - -#define REACTION_SURF_GRAVEL 0x80000 -#define REACTION_SURF_WOOD 0x81000 -#define REACTION_SURF_CARPET 0x100000 -#define REACTION_SURF_METAL2 0x101000 -#define REACTION_SURF_GLASS 0x180000 -#define REACTION_SURF_GRASS 0x181000 -#define REACTION_SURF_SNOW 0x200000 -#define REACTION_SURF_MUD 0x201000 -#define REACTION_SURF_WOOD2 0x280000 -#define REACTION_SURF_HARDMETAL 0x281000 -#define REACTION_SURF_LEAVES 0x300000 -#define REACTION_SURF_CEMENT 0x301000 -#define REACTION_SURF_MARBLE 0x380000 -#define REACTION_SURF_SNOW2 0x381000 -#define REACTION_SURF_HARDSTEPS 0x400000 -#define REACTION_SURF_SAND 0x401000 - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "reaction", /* -game x */ - "Boomstick", /* default base game data dir */ - ".Reaction", /* unix home sub-dir */ - "reaction", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - { "rq3_gravel", 0, 0, REACTION_SURF_GRAVEL, 0, 0, 0 }, - { "rq3_wood", 0, 0, REACTION_SURF_WOOD, 0, 0, 0 }, - { "rq3_carpet", 0, 0, REACTION_SURF_CARPET, 0, 0, 0 }, - { "rq3_metal2", 0, 0, REACTION_SURF_METAL2, 0, 0, 0 }, - { "rq3_glass", 0, 0, REACTION_SURF_GLASS, 0, 0, 0 }, - { "rq3_grass", 0, 0, REACTION_SURF_GRASS, 0, 0, 0 }, - { "rq3_snow", 0, 0, REACTION_SURF_SNOW, 0, 0, 0 }, - { "rq3_mud", 0, 0, REACTION_SURF_MUD, 0, 0, 0 }, - { "rq3_wood2", 0, 0, REACTION_SURF_WOOD2, 0, 0, 0 }, - { "rq3_hardmetal", 0, 0, REACTION_SURF_HARDMETAL, 0, 0, 0 }, - { "rq3_leaves", 0, 0, REACTION_SURF_LEAVES, 0, 0, 0 }, - { "rq3_cement", 0, 0, REACTION_SURF_CEMENT, 0, 0, 0 }, - { "rq3_marble", 0, 0, REACTION_SURF_MARBLE, 0, 0, 0 }, - { "rq3_snow2", 0, 0, REACTION_SURF_SNOW2, 0, 0, 0 }, - { "rq3_hardsteps", 0, 0, REACTION_SURF_HARDSTEPS, 0, 0, 0 }, - { "rq3_sand", 0, 0, REACTION_SURF_SAND, 0, 0, 0 }, - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_sof2.h b/tools/quake3/q3map2/game_sof2.h deleted file mode 100644 index c455dab5..00000000 --- a/tools/quake3/q3map2/game_sof2.h +++ /dev/null @@ -1,280 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_SOF2_H -#define GAME_SOF2_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* thanks to the gracious fellows at raven */ -#define S_CONT_SOLID 0x00000001 /* Default setting. An eye is never valid in a solid */ -#define S_CONT_LAVA 0x00000002 -#define S_CONT_WATER 0x00000004 -#define S_CONT_FOG 0x00000008 -#define S_CONT_PLAYERCLIP 0x00000010 -#define S_CONT_MONSTERCLIP 0x00000020 -#define S_CONT_BOTCLIP 0x00000040 -#define S_CONT_SHOTCLIP 0x00000080 -#define S_CONT_BODY 0x00000100 /* should never be on a brush, only in game */ -#define S_CONT_CORPSE 0x00000200 /* should never be on a brush, only in game */ -#define S_CONT_TRIGGER 0x00000400 -#define S_CONT_NODROP 0x00000800 /* don't leave bodies or items (death fog, lava) */ -#define S_CONT_TERRAIN 0x00001000 /* volume contains terrain data */ -#define S_CONT_LADDER 0x00002000 -#define S_CONT_ABSEIL 0x00004000 /* used like ladder to define where an NPC can abseil */ -#define S_CONT_OPAQUE 0x00008000 /* defaults to on, when off, solid can be seen through */ -#define S_CONT_OUTSIDE 0x00010000 /* volume is considered to be in the outside (i.e. not indoors) */ -#define S_CONT_SLIME 0x00020000 /* don't be fooled. it may SAY "slime" but it really means "projectileclip" */ -#define S_CONT_LIGHTSABER 0x00040000 -#define S_CONT_TELEPORTER 0x00080000 -#define S_CONT_ITEM 0x00100000 -#define S_CONT_DETAIL 0x08000000 /* brushes not used for the bsp */ -#define S_CONT_TRANSLUCENT int(0x80000000) /* don't consume surface fragments inside */ - -#define S_SURF_SKY 0x00002000 /* lighting from environment map */ -#define S_SURF_SLICK 0x00004000 /* affects game physics */ -#define S_SURF_METALSTEPS 0x00008000 /* chc needs this since we use same tools */ -#define S_SURF_FORCEFIELD 0x00010000 /* chc */ -#define S_SURF_NODAMAGE 0x00040000 /* never give falling damage */ -#define S_SURF_NOIMPACT 0x00080000 /* don't make missile explosions */ -#define S_SURF_NOMARKS 0x00100000 /* don't leave missile marks */ -#define S_SURF_NODRAW 0x00200000 /* don't generate a drawsurface at all */ -#define S_SURF_NOSTEPS 0x00400000 /* no footstep sounds */ -#define S_SURF_NODLIGHT 0x00800000 /* don't dlight even if solid (solid lava, skies) */ -#define S_SURF_NOMISCENTS 0x01000000 /* no client models allowed on this surface */ - -#define S_SURF_PATCH int(0x80000000) /* mark this face as a patch(editor only) */ - -#define S_SURF_BEVELSMASK ( S_SURF_SLICK | S_SURF_METALSTEPS | S_SURF_NODAMAGE | S_SURF_NOSTEPS | S_SURF_NOMISCENTS ) /* compiler utility */ - -/* materials */ -#define S_MAT_BITS 5 -#define S_MAT_MASK 0x1f /* mask to get the material type */ - -#define S_MAT_NONE 0 /* for when the artist hasn't set anything up =) */ -#define S_MAT_SOLIDWOOD 1 /* freshly cut timber */ -#define S_MAT_HOLLOWWOOD 2 /* termite infested creaky wood */ -#define S_MAT_SOLIDMETAL 3 /* solid girders */ -#define S_MAT_HOLLOWMETAL 4 /* hollow metal machines */ -#define S_MAT_SHORTGRASS 5 /* manicured lawn */ -#define S_MAT_LONGGRASS 6 /* long jungle grass */ -#define S_MAT_DIRT 7 /* hard mud */ -#define S_MAT_SAND 8 /* sandy beach */ -#define S_MAT_GRAVEL 9 /* lots of small stones */ -#define S_MAT_GLASS 10 -#define S_MAT_CONCRETE 11 /* hardened concrete pavement */ -#define S_MAT_MARBLE 12 /* marble floors */ -#define S_MAT_WATER 13 /* light covering of water on a surface */ -#define S_MAT_SNOW 14 /* freshly laid snow */ -#define S_MAT_ICE 15 /* packed snow/solid ice */ -#define S_MAT_FLESH 16 /* hung meat, corpses in the world */ -#define S_MAT_MUD 17 /* wet soil */ -#define S_MAT_BPGLASS 18 /* bulletproof glass */ -#define S_MAT_DRYLEAVES 19 /* dried up leaves on the floor */ -#define S_MAT_GREENLEAVES 20 /* fresh leaves still on a tree */ -#define S_MAT_FABRIC 21 /* Cotton sheets */ -#define S_MAT_CANVAS 22 /* tent material */ -#define S_MAT_ROCK 23 -#define S_MAT_RUBBER 24 /* hard tire like rubber */ -#define S_MAT_PLASTIC 25 -#define S_MAT_TILES 26 /* tiled floor */ -#define S_MAT_CARPET 27 /* lush carpet */ -#define S_MAT_PLASTER 28 /* drywall style plaster */ -#define S_MAT_SHATTERGLASS 29 /* glass with the Crisis Zone style shattering */ -#define S_MAT_ARMOR 30 /* body armor */ -#define S_MAT_COMPUTER 31 /* computers/electronic equipment */ -#define S_MAT_LAST 32 /* number of materials */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "sof2", /* -game x */ - "base", /* default base game data dir */ - ".sof2", /* unix home sub-dir */ - "soldier", /* magic path word */ - "shaders", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - true, /* flares */ - "gfx/misc/lens_flare", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "RBSP", /* bsp file prefix */ - 1, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadRBSPFile, /* bsp load function */ - WriteRBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", S_CONT_SOLID | S_CONT_OPAQUE, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", 0, S_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", S_CONT_TRANSLUCENT, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", S_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", S_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", 0, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, 0, 0, C_HINT, 0 }, - { "nodraw", 0, 0, S_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, 0, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, 0, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, 0, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, S_CONT_SOLID, 0, 0, 0, C_SOLID }, - { "nonopaque", 0, S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, 0 }, /* setting trans ok? */ - - { "trigger", S_CONT_TRIGGER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", S_CONT_WATER, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", S_CONT_SLIME, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", S_CONT_LAVA, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "shotclip", S_CONT_SHOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* setting trans/detail ok? */ - { "playerclip", S_CONT_PLAYERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", S_CONT_MONSTERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", S_CONT_NODROP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "terrain", S_CONT_TERRAIN, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "ladder", S_CONT_LADDER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "abseil", S_CONT_ABSEIL, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "outside", S_CONT_OUTSIDE, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "botclip", S_CONT_BOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - - { "fog", S_CONT_FOG, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_FOG | C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* nonopaque? */ - { "sky", 0, 0, S_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, S_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, S_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, S_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "nodamage", 0, 0, S_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, S_SURF_METALSTEPS, 0, 0, 0 }, - { "nosteps", 0, 0, S_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, S_SURF_NODLIGHT, 0, 0, 0 }, - { "nomiscents", 0, 0, S_SURF_NOMISCENTS, 0, 0, 0 }, - { "forcefield", 0, 0, S_SURF_FORCEFIELD, 0, 0, 0 }, - - - /* materials */ - { "*mat_none", 0, 0, S_MAT_NONE, S_MAT_MASK, 0, 0 }, - { "*mat_solidwood", 0, 0, S_MAT_SOLIDWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_hollowwood", 0, 0, S_MAT_HOLLOWWOOD, S_MAT_MASK, 0, 0 }, - { "*mat_solidmetal", 0, 0, S_MAT_SOLIDMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_hollowmetal", 0, 0, S_MAT_HOLLOWMETAL, S_MAT_MASK, 0, 0 }, - { "*mat_shortgrass", 0, 0, S_MAT_SHORTGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_longgrass", 0, 0, S_MAT_LONGGRASS, S_MAT_MASK, 0, 0 }, - { "*mat_dirt", 0, 0, S_MAT_DIRT, S_MAT_MASK, 0, 0 }, - { "*mat_sand", 0, 0, S_MAT_SAND, S_MAT_MASK, 0, 0 }, - { "*mat_gravel", 0, 0, S_MAT_GRAVEL, S_MAT_MASK, 0, 0 }, - { "*mat_glass", 0, 0, S_MAT_GLASS, S_MAT_MASK, 0, 0 }, - { "*mat_concrete", 0, 0, S_MAT_CONCRETE, S_MAT_MASK, 0, 0 }, - { "*mat_marble", 0, 0, S_MAT_MARBLE, S_MAT_MASK, 0, 0 }, - { "*mat_water", 0, 0, S_MAT_WATER, S_MAT_MASK, 0, 0 }, - { "*mat_snow", 0, 0, S_MAT_SNOW, S_MAT_MASK, 0, 0 }, - { "*mat_ice", 0, 0, S_MAT_ICE, S_MAT_MASK, 0, 0 }, - { "*mat_flesh", 0, 0, S_MAT_FLESH, S_MAT_MASK, 0, 0 }, - { "*mat_mud", 0, 0, S_MAT_MUD, S_MAT_MASK, 0, 0 }, - { "*mat_bpglass", 0, 0, S_MAT_BPGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_dryleaves", 0, 0, S_MAT_DRYLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_greenleaves", 0, 0, S_MAT_GREENLEAVES, S_MAT_MASK, 0, 0 }, - { "*mat_fabric", 0, 0, S_MAT_FABRIC, S_MAT_MASK, 0, 0 }, - { "*mat_canvas", 0, 0, S_MAT_CANVAS, S_MAT_MASK, 0, 0 }, - { "*mat_rock", 0, 0, S_MAT_ROCK, S_MAT_MASK, 0, 0 }, - { "*mat_rubber", 0, 0, S_MAT_RUBBER, S_MAT_MASK, 0, 0 }, - { "*mat_plastic", 0, 0, S_MAT_PLASTIC, S_MAT_MASK, 0, 0 }, - { "*mat_tiles", 0, 0, S_MAT_TILES, S_MAT_MASK, 0, 0 }, - { "*mat_carpet", 0, 0, S_MAT_CARPET, S_MAT_MASK, 0, 0 }, - { "*mat_plaster", 0, 0, S_MAT_PLASTER, S_MAT_MASK, 0, 0 }, - { "*mat_shatterglass", 0, 0, S_MAT_SHATTERGLASS, S_MAT_MASK, 0, 0 }, - { "*mat_armor", 0, 0, S_MAT_ARMOR, S_MAT_MASK, 0, 0 }, - { "*mat_computer", 0, 0, S_MAT_COMPUTER, S_MAT_MASK, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - S_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_tenebrae.h b/tools/quake3/q3map2/game_tenebrae.h deleted file mode 100644 index 86499845..00000000 --- a/tools/quake3/q3map2/game_tenebrae.h +++ /dev/null @@ -1,213 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_TENEBRAE_H -#define GAME_TENEBRAE_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define T_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define T_CONT_LAVA 8 -#define T_CONT_SLIME 16 -#define T_CONT_WATER 32 -#define T_CONT_FOG 64 - -#define T_CONT_AREAPORTAL 0x8000 - -#define T_CONT_PLAYERCLIP 0x10000 -#define T_CONT_MONSTERCLIP 0x20000 -#define T_CONT_TELEPORTER 0x40000 -#define T_CONT_JUMPPAD 0x80000 -#define T_CONT_CLUSTERPORTAL 0x100000 -#define T_CONT_DONOTENTER 0x200000 -#define T_CONT_BOTCLIP 0x400000 - -#define T_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define T_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define T_CONT_CORPSE 0x4000000 -#define T_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define T_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define T_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define T_CONT_TRIGGER 0x40000000 -#define T_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define T_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define T_SURF_SLICK 0x2 /* effects game physics */ -#define T_SURF_SKY 0x4 /* lighting from environment map */ -#define T_SURF_LADDER 0x8 -#define T_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define T_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define T_SURF_FLESH 0x40 /* make flesh sounds and effects */ -#define T_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define T_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define T_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define T_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define T_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define T_SURF_METALSTEPS 0x1000 /* clanking footsteps */ -#define T_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define T_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define T_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define T_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define T_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define T_SURF_DUST 0x40000 /* leave a dust trail when walking on this surface */ - -/* ydnar flags */ -#define T_SURF_VERTEXLIT ( T_SURF_POINTLIGHT | T_SURF_NOLIGHTMAP ) -#define T_SURF_BEVELSMASK ( T_SURF_NODAMAGE | T_SURF_SLICK | T_SURF_FLESH | T_SURF_METALSTEPS | T_SURF_NOSTEPS | T_SURF_DUST ) - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "tenebrae", /* -game x */ - "base", /* default base game data dir */ - ".tenebrae", /* unix home sub-dir */ - "tenebrae", /* magic path word */ - "scripts", /* shader directory */ - 1024, /* max lightmapped surface verts */ - 1024, /* max surface verts */ - 6144, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 512, /* lightmap width/height */ - 2.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - true, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", T_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", T_CONT_ORIGIN, T_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", T_CONT_AREAPORTAL, T_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", T_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", T_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", T_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, T_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, T_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, T_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, T_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, T_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, T_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, T_CONT_SOLID, T_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", T_CONT_TRIGGER, T_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", T_CONT_WATER, T_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", T_CONT_SLIME, T_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", T_CONT_LAVA, T_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", T_CONT_PLAYERCLIP, T_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", T_CONT_MONSTERCLIP, T_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", T_CONT_NODROP, T_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", T_CONT_CLUSTERPORTAL, T_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", T_CONT_DONOTENTER, T_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", T_CONT_BOTCLIP, T_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", T_CONT_FOG, T_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, T_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, T_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, T_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, T_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, T_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, T_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, T_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, T_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, T_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, T_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, T_SURF_DUST, 0, 0, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - T_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_tremulous.h b/tools/quake3/q3map2/game_tremulous.h deleted file mode 100644 index d0d200ee..00000000 --- a/tools/quake3/q3map2/game_tremulous.h +++ /dev/null @@ -1,180 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - -/* Tremulous support, by LinuxManMikeC */ - - -/* marker */ -#ifndef GAME_TREMULOUS_H -#define GAME_TREMULOUS_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - also uses defines from game_quake3.h - - ------------------------------------------------------------------------------- */ -#define TREM_CONT_NOALIENBUILD 0x1000 -#define TREM_CONT_NOHUMANBUILD 0x2000 -#define TREM_CONT_NOBUILD 0x4000 - -#define TREM_SURF_NOALIENBUILDSURFACE 0x80000 -#define TREM_SURF_NOHUMANBUILDSURFACE 0x100000 -#define TREM_SURF_NOBUILDSURFACE 0x200000 - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "tremulous", /* -game x */ - "base", /* default base game data dir */ - ".tremulous", /* unix home sub-dir */ - "tremulous", /* magic path word - think this is right for trem*/ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - - /* tremulous */ - {"noalienbuild", TREM_CONT_NOALIENBUILD,0,0,0,0,0}, - {"nohumanbuild", TREM_CONT_NOHUMANBUILD,0,0,0,0,0}, - {"nobuild", TREM_CONT_NOBUILD,0,0,0,0,0}, - - {"noalienbuildsurface", 0,0,TREM_SURF_NOALIENBUILDSURFACE,0,0,0}, - {"nohumanbuildsurface", 0,0,TREM_SURF_NOHUMANBUILDSURFACE,0,0,0}, - {"nobuildsurface", 0,0,TREM_SURF_NOBUILDSURFACE,0,0,0}, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_unvanquished.h b/tools/quake3/q3map2/game_unvanquished.h deleted file mode 100644 index ee60977b..00000000 --- a/tools/quake3/q3map2/game_unvanquished.h +++ /dev/null @@ -1,174 +0,0 @@ -/* ------------------------------------------------------------------------------- - -Copyright (C) 1999-2007 id Software, Inc. and contributors. -For a list of contributors, see the accompanying CONTRIBUTORS file. - -This file is part of GtkRadiant. - -GtkRadiant is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -GtkRadiant is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GtkRadiant; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - ----------------------------------------------------------------------------------- - -This code has been altered significantly from its original form, to support -several games based on the Quake III Arena engine, in the form of "Q3Map2." - -------------------------------------------------------------------------------- */ - -/* Derived from Tremulous support by LinuxManMikeC */ - - -/* marker */ -#ifndef GAME_UNVANQUISHED_H -#define GAME_UNVANQUISHED_H - - - -/* ------------------------------------------------------------------------------- - -content and surface flags - also uses defines from game_quake3.h - -------------------------------------------------------------------------------- */ - -#define UNV_CONT_NOALIENBUILD 0x1000 -#define UNV_CONT_NOHUMANBUILD 0x2000 -#define UNV_CONT_NOBUILD 0x4000 - -#define UNV_SURF_NOALIENBUILDSURFACE 0x80000 -#define UNV_SURF_NOHUMANBUILDSURFACE 0x100000 -#define UNV_SURF_NOBUILDSURFACE 0x200000 - - - -/* ------------------------------------------------------------------------------- - -game_t struct - -------------------------------------------------------------------------------- */ - -{ - "unvanquished", /* -game x */ - "pkg", /* default base game data dir */ - ".unvanquished", /* unix home sub-dir */ - "unvanquished", /* magic path word */ - "scripts", /* shader directory */ - 1048575, /* max lightmapped surface verts */ - 1048575, /* max surface verts */ - 1048575, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 1, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::White, /* minimap mode */ - "../minimaps/%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - /* unvanquished */ - {"noalienbuild", UNV_CONT_NOALIENBUILD, 0, 0, 0, 0, 0 }, - {"nohumanbuild", UNV_CONT_NOHUMANBUILD, 0, 0, 0, 0, 0 }, - {"nobuild", UNV_CONT_NOBUILD, 0, 0, 0, 0, 0 }, - - {"noalienbuildsurface", 0, 0, UNV_SURF_NOALIENBUILDSURFACE, 0, 0, 0 }, - {"nohumanbuildsurface", 0, 0, UNV_SURF_NOHUMANBUILDSURFACE, 0, 0, 0 }, - {"nobuildsurface", 0, 0, UNV_SURF_NOBUILDSURFACE, 0, 0, 0 }, - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_wolf.h b/tools/quake3/q3map2/game_wolf.h deleted file mode 100644 index 40526d5c..00000000 --- a/tools/quake3/q3map2/game_wolf.h +++ /dev/null @@ -1,259 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_WOLF_H -#define GAME_WOLF_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* game flags */ -#define W_CONT_SOLID 1 /* an eye is never valid in a solid */ -#define W_CONT_LAVA 8 -#define W_CONT_SLIME 16 -#define W_CONT_WATER 32 -#define W_CONT_FOG 64 - -#define W_CONT_MISSILECLIP 0x80 /* wolf ranged missile blocking */ -#define W_CONT_ITEM 0x100 /* wolf item contents */ -#define W_CONT_AI_NOSIGHT 0x1000 /* wolf ai sight blocking */ -#define W_CONT_CLIPSHOT 0x2000 /* wolf shot clip */ -#define W_CONT_AREAPORTAL 0x8000 - -#define W_CONT_PLAYERCLIP 0x10000 -#define W_CONT_MONSTERCLIP 0x20000 -#define W_CONT_TELEPORTER 0x40000 -#define W_CONT_JUMPPAD 0x80000 -#define W_CONT_CLUSTERPORTAL 0x100000 -#define W_CONT_DONOTENTER 0x200000 -#define W_CONT_DONOTENTER_LARGE 0x400000 /* wolf dne */ - -#define W_CONT_ORIGIN 0x1000000 /* removed before bsping an entity */ - -#define W_CONT_BODY 0x2000000 /* should never be on a brush, only in game */ -#define W_CONT_CORPSE 0x4000000 -#define W_CONT_DETAIL 0x8000000 /* brushes not used for the bsp */ -#define W_CONT_STRUCTURAL 0x10000000 /* brushes used for the bsp */ -#define W_CONT_TRANSLUCENT 0x20000000 /* don't consume surface fragments inside */ -#define W_CONT_TRIGGER 0x40000000 -#define W_CONT_NODROP int(0x80000000) /* don't leave bodies or items (death fog, lava) */ - -#define W_SURF_NODAMAGE 0x1 /* never give falling damage */ -#define W_SURF_SLICK 0x2 /* effects game physics */ -#define W_SURF_SKY 0x4 /* lighting from environment map */ -#define W_SURF_LADDER 0x8 -#define W_SURF_NOIMPACT 0x10 /* don't make missile explosions */ -#define W_SURF_NOMARKS 0x20 /* don't leave missile marks */ -#define W_SURF_CERAMIC 0x40 /* wolf ceramic material */ -#define W_SURF_NODRAW 0x80 /* don't generate a drawsurface at all */ -#define W_SURF_HINT 0x100 /* make a primary bsp splitter */ -#define W_SURF_SKIP 0x200 /* completely ignore, allowing non-closed brushes */ -#define W_SURF_NOLIGHTMAP 0x400 /* surface doesn't need a lightmap */ -#define W_SURF_POINTLIGHT 0x800 /* generate lighting info at vertexes */ -#define W_SURF_METAL 0x1000 /* wolf metal material */ -#define W_SURF_NOSTEPS 0x2000 /* no footstep sounds */ -#define W_SURF_NONSOLID 0x4000 /* don't collide against curves with this set */ -#define W_SURF_LIGHTFILTER 0x8000 /* act as a light filter during q3map -light */ -#define W_SURF_ALPHASHADOW 0x10000 /* do per-pixel light shadow casting in q3map */ -#define W_SURF_NODLIGHT 0x20000 /* don't dlight even if solid (solid lava, skies) */ -#define W_SURF_WOOD 0x40000 /* wolf wood material */ -#define W_SURF_GRASS 0x80000 /* wolf grass material */ -#define W_SURF_GRAVEL 0x100000 /* wolf gravel material */ -#define W_SURF_GLASS 0x200000 /* wolf glass material */ -#define W_SURF_SNOW 0x400000 /* wolf snow material */ -#define W_SURF_ROOF 0x800000 /* wolf roof material */ -#define W_SURF_RUBBLE 0x1000000 /* wolf rubble material */ -#define W_SURF_CARPET 0x2000000 /* wolf carpet material */ - -#define W_SURF_MONSTERSLICK 0x4000000 /* wolf npc slick surface */ -#define W_SURF_MONSLICK_W 0x8000000 /* wolf slide bodies west */ -#define W_SURF_MONSLICK_N 0x10000000 /* wolf slide bodies north */ -#define W_SURF_MONSLICK_E 0x20000000 /* wolf slide bodies east */ -#define W_SURF_MONSLICK_S 0x40000000 /* wolf slide bodies south */ - -/* ydnar flags */ -#define W_SURF_VERTEXLIT ( W_SURF_POINTLIGHT | W_SURF_NOLIGHTMAP ) -#define W_SURF_BEVELSMASK ( W_SURF_NODAMAGE | W_SURF_SLICK | W_SURF_CERAMIC | W_SURF_METAL | W_SURF_NOSTEPS | W_SURF_WOOD | W_SURF_GRASS | W_SURF_GRAVEL | W_SURF_GLASS | W_SURF_SNOW | W_SURF_ROOF | W_SURF_RUBBLE | W_SURF_CARPET | W_SURF_MONSTERSLICK | W_SURF_MONSLICK_W | W_SURF_MONSLICK_N | W_SURF_MONSLICK_E | W_SURF_MONSLICK_S ) - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "wolf", /* -game x */ - "main", /* default base game data dir */ - ".wolf", /* unix home sub-dir */ - "wolf", /* magic path word */ - "scripts", /* shader directory */ - 64, /* max lightmapped surface verts */ - 999, /* max surface verts */ - 6000, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - true, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 47, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", W_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", W_CONT_ORIGIN, W_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", W_CONT_AREAPORTAL, W_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", W_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", W_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", W_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, W_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, W_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, W_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, W_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, W_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, W_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, W_CONT_SOLID, W_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", W_CONT_TRIGGER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", W_CONT_WATER, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slag", W_CONT_SLIME, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", W_CONT_LAVA, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", W_CONT_PLAYERCLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", W_CONT_MONSTERCLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "clipmissile", W_CONT_MISSILECLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "clipshot", W_CONT_CLIPSHOT, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", W_CONT_NODROP, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", W_CONT_CLUSTERPORTAL, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", W_CONT_DONOTENTER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenterlarge",W_CONT_DONOTENTER_LARGE, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", W_CONT_FOG, W_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, W_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, W_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, W_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, W_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, W_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, W_SURF_NODAMAGE, 0, 0, 0 }, - { "nosteps", 0, 0, W_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, W_SURF_NODLIGHT, 0, 0, 0 }, - - - /* materials */ - { "metal", 0, 0, W_SURF_METAL, 0, 0, 0 }, - { "metalsteps", 0, 0, W_SURF_METAL, 0, 0, 0 }, - { "glass", 0, 0, W_SURF_GLASS, 0, 0, 0 }, - { "ceramic", 0, 0, W_SURF_CERAMIC, 0, 0, 0 }, - { "woodsteps", 0, 0, W_SURF_WOOD, 0, 0, 0 }, - { "grasssteps", 0, 0, W_SURF_GRASS, 0, 0, 0 }, - { "gravelsteps", 0, 0, W_SURF_GRAVEL, 0, 0, 0 }, - { "rubble", 0, 0, W_SURF_RUBBLE, 0, 0, 0 }, - { "carpetsteps", 0, 0, W_SURF_CARPET, 0, 0, 0 }, - { "snowsteps", 0, 0, W_SURF_SNOW, 0, 0, 0 }, - { "roofsteps", 0, 0, W_SURF_ROOF, 0, 0, 0 }, - - - /* ai */ - { "ai_nosight", W_CONT_AI_NOSIGHT, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - /* ydnar: experimental until bits are confirmed! */ - { "ai_nopass", W_CONT_DONOTENTER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "ai_nopasslarge", W_CONT_DONOTENTER_LARGE, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - - /* sliding bodies */ - { "monsterslick", 0, 0, W_SURF_MONSTERSLICK, 0, C_TRANSLUCENT, 0 }, - { "monsterslicknorth", 0, 0, W_SURF_MONSLICK_N, 0, C_TRANSLUCENT, 0 }, - { "monsterslickeast", 0, 0, W_SURF_MONSLICK_E, 0, C_TRANSLUCENT, 0 }, - { "monsterslicksouth", 0, 0, W_SURF_MONSLICK_S, 0, C_TRANSLUCENT, 0 }, - { "monsterslickwest", 0, 0, W_SURF_MONSLICK_W, 0, C_TRANSLUCENT, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - W_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_wolfet.h b/tools/quake3/q3map2/game_wolfet.h deleted file mode 100644 index b01f47f1..00000000 --- a/tools/quake3/q3map2/game_wolfet.h +++ /dev/null @@ -1,198 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - Support for Wolfenstein: Enemy Territory by ydnar@splashdamage.com - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_WOLFET_H -#define GAME_WOLFET_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - - ------------------------------------------------------------------------------- */ - -/* this file must be included *after* game_wolf.h because it shares defines! */ - -#define W_SURF_SPLASH 0x00000040 /* enemy territory water splash surface */ -#define W_SURF_LANDMINE int(0x80000000) /* enemy territory 'landminable' surface */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "et", /* -game x */ - "etmain", /* default base game data dir */ - ".etwolf", /* unix home sub-dir */ - "et", /* magic path word */ - "scripts", /* shader directory */ - 1024, /* max lightmapped surface verts */ - 1024, /* max surface verts */ - 6144, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - true, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - false, /* lightmap sRGB */ - false, /* texture sRGB */ - false, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - false, /* disable shader lightstyles hack */ - false, /* keep light entities on bsp */ - 8, /* default patchMeta subdivisions tolerance */ - false, /* patch casting enabled */ - false, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 0.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "%s.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 47, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", W_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - - /* compiler */ - { "origin", W_CONT_ORIGIN, W_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", W_CONT_AREAPORTAL, W_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", W_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", W_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", W_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, W_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, W_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, W_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, W_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, W_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, W_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - - /* game */ - { "nonsolid", 0, W_CONT_SOLID, W_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", W_CONT_TRIGGER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", W_CONT_WATER, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slag", W_CONT_SLIME, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", W_CONT_SLIME, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, // alias to support shaders of Q3 maps - { "lava", W_CONT_LAVA, W_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", W_CONT_PLAYERCLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", W_CONT_MONSTERCLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "clipmissile", W_CONT_MISSILECLIP, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "clipshot", W_CONT_CLIPSHOT, W_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", W_CONT_NODROP, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", W_CONT_CLUSTERPORTAL, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", W_CONT_DONOTENTER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenterlarge",W_CONT_DONOTENTER_LARGE, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", W_CONT_FOG, W_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, W_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, W_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, W_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, W_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, W_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, W_SURF_NODAMAGE, 0, 0, 0 }, - { "nosteps", 0, 0, W_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, W_SURF_NODLIGHT, 0, 0, 0 }, - - /* wolf et landmine-able surface */ - { "landmine", 0, 0, W_SURF_LANDMINE, 0, 0, 0 }, - - /* materials */ - { "metal", 0, 0, W_SURF_METAL, 0, 0, 0 }, - { "metalsteps", 0, 0, W_SURF_METAL, 0, 0, 0 }, - { "glass", 0, 0, W_SURF_GLASS, 0, 0, 0 }, - { "splash", 0, 0, W_SURF_SPLASH, 0, 0, 0 }, - { "woodsteps", 0, 0, W_SURF_WOOD, 0, 0, 0 }, - { "grasssteps", 0, 0, W_SURF_GRASS, 0, 0, 0 }, - { "gravelsteps", 0, 0, W_SURF_GRAVEL, 0, 0, 0 }, - { "rubble", 0, 0, W_SURF_RUBBLE, 0, 0, 0 }, - { "carpetsteps", 0, 0, W_SURF_CARPET, 0, 0, 0 }, - { "snowsteps", 0, 0, W_SURF_SNOW, 0, 0, 0 }, - { "roofsteps", 0, 0, W_SURF_ROOF, 0, 0, 0 }, - - - /* ai */ - { "ai_nosight", W_CONT_AI_NOSIGHT, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - /* ydnar: experimental until bits are confirmed! */ - { "ai_nopass", W_CONT_DONOTENTER, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "ai_nopasslarge", W_CONT_DONOTENTER_LARGE, W_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - - /* sliding bodies */ - { "monsterslick", 0, 0, W_SURF_MONSTERSLICK, 0, C_TRANSLUCENT, 0 }, - { "monsterslicknorth", 0, 0, W_SURF_MONSLICK_N, 0, C_TRANSLUCENT, 0 }, - { "monsterslickeast", 0, 0, W_SURF_MONSLICK_E, 0, C_TRANSLUCENT, 0 }, - { "monsterslicksouth", 0, 0, W_SURF_MONSLICK_S, 0, C_TRANSLUCENT, 0 }, - { "monsterslickwest", 0, 0, W_SURF_MONSLICK_W, 0, C_TRANSLUCENT, 0 }, - - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - W_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/game_xonotic.h b/tools/quake3/q3map2/game_xonotic.h deleted file mode 100644 index 846ac174..00000000 --- a/tools/quake3/q3map2/game_xonotic.h +++ /dev/null @@ -1,159 +0,0 @@ -/* ------------------------------------------------------------------------------- - - Copyright (C) 1999-2007 id Software, Inc. and contributors. - For a list of contributors, see the accompanying CONTRIBUTORS file. - - This file is part of GtkRadiant. - - GtkRadiant is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - GtkRadiant is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with GtkRadiant; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - ---------------------------------------------------------------------------------- - - This code has been altered significantly from its original form, to support - several games based on the Quake III Arena engine, in the form of "Q3Map2." - - ------------------------------------------------------------------------------- */ - - - -/* marker */ -#ifndef GAME_XONOTIC_H -#define GAME_XONOTIC_H - - - -/* ------------------------------------------------------------------------------- - - content and surface flags - are in game_quake3.h - - ------------------------------------------------------------------------------- */ - - - -/* ------------------------------------------------------------------------------- - - game_t struct - - ------------------------------------------------------------------------------- */ - -{ - "xonotic", /* -game x */ - "data", /* default base game data dir */ - ".xonotic", /* unix home sub-dir */ - "xonotic", /* magic path word */ - "scripts", /* shader directory */ - 1048575, /* max lightmapped surface verts */ - 1048575, /* max surface verts */ - 1048575, /* max surface indexes */ - false, /* flares */ - "flareshader", /* default flare shader */ - false, /* wolf lighting model? */ - 128, /* lightmap width/height */ - 1.0f, /* lightmap gamma */ - true, /* lightmap sRGB */ - true, /* texture sRGB */ - true, /* color sRGB */ - 0.0f, /* lightmap exposure */ - 1.0f, /* lightmap compensate */ - 1.0f, /* lightgrid scale */ - 1.0f, /* lightgrid ambient scale */ - false, /* light angle attenuation uses half-lambert curve */ - true, /* disable shader lightstyles hack */ - true, /* keep light entities on bsp */ - 4, /* default patchMeta subdivisions tolerance */ - true, /* patch casting enabled */ - true, /* compile deluxemaps */ - 0, /* deluxemaps default mode */ - 512, /* minimap size */ - 1.0f, /* minimap sharpener */ - 1.0f / 66.0f, /* minimap border */ - true, /* minimap keep aspect */ - EMiniMapMode::Gray, /* minimap mode */ - "../gfx/%s_mini.tga", /* minimap name format */ - "IBSP", /* bsp file prefix */ - 46, /* bsp file version */ - false, /* cod-style lump len/ofs order */ - LoadIBSPFile, /* bsp load function */ - WriteIBSPFile, /* bsp write function */ - - { - /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ - - /* default */ - { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, - - /* ydnar */ - { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, - { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, - { "skip", 0, 0, 0, 0, C_SKIP, 0 }, - - /* compiler */ - { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, - { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, - { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, - { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, - { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, - { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, - { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, - - { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, - { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, - { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, - - /* game */ - { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, - - { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, - - { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, - { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, - - { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, - { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, - - { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, - - { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, - { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, - { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, - { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, - { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, - { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, - { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, - { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, - { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, - - /* null */ - { NULL, 0, 0, 0, 0, 0, 0 } - }, - - Q_SURF_BEVELSMASK -} - - - -/* end marker */ -#endif diff --git a/tools/quake3/q3map2/games.cpp b/tools/quake3/q3map2/games.cpp new file mode 100644 index 00000000..c1bd70b8 --- /dev/null +++ b/tools/quake3/q3map2/games.cpp @@ -0,0 +1,942 @@ +/* ------------------------------------------------------------------------------- + + Copyright (C) 1999-2007 id Software, Inc. and contributors. + For a list of contributors, see the accompanying CONTRIBUTORS file. + + This file is part of GtkRadiant. + + GtkRadiant is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + GtkRadiant is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with GtkRadiant; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + + ---------------------------------------------------------------------------------- + + This code has been altered significantly from its original form, to support + several games based on the Quake III Arena engine, in the form of "Q3Map2." + + ------------------------------------------------------------------------------- */ + +#include "games.h" +#include "bspfile_ibsp.h" +#include "bspfile_rbsp.h" + +struct game_default : game_t +{ + /* game flags */ + static const int Q_CONT_SOLID = 1; /* an eye is never valid in a solid */ + static const int Q_CONT_LAVA = 8; + static const int Q_CONT_SLIME = 16; + static const int Q_CONT_WATER = 32; + static const int Q_CONT_FOG = 64; + + static const int Q_CONT_AREAPORTAL = 0x8000; + + static const int Q_CONT_PLAYERCLIP = 0x10000; + static const int Q_CONT_MONSTERCLIP = 0x20000; + static const int Q_CONT_TELEPORTER = 0x40000; + static const int Q_CONT_JUMPPAD = 0x80000; + static const int Q_CONT_CLUSTERPORTAL = 0x100000; + static const int Q_CONT_DONOTENTER = 0x200000; + static const int Q_CONT_BOTCLIP = 0x400000; + + static const int Q_CONT_ORIGIN = 0x1000000; /* removed before bsping an entity */ + + static const int Q_CONT_BODY = 0x2000000; /* should never be on a brush, only in game */ + static const int Q_CONT_CORPSE = 0x4000000; + static const int Q_CONT_DETAIL = 0x8000000; /* brushes not used for the bsp */ + static const int Q_CONT_STRUCTURAL = 0x10000000; /* brushes used for the bsp */ + static const int Q_CONT_TRANSLUCENT = 0x20000000; /* don't consume surface fragments inside */ + static const int Q_CONT_TRIGGER = 0x40000000; + static const int Q_CONT_NODROP = 0x80000000; /* don't leave bodies or items (death fog, lava) */ + + static const int Q_SURF_NODAMAGE = 0x1; /* never give falling damage */ + static const int Q_SURF_SLICK = 0x2; /* effects game physics: zero friction on this */ + static const int Q_SURF_SKY = 0x4; /* lighting from environment map */ + static const int Q_SURF_LADDER = 0x8; + static const int Q_SURF_NOIMPACT = 0x10; /* don't make missile explosions */ + static const int Q_SURF_NOMARKS = 0x20; /* don't leave missile marks */ + static const int Q_SURF_FLESH = 0x40; /* make flesh sounds and effects */ + static const int Q_SURF_NODRAW = 0x80; /* don't generate a drawsurface at all */ + static const int Q_SURF_HINT = 0x100; /* make a primary bsp splitter */ + static const int Q_SURF_SKIP = 0x200; /* completely ignore, allowing non-closed brushes */ + static const int Q_SURF_NOLIGHTMAP = 0x400; /* surface doesn't need a lightmap */ + static const int Q_SURF_POINTLIGHT = 0x800; /* generate lighting info at vertexes */ + static const int Q_SURF_METALSTEPS = 0x1000; /* clanking footsteps */ + static const int Q_SURF_NOSTEPS = 0x2000; /* no footstep sounds */ + static const int Q_SURF_NONSOLID = 0x4000; /* don't collide against curves with this set */ + static const int Q_SURF_LIGHTFILTER = 0x8000; /* act as a light filter during q3map -light */ + static const int Q_SURF_ALPHASHADOW = 0x10000; /* do per-pixel light shadow casting in q3map */ + static const int Q_SURF_NODLIGHT = 0x20000; /* don't dlight even if solid (solid lava, skies) */ + static const int Q_SURF_DUST = 0x40000; /* leave a dust trail when walking on this surface */ + + /* ydnar flags */ + static const int Q_SURF_VERTEXLIT = ( Q_SURF_POINTLIGHT | Q_SURF_NOLIGHTMAP ); + static const int Q_SURF_BEVELSMASK = ( Q_SURF_NODAMAGE | Q_SURF_SLICK | Q_SURF_FLESH | Q_SURF_METALSTEPS | Q_SURF_NOSTEPS | Q_SURF_DUST ); + + game_default() : game_t{ + "quake3", /* -game x */ + "baseq3", /* default base game data dir */ + ".q3a", /* unix home sub-dir */ + "quake", /* magic path word */ + "scripts", /* shader directory */ + 64, /* max lightmapped surface verts */ + 999, /* max surface verts */ + 6000, /* max surface indexes */ + false, /* flares */ + "flareshader", /* default flare shader */ + false, /* wolf lighting model? */ + 128, /* lightmap width/height */ + 1.0f, /* lightmap gamma */ + false, /* lightmap sRGB */ + false, /* texture sRGB */ + false, /* color sRGB */ + 0.0f, /* lightmap exposure */ + 1.0f, /* lightmap compensate */ + 1.0f, /* lightgrid scale */ + 1.0f, /* lightgrid ambient scale */ + false, /* light angle attenuation uses half-lambert curve */ + false, /* disable shader lightstyles hack */ + false, /* keep light entities on bsp */ + 8, /* default patchMeta subdivisions tolerance */ + false, /* patch casting enabled */ + false, /* compile deluxemaps */ + 0, /* deluxemaps default mode */ + 512, /* minimap size */ + 1.0f, /* minimap sharpener */ + 0.0f, /* minimap border */ + true, /* minimap keep aspect */ + EMiniMapMode::Gray, /* minimap mode */ + "%s.tga", /* minimap name format */ + "IBSP", /* bsp file prefix */ + 46, /* bsp file version */ + false, /* cod-style lump len/ofs order */ + LoadIBSPFile, /* bsp load function */ + WriteIBSPFile, /* bsp write function */ + + { + /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ + + /* default */ + { "default", Q_CONT_SOLID, -1, 0, -1, C_SOLID, -1 }, + + + /* ydnar */ + { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, + { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, + { "skip", 0, 0, 0, 0, C_SKIP, 0 }, + + + /* compiler */ + { "origin", Q_CONT_ORIGIN, Q_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, + { "areaportal", Q_CONT_AREAPORTAL, Q_CONT_SOLID, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, + { "trans", Q_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, + { "detail", Q_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, + { "structural", Q_CONT_STRUCTURAL, 0, 0, 0, C_STRUCTURAL, 0 }, + { "hint", 0, 0, Q_SURF_HINT, 0, C_HINT, 0 }, + { "nodraw", 0, 0, Q_SURF_NODRAW, 0, C_NODRAW, 0 }, + + { "alphashadow", 0, 0, Q_SURF_ALPHASHADOW, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, + { "lightfilter", 0, 0, Q_SURF_LIGHTFILTER, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, + { "nolightmap", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, + { "pointlight", 0, 0, Q_SURF_VERTEXLIT, 0, C_VERTEXLIT, 0 }, + + + /* game */ + { "nonsolid", 0, Q_CONT_SOLID, Q_SURF_NONSOLID, 0, 0, C_SOLID }, + + { "trigger", Q_CONT_TRIGGER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + { "water", Q_CONT_WATER, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + { "slime", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + { "lava", Q_CONT_LAVA, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + + { "playerclip", Q_CONT_PLAYERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "monsterclip", Q_CONT_MONSTERCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "nodrop", Q_CONT_NODROP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + { "clusterportal", Q_CONT_CLUSTERPORTAL, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + { "donotenter", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + { "botclip", Q_CONT_BOTCLIP, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + { "fog", Q_CONT_FOG, Q_CONT_SOLID, 0, 0, C_FOG, C_SOLID }, + { "sky", 0, 0, Q_SURF_SKY, 0, C_SKY, 0 }, + + { "slick", 0, 0, Q_SURF_SLICK, 0, 0, 0 }, + + { "noimpact", 0, 0, Q_SURF_NOIMPACT, 0, 0, 0 }, + { "nomarks", 0, 0, Q_SURF_NOMARKS, 0, C_NOMARKS, 0 }, + { "ladder", 0, 0, Q_SURF_LADDER, 0, 0, 0 }, + { "nodamage", 0, 0, Q_SURF_NODAMAGE, 0, 0, 0 }, + { "metalsteps", 0, 0, Q_SURF_METALSTEPS, 0, 0, 0 }, + { "flesh", 0, 0, Q_SURF_FLESH, 0, 0, 0 }, + { "nosteps", 0, 0, Q_SURF_NOSTEPS, 0, 0, 0 }, + { "nodlight", 0, 0, Q_SURF_NODLIGHT, 0, 0, 0 }, + { "dust", 0, 0, Q_SURF_DUST, 0, 0, 0 }, + }, + + Q_SURF_BEVELSMASK + }{} +}; + +struct game_quake3 : game_default +{ + static const int Q_SURF_NOOB = 0x80000; /* no overbounces on this surface in Q3A:Defrag mod */ + + game_quake3(){ + surfaceParms.insert( surfaceParms.end(), { + { "noob", 0, 0, Q_SURF_NOOB, 0, 0, 0 }, + { "ob", 0, 0, 0, 0, C_OB, 0 }, + } ); + brushBevelsSurfaceFlagsMask |= Q_SURF_NOOB; + } +}; + +struct game_quakelive : game_default +{ + // Additional surface flags for Quake Live + + static const int Q_SURF_SNOWSTEPS = 0x80000; // snow footsteps + static const int Q_SURF_WOODSTEPS = 0x100000; // wood footsteps + static const int Q_SURF_DMGTHROUGH = 0x200000; // Missile dmg through surface(?) + // (This is not in use atm, will + // probably be re-purposed some day.) + game_quakelive(){ + arg = "quakelive"; + // gamePath = "baseq3"; /* default base game data dir (FIXME what does quake live really use?) */ + homeBasePath = ".quakelive/quakelive/home"; /* unix home sub-dir (FIXME what does quake live really use?) */ + // magic = "quake"; /* magic path word (FIXME where does quake live install to?) */ + bspVersion = 47; + surfaceParms.insert( surfaceParms.end(), { + { "snowsteps", 0, 0, Q_SURF_SNOWSTEPS, 0, 0, 0 }, + { "woodsteps", 0, 0, Q_SURF_WOODSTEPS, 0, 0, 0 }, + { "dmgthrough", 0, 0, Q_SURF_DMGTHROUGH, 0, 0, 0 }, + } ); + brushBevelsSurfaceFlagsMask |= ( Q_SURF_SNOWSTEPS | Q_SURF_WOODSTEPS ); + } +}; + +struct game_nexuiz : game_default +{ + game_nexuiz(){ + arg = "nexuiz"; + gamePath = "data"; + homeBasePath = ".nexuiz"; + magic = "nexuiz"; + maxLMSurfaceVerts = 999; + noStyles = true; + keepLights = true; + miniMapBorder = 1.0f / 66.0f; + miniMapNameFormat = "../gfx/%s_mini.tga"; + } +}; + +struct game_xonotic : game_default +{ + game_xonotic(){ + arg = "xonotic"; + gamePath = "data"; + homeBasePath = ".xonotic"; + magic = "xonotic"; + maxLMSurfaceVerts = 1048575; + maxSurfaceVerts = 1048575; + maxSurfaceIndexes = 1048575; + lightmapsRGB = true; + texturesRGB = true; + colorsRGB = true; + noStyles = true; + keepLights = true; + patchSubdivisions = 4; + patchShadows = true; + deluxeMap = true; + miniMapBorder = 1.0f / 66.0f; + miniMapNameFormat = "../gfx/%s_mini.tga"; + } +}; + +struct game_tremulous : game_default +{ + static const int TREM_CONT_NOALIENBUILD = 0x1000; + static const int TREM_CONT_NOHUMANBUILD = 0x2000; + static const int TREM_CONT_NOBUILD = 0x4000; + + static const int TREM_SURF_NOALIENBUILDSURFACE = 0x80000; + static const int TREM_SURF_NOHUMANBUILDSURFACE = 0x100000; + static const int TREM_SURF_NOBUILDSURFACE = 0x200000; + + game_tremulous(){ + arg = "tremulous"; + gamePath = "base"; + homeBasePath = ".tremulous"; + magic = "tremulous"; + surfaceParms.insert( surfaceParms.end(), { + {"noalienbuild", TREM_CONT_NOALIENBUILD,0,0,0,0,0}, + {"nohumanbuild", TREM_CONT_NOHUMANBUILD,0,0,0,0,0}, + {"nobuild", TREM_CONT_NOBUILD,0,0,0,0,0}, + + {"noalienbuildsurface", 0,0,TREM_SURF_NOALIENBUILDSURFACE,0,0,0}, + {"nohumanbuildsurface", 0,0,TREM_SURF_NOHUMANBUILDSURFACE,0,0,0}, + {"nobuildsurface", 0,0,TREM_SURF_NOBUILDSURFACE,0,0,0}, + } ); + } +}; + +struct game_unvanquished : game_tremulous +{ + game_unvanquished(){ + arg = "unvanquished"; + gamePath = "pkg"; + homeBasePath = ".unvanquished"; + magic = "unvanquished"; + maxLMSurfaceVerts = 1048575; + maxSurfaceVerts = 1048575; + maxSurfaceIndexes = 1048575; + keepLights = true; + deluxeMode = 1; + miniMapMode = EMiniMapMode::White; + miniMapNameFormat = "../minimaps/%s.tga"; + } +}; + +struct game_tenebrae : game_default +{ + game_tenebrae(){ + arg = "tenebrae"; + gamePath = "base"; + homeBasePath = ".tenebrae"; + magic = "tenebrae"; + maxLMSurfaceVerts = 1024; + maxSurfaceVerts = 1024; + maxSurfaceIndexes = 6144; + lightmapSize = 512; + lightmapGamma = 2.0f; + noStyles = true; + deluxeMap = true; + } +}; + +struct game_wolf : game_default +{ + static const int W_CONT_MISSILECLIP = 0x80; /* wolf ranged missile blocking */ + static const int W_CONT_ITEM = 0x100; /* wolf item contents */ + static const int W_CONT_AI_NOSIGHT = 0x1000; /* wolf ai sight blocking */ + static const int W_CONT_CLIPSHOT = 0x2000; /* wolf shot clip */ + + static const int W_CONT_DONOTENTER_LARGE = 0x400000; /* wolf dne */ // == Q_CONT_BOTCLIP + + static const int W_SURF_CERAMIC = 0x40; /* wolf ceramic material */ // == Q_SURF_FLESH + static const int W_SURF_METAL = 0x1000; /* wolf metal material */ // == Q_SURF_METALSTEPS + static const int W_SURF_WOOD = 0x40000; /* wolf wood material */ // == Q_SURF_DUST + static const int W_SURF_GRASS = 0x80000; /* wolf grass material */ + static const int W_SURF_GRAVEL = 0x100000; /* wolf gravel material */ + static const int W_SURF_GLASS = 0x200000; /* wolf glass material */ + static const int W_SURF_SNOW = 0x400000; /* wolf snow material */ + static const int W_SURF_ROOF = 0x800000; /* wolf roof material */ + static const int W_SURF_RUBBLE = 0x1000000; /* wolf rubble material */ + static const int W_SURF_CARPET = 0x2000000; /* wolf carpet material */ + + static const int W_SURF_MONSTERSLICK = 0x4000000; /* wolf npc slick surface */ + static const int W_SURF_MONSLICK_W = 0x8000000; /* wolf slide bodies west */ + static const int W_SURF_MONSLICK_N = 0x10000000; /* wolf slide bodies north */ + static const int W_SURF_MONSLICK_E = 0x20000000; /* wolf slide bodies east */ + static const int W_SURF_MONSLICK_S = 0x40000000; /* wolf slide bodies south */ + + game_wolf(){ + arg = "wolf"; + gamePath = "main"; + homeBasePath = ".wolf"; + magic = "wolf"; + wolfLight = true; + bspVersion = 47; + surfaceParms.insert( surfaceParms.end(), { + /* game */ + { "slag", Q_CONT_SLIME, Q_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + + { "clipmissile", W_CONT_MISSILECLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "clipshot", W_CONT_CLIPSHOT, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + + { "donotenterlarge",W_CONT_DONOTENTER_LARGE, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + /* materials */ + { "metal", 0, 0, W_SURF_METAL, 0, 0, 0 }, + { "metalsteps", 0, 0, W_SURF_METAL, 0, 0, 0 }, + { "glass", 0, 0, W_SURF_GLASS, 0, 0, 0 }, + { "ceramic", 0, 0, W_SURF_CERAMIC, 0, 0, 0 }, + { "woodsteps", 0, 0, W_SURF_WOOD, 0, 0, 0 }, + { "grasssteps", 0, 0, W_SURF_GRASS, 0, 0, 0 }, + { "gravelsteps", 0, 0, W_SURF_GRAVEL, 0, 0, 0 }, + { "rubble", 0, 0, W_SURF_RUBBLE, 0, 0, 0 }, + { "carpetsteps", 0, 0, W_SURF_CARPET, 0, 0, 0 }, + { "snowsteps", 0, 0, W_SURF_SNOW, 0, 0, 0 }, + { "roofsteps", 0, 0, W_SURF_ROOF, 0, 0, 0 }, + + + /* ai */ + { "ai_nosight", W_CONT_AI_NOSIGHT, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + /* ydnar: experimental until bits are confirmed! */ + { "ai_nopass", Q_CONT_DONOTENTER, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + { "ai_nopasslarge", W_CONT_DONOTENTER_LARGE, Q_CONT_SOLID, 0, 0, C_TRANSLUCENT, C_SOLID }, + + + /* sliding bodies */ + { "monsterslick", 0, 0, W_SURF_MONSTERSLICK, 0, C_TRANSLUCENT, 0 }, + { "monsterslicknorth", 0, 0, W_SURF_MONSLICK_N, 0, C_TRANSLUCENT, 0 }, + { "monsterslickeast", 0, 0, W_SURF_MONSLICK_E, 0, C_TRANSLUCENT, 0 }, + { "monsterslicksouth", 0, 0, W_SURF_MONSLICK_S, 0, C_TRANSLUCENT, 0 }, + { "monsterslickwest", 0, 0, W_SURF_MONSLICK_W, 0, C_TRANSLUCENT, 0 }, + + } ); + brushBevelsSurfaceFlagsMask |= ( W_SURF_CERAMIC | W_SURF_METAL | W_SURF_WOOD | W_SURF_GRASS | W_SURF_GRAVEL | W_SURF_GLASS | W_SURF_SNOW | W_SURF_ROOF | W_SURF_RUBBLE | W_SURF_CARPET | W_SURF_MONSTERSLICK | W_SURF_MONSLICK_W | W_SURF_MONSLICK_N | W_SURF_MONSLICK_E | W_SURF_MONSLICK_S ); + } +}; + +struct game_wolfet : game_wolf +{ + static const int W_SURF_SPLASH = 0x00000040; /* enemy territory water splash surface */ // == W_SURF_CERAMIC + static const int W_SURF_LANDMINE = 0x80000000; /* enemy territory 'landminable' surface */ + + game_wolfet(){ + arg = "et"; + gamePath = "etmain"; + homeBasePath = ".etwolf"; + magic = "et"; + maxLMSurfaceVerts = 1024; + maxSurfaceVerts = 1024; + maxSurfaceIndexes = 6144; + surfaceParms.insert( surfaceParms.end(), { + { "landmine", 0, 0, W_SURF_LANDMINE, 0, 0, 0 }, + { "splash", 0, 0, W_SURF_SPLASH, 0, 0, 0 }, + } ); + } +}; + +struct game_etut : game_default +{ + /* materials */ + static const int U_MAT_MASK = 0xFFF00000; /* mask to get the material type */ + + static const int U_MAT_NONE = 0x00000000; + static const int U_MAT_TIN = 0x00100000; + static const int U_MAT_ALUMINUM = 0x00200000; + static const int U_MAT_IRON = 0x00300000; + static const int U_MAT_TITANIUM = 0x00400000; + static const int U_MAT_STEEL = 0x00500000; + static const int U_MAT_BRASS = 0x00600000; + static const int U_MAT_COPPER = 0x00700000; + static const int U_MAT_CEMENT = 0x00800000; + static const int U_MAT_ROCK = 0x00900000; + static const int U_MAT_GRAVEL = 0x00A00000; + static const int U_MAT_PAVEMENT = 0x00B00000; + static const int U_MAT_BRICK = 0x00C00000; + static const int U_MAT_CLAY = 0x00D00000; + static const int U_MAT_GRASS = 0x00E00000; + static const int U_MAT_DIRT = 0x00F00000; + static const int U_MAT_MUD = 0x01000000; + static const int U_MAT_SNOW = 0x01100000; + static const int U_MAT_ICE = 0x01200000; + static const int U_MAT_SAND = 0x01300000; + static const int U_MAT_CERAMICTILE = 0x01400000; + static const int U_MAT_LINOLEUM = 0x01500000; + static const int U_MAT_RUG = 0x01600000; + static const int U_MAT_PLASTER = 0x01700000; + static const int U_MAT_PLASTIC = 0x01800000; + static const int U_MAT_CARDBOARD = 0x01900000; + static const int U_MAT_HARDWOOD = 0x01A00000; + static const int U_MAT_SOFTWOOD = 0x01B00000; + static const int U_MAT_PLANK = 0x01C00000; + static const int U_MAT_GLASS = 0x01D00000; + static const int U_MAT_WATER = 0x01E00000; + static const int U_MAT_STUCCO = 0x01F00000; + + game_etut(){ + arg = "etut"; + gamePath = "etut"; + homeBasePath = ".etwolf"; + magic = "et"; + maxLMSurfaceVerts = 1024; + maxSurfaceVerts = 1024; + maxSurfaceIndexes = 6144; + lightmapsRGB = true; + // texturesRGB = false; /* texture sRGB (yes, this is incorrect, but we better match ET:UT) */ + bspVersion = 47; + surfaceParms.insert( surfaceParms.end(), { + /* materials */ + { "*mat_none", 0, 0, U_MAT_NONE, U_MAT_MASK, 0, 0 }, + { "*mat_tin", 0, 0, U_MAT_TIN, U_MAT_MASK, 0, 0 }, + { "*mat_aluminum", 0, 0, U_MAT_ALUMINUM, U_MAT_MASK, 0, 0 }, + { "*mat_iron", 0, 0, U_MAT_IRON, U_MAT_MASK, 0, 0 }, + { "*mat_titanium", 0, 0, U_MAT_TITANIUM, U_MAT_MASK, 0, 0 }, + { "*mat_steel", 0, 0, U_MAT_STEEL, U_MAT_MASK, 0, 0 }, + { "*mat_brass", 0, 0, U_MAT_BRASS, U_MAT_MASK, 0, 0 }, + { "*mat_copper", 0, 0, U_MAT_COPPER, U_MAT_MASK, 0, 0 }, + { "*mat_cement", 0, 0, U_MAT_CEMENT, U_MAT_MASK, 0, 0 }, + { "*mat_rock", 0, 0, U_MAT_ROCK, U_MAT_MASK, 0, 0 }, + { "*mat_gravel", 0, 0, U_MAT_GRAVEL, U_MAT_MASK, 0, 0 }, + { "*mat_pavement", 0, 0, U_MAT_PAVEMENT, U_MAT_MASK, 0, 0 }, + { "*mat_brick", 0, 0, U_MAT_BRICK, U_MAT_MASK, 0, 0 }, + { "*mat_clay", 0, 0, U_MAT_CLAY, U_MAT_MASK, 0, 0 }, + { "*mat_grass", 0, 0, U_MAT_GRASS, U_MAT_MASK, 0, 0 }, + { "*mat_dirt", 0, 0, U_MAT_DIRT, U_MAT_MASK, 0, 0 }, + { "*mat_mud", 0, 0, U_MAT_MUD, U_MAT_MASK, 0, 0 }, + { "*mat_snow", 0, 0, U_MAT_SNOW, U_MAT_MASK, 0, 0 }, + { "*mat_ice", 0, 0, U_MAT_ICE, U_MAT_MASK, 0, 0 }, + { "*mat_sand", 0, 0, U_MAT_SAND, U_MAT_MASK, 0, 0 }, + { "*mat_ceramic", 0, 0, U_MAT_CERAMICTILE, U_MAT_MASK, 0, 0 }, + { "*mat_ceramictile", 0, 0, U_MAT_CERAMICTILE, U_MAT_MASK, 0, 0 }, + { "*mat_linoleum", 0, 0, U_MAT_LINOLEUM, U_MAT_MASK, 0, 0 }, + { "*mat_rug", 0, 0, U_MAT_RUG, U_MAT_MASK, 0, 0 }, + { "*mat_plaster", 0, 0, U_MAT_PLASTER, U_MAT_MASK, 0, 0 }, + { "*mat_plastic", 0, 0, U_MAT_PLASTIC, U_MAT_MASK, 0, 0 }, + { "*mat_cardboard", 0, 0, U_MAT_CARDBOARD, U_MAT_MASK, 0, 0 }, + { "*mat_hardwood", 0, 0, U_MAT_HARDWOOD, U_MAT_MASK, 0, 0 }, + { "*mat_softwood", 0, 0, U_MAT_SOFTWOOD, U_MAT_MASK, 0, 0 }, + { "*mat_plank", 0, 0, U_MAT_PLANK, U_MAT_MASK, 0, 0 }, + { "*mat_glass", 0, 0, U_MAT_GLASS, U_MAT_MASK, 0, 0 }, + { "*mat_water", 0, 0, U_MAT_WATER, U_MAT_MASK, 0, 0 }, + { "*mat_stucco", 0, 0, U_MAT_STUCCO, U_MAT_MASK, 0, 0 }, + } ); + } +}; + +struct game_ef : game_default +{ + static const int E_CONT_LADDER = 128; /* elite force ladder contents */ + static const int E_CONT_SHOTCLIP = 0x40000; /* elite force shot clip */ + static const int E_CONT_ITEM = 0x80000; + static const int E_SURF_FORCEFIELD = 0x40000; /* elite force forcefield brushes */ + + game_ef(){ + arg = "ef"; + gamePath = "baseef"; + homeBasePath = ".ef"; + magic = "elite"; + /* overwrite "ladder" entry; note: magic number */ + surfaceParms[31] = + { "ladder", E_CONT_LADDER, Q_CONT_SOLID, Q_SURF_LADDER, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }; + surfaceParms.insert( surfaceParms.end(), { + { "shotclip", E_CONT_SHOTCLIP, Q_CONT_SOLID, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "forcefield", 0, 0, E_SURF_FORCEFIELD, 0, 0, 0 }, + } ); + } +}; + +struct game_qfusion : game_default +{ + game_qfusion(){ + arg = "qfusion"; + gamePath = "base"; + homeBasePath = ".qfusion"; + magic = "qfusion"; + maxLMSurfaceVerts = 65535; + maxSurfaceVerts = 65535; + maxSurfaceIndexes = 393210; + lightmapSize = 512; + lightmapsRGB = true; + texturesRGB = true; + colorsRGB = true; + lightAngleHL = true; + noStyles = true; + keepLights = true; + patchSubdivisions = 4; + patchShadows = true; + deluxeMap = true; + miniMapBorder = 1.0f / 66.0f; + miniMapNameFormat = "../minimaps/%s.tga"; + bspIdent = "FBSP"; + bspVersion = 1; + load = LoadRBSPFile; + write = WriteRBSPFile; + } +}; + +struct game_reaction : game_default +{ +/* Additional surface flags follow. These were given to me (Rambetter) by TTI from the Reaction team. + Note that some of these values have more than one bit set. I'm not sure how Reaction is using these + bits, but this is what I got from TTI. */ + static const int REACTION_SURF_GRAVEL = 0x80000; + static const int REACTION_SURF_WOOD = 0x81000; + static const int REACTION_SURF_CARPET = 0x100000; + static const int REACTION_SURF_METAL2 = 0x101000; + static const int REACTION_SURF_GLASS = 0x180000; + static const int REACTION_SURF_GRASS = 0x181000; + static const int REACTION_SURF_SNOW = 0x200000; + static const int REACTION_SURF_MUD = 0x201000; + static const int REACTION_SURF_WOOD2 = 0x280000; + static const int REACTION_SURF_HARDMETAL = 0x281000; + static const int REACTION_SURF_LEAVES = 0x300000; + static const int REACTION_SURF_CEMENT = 0x301000; + static const int REACTION_SURF_MARBLE = 0x380000; + static const int REACTION_SURF_SNOW2 = 0x381000; + static const int REACTION_SURF_HARDSTEPS = 0x400000; + static const int REACTION_SURF_SAND = 0x401000; + + game_reaction(){ + arg = "reaction"; + gamePath = "Boomstick"; + homeBasePath = ".Reaction"; + magic = "reaction"; + surfaceParms.insert( surfaceParms.end(), { + { "rq3_gravel", 0, 0, REACTION_SURF_GRAVEL, 0, 0, 0 }, + { "rq3_wood", 0, 0, REACTION_SURF_WOOD, 0, 0, 0 }, + { "rq3_carpet", 0, 0, REACTION_SURF_CARPET, 0, 0, 0 }, + { "rq3_metal2", 0, 0, REACTION_SURF_METAL2, 0, 0, 0 }, + { "rq3_glass", 0, 0, REACTION_SURF_GLASS, 0, 0, 0 }, + { "rq3_grass", 0, 0, REACTION_SURF_GRASS, 0, 0, 0 }, + { "rq3_snow", 0, 0, REACTION_SURF_SNOW, 0, 0, 0 }, + { "rq3_mud", 0, 0, REACTION_SURF_MUD, 0, 0, 0 }, + { "rq3_wood2", 0, 0, REACTION_SURF_WOOD2, 0, 0, 0 }, + { "rq3_hardmetal", 0, 0, REACTION_SURF_HARDMETAL, 0, 0, 0 }, + { "rq3_leaves", 0, 0, REACTION_SURF_LEAVES, 0, 0, 0 }, + { "rq3_cement", 0, 0, REACTION_SURF_CEMENT, 0, 0, 0 }, + { "rq3_marble", 0, 0, REACTION_SURF_MARBLE, 0, 0, 0 }, + { "rq3_snow2", 0, 0, REACTION_SURF_SNOW2, 0, 0, 0 }, + { "rq3_hardsteps", 0, 0, REACTION_SURF_HARDSTEPS, 0, 0, 0 }, + { "rq3_sand", 0, 0, REACTION_SURF_SAND, 0, 0, 0 }, + } ); + } +}; + +/* vortex: darkplaces q1 engine */ +struct game_darkplaces : game_default +{ + game_darkplaces(){ + arg = "darkplaces"; + gamePath = "id1"; + homeBasePath = ".darkplaces"; + magic = "darkplaces"; + maxLMSurfaceVerts = 999; + lightmapExposure = 200.0f; + gridScale = 0.3f; + gridAmbientScale = 0.6f; + noStyles = true; + keepLights = true; + patchSubdivisions = 4; + } +}; + +/* vortex: deluxe quake game ( darkplaces q1 engine) */ +struct game_dq : game_default +{ + game_dq(){ + arg = "dq"; + gamePath = "basedq"; + homeBasePath = ".dq"; + magic = "dq"; + lightmapGamma = 1.2f; + lightmapExposure = 200.0f; + gridScale = 0.3f; + gridAmbientScale = 0.6f; + noStyles = true; + keepLights = true; + patchSubdivisions = 4; + patchShadows = true; + deluxeMap = true; + deluxeMode = 1; + } +}; + +/* vortex: prophecy game ( darkplaces q1 engine) */ +struct game_prophecy : game_default +{ + game_prophecy(){ + arg = "prophecy"; + gamePath = "base"; + homeBasePath = ".prophecy"; + magic = "prophecy"; + lightmapExposure = 200.0f; + gridScale = 0.4f; + gridAmbientScale = 0.6f; + noStyles = true; + keepLights = true; + patchSubdivisions = 4; + patchShadows = true; + deluxeMap = true; + } +}; + +struct game_sof2 : game_t +{ + /* thanks to the gracious fellows at raven */ + static const int S_CONT_SOLID = 0x00000001; /* Default setting. An eye is never valid in a solid */ + static const int S_CONT_LAVA = 0x00000002; + static const int S_CONT_WATER = 0x00000004; + static const int S_CONT_FOG = 0x00000008; + static const int S_CONT_PLAYERCLIP = 0x00000010; + static const int S_CONT_MONSTERCLIP = 0x00000020; + static const int S_CONT_BOTCLIP = 0x00000040; + static const int S_CONT_SHOTCLIP = 0x00000080; + static const int S_CONT_BODY = 0x00000100; /* should never be on a brush, only in game */ + static const int S_CONT_CORPSE = 0x00000200; /* should never be on a brush, only in game */ + static const int S_CONT_TRIGGER = 0x00000400; + static const int S_CONT_NODROP = 0x00000800; /* don't leave bodies or items (death fog, lava) */ + static const int S_CONT_TERRAIN = 0x00001000; /* volume contains terrain data */ + static const int S_CONT_LADDER = 0x00002000; + static const int S_CONT_ABSEIL = 0x00004000; /* used like ladder to define where an NPC can abseil */ + static const int S_CONT_OPAQUE = 0x00008000; /* defaults to on, when off, solid can be seen through */ + static const int S_CONT_OUTSIDE = 0x00010000; /* volume is considered to be in the outside (i.e. not indoors) */ + static const int S_CONT_SLIME = 0x00020000; /* don't be fooled. it may SAY "slime" but it really means "projectileclip" */ + static const int S_CONT_LIGHTSABER = 0x00040000; + static const int S_CONT_TELEPORTER = 0x00080000; + static const int S_CONT_ITEM = 0x00100000; + static const int S_CONT_DETAIL = 0x08000000; /* brushes not used for the bsp */ + static const int S_CONT_TRANSLUCENT = 0x80000000; /* don't consume surface fragments inside */ + + static const int S_SURF_SKY = 0x00002000; /* lighting from environment map */ + static const int S_SURF_SLICK = 0x00004000; /* affects game physics */ + static const int S_SURF_METALSTEPS = 0x00008000; /* chc needs this since we use same tools */ + static const int S_SURF_FORCEFIELD = 0x00010000; /* chc */ + static const int S_SURF_NODAMAGE = 0x00040000; /* never give falling damage */ + static const int S_SURF_NOIMPACT = 0x00080000; /* don't make missile explosions */ + static const int S_SURF_NOMARKS = 0x00100000; /* don't leave missile marks */ + static const int S_SURF_NODRAW = 0x00200000; /* don't generate a drawsurface at all */ + static const int S_SURF_NOSTEPS = 0x00400000; /* no footstep sounds */ + static const int S_SURF_NODLIGHT = 0x00800000; /* don't dlight even if solid (solid lava, skies) */ + static const int S_SURF_NOMISCENTS = 0x01000000; /* no client models allowed on this surface */ + + static const int S_SURF_PATCH = 0x80000000; /* mark this face as a patch(editor only) */ + + static const int S_SURF_BEVELSMASK = ( S_SURF_SLICK | S_SURF_METALSTEPS | S_SURF_NODAMAGE | S_SURF_NOSTEPS | S_SURF_NOMISCENTS ); /* compiler utility */ + + /* materials */ + static const int S_MAT_BITS = 5; + static const int S_MAT_MASK = 0x1f; /* mask to get the material type */ + + static const int S_MAT_NONE = 0; /* for when the artist hasn't set anything up =) */ + static const int S_MAT_SOLIDWOOD = 1; /* freshly cut timber */ + static const int S_MAT_HOLLOWWOOD = 2; /* termite infested creaky wood */ + static const int S_MAT_SOLIDMETAL = 3; /* solid girders */ + static const int S_MAT_HOLLOWMETAL = 4; /* hollow metal machines */ + static const int S_MAT_SHORTGRASS = 5; /* manicured lawn */ + static const int S_MAT_LONGGRASS = 6; /* long jungle grass */ + static const int S_MAT_DIRT = 7; /* hard mud */ + static const int S_MAT_SAND = 8; /* sandy beach */ + static const int S_MAT_GRAVEL = 9; /* lots of small stones */ + static const int S_MAT_GLASS = 10; + static const int S_MAT_CONCRETE = 11; /* hardened concrete pavement */ + static const int S_MAT_MARBLE = 12; /* marble floors */ + static const int S_MAT_WATER = 13; /* light covering of water on a surface */ + static const int S_MAT_SNOW = 14; /* freshly laid snow */ + static const int S_MAT_ICE = 15; /* packed snow/solid ice */ + static const int S_MAT_FLESH = 16; /* hung meat, corpses in the world */ + static const int S_MAT_MUD = 17; /* wet soil */ + static const int S_MAT_BPGLASS = 18; /* bulletproof glass */ + static const int S_MAT_DRYLEAVES = 19; /* dried up leaves on the floor */ + static const int S_MAT_GREENLEAVES = 20; /* fresh leaves still on a tree */ + static const int S_MAT_FABRIC = 21; /* Cotton sheets */ + static const int S_MAT_CANVAS = 22; /* tent material */ + static const int S_MAT_ROCK = 23; + static const int S_MAT_RUBBER = 24; /* hard tire like rubber */ + static const int S_MAT_PLASTIC = 25; + static const int S_MAT_TILES = 26; /* tiled floor */ + static const int S_MAT_CARPET = 27; /* lush carpet */ + static const int S_MAT_PLASTER = 28; /* drywall style plaster */ + static const int S_MAT_SHATTERGLASS = 29; /* glass with the Crisis Zone style shattering */ + static const int S_MAT_ARMOR = 30; /* body armor */ + static const int S_MAT_COMPUTER = 31; /* computers/electronic equipment */ + static const int S_MAT_LAST = 32; /* number of materials */ + + game_sof2() : game_t{ + "sof2", /* -game x */ + "base", /* default base game data dir */ + ".sof2", /* unix home sub-dir */ + "soldier", /* magic path word */ + "shaders", /* shader directory */ + 64, /* max lightmapped surface verts */ + 999, /* max surface verts */ + 6000, /* max surface indexes */ + true, /* flares */ + "gfx/misc/lens_flare", /* default flare shader */ + false, /* wolf lighting model? */ + 128, /* lightmap width/height */ + 1.0f, /* lightmap gamma */ + false, /* lightmap sRGB */ + false, /* texture sRGB */ + false, /* color sRGB */ + 0.0f, /* lightmap exposure */ + 1.0f, /* lightmap compensate */ + 1.0f, /* lightgrid scale */ + 1.0f, /* lightgrid ambient scale */ + false, /* light angle attenuation uses half-lambert curve */ + false, /* disable shader lightstyles hack */ + false, /* keep light entities on bsp */ + 8, /* default patchMeta subdivisions tolerance */ + false, /* patch casting enabled */ + false, /* compile deluxemaps */ + 0, /* deluxemaps default mode */ + 512, /* minimap size */ + 1.0f, /* minimap sharpener */ + 0.0f, /* minimap border */ + true, /* minimap keep aspect */ + EMiniMapMode::Gray, /* minimap mode */ + "%s.tga", /* minimap name format */ + "RBSP", /* bsp file prefix */ + 1, /* bsp file version */ + false, /* cod-style lump len/ofs order */ + LoadRBSPFile, /* bsp load function */ + WriteRBSPFile, /* bsp write function */ + + { + /* name contentFlags contentFlagsClear surfaceFlags surfaceFlagsClear compileFlags compileFlagsClear */ + + /* default */ + { "default", S_CONT_SOLID | S_CONT_OPAQUE, -1, 0, -1, C_SOLID, -1 }, + + + /* ydnar */ + { "lightgrid", 0, 0, 0, 0, C_LIGHTGRID, 0 }, + { "antiportal", 0, 0, 0, 0, C_ANTIPORTAL, 0 }, + { "skip", 0, 0, 0, 0, C_SKIP, 0 }, + + + /* compiler */ + { "origin", 0, S_CONT_SOLID, 0, 0, C_ORIGIN | C_TRANSLUCENT, C_SOLID }, + { "areaportal", S_CONT_TRANSLUCENT, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_AREAPORTAL | C_TRANSLUCENT, C_SOLID }, + { "trans", S_CONT_TRANSLUCENT, 0, 0, 0, C_TRANSLUCENT, 0 }, + { "detail", S_CONT_DETAIL, 0, 0, 0, C_DETAIL, 0 }, + { "structural", 0, 0, 0, 0, C_STRUCTURAL, 0 }, + { "hint", 0, 0, 0, 0, C_HINT, 0 }, + { "nodraw", 0, 0, S_SURF_NODRAW, 0, C_NODRAW, 0 }, + + { "alphashadow", 0, 0, 0, 0, C_ALPHASHADOW | C_TRANSLUCENT, 0 }, + { "lightfilter", 0, 0, 0, 0, C_LIGHTFILTER | C_TRANSLUCENT, 0 }, + { "nolightmap", 0, 0, 0, 0, C_VERTEXLIT, 0 }, + { "pointlight", 0, 0, 0, 0, C_VERTEXLIT, 0 }, + + + /* game */ + { "nonsolid", 0, S_CONT_SOLID, 0, 0, 0, C_SOLID }, + { "nonopaque", 0, S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, 0 }, /* setting trans ok? */ + + { "trigger", S_CONT_TRIGGER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_TRANSLUCENT, C_SOLID }, + + { "water", S_CONT_WATER, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + { "slime", S_CONT_SLIME, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + { "lava", S_CONT_LAVA, S_CONT_SOLID, 0, 0, C_LIQUID | C_TRANSLUCENT, C_SOLID }, + + { "shotclip", S_CONT_SHOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* setting trans/detail ok? */ + { "playerclip", S_CONT_PLAYERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "monsterclip", S_CONT_MONSTERCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "nodrop", S_CONT_NODROP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + + { "terrain", S_CONT_TERRAIN, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "ladder", S_CONT_LADDER, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "abseil", S_CONT_ABSEIL, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + { "outside", S_CONT_OUTSIDE, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + + { "botclip", S_CONT_BOTCLIP, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_DETAIL | C_TRANSLUCENT, C_SOLID }, + + { "fog", S_CONT_FOG, S_CONT_SOLID | S_CONT_OPAQUE, 0, 0, C_FOG | C_DETAIL | C_TRANSLUCENT, C_SOLID }, /* nonopaque? */ + { "sky", 0, 0, S_SURF_SKY, 0, C_SKY, 0 }, + + { "slick", 0, 0, S_SURF_SLICK, 0, 0, 0 }, + + { "noimpact", 0, 0, S_SURF_NOIMPACT, 0, 0, 0 }, + { "nomarks", 0, 0, S_SURF_NOMARKS, 0, C_NOMARKS, 0 }, + { "nodamage", 0, 0, S_SURF_NODAMAGE, 0, 0, 0 }, + { "metalsteps", 0, 0, S_SURF_METALSTEPS, 0, 0, 0 }, + { "nosteps", 0, 0, S_SURF_NOSTEPS, 0, 0, 0 }, + { "nodlight", 0, 0, S_SURF_NODLIGHT, 0, 0, 0 }, + { "nomiscents", 0, 0, S_SURF_NOMISCENTS, 0, 0, 0 }, + { "forcefield", 0, 0, S_SURF_FORCEFIELD, 0, 0, 0 }, + + + /* materials */ + { "*mat_none", 0, 0, S_MAT_NONE, S_MAT_MASK, 0, 0 }, + { "*mat_solidwood", 0, 0, S_MAT_SOLIDWOOD, S_MAT_MASK, 0, 0 }, + { "*mat_hollowwood", 0, 0, S_MAT_HOLLOWWOOD, S_MAT_MASK, 0, 0 }, + { "*mat_solidmetal", 0, 0, S_MAT_SOLIDMETAL, S_MAT_MASK, 0, 0 }, + { "*mat_hollowmetal", 0, 0, S_MAT_HOLLOWMETAL, S_MAT_MASK, 0, 0 }, + { "*mat_shortgrass", 0, 0, S_MAT_SHORTGRASS, S_MAT_MASK, 0, 0 }, + { "*mat_longgrass", 0, 0, S_MAT_LONGGRASS, S_MAT_MASK, 0, 0 }, + { "*mat_dirt", 0, 0, S_MAT_DIRT, S_MAT_MASK, 0, 0 }, + { "*mat_sand", 0, 0, S_MAT_SAND, S_MAT_MASK, 0, 0 }, + { "*mat_gravel", 0, 0, S_MAT_GRAVEL, S_MAT_MASK, 0, 0 }, + { "*mat_glass", 0, 0, S_MAT_GLASS, S_MAT_MASK, 0, 0 }, + { "*mat_concrete", 0, 0, S_MAT_CONCRETE, S_MAT_MASK, 0, 0 }, + { "*mat_marble", 0, 0, S_MAT_MARBLE, S_MAT_MASK, 0, 0 }, + { "*mat_water", 0, 0, S_MAT_WATER, S_MAT_MASK, 0, 0 }, + { "*mat_snow", 0, 0, S_MAT_SNOW, S_MAT_MASK, 0, 0 }, + { "*mat_ice", 0, 0, S_MAT_ICE, S_MAT_MASK, 0, 0 }, + { "*mat_flesh", 0, 0, S_MAT_FLESH, S_MAT_MASK, 0, 0 }, + { "*mat_mud", 0, 0, S_MAT_MUD, S_MAT_MASK, 0, 0 }, + { "*mat_bpglass", 0, 0, S_MAT_BPGLASS, S_MAT_MASK, 0, 0 }, + { "*mat_dryleaves", 0, 0, S_MAT_DRYLEAVES, S_MAT_MASK, 0, 0 }, + { "*mat_greenleaves", 0, 0, S_MAT_GREENLEAVES, S_MAT_MASK, 0, 0 }, + { "*mat_fabric", 0, 0, S_MAT_FABRIC, S_MAT_MASK, 0, 0 }, + { "*mat_canvas", 0, 0, S_MAT_CANVAS, S_MAT_MASK, 0, 0 }, + { "*mat_rock", 0, 0, S_MAT_ROCK, S_MAT_MASK, 0, 0 }, + { "*mat_rubber", 0, 0, S_MAT_RUBBER, S_MAT_MASK, 0, 0 }, + { "*mat_plastic", 0, 0, S_MAT_PLASTIC, S_MAT_MASK, 0, 0 }, + { "*mat_tiles", 0, 0, S_MAT_TILES, S_MAT_MASK, 0, 0 }, + { "*mat_carpet", 0, 0, S_MAT_CARPET, S_MAT_MASK, 0, 0 }, + { "*mat_plaster", 0, 0, S_MAT_PLASTER, S_MAT_MASK, 0, 0 }, + { "*mat_shatterglass", 0, 0, S_MAT_SHATTERGLASS, S_MAT_MASK, 0, 0 }, + { "*mat_armor", 0, 0, S_MAT_ARMOR, S_MAT_MASK, 0, 0 }, + { "*mat_computer", 0, 0, S_MAT_COMPUTER, S_MAT_MASK, 0, 0 }, + }, + + S_SURF_BEVELSMASK + }{} +}; + +struct game_jk2 : game_sof2 +{ + game_jk2(){ + arg = "jk2"; + homeBasePath = ".jk2"; + magic = "GameData"; + flareShader = "gfx/misc/flare"; + } +}; + +struct game_ja : game_sof2 +{ + static const int JA_CONT_INSIDE = 0x10000000; /* jedi academy 'inside' */ + static const int JA_SURF_FORCESIGHT = 0x02000000; /* jedi academy 'forcesight' */ + + game_ja(){ + arg = "ja"; + homeBasePath = ".ja"; + magic = "GameData"; + flareShader = "gfx/misc/flare"; + surfaceParms.insert( surfaceParms.end(),{ + { "inside", JA_CONT_INSIDE, 0, 0, 0, 0, 0 }, + { "forcesight", 0, 0, JA_SURF_FORCESIGHT, 0, 0, 0 }, + } ); + } +}; + + + +const std::vector g_games = { game_quake3(), + game_quakelive(), + game_nexuiz(), + game_xonotic(), + game_tremulous(), + game_unvanquished(), + game_tenebrae(), + game_wolf(), + game_wolfet(), + game_etut(), + game_ef(), + game_qfusion(), + game_reaction(), + game_darkplaces(), + game_dq(), + game_prophecy(), + game_sof2(), + game_jk2(), + game_ja(), + }; +const game_t *game = &g_games[0]; diff --git a/tools/quake3/q3map2/games.h b/tools/quake3/q3map2/games.h new file mode 100644 index 00000000..26795a0e --- /dev/null +++ b/tools/quake3/q3map2/games.h @@ -0,0 +1,120 @@ +/* ------------------------------------------------------------------------------- + + Copyright (C) 1999-2007 id Software, Inc. and contributors. + For a list of contributors, see the accompanying CONTRIBUTORS file. + + This file is part of GtkRadiant. + + GtkRadiant is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + GtkRadiant is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with GtkRadiant; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + + ---------------------------------------------------------------------------------- + + This code has been altered significantly from its original form, to support + several games based on the Quake III Arena engine, in the form of "Q3Map2." + + ------------------------------------------------------------------------------- */ + + + +/* marker */ +#pragma once + +#include + + +/* ydnar: compiler flags, because games have widely varying content/surface flags */ +const int C_SOLID = 0x00000001; +const int C_TRANSLUCENT = 0x00000002; +const int C_STRUCTURAL = 0x00000004; +const int C_HINT = 0x00000008; +const int C_NODRAW = 0x00000010; +const int C_LIGHTGRID = 0x00000020; +const int C_ALPHASHADOW = 0x00000040; +const int C_LIGHTFILTER = 0x00000080; +const int C_VERTEXLIT = 0x00000100; +const int C_LIQUID = 0x00000200; +const int C_FOG = 0x00000400; +const int C_SKY = 0x00000800; +const int C_ORIGIN = 0x00001000; +const int C_AREAPORTAL = 0x00002000; +const int C_ANTIPORTAL = 0x00004000; /* like hint, but doesn't generate portals */ +const int C_SKIP = 0x00008000; /* like hint, but skips this face (doesn't split bsp) */ +const int C_NOMARKS = 0x00010000; /* no decals */ +const int C_OB = 0x00020000; /* skip -noob for this */ +const int C_DETAIL = 0x08000000; /* THIS MUST BE THE SAME AS IN RADIANT! */ + + +/* ydnar: for multiple game support */ +struct surfaceParm_t +{ + const char *name; + int contentFlags, contentFlagsClear; + int surfaceFlags, surfaceFlagsClear; + int compileFlags, compileFlagsClear; +}; + +enum class EMiniMapMode +{ + Gray, + Black, + White +}; + +struct game_t +{ + const char *arg; /* -game matches this */ + const char *gamePath; /* main game data dir */ + const char *homeBasePath; /* home sub-dir on unix */ + const char *magic; /* magic word for figuring out base path */ + const char *shaderPath; /* shader directory */ + int maxLMSurfaceVerts; /* default maximum lightmapped surface verts */ + int maxSurfaceVerts; /* default maximum surface verts */ + int maxSurfaceIndexes; /* default maximum surface indexes (tris * 3) */ + bool emitFlares; /* when true, emit flare surfaces */ + const char *flareShader; /* default flare shader (MUST BE SET) */ + bool wolfLight; /* when true, lights work like wolf q3map */ + int lightmapSize; /* bsp lightmap width/height */ + float lightmapGamma; /* default lightmap gamma */ + bool lightmapsRGB; /* default lightmap sRGB mode */ + bool texturesRGB; /* default texture sRGB mode */ + bool colorsRGB; /* default color sRGB mode */ + float lightmapExposure; /* default lightmap exposure */ + float lightmapCompensate; /* default lightmap compensate value */ + float gridScale; /* vortex: default lightgrid scale (affects both directional and ambient spectres) */ + float gridAmbientScale; /* vortex: default lightgrid ambient spectre scale */ + bool lightAngleHL; /* jal: use half-lambert curve for light angle attenuation */ + bool noStyles; /* use lightstyles hack or not */ + bool keepLights; /* keep light entities on bsp */ + int patchSubdivisions; /* default patchMeta subdivisions tolerance */ + bool patchShadows; /* patch casting enabled */ + bool deluxeMap; /* compile deluxemaps */ + int deluxeMode; /* deluxemap mode (0 - modelspace, 1 - tangentspace with renormalization, 2 - tangentspace without renormalization) */ + int miniMapSize; /* minimap size */ + float miniMapSharpen; /* minimap sharpening coefficient */ + float miniMapBorder; /* minimap border amount */ + bool miniMapKeepAspect; /* minimap keep aspect ratio by letterboxing */ + EMiniMapMode miniMapMode; /* minimap mode */ + const char *miniMapNameFormat; /* minimap name format */ + const char *bspIdent; /* 4-letter bsp file prefix */ + int bspVersion; /* bsp version to use */ + bool lumpSwap; /* cod-style len/ofs order */ + typedef void ( *bspFunc )( const char * ); + bspFunc load, write; /* load/write function pointers */ + std::vector surfaceParms; /* surfaceparm array */ + int brushBevelsSurfaceFlagsMask; /* apply only these surfaceflags to bevels to reduce extra bsp shaders amount; applying them to get correct physics at walkable brush edges and vertices */ +}; + +extern const std::vector g_games; +extern const game_t *game; diff --git a/tools/quake3/q3map2/help.cpp b/tools/quake3/q3map2/help.cpp index 08f5d544..cd3a63ed 100644 --- a/tools/quake3/q3map2/help.cpp +++ b/tools/quake3/q3map2/help.cpp @@ -405,8 +405,8 @@ void HelpCommon() void HelpGames(){ Sys_Printf( "Available games:\n" ); - for( game_t *game = games; game->arg != NULL; ++game ) - Sys_Printf( " %s\n", game->arg ); + for( const game_t& game : g_games ) + Sys_Printf( " %s\n", game.arg ); } void HelpMain(const char* arg) diff --git a/tools/quake3/q3map2/lightmaps_ydnar.cpp b/tools/quake3/q3map2/lightmaps_ydnar.cpp index dd7987fa..dba1b5a2 100644 --- a/tools/quake3/q3map2/lightmaps_ydnar.cpp +++ b/tools/quake3/q3map2/lightmaps_ydnar.cpp @@ -30,6 +30,7 @@ /* dependencies */ #include "q3map2.h" +#include "bspfile_rbsp.h" diff --git a/tools/quake3/q3map2/path_init.cpp b/tools/quake3/q3map2/path_init.cpp index af1eca60..b7b6e675 100644 --- a/tools/quake3/q3map2/path_init.cpp +++ b/tools/quake3/q3map2/path_init.cpp @@ -195,7 +195,7 @@ void LokiInitPaths( char *argv0 ){ returns NULL if no match found */ -game_t *GetGame( char *arg ){ +const game_t *GetGame( char *arg ){ /* dummy check */ if ( strEmptyOrNull( arg ) ) { return NULL; @@ -214,13 +214,10 @@ game_t *GetGame( char *arg ){ } /* test it */ - int i = 0; - while ( games[ i ].arg != NULL ) + for( const game_t& game : g_games ) { - if ( striEqual( arg, games[ i ].arg ) ) { - return &games[ i ]; - } - i++; + if ( striEqual( arg, game.arg ) ) + return &game; } /* no matching game */ @@ -371,7 +368,7 @@ void InitPaths( int *argc, char **argv ){ LokiInitPaths( argv[ 0 ] ); /* set game to default (q3a) */ - game = &games[ 0 ]; + game = &g_games[ 0 ]; numBasePaths = 0; numGamePaths = 0; @@ -393,7 +390,7 @@ void InitPaths( int *argc, char **argv ){ argv[ i - 1 ] = NULL; game = GetGame( argv[ i ] ); if ( game == NULL ) { - game = &games[ 0 ]; + game = &g_games[ 0 ]; } argv[ i ] = NULL; } diff --git a/tools/quake3/q3map2/q3map2.h b/tools/quake3/q3map2/q3map2.h index 4a1eb200..d9c49754 100644 --- a/tools/quake3/q3map2/q3map2.h +++ b/tools/quake3/q3map2/q3map2.h @@ -92,6 +92,7 @@ #include #include "maxworld.h" +#include "games.h" /* ------------------------------------------------------------------------------- @@ -135,28 +136,6 @@ #endif -/* ydnar: compiler flags, because games have widely varying content/surface flags */ -#define C_SOLID 0x00000001 -#define C_TRANSLUCENT 0x00000002 -#define C_STRUCTURAL 0x00000004 -#define C_HINT 0x00000008 -#define C_NODRAW 0x00000010 -#define C_LIGHTGRID 0x00000020 -#define C_ALPHASHADOW 0x00000040 -#define C_LIGHTFILTER 0x00000080 -#define C_VERTEXLIT 0x00000100 -#define C_LIQUID 0x00000200 -#define C_FOG 0x00000400 -#define C_SKY 0x00000800 -#define C_ORIGIN 0x00001000 -#define C_AREAPORTAL 0x00002000 -#define C_ANTIPORTAL 0x00004000 /* like hint, but doesn't generate portals */ -#define C_SKIP 0x00008000 /* like hint, but skips this face (doesn't split bsp) */ -#define C_NOMARKS 0x00010000 /* no decals */ -#define C_OB 0x00020000 /* skip -noob for this */ -#define C_DETAIL 0x08000000 /* THIS MUST BE THE SAME AS IN RADIANT! */ - - /* shadow flags */ #define WORLDSPAWN_CAST_SHADOWS 1 #define WORLDSPAWN_RECV_SHADOWS 1 @@ -178,7 +157,7 @@ #define HINT_PRIORITY 1000 /* ydnar: force hint splits first and antiportal/areaportal splits last */ #define ANTIPORTAL_PRIORITY -1000 #define AREAPORTAL_PRIORITY -1000 -#define DETAIL_PRIORITY -3000 +#define DETAIL_PRIORITY -3000 #define PSIDE_FRONT 1 #define PSIDE_BACK 2 @@ -272,9 +251,6 @@ enum class EBrushType -typedef void ( *bspFunc )( const char * ); - - struct bspLump_t { int offset, length; @@ -434,66 +410,6 @@ struct bspAdvertisement_t typedef Vector3 tcMod_t[ 3 ]; -/* ydnar: for multiple game support */ -struct surfaceParm_t -{ - const char *name; - int contentFlags, contentFlagsClear; - int surfaceFlags, surfaceFlagsClear; - int compileFlags, compileFlagsClear; -}; - -enum class EMiniMapMode -{ - Gray, - Black, - White -}; - -struct game_t -{ - const char *arg; /* -game matches this */ - const char *gamePath; /* main game data dir */ - const char *homeBasePath; /* home sub-dir on unix */ - const char *magic; /* magic word for figuring out base path */ - const char *shaderPath; /* shader directory */ - int maxLMSurfaceVerts; /* default maximum meta surface verts */ - int maxSurfaceVerts; /* default maximum surface verts */ - int maxSurfaceIndexes; /* default maximum surface indexes (tris * 3) */ - bool emitFlares; /* when true, emit flare surfaces */ - const char *flareShader; /* default flare shader (MUST BE SET) */ - bool wolfLight; /* when true, lights work like wolf q3map */ - int lightmapSize; /* bsp lightmap width/height */ - float lightmapGamma; /* default lightmap gamma */ - bool lightmapsRGB; /* default lightmap sRGB mode */ - bool texturesRGB; /* default texture sRGB mode */ - bool colorsRGB; /* default color sRGB mode */ - float lightmapExposure; /* default lightmap exposure */ - float lightmapCompensate; /* default lightmap compensate value */ - float gridScale; /* vortex: default lightgrid scale (affects both directional and ambient spectres) */ - float gridAmbientScale; /* vortex: default lightgrid ambient spectre scale */ - bool lightAngleHL; /* jal: use half-lambert curve for light angle attenuation */ - bool noStyles; /* use lightstyles hack or not */ - bool keepLights; /* keep light entities on bsp */ - int patchSubdivisions; /* default patch subdivisions tolerance */ - bool patchShadows; /* patch casting enabled */ - bool deluxeMap; /* compile deluxemaps */ - int deluxeMode; /* deluxemap mode (0 - modelspace, 1 - tangentspace with renormalization, 2 - tangentspace without renormalization) */ - int miniMapSize; /* minimap size */ - float miniMapSharpen; /* minimap sharpening coefficient */ - float miniMapBorder; /* minimap border amount */ - bool miniMapKeepAspect; /* minimap keep aspect ratio by letterboxing */ - EMiniMapMode miniMapMode; /* minimap mode */ - const char *miniMapNameFormat; /* minimap name format */ - const char *bspIdent; /* 4-letter bsp file prefix */ - int bspVersion; /* bsp version to use */ - bool lumpSwap; /* cod-style len/ofs order */ - bspFunc load, write; /* load/write function pointers */ - surfaceParm_t surfaceParms[ 128 ]; /* surfaceparm array */ - int brushBevelsSurfaceFlagsMask; /* apply only these surfaceflags to bevels to reduce extra bsp shaders amount; applying them to get correct physics at walkable brush edges and vertices */ -}; - - struct image_t { char *name, *filename; @@ -1499,7 +1415,7 @@ void HelpMain(const char* arg); void HelpGames(); /* path_init.c */ -game_t *GetGame( char *arg ); +const game_t *GetGame( char *arg ); void InitPaths( int *argc, char **argv ); @@ -1878,19 +1794,6 @@ void InjectCommandLine( char **argv, int beginArgs, int e -/* bspfile_ibsp.c */ -void LoadIBSPFile( const char *filename ); -void WriteIBSPFile( const char *filename ); -void PartialLoadIBSPFile( const char *filename ); - - - -/* bspfile_rbsp.c */ -void LoadRBSPFile( const char *filename ); -void WriteRBSPFile( const char *filename ); - - - /* ------------------------------------------------------------------------------- bsp/general global variables @@ -1905,55 +1808,6 @@ void WriteRBSPFile( const char *filename ); #define Q_ASSIGN( a ) #endif -/* game support */ -Q_EXTERN game_t games[] -#ifndef MAIN_C -; -#else - = - { - #include "game_quake3.h" - , - #include "game_quakelive.h" /* must be after game_quake3.h as they share defines! */ - , - #include "game_nexuiz.h" /* must be after game_quake3.h as they share defines! */ - , - #include "game_xonotic.h" /* must be after game_quake3.h as they share defines! */ - , - #include "game_tremulous.h" /*LinuxManMikeC: must be after game_quake3.h, depends on #define's set in it */ - , - #include "game_unvanquished.h" - , - #include "game_tenebrae.h" - , - #include "game_wolf.h" - , - #include "game_wolfet.h" /* must be after game_wolf.h as they share defines! */ - , - #include "game_etut.h" - , - #include "game_ef.h" - , - #include "game_sof2.h" - , - #include "game_jk2.h" /* must be after game_sof2.h as they share defines! */ - , - #include "game_ja.h" /* must be after game_jk2.h as they share defines! */ - , - #include "game_qfusion.h" /* qfusion game */ - , - #include "game_reaction.h" /* must be after game_quake3.h */ - , - #include "game_darkplaces.h" /* vortex: darkplaces q1 engine */ - , - #include "game_dq.h" /* vortex: deluxe quake game ( darkplaces q1 engine) */ - , - #include "game_prophecy.h" /* vortex: prophecy game ( darkplaces q1 engine) */ - , - #include "game__null.h" /* null game (must be last item) */ - }; -#endif -Q_EXTERN game_t *game Q_ASSIGN( &games[ 0 ] ); /* general */ diff --git a/tools/quake3/q3map2/shaders.cpp b/tools/quake3/q3map2/shaders.cpp index 5c97c415..08a4f82c 100644 --- a/tools/quake3/q3map2/shaders.cpp +++ b/tools/quake3/q3map2/shaders.cpp @@ -216,8 +216,7 @@ void TCModRotate( tcMod_t& mod, float euler ){ */ bool ApplySurfaceParm( const char *name, int *contentFlags, int *surfaceFlags, int *compileFlags ){ - int i, fake; - surfaceParm_t *sp; + int fake; /* dummy check */ @@ -235,42 +234,38 @@ bool ApplySurfaceParm( const char *name, int *contentFlags, int *surfaceFlags, i } /* walk the current game's surfaceparms */ - sp = game->surfaceParms; - while ( sp->name != NULL ) + for( const surfaceParm_t& sp : game->surfaceParms ) { /* match? */ - if ( striEqual( name, sp->name ) ) { + if ( striEqual( name, sp.name ) ) { /* clear and set flags */ - *contentFlags &= ~( sp->contentFlagsClear ); - *contentFlags |= sp->contentFlags; - *surfaceFlags &= ~( sp->surfaceFlagsClear ); - *surfaceFlags |= sp->surfaceFlags; - *compileFlags &= ~( sp->compileFlagsClear ); - *compileFlags |= sp->compileFlags; + *contentFlags &= ~( sp.contentFlagsClear ); + *contentFlags |= sp.contentFlags; + *surfaceFlags &= ~( sp.surfaceFlagsClear ); + *surfaceFlags |= sp.surfaceFlags; + *compileFlags &= ~( sp.compileFlagsClear ); + *compileFlags |= sp.compileFlags; /* return ok */ return true; } - - /* next */ - sp++; } /* check custom info parms */ - for ( i = 0; i < numCustSurfaceParms; i++ ) + for ( int i = 0; i < numCustSurfaceParms; i++ ) { /* get surfaceparm */ - sp = &custSurfaceParms[ i ]; + const surfaceParm_t& sp = custSurfaceParms[ i ]; /* match? */ - if ( striEqual( name, sp->name ) ) { + if ( striEqual( name, sp.name ) ) { /* clear and set flags */ - *contentFlags &= ~( sp->contentFlagsClear ); - *contentFlags |= sp->contentFlags; - *surfaceFlags &= ~( sp->surfaceFlagsClear ); - *surfaceFlags |= sp->surfaceFlags; - *compileFlags &= ~( sp->compileFlagsClear ); - *compileFlags |= sp->compileFlags; + *contentFlags &= ~( sp.contentFlagsClear ); + *contentFlags |= sp.contentFlags; + *surfaceFlags &= ~( sp.surfaceFlagsClear ); + *surfaceFlags |= sp.surfaceFlags; + *compileFlags &= ~( sp.compileFlagsClear ); + *compileFlags |= sp.compileFlags; /* return ok */ return true; diff --git a/tools/quake3/q3map2/writebsp.cpp b/tools/quake3/q3map2/writebsp.cpp index 16a0da19..e35673af 100644 --- a/tools/quake3/q3map2/writebsp.cpp +++ b/tools/quake3/q3map2/writebsp.cpp @@ -523,10 +523,12 @@ void EmitFogs( void ){ } /* warn about overflow */ - if( game->write == WriteIBSPFile && numMapFogs > MAX_IBSP_FOGS ) + if( strEqual( game->bspIdent, "RBSP" ) ){ + if( numMapFogs > MAX_RBSP_FOGS ) + Sys_Warning( "MAX_RBSP_FOGS (%i) exceeded (%i). Visual inconsistencies are expected.\n", MAX_RBSP_FOGS, numMapFogs ); + } + else if( numMapFogs > MAX_IBSP_FOGS ) Sys_Warning( "MAX_IBSP_FOGS (%i) exceeded (%i). Visual inconsistencies are expected.\n", MAX_IBSP_FOGS, numMapFogs ); - if( game->write == WriteRBSPFile && numMapFogs > MAX_RBSP_FOGS ) - Sys_Warning( "MAX_RBSP_FOGS (%i) exceeded (%i). Visual inconsistencies are expected.\n", MAX_RBSP_FOGS, numMapFogs ); }