From 64fe6940f05eeecc990bb008dcb0b8530741074a Mon Sep 17 00:00:00 2001 From: TTimo Date: Sun, 4 Nov 2007 04:09:22 +0000 Subject: [PATCH] eol git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/branches/ZeroRadiant@190 8a3a26a2-13c4-0310-b231-cf6edde360e5 --- INSTALL.txt | 14 +- contrib/bkgrnd2d/bkgrnd2d.def | 16 +- contrib/bkgrnd2d/readme_bkgrnd2d-b0.25.txt | 262 ++-- contrib/bobtoolz/bobToolz.def | 16 +- contrib/bobtoolz/bt/bt-el1.txt | 32 +- contrib/bobtoolz/bt/ctf-blue.txt | 120 +- contrib/bobtoolz/bt/ctf-red.txt | 120 +- contrib/bobtoolz/bt/door-tex-trim.txt | 8 +- contrib/bobtoolz/bt/door-tex.txt | 18 +- contrib/bobtoolz/bt/tp_ent.txt | 26 +- contrib/bobtoolz/ctftoolz.def | 24 +- contrib/bobtoolz/txt/changelog.txt | 192 +-- contrib/bobtoolz/txt/readme.txt | 152 +-- contrib/camera/camera.def | 16 +- contrib/gtkgensurf/gensurf.def | 16 +- contrib/hydratoolz/hydratoolz.def | 16 +- contrib/prtview/PrtView.def | 16 +- contrib/prtview/PrtView.txt | 22 +- docs/developer/Inspector/inspector.txt | 532 ++++---- docs/developer/RegExp/replace.pl | 32 +- docs/developer/RegExp/tstscrpt.pl | 32 +- docs/developer/XML.txt | 54 +- docs/developer/XMLPush/ReadMe.txt | 68 +- docs/developer/XMLmap.txt | 54 +- docs/developer/data-driven-design.txt | 152 +-- docs/developer/q3mapfeedback.txt | 64 +- docs/manual/quake3/Compile_Manual/bspc.txt | 1130 +++++++-------- .../quake3/Compile_Manual/headskins.txt | 150 +- .../quake3/Compile_Manual/modelskins.txt | 146 +- install.py | 96 +- libs/synapse/doc/design.txt | 378 ++--- libs/synapse/doc/runtime.txt | 116 +- libs/synapse/doc/unload.txt | 170 +-- makeversion.py | 144 +- plugins/eclassfgd/fgd.def | 16 +- plugins/entity/entity.def | 16 +- plugins/image/image.def | 16 +- plugins/imagehl/imagehl.def | 16 +- plugins/imagehl/imagehl.txt | 60 +- plugins/imagem8/imagem8.def | 16 +- plugins/imagepng/imagepng.def | 16 +- plugins/map/map.def | 16 +- plugins/mapxml/mapxml.def | 16 +- plugins/model/model.def | 14 +- plugins/shaders/shaders.def | 16 +- plugins/shaders/shadershl.def | 16 +- plugins/spritemodel/spritemodel.def | 16 +- plugins/surface_heretic2/surface_heretic2.def | 16 +- plugins/textool/TexTool.def | 24 +- plugins/textool/changelog.txt | 14 +- plugins/vfspk3/vfspk3.def | 16 +- plugins/vfswad/vfswad.def | 16 +- plugins/vfswad/vfswad.txt | 60 +- tools/quake3/q3map2/changelog.q3map2.txt | 1214 ++++++++--------- tools/quake3/q3map2/listen.pl | 92 +- utils.py | 260 ++-- win32_install.py | 332 ++--- 57 files changed, 3349 insertions(+), 3349 deletions(-) diff --git a/INSTALL.txt b/INSTALL.txt index 022a6510..a9e72791 100644 --- a/INSTALL.txt +++ b/INSTALL.txt @@ -1,7 +1,7 @@ -Compilation instructions ------------------------- - -See latest information for compiling and installation -on the developer pages: - -http://www.qeradiant.com/wikifaq/index.php?GtkRadiant%20Hacker +Compilation instructions +------------------------ + +See latest information for compiling and installation +on the developer pages: + +http://www.qeradiant.com/wikifaq/index.php?GtkRadiant%20Hacker diff --git a/contrib/bkgrnd2d/bkgrnd2d.def b/contrib/bkgrnd2d/bkgrnd2d.def index 36c4457f..fa90fdb1 100644 --- a/contrib/bkgrnd2d/bkgrnd2d.def +++ b/contrib/bkgrnd2d/bkgrnd2d.def @@ -1,8 +1,8 @@ -; bkgrnd2d.def : Declares the module parameters for the DLL. - -LIBRARY "BKGRND2D" -DESCRIPTION 'BKGRND2D Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; bkgrnd2d.def : Declares the module parameters for the DLL. + +LIBRARY "BKGRND2D" +DESCRIPTION 'BKGRND2D Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/bkgrnd2d/readme_bkgrnd2d-b0.25.txt b/contrib/bkgrnd2d/readme_bkgrnd2d-b0.25.txt index 6184245e..c1e401c7 100644 --- a/contrib/bkgrnd2d/readme_bkgrnd2d-b0.25.txt +++ b/contrib/bkgrnd2d/readme_bkgrnd2d-b0.25.txt @@ -1,131 +1,131 @@ -November 25 2003 -bkgrnd2d v 0.25 beta for radiant 1.3.13 -by SCDS_reyalP (email hellsownpuppy@yahoo.com) - -WARNING: -This is an beta release. It is provided with absolutely NO WARRANTY. -If it turns your data to mush and melts your CPU, don't blame me. - -Overview: -This little plugin allows you to display an image in the the gtkradiant 2d -windows. This is useful for layout sketches, maps made from -existing plans, building geometry based on photgraphs, viewing terrain -alphamaps in relation to your terrain, and so on. - -Installation: -extract the .dll and bitmaps into your gtkradiant/plugins directory, and -restart radiant. Be sure to use directory names, to ensure the bitmaps go -in your plugins/bitmaps directory. - -Uninstallation: -Close radiant, delete the bkgrnd2d.dll from the plugins directory, and -delete the bkgrnd2*.bmp files from the plugins/bitmaps directory. - -User Interface: -- The plugin adds 4 buttons to the radiant plugin toolbar. The first 3 - toggle the display of a background image in the specified view. The fourth - brings up a configuration dialog. The configuration dialog can also be - opened from the plugins menu. - -- If an image has not been loaded, or it's display size and location have - not been set, pushing one of the toggle buttons will bring up the dialog - with the corresponding page selected. - -- The configuration dialog is non-modal, meaning that you can leave it open - while you work in radiant. If it gets lost behind another window, clicking - on the configuration button will bring it to the forground. - -Usage: -- bring up the configuration dialog. - -- Choose the "Browse..." button. This will prompt you for an image file. - The file *MUST* be inside your basegame directory (baseq3, main, etmain or - whatever your chosen game uses). The image must be in a format supported by - the game in use. For q3 based games this is truecolor .jpg, .tga and - sometimes .png. For q2 this is .wal - -- Use one of the following methods to set the size (in game units) that the - file is displayed. - 1) select 1 or more brushes or entities and choose "from selection" - This will use the total dimensions off all selected brushes and entities - to size the image. - 2) For the X/Y view only, choose 'Size to min/max keys' This will look in - the worldspawn entity for the keys mapcoordsmins and mapcoordsmaxs (also - used for ET tracemap generation and command map sizing) and use those - dimensions to size the image. - -- Use the toggle buttons to show or hide the loaded images. The buttons will - press or unpress whenever you click them, but an image will only be - displayed once you have successfully loaded a file and set its size/postion. - -- Set the opacity of the image using the slider in the configuration dialog. - -- If any of these commands do not produce the expected results, there may be - an information in the radiant console. Please include this when reporting - bugs. - - -Notes and limitations: -- This plugin is compiled for GtkRadiant 1.3.13. It may or may not work with - later versions. It will *NOT* work with version 1.3.12 and below. If you - build from source (see below) you can build it for other versions. - -- As mentioned above, the image *MUST* be inside your basegame directory, or - another directory in which radiant looks for game files. - -- To prevent the image from being distorted, you should size it to the - original images aspect ratio. mapcoordsmaxs/mapcoordsmins and command maps - should always be square. - -- If you want a specific pixel to world unit relationship, you must arrange - that yourself. - -- On load, the image is converted to a texture whose dimensions are powers - of 2. If the original image dimensions are not powers of 2, some detail will - be lost due to resampling. If it is too large to fit on a single texture, - resolution is reduced. - -- radiants gamma and mipmap options are applied to the image. - -- If the image has an alpha channel, it will be included in the blending - process. 0 is transparent, 255 is opaque. .tga images are recommended if - you want to have an alpha channel. - -- since the plugin will only use true color files, you cannot use a terrain - indexmap (aka alphamap) or heightmap directly. You can of course, save a - copy of your indexmap in a 32 bit format. - -- There is no unload command. - -- You put the plugin in a game specific plugin directory, rather than the - radiant plugin directory. - -- You cannot set the image size with sub-unit precision. - -- Only win32 binaries are included. The source is available from: - http://www.cyberonic.net/~gdevault/rfm/mapstuff/bkgrnd2d-b0.25-src.zip - If you want to use it on another platform you will need a buildable gtkradiant - source tree to build it. For any non-windows platform you will also have to - figure out the compile options. I suggest ripping those off from some other - plugin. - -TODO: -- make file selection paterns match supported filetypes -- large images without downsampling -- bitmap and pcx support for indexmaps -- automatic size from indexmapped entities -- render under the grid instead of blending -- mac/*nix support -- remember/save/restore settings -- texture options independant of radiant prefs -- clean up icky code - -Changes from 0.1 -- all 2d views supported -- new ui -- file selection patterns, default directory improved - -Changes from 0.2 -- tooltips in dialog -- various code cleanup - +November 25 2003 +bkgrnd2d v 0.25 beta for radiant 1.3.13 +by SCDS_reyalP (email hellsownpuppy@yahoo.com) + +WARNING: +This is an beta release. It is provided with absolutely NO WARRANTY. +If it turns your data to mush and melts your CPU, don't blame me. + +Overview: +This little plugin allows you to display an image in the the gtkradiant 2d +windows. This is useful for layout sketches, maps made from +existing plans, building geometry based on photgraphs, viewing terrain +alphamaps in relation to your terrain, and so on. + +Installation: +extract the .dll and bitmaps into your gtkradiant/plugins directory, and +restart radiant. Be sure to use directory names, to ensure the bitmaps go +in your plugins/bitmaps directory. + +Uninstallation: +Close radiant, delete the bkgrnd2d.dll from the plugins directory, and +delete the bkgrnd2*.bmp files from the plugins/bitmaps directory. + +User Interface: +- The plugin adds 4 buttons to the radiant plugin toolbar. The first 3 + toggle the display of a background image in the specified view. The fourth + brings up a configuration dialog. The configuration dialog can also be + opened from the plugins menu. + +- If an image has not been loaded, or it's display size and location have + not been set, pushing one of the toggle buttons will bring up the dialog + with the corresponding page selected. + +- The configuration dialog is non-modal, meaning that you can leave it open + while you work in radiant. If it gets lost behind another window, clicking + on the configuration button will bring it to the forground. + +Usage: +- bring up the configuration dialog. + +- Choose the "Browse..." button. This will prompt you for an image file. + The file *MUST* be inside your basegame directory (baseq3, main, etmain or + whatever your chosen game uses). The image must be in a format supported by + the game in use. For q3 based games this is truecolor .jpg, .tga and + sometimes .png. For q2 this is .wal + +- Use one of the following methods to set the size (in game units) that the + file is displayed. + 1) select 1 or more brushes or entities and choose "from selection" + This will use the total dimensions off all selected brushes and entities + to size the image. + 2) For the X/Y view only, choose 'Size to min/max keys' This will look in + the worldspawn entity for the keys mapcoordsmins and mapcoordsmaxs (also + used for ET tracemap generation and command map sizing) and use those + dimensions to size the image. + +- Use the toggle buttons to show or hide the loaded images. The buttons will + press or unpress whenever you click them, but an image will only be + displayed once you have successfully loaded a file and set its size/postion. + +- Set the opacity of the image using the slider in the configuration dialog. + +- If any of these commands do not produce the expected results, there may be + an information in the radiant console. Please include this when reporting + bugs. + + +Notes and limitations: +- This plugin is compiled for GtkRadiant 1.3.13. It may or may not work with + later versions. It will *NOT* work with version 1.3.12 and below. If you + build from source (see below) you can build it for other versions. + +- As mentioned above, the image *MUST* be inside your basegame directory, or + another directory in which radiant looks for game files. + +- To prevent the image from being distorted, you should size it to the + original images aspect ratio. mapcoordsmaxs/mapcoordsmins and command maps + should always be square. + +- If you want a specific pixel to world unit relationship, you must arrange + that yourself. + +- On load, the image is converted to a texture whose dimensions are powers + of 2. If the original image dimensions are not powers of 2, some detail will + be lost due to resampling. If it is too large to fit on a single texture, + resolution is reduced. + +- radiants gamma and mipmap options are applied to the image. + +- If the image has an alpha channel, it will be included in the blending + process. 0 is transparent, 255 is opaque. .tga images are recommended if + you want to have an alpha channel. + +- since the plugin will only use true color files, you cannot use a terrain + indexmap (aka alphamap) or heightmap directly. You can of course, save a + copy of your indexmap in a 32 bit format. + +- There is no unload command. + +- You put the plugin in a game specific plugin directory, rather than the + radiant plugin directory. + +- You cannot set the image size with sub-unit precision. + +- Only win32 binaries are included. The source is available from: + http://www.cyberonic.net/~gdevault/rfm/mapstuff/bkgrnd2d-b0.25-src.zip + If you want to use it on another platform you will need a buildable gtkradiant + source tree to build it. For any non-windows platform you will also have to + figure out the compile options. I suggest ripping those off from some other + plugin. + +TODO: +- make file selection paterns match supported filetypes +- large images without downsampling +- bitmap and pcx support for indexmaps +- automatic size from indexmapped entities +- render under the grid instead of blending +- mac/*nix support +- remember/save/restore settings +- texture options independant of radiant prefs +- clean up icky code + +Changes from 0.1 +- all 2d views supported +- new ui +- file selection patterns, default directory improved + +Changes from 0.2 +- tooltips in dialog +- various code cleanup + diff --git a/contrib/bobtoolz/bobToolz.def b/contrib/bobtoolz/bobToolz.def index 9ff9f292..c22c76d3 100644 --- a/contrib/bobtoolz/bobToolz.def +++ b/contrib/bobtoolz/bobToolz.def @@ -1,8 +1,8 @@ -; plugin.def : Declares the module parameters for the DLL. - -LIBRARY "bobToolz" -; DESCRIPTION 'bobToolz Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; plugin.def : Declares the module parameters for the DLL. + +LIBRARY "bobToolz" +; DESCRIPTION 'bobToolz Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/bobtoolz/bt/bt-el1.txt b/contrib/bobtoolz/bt/bt-el1.txt index ccac5e6e..f6485f94 100644 --- a/contrib/bobtoolz/bt/bt-el1.txt +++ b/contrib/bobtoolz/bt/bt-el1.txt @@ -1,17 +1,17 @@ -common/areaportal -common/clip -common/clusterportal -common/cushion -common/donotenter -common/full_clip -common/hint -common/missileclip -common/nodraw -common/nodrawnonsolid -common/nodrop -common/noimpact -common/origin -common/trigger -common/weapclip -liquid +common/areaportal +common/clip +common/clusterportal +common/cushion +common/donotenter +common/full_clip +common/hint +common/missileclip +common/nodraw +common/nodrawnonsolid +common/nodrop +common/noimpact +common/origin +common/trigger +common/weapclip +liquid fog \ No newline at end of file diff --git a/contrib/bobtoolz/bt/ctf-blue.txt b/contrib/bobtoolz/bt/ctf-blue.txt index de5b0188..5a5f6ca3 100644 --- a/contrib/bobtoolz/bt/ctf-blue.txt +++ b/contrib/bobtoolz/bt/ctf-blue.txt @@ -1,61 +1,61 @@ -base_light/light1blue_2000 -base_light/light1blue_5000 -ctf/blue_telep -ctf/ctf_blueflag -ctf/ctf_tower_bluefin_shiny -gothic_door/door02_eblue2_shiny -gothic_light/ironcrossltblue_10000 -gothic_light/ironcrossltblue_2000 -gothic_light/ironcrossltblue_20000 -gothic_light/ironcrossltblue_3000 -gothic_light/ironcrossltblue_30000 -gothic_light/ironcrossltblue_4000 -gothic_light/ironcrossltblue_5000 -sfx/beam_blue -sfx/flameanim_blue -sfx/flameanim_blue_nolight -sfx/flameanim_blue_pj -sfx/mkc_fog_ctfblue -sfx/xbluefog -base_wall2/blue_metal -base_wall2/jumppad_blue_kc -base_wall2/blue_line -base_wall2/double_line_blue -base_wall2/blue_arrow_small -base_wall2/blue_circle -base_wall2/bluearrows -base_wall2/blue_solid -ctf2/blueteam01 -ctf2/blueteam02 -ctf2/xblueteam01 -ctf2/blue_banner02 -proto2/blueflag -proto2/blueob -proto2/marbledoor_blue -proto2/concrete_bluenfx -proto2/bluelight_on -proto2/bsbluelight_on -proto2/rsbluelight_off -proto2/bsbluelight_off -proto2/rsbluelight_on -proto2/bluetrim01 -proto2/blue_zot -proto2/blue_zot2 -proto2/bluea_dcl -proto2/concrete_blue -proto2/teamwerkz_blue1 -proto2/blueflare2 -proto2/blueflare -sfx2/flameanim_blue_lowlite -sfx2/blue_jumpad05 -sfx2/blue_launchpad -sfx2/blue_jumpad -sfx2/blue_jumpad2 -sfx2/blue_jumpad3 -sfx2/bluegoal2 -tim/blue_flagbase -team_icon/the fallen_blue -team_icon/intruders_blue -team_icon/crusaders_blue -team_icon/pagans_blue +base_light/light1blue_2000 +base_light/light1blue_5000 +ctf/blue_telep +ctf/ctf_blueflag +ctf/ctf_tower_bluefin_shiny +gothic_door/door02_eblue2_shiny +gothic_light/ironcrossltblue_10000 +gothic_light/ironcrossltblue_2000 +gothic_light/ironcrossltblue_20000 +gothic_light/ironcrossltblue_3000 +gothic_light/ironcrossltblue_30000 +gothic_light/ironcrossltblue_4000 +gothic_light/ironcrossltblue_5000 +sfx/beam_blue +sfx/flameanim_blue +sfx/flameanim_blue_nolight +sfx/flameanim_blue_pj +sfx/mkc_fog_ctfblue +sfx/xbluefog +base_wall2/blue_metal +base_wall2/jumppad_blue_kc +base_wall2/blue_line +base_wall2/double_line_blue +base_wall2/blue_arrow_small +base_wall2/blue_circle +base_wall2/bluearrows +base_wall2/blue_solid +ctf2/blueteam01 +ctf2/blueteam02 +ctf2/xblueteam01 +ctf2/blue_banner02 +proto2/blueflag +proto2/blueob +proto2/marbledoor_blue +proto2/concrete_bluenfx +proto2/bluelight_on +proto2/bsbluelight_on +proto2/rsbluelight_off +proto2/bsbluelight_off +proto2/rsbluelight_on +proto2/bluetrim01 +proto2/blue_zot +proto2/blue_zot2 +proto2/bluea_dcl +proto2/concrete_blue +proto2/teamwerkz_blue1 +proto2/blueflare2 +proto2/blueflare +sfx2/flameanim_blue_lowlite +sfx2/blue_jumpad05 +sfx2/blue_launchpad +sfx2/blue_jumpad +sfx2/blue_jumpad2 +sfx2/blue_jumpad3 +sfx2/bluegoal2 +tim/blue_flagbase +team_icon/the fallen_blue +team_icon/intruders_blue +team_icon/crusaders_blue +team_icon/pagans_blue team_icon/stroggs_blue \ No newline at end of file diff --git a/contrib/bobtoolz/bt/ctf-red.txt b/contrib/bobtoolz/bt/ctf-red.txt index 68c43dac..8dec85e7 100644 --- a/contrib/bobtoolz/bt/ctf-red.txt +++ b/contrib/bobtoolz/bt/ctf-red.txt @@ -1,61 +1,61 @@ -base_light/light1red_2000 -base_light/light1red_5000 -ctf/red_telep -ctf/ctf_redflag -ctf/ctf_tower_redfin_shiny -gothic_door/door02_bred2_shiny -gothic_light/ironcrossltred_10000 -gothic_light/ironcrossltred_2000 -gothic_light/ironcrossltred_20000 -gothic_light/ironcrossltred_3000 -gothic_light/ironcrossltred_30000 -gothic_light/ironcrossltred_4000 -gothic_light/ironcrossltred_5000 -sfx/beam_red -sfx/flameanim_red -sfx/flameanim_red_nolight -sfx/flameanim_red_pj -sfx/mkc_fog_ctfred -sfx/xredfog -base_wall2/red_metal -base_wall2/jumppad_red_kc -base_wall2/red_line -base_wall2/double_line_red -base_wall2/red_arrow_small -base_wall2/red_circle -base_wall2/redarrows -base_wall2/red_solid -ctf2/redteam01 -ctf2/redteam02 -ctf2/xredteam01x -ctf2/red_banner02 -proto2/redflag -proto2/redob -proto2/marbledoor_red -proto2/concrete_rednfx -proto2/redlight_on -proto2/bsredlight_on -proto2/rsredlight_off -proto2/bsredlight_off -proto2/rsredlight_on -proto2/redtrim01 -proto2/red_zot -proto2/red_zot2 -proto2/reda_dcl -proto2/concrete_red -proto2/teamwerkz_red1 -proto2/redflare2 -proto2/redflare -sfx2/flameanim_red_lowlite -sfx2/red_jumpad05 -sfx2/red_launchpad -sfx2/red_jumpad -sfx2/red_jumpad2 -sfx2/red_jumpad3 -sfx2/redgoal2 -tim/red_flagbase -team_icon/the fallen_red -team_icon/intruders_red -team_icon/crusaders_red -team_icon/pagans_red +base_light/light1red_2000 +base_light/light1red_5000 +ctf/red_telep +ctf/ctf_redflag +ctf/ctf_tower_redfin_shiny +gothic_door/door02_bred2_shiny +gothic_light/ironcrossltred_10000 +gothic_light/ironcrossltred_2000 +gothic_light/ironcrossltred_20000 +gothic_light/ironcrossltred_3000 +gothic_light/ironcrossltred_30000 +gothic_light/ironcrossltred_4000 +gothic_light/ironcrossltred_5000 +sfx/beam_red +sfx/flameanim_red +sfx/flameanim_red_nolight +sfx/flameanim_red_pj +sfx/mkc_fog_ctfred +sfx/xredfog +base_wall2/red_metal +base_wall2/jumppad_red_kc +base_wall2/red_line +base_wall2/double_line_red +base_wall2/red_arrow_small +base_wall2/red_circle +base_wall2/redarrows +base_wall2/red_solid +ctf2/redteam01 +ctf2/redteam02 +ctf2/xredteam01x +ctf2/red_banner02 +proto2/redflag +proto2/redob +proto2/marbledoor_red +proto2/concrete_rednfx +proto2/redlight_on +proto2/bsredlight_on +proto2/rsredlight_off +proto2/bsredlight_off +proto2/rsredlight_on +proto2/redtrim01 +proto2/red_zot +proto2/red_zot2 +proto2/reda_dcl +proto2/concrete_red +proto2/teamwerkz_red1 +proto2/redflare2 +proto2/redflare +sfx2/flameanim_red_lowlite +sfx2/red_jumpad05 +sfx2/red_launchpad +sfx2/red_jumpad +sfx2/red_jumpad2 +sfx2/red_jumpad3 +sfx2/redgoal2 +tim/red_flagbase +team_icon/the fallen_red +team_icon/intruders_red +team_icon/crusaders_red +team_icon/pagans_red team_icon/stroggs_red \ No newline at end of file diff --git a/contrib/bobtoolz/bt/door-tex-trim.txt b/contrib/bobtoolz/bt/door-tex-trim.txt index 5211a98c..d52ef76f 100644 --- a/contrib/bobtoolz/bt/door-tex-trim.txt +++ b/contrib/bobtoolz/bt/door-tex-trim.txt @@ -1,5 +1,5 @@ -base_support/support1rust -base_support/support1shiny -base_support/support2rust -base_support/wplat1_1 +base_support/support1rust +base_support/support1shiny +base_support/support2rust +base_support/wplat1_1 base_support/plate2_5 \ No newline at end of file diff --git a/contrib/bobtoolz/bt/door-tex.txt b/contrib/bobtoolz/bt/door-tex.txt index 94b352f3..69629989 100644 --- a/contrib/bobtoolz/bt/door-tex.txt +++ b/contrib/bobtoolz/bt/door-tex.txt @@ -1,10 +1,10 @@ -base_door/shinymetaldoor -base_door/shinymetaldoor_outside -gothic_door/door02_bred -gothic_door/door02_bred2_shiny -gothic_door/door02_eblue2_shiny -gothic_door/door02_i_ornate5_fin -gothic_door/door02_j -gothic_door/door02_j3 -gothic_door/door02_j4 +base_door/shinymetaldoor +base_door/shinymetaldoor_outside +gothic_door/door02_bred +gothic_door/door02_bred2_shiny +gothic_door/door02_eblue2_shiny +gothic_door/door02_i_ornate5_fin +gothic_door/door02_j +gothic_door/door02_j3 +gothic_door/door02_j4 gothic_door/door02_k2b \ No newline at end of file diff --git a/contrib/bobtoolz/bt/tp_ent.txt b/contrib/bobtoolz/bt/tp_ent.txt index 09488da9..f0645b34 100644 --- a/contrib/bobtoolz/bt/tp_ent.txt +++ b/contrib/bobtoolz/bt/tp_ent.txt @@ -1,14 +1,14 @@ -{ - "entity" "misc_model" - - "offset" "-16" - - "model" "models/mapobjects/trees_sd/tree_a.md3" - "model" "models/mapobjects/trees_sd/tree_b.md3" - "model" "models/mapobjects/trees_sd/tree_c.md3" - "model" "models/mapobjects/trees_sd/tree_d.md3" - - "pitch" "-5" "5" - "yaw" "0" "360" - "scale" "1" "1.3" +{ + "entity" "misc_model" + + "offset" "-16" + + "model" "models/mapobjects/trees_sd/tree_a.md3" + "model" "models/mapobjects/trees_sd/tree_b.md3" + "model" "models/mapobjects/trees_sd/tree_c.md3" + "model" "models/mapobjects/trees_sd/tree_d.md3" + + "pitch" "-5" "5" + "yaw" "0" "360" + "scale" "1" "1.3" } \ No newline at end of file diff --git a/contrib/bobtoolz/ctftoolz.def b/contrib/bobtoolz/ctftoolz.def index be5bab42..2c063edd 100644 --- a/contrib/bobtoolz/ctftoolz.def +++ b/contrib/bobtoolz/ctftoolz.def @@ -1,12 +1,12 @@ -; plugin.def : Declares the module parameters for the DLL. - -LIBRARY "ctfToolz" -DESCRIPTION 'ctfToolz Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - QERPlug_Init @1 - QERPlug_GetName @2 - QERPlug_GetCommandList @3 - QERPlug_Dispatch @4 - QERPlug_GetFuncTable @5 +; plugin.def : Declares the module parameters for the DLL. + +LIBRARY "ctfToolz" +DESCRIPTION 'ctfToolz Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + QERPlug_Init @1 + QERPlug_GetName @2 + QERPlug_GetCommandList @3 + QERPlug_Dispatch @4 + QERPlug_GetFuncTable @5 diff --git a/contrib/bobtoolz/txt/changelog.txt b/contrib/bobtoolz/txt/changelog.txt index c7440a5e..777dc775 100644 --- a/contrib/bobtoolz/txt/changelog.txt +++ b/contrib/bobtoolz/txt/changelog.txt @@ -1,96 +1,96 @@ -BobToolz Changelog: -[=================] - -Changes in v1110 (GTK): -[=====================] - -djbob - -Added: -(16.05.01) - Impemented a little feature that highligths the q3map bug that is causing problems for autocaulk, (see readme) -(01.04.01) - Added DPatch class to implement patches, however radiant does not (currently) support adding patches to an entity via a plugin, so, its actually redundant atm, i was adding this to fix the patches being removed from entities probelm with dealing with entities outside of the worldspawn. - -Changes: -(02.04.01) - EPair keys and values can now be 128 characters long, not 64, happy now hydra? - Texture reseter works on patches now too. - -Removed: -(29.03.01) - Removed CTF colour changer, it is now in the ctftoolz. - -Fixed: -(02.04.01) - Worldspawn brushes are rebuilt per brush, rather than per entity in texture reseter. -(03.04.01) - Worldspawn brushes are rebuilt per brush, rather than per entity in brush cleanup. - -Changes in v1100 (GTK): -[=====================] - -djbob - -Added: -(24.03.01) - Added CTF colour changer for worldspawn+func_group. - -Changes: -(25.03.01) - Brought some functions over to using DMap class, allowing them to run on multiple entities, patches are still a no-no atm. - This includes: - - a) brush cleanup, will now fix problems on brushes that are not in the worldspawn, and rebuild the entitiy afterwards. - b) texture reseter will change textures on all brushes now, not just those in the worldspawn. - c) CTF colour changer will also work on brushes outside of the worldspawn entity. - -This introduces one prolem, patches in entities will no longer be part of the new entity, sorry for any trouble this causes, i will fix it soon hopefully. - -Fixes: -(25.03.01) - Fixed bug in DMap class that prevented it destroying brushes... thus enabling the class to work!!!! - -Changes in v1090 (GTK): -[=====================] - -djbob - -Added: -(22.03.01) - Added PitOMatic Function. - -Changes in v1080b (GTK): -[======================] - -djbob - -Fixes: - Removed some previously unnoticed porting introduced bugs. - -Added: - Polygon stuff now passes through my internal validation routines, no more phantom brushes will be made, or squiffy planes. - -Changes in v1080 (GTK): -[=====================] - -djbob - -Fixes: -(05.03.01) - Fixed line removed by rr2 in autocaulk. - Fixed Autocaulk not working with maps larger than the old grid. - -Added: -(04.03.01) - Added Changelog. - Added ability to align polygons so that top edge will be flat. (Request By Casey) -(05.03.01) - Added ability to change main texture for stairs. - -rr2do2 - -Changes: -(??.??.01) - Removed all traces of MFC from GTK version, the evil that it is ;] - +BobToolz Changelog: +[=================] + +Changes in v1110 (GTK): +[=====================] + +djbob + +Added: +(16.05.01) + Impemented a little feature that highligths the q3map bug that is causing problems for autocaulk, (see readme) +(01.04.01) + Added DPatch class to implement patches, however radiant does not (currently) support adding patches to an entity via a plugin, so, its actually redundant atm, i was adding this to fix the patches being removed from entities probelm with dealing with entities outside of the worldspawn. + +Changes: +(02.04.01) + EPair keys and values can now be 128 characters long, not 64, happy now hydra? + Texture reseter works on patches now too. + +Removed: +(29.03.01) + Removed CTF colour changer, it is now in the ctftoolz. + +Fixed: +(02.04.01) + Worldspawn brushes are rebuilt per brush, rather than per entity in texture reseter. +(03.04.01) + Worldspawn brushes are rebuilt per brush, rather than per entity in brush cleanup. + +Changes in v1100 (GTK): +[=====================] + +djbob + +Added: +(24.03.01) + Added CTF colour changer for worldspawn+func_group. + +Changes: +(25.03.01) + Brought some functions over to using DMap class, allowing them to run on multiple entities, patches are still a no-no atm. + This includes: + + a) brush cleanup, will now fix problems on brushes that are not in the worldspawn, and rebuild the entitiy afterwards. + b) texture reseter will change textures on all brushes now, not just those in the worldspawn. + c) CTF colour changer will also work on brushes outside of the worldspawn entity. + +This introduces one prolem, patches in entities will no longer be part of the new entity, sorry for any trouble this causes, i will fix it soon hopefully. + +Fixes: +(25.03.01) + Fixed bug in DMap class that prevented it destroying brushes... thus enabling the class to work!!!! + +Changes in v1090 (GTK): +[=====================] + +djbob + +Added: +(22.03.01) + Added PitOMatic Function. + +Changes in v1080b (GTK): +[======================] + +djbob + +Fixes: + Removed some previously unnoticed porting introduced bugs. + +Added: + Polygon stuff now passes through my internal validation routines, no more phantom brushes will be made, or squiffy planes. + +Changes in v1080 (GTK): +[=====================] + +djbob + +Fixes: +(05.03.01) + Fixed line removed by rr2 in autocaulk. + Fixed Autocaulk not working with maps larger than the old grid. + +Added: +(04.03.01) + Added Changelog. + Added ability to align polygons so that top edge will be flat. (Request By Casey) +(05.03.01) + Added ability to change main texture for stairs. + +rr2do2 + +Changes: +(??.??.01) + Removed all traces of MFC from GTK version, the evil that it is ;] + diff --git a/contrib/bobtoolz/txt/readme.txt b/contrib/bobtoolz/txt/readme.txt index d816b5b1..5c0feddb 100644 --- a/contrib/bobtoolz/txt/readme.txt +++ b/contrib/bobtoolz/txt/readme.txt @@ -1,77 +1,77 @@ -BobToolz GTK: v1100 -[=================] - -Date: -[===] -16.05.01 - -The multipurpose Quake3 Mappers Tool -[==================================] - -Author: djbob -Other work: q3terra, ctftoolz, EECA mod - -eMail: gbiggans@uglab.eee.strath.ac.uk (NO SPAM thank u very much :P) - -www: www.planetquake.com/toolz - www.planetquake.com/eeca - -IRC: #freepq irc.fdf.net - #qeradiant irc.telefragged.com - -Files Contained In This Package: -[==============================] - -Readme.txt --- This file. -Changelog.txt --- Version information. -bobToolz.dll --- The plugin itsself. -bt/*.txt --- A few text files required by the plugin. - - -What's a boy to do? -[=================] - -Put The plugin in your GTKRadiant plugins folder: -e.g. mine: c:\gamez\quake3\GTKRadiant\plugins - -Run Radiant, and select the toolz from the dropdown plugin menu. - -Help is available in the form of a manual on my site. - - - -For the new q3map bug highlighting feature, run autocaulk-build mini prt, then run autocaulk. -identify an area which has been caulked incorrectly, then reopen the map, select the q3map bug highlight option, and wait. -once the selected brushes appear, u have 2 choices, - -a) press i and remove all the original brushes, or -b) keep going with both sets (slower, but more useful) - -navigate to the problem region, you should find that the set of inverse brushes that has been built is missing a brush -at the problem area, i suppose the next problem is finding out why :] - -this function is mainly provided for other coders to show the problem, and is probably of little use to anyone else, -but u never know. - - -Coming Soon: -[==========] -Region area saving. perhaps, if i get the time to finish it. - - -Testing, Feedback & Ideas: -[========================] - - Akuma, Casey, Cartman2K, maverik, rayden, nephilim_goth and god knows who else. - Thx to you all. - -Thanx: -[====] - - ttimo, da man :] - spog, for his often baffling advice.... and questions.... - Thx to rr2do2, for his linux conversion, and removing the "evil" (his words :]) MFC code. - Thx to RKone, for improving my q3w sig. - Azr for giving me ops in #qeradiant, k3wl :] - Everyone at the Quake3World Forums, I think of you all as my little worshippers :P +BobToolz GTK: v1100 +[=================] + +Date: +[===] +16.05.01 + +The multipurpose Quake3 Mappers Tool +[==================================] + +Author: djbob +Other work: q3terra, ctftoolz, EECA mod + +eMail: gbiggans@uglab.eee.strath.ac.uk (NO SPAM thank u very much :P) + +www: www.planetquake.com/toolz + www.planetquake.com/eeca + +IRC: #freepq irc.fdf.net + #qeradiant irc.telefragged.com + +Files Contained In This Package: +[==============================] + +Readme.txt --- This file. +Changelog.txt --- Version information. +bobToolz.dll --- The plugin itsself. +bt/*.txt --- A few text files required by the plugin. + + +What's a boy to do? +[=================] + +Put The plugin in your GTKRadiant plugins folder: +e.g. mine: c:\gamez\quake3\GTKRadiant\plugins + +Run Radiant, and select the toolz from the dropdown plugin menu. + +Help is available in the form of a manual on my site. + + + +For the new q3map bug highlighting feature, run autocaulk-build mini prt, then run autocaulk. +identify an area which has been caulked incorrectly, then reopen the map, select the q3map bug highlight option, and wait. +once the selected brushes appear, u have 2 choices, + +a) press i and remove all the original brushes, or +b) keep going with both sets (slower, but more useful) + +navigate to the problem region, you should find that the set of inverse brushes that has been built is missing a brush +at the problem area, i suppose the next problem is finding out why :] + +this function is mainly provided for other coders to show the problem, and is probably of little use to anyone else, +but u never know. + + +Coming Soon: +[==========] +Region area saving. perhaps, if i get the time to finish it. + + +Testing, Feedback & Ideas: +[========================] + + Akuma, Casey, Cartman2K, maverik, rayden, nephilim_goth and god knows who else. + Thx to you all. + +Thanx: +[====] + + ttimo, da man :] + spog, for his often baffling advice.... and questions.... + Thx to rr2do2, for his linux conversion, and removing the "evil" (his words :]) MFC code. + Thx to RKone, for improving my q3w sig. + Azr for giving me ops in #qeradiant, k3wl :] + Everyone at the Quake3World Forums, I think of you all as my little worshippers :P id Software, of course. \ No newline at end of file diff --git a/contrib/camera/camera.def b/contrib/camera/camera.def index 509df54a..6a597438 100644 --- a/contrib/camera/camera.def +++ b/contrib/camera/camera.def @@ -1,8 +1,8 @@ -; camera.def : Declares the module parameters for the DLL. - -LIBRARY "CAMERA" -DESCRIPTION 'CAMERA Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; camera.def : Declares the module parameters for the DLL. + +LIBRARY "CAMERA" +DESCRIPTION 'CAMERA Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/gtkgensurf/gensurf.def b/contrib/gtkgensurf/gensurf.def index 079253ce..e3152e85 100644 --- a/contrib/gtkgensurf/gensurf.def +++ b/contrib/gtkgensurf/gensurf.def @@ -1,8 +1,8 @@ -; gensurf.def : Declares the module parameters for the DLL. - -LIBRARY "gensurf" -DESCRIPTION 'gensurf Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; gensurf.def : Declares the module parameters for the DLL. + +LIBRARY "gensurf" +DESCRIPTION 'gensurf Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/hydratoolz/hydratoolz.def b/contrib/hydratoolz/hydratoolz.def index c7ce9f33..c48e519a 100644 --- a/contrib/hydratoolz/hydratoolz.def +++ b/contrib/hydratoolz/hydratoolz.def @@ -1,8 +1,8 @@ -; fgd.def : Declares the module parameters for the DLL. - -LIBRARY "HydraToolz" -DESCRIPTION 'HydraToolz Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; fgd.def : Declares the module parameters for the DLL. + +LIBRARY "HydraToolz" +DESCRIPTION 'HydraToolz Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/prtview/PrtView.def b/contrib/prtview/PrtView.def index 4b693944..24f945d7 100644 --- a/contrib/prtview/PrtView.def +++ b/contrib/prtview/PrtView.def @@ -1,8 +1,8 @@ -; PrtView.def : Declares the module parameters for the DLL. - -LIBRARY "PrtView" -; DESCRIPTION 'PrtView Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; PrtView.def : Declares the module parameters for the DLL. + +LIBRARY "PrtView" +; DESCRIPTION 'PrtView Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/contrib/prtview/PrtView.txt b/contrib/prtview/PrtView.txt index fba9508d..50228e02 100644 --- a/contrib/prtview/PrtView.txt +++ b/contrib/prtview/PrtView.txt @@ -1,12 +1,12 @@ -Put PrtView.dll in the Q3Radiant plugins directory. - -This program is pretty self explanitary, but point needs to -be mentioned. In the configuration menu for 3D view options, -the lines and polygons flags are tri-state. In the third state, -the lines or polygons will only be drawn if the have the -hint flag set. Older version of q3map will not set this flag -and the hint shader may have to be modified to set it. As of -this writing, I do not know all the details. - -Geoffrey DeWan +Put PrtView.dll in the Q3Radiant plugins directory. + +This program is pretty self explanitary, but point needs to +be mentioned. In the configuration menu for 3D view options, +the lines and polygons flags are tri-state. In the third state, +the lines or polygons will only be drawn if the have the +hint flag set. Older version of q3map will not set this flag +and the hint shader may have to be modified to set it. As of +this writing, I do not know all the details. + +Geoffrey DeWan gdewan@prairienet.org \ No newline at end of file diff --git a/docs/developer/Inspector/inspector.txt b/docs/developer/Inspector/inspector.txt index acf80040..7cb2b74d 100644 --- a/docs/developer/Inspector/inspector.txt +++ b/docs/developer/Inspector/inspector.txt @@ -1,266 +1,266 @@ -OK. Again I would have liked to get a design document before it being done. Main functionalities we -need in the inspector: - -- Unifiy the inspector under a single dialog box, called with 'S' - -- Depending on what is currently selected, display several frames in the inspector: -only brushes -> surface inspector -only patches -> patch inspector -brushes & patches -> both -and later when brush primitives are mixed with regular brushes + plugin entities, raise whatever -additional inspector stuff we need - -- The camera view must update realtime when we change some parameters. - -- Get rid of the Apply button, use the Undo code to store settings when surface inspector is -raised. If user hits Cancel, call the undo stuff. - -- Use the message broadcasting stuff to keep the inspectors up to date when the user changes the -current selection. Be careful to keep the undo stuff in sync with the select / deselect operations. - -- Use a 3-state scheme to display the params in the widgets. If two faces are selected that don't -have the same shift increment, just grey out the shift box. - -Messaging: -- a good chunk of the work is moving the selection/creation stuff to the messaging API - we no longer use UpdateSurfaceDialog, we post messages instead .. - the surface inspector has hooked one of it's listeners into the corresponding message - we may need to reorganize the messages, maybe introduce a hierarchy? - or pass a void * param with messages? - -- we don't post messages like "update surface inspector", we post messages that say "this and that -have changed", then the surface inspector reacts if it needs to. -Do we need marshalling in the messages? Very likely .. maybe using Gtk signal stuff would be interesting? - --> the messaging stuff is a big chunk of work and our surface inspector changes are not totally -dependent on it. Better leave that for l8r - -the inspector works by states and transitions? Or we post messages to it? -Use case: -the user raises the inspector .. if we are up we'll ignore, if we are hidden we'll -go through the whole process (initialise, look at what is selected, display) -then we enter an active state (listening for select / deselects and applying stuff) - -all in all it seems to be too big a change for next release. will see later probably. -Trying a few more days with it, see what happens. after all the interface is fairly restricted -so there's a good chance our changes are fairly stable in the end. But rebuilding the whole interface -part might be too much ... -We need something state based? AND a set of messages .. -but first, need to write the initialisation loop -build the dialog, get the current surface information and display - -Undoing the changes on the selected stuff: -at any point in time, one can get a snapshot of selected stuff and use it to store the surface -properties settings for later on. But what happens if the user modifies the selected brush, pushing -it in the undo stack? Then we would cancel the changes? (and just backup to the state right after -the modif) -We could has the 'Apply' button used for that .. grey it out when the current state is the one in -the backup. This happens whenever we hit 'Apply' or change something in the selection. -The selection has several items: entities, brushes and selected faces (possibly later generic plugin entities) -Current undo stuff is aimed at entities and brushes. -NOTE: you can't have selected faces and brushes/entities at the same time, that's a good point to -keep that seperated to deal with undo and storage -On what side should the implemetation be ? undo.cpp select.cpp or surfacedialog.cpp ? -We are going to do it with the messaging API anyway.. -And hook in the undo stuff, to reset the snapshot each time something gets pushed in the undo? - -We have advanced stuff on the Inspector branch, doing basics on Alpha branch. -Start writing the watch code in surfacedialog.cpp, see if we need some merging with Undo stuff l8r -We need to track for the patch inspector as well.. - -basic code for CSurfaceUndo written. need to add hooks for the snapshot stuff and undo stuff. and a -debug flag to monitor the life cycle of the object. - -some use cases: -- select a brush -- bring up surface inspector -- check we had the debug messages from CSurfaceUndo (initialise, activate, snapshot) -- edit the surface settings -- check the views are updating correctly -- hit Ok -- check we had a deactivate message -OK - -- select a brush -- bring up surface inspector -- check we had the debug messages from CSurfaceUndo (initialise, activate, snapshot) -- edit the surface settings -- check the views are updating correctly -- hit cancel / escape -- check we have a undo and deactivate from CSurfaceUndo -OK - -- select a brush -- bring up the surface inspector -- edit the surface settings -- hit apply -- edit them again -- hit cancel / escape -- check you get back to the apply state -OK - -- make two brushes -- select a brush -- bring up surface inspector -- change settings -- select an additional brush -- check the surface inspector, new snapshot -- hit cancel -- check brushes remained in the same state -- use standard Undo -- check the first brush got back to it's initial settings -OK - -- select a brush -- bring up surface inspector -- change settings -- select an additional brush -- check the surface inspector, new snapshot -- change more settings -- hit cancel -- check the first brush returned to intermediate state, and second to initial state (i.e. last snapshot) -OK - -g_surfaceUndo acts as a layer on top of the core Undo code when the surface inspector is activated. -We need it because the surface inspector can edit faces which are not handled by the undo? -(or does the current code push the whole brush when editing a face?) - -not sure of the utility of the g_surfaceDialog hooks here .. -default undo usage in the sruface inspector sends way too many undo messages. -with the new scheme we store in undo only when select/deselect or user hits apply -that way the 'Cancel' and later Ctrl+Z calls make sense -but is it worth implementing a new class to achieve that?? .. yes because we intend a later cleanup -of this part. (ahem is this reason good enough..) -this part is actually much closer from the undo code than I had expected.. -'Cancel' call being an Undo call.. - -going to Inspector3: -don't create a new class, simply use the Undo more intelligently? -i.e. don't create undo stuff when editing the brush --> we add a flag to turn off the default undo behaviour and force Undo storage when we want -we could also store the undo Id we are interested in and call undo several times to get it back - -NOTE: what happens if the user hits undo when the surface inspector is up? --> we'll have to take his request into account? -err .. performing which undo? The texture positioning or something else? -seems the snapshot approach would still make sense then? - -more use cases, see with Undo calls and select/deselect events -NOTE: this whole thing is probably a single call to select_settexture that needs to be turned on/off -instead of working at the undo level. but we would like to move to messaging so maybe it still makes sense -the undo call is in Select_SetTexture (which does not have that many callers, I was expecting more) - -the question about having the undo code keep working when surface inspector is around is still raised. -but it makes it a lot harder, gotta have a real inspector mode in the undo? -dunno, think about it again later - -two operations are mixed in a single one and should not be: -reading the map to get the current data we'll manipulate -feed it in the dialog box widgets -WARNING: when putting stuff in the widgets, it raises a shitload of update messages and therefor completely -fucks up our OnOK OnApply OnCancel scheme (specially OnApply!) - -NOTE: we want to switch between Surface inspector for brushes only and Patch inspector for patches only -there's some crappy code in the surface inspector that we need to get rid of -but need to check about that before with Spog or others - -Forcing the way into using the surface inspector is SCREWED? -Doesn't seem to work the way we want to. Always get parasite Undo messages and stuff. -We could use a seperate stack for Undo with the surface inspector? -Just store the surface properties in a seperate stack? -When user hits cancel you go back and apply whatever you had? -Doesn't seem like a clean way either. - -Now dealing with both regular surface inspector and patch inspector: -we have some stuff that needs to be on/off with the two inspectors -what about catching the messages and issuing new snapshots? -the main surface inspector is doing it? -no! -so what, we have several states? -FUCKED UP - -INSPECTOR 5 ---------------------------------------------------------------- -restarted from scratch, made much more simple changes. -trying another trick for undo (!) -just let the undo work as usual, but call undo ourselves in SetTexMods if we have create the last do -requires proper initialization/deinitialisation.. in SetTexMods and GetTexMods.. - -getting rid of patch manipulation code in the regular surface inspector. The buttons will -still work, but manip will require the patch inspector. (seems the patch inspector doesn't have that -much success anyway) - -TODO: -OK get rid of patch stuff -OK get rid of the texture toolbar? (it's broken right now) - (and doesn't have anything usefull..) -OK (Partial) OnCancel? we need to cancel the texdef as well - store an undo texdef each time we grab new texdef stuff - this works in reverse than the Undo code? When we do the initial - problem is, in some cases the settings that show up are not in sync with what's in the inspector?? - (we can't avoid that because if a brush is selected there's no single setting) - prolly get it out as is and let Spog or others send feedback about what it's supposed to do.. - for now: store stuff in the cancel texdef when we initialize an undo loop - revert to that if OnCancel is used -OK message when spinning over a patch? -DUPLICATE (.. see below ..) check the increments we store in the SI are used when shift + arrows etc. - no it doesn't work .. the shifting on keyboard shortcuts is done with m_nTextureTweak - seems m_nTextureTweak is nowhere available in the prefs (and it's not in MFC builds either) - some cleanup to be done around that it seems -OK (.. merged with below, maybe some special cases left ..) texture widget (catch the Enter key to force-call an OnApply) -OK (.. see above ..) catch Enter key at dialog level to call OnDone -NO (.. it's clean, but thats too many lines of code ..) move the code that blokes updates to use gtk_signal_handler_block_by_func and gtk_signal_handler_block_by_func -OK shift + arrow must match the SI settings, -OK (FIXME .. not using the right scale (using the scale step instead! + add a button in SI to 'Match grid') -POSTPONED (.. m_nTextureTweak is used in the nudge commands .. - .. and nudge shortcuts are broken right now ..) get rid of m_nTextureTweak -+ SI and PI always on top! - -+ known issues: "Match Grid" is broken in BP mode - -now on the patch inspector (nightmare!): -OK (.. put it as readonly .. don't bother ..) texture name widget is screwed? -OK the spinners scheme doesn't work, the stuff in the dialog is the inc step and we just need arrows -OK get rid of the 'Type' dialog box -POSTPONED (.. can't do undo on PI without proper Undo module ..) add proper Done Apply Cancel with Undo -NO (.. too much work for something that sucks ..) make the changes reflect in the views when manipulating the entries -OK (.. using %g ..) cut down on the number of digits! -OK increment steps to be stored in the registry - -putting the Cancel stuff in the surface inspector: only based on the Undo code, no cancel settings to store -because we don't have actual storage of a current texdef (we only send alterations) BTW we should do that for -brushes as well -the patch inspector works by increments, Patch_SetTextureInfo to incrementally modify the patch. -we can still do some undo by having a texdef storing the changes and working together with the undo -if the undo is recognized, it means our current texdef increment is valid -no, we can't represent the combination of several increments scale and rotate in a single texdef.. -get rid of the undo code for now .. only Apply and Done left - -it seems it's still vastly broken when you select something. or is it on linux only? -need a LOT of testing and figuring it out!! -selecting a brush breaks totally.. (the texture screws up it seems) -does it attempt to change the texture of the selected object?? -also: it seems you can multiple select a same brush?? - -the UNDO code of the SURFACE INSPECTOR IS STILL BROKEN ???? -(ok I'm really screwed, time to sleep) --> can't reproduce now?? maybe it's linux specific problem, I can't tell - -FOUND A WAY TO REPRODUCE THE CRASH: -+ select brush -+ hit "Fit" -+ hit the shift spinners two times -OR: -+ select single face on brush -+ manually edit scale values --> maybe we have a problem with current texture? (NO) -it's some kind of infinite loop? we call UpdateSurfaceInspector from Select_Brush and bang! -no, it's a texdef from a face that got deleted -prolly that hooking the undo code in there screws up the selected faces stuff -if you undo a selected face operation, you end up with the whole brush selected. -but that does not necessarily explain why you remove the face at Undo_Start -ho well .. removed the undo buffering when selected faces and everything's better -would need to re-establish the right face selection after undo, might solve the problem -(actually you'd still need to have the settings point to the right object) - -From PJ about the 'Match Grid' stuff: textures are moved in pixels, not units. -We must rely on the current texture scale AND gridsize to compute the shift increment +OK. Again I would have liked to get a design document before it being done. Main functionalities we +need in the inspector: + +- Unifiy the inspector under a single dialog box, called with 'S' + +- Depending on what is currently selected, display several frames in the inspector: +only brushes -> surface inspector +only patches -> patch inspector +brushes & patches -> both +and later when brush primitives are mixed with regular brushes + plugin entities, raise whatever +additional inspector stuff we need + +- The camera view must update realtime when we change some parameters. + +- Get rid of the Apply button, use the Undo code to store settings when surface inspector is +raised. If user hits Cancel, call the undo stuff. + +- Use the message broadcasting stuff to keep the inspectors up to date when the user changes the +current selection. Be careful to keep the undo stuff in sync with the select / deselect operations. + +- Use a 3-state scheme to display the params in the widgets. If two faces are selected that don't +have the same shift increment, just grey out the shift box. + +Messaging: +- a good chunk of the work is moving the selection/creation stuff to the messaging API + we no longer use UpdateSurfaceDialog, we post messages instead .. + the surface inspector has hooked one of it's listeners into the corresponding message + we may need to reorganize the messages, maybe introduce a hierarchy? + or pass a void * param with messages? + +- we don't post messages like "update surface inspector", we post messages that say "this and that +have changed", then the surface inspector reacts if it needs to. +Do we need marshalling in the messages? Very likely .. maybe using Gtk signal stuff would be interesting? + +-> the messaging stuff is a big chunk of work and our surface inspector changes are not totally +dependent on it. Better leave that for l8r + +the inspector works by states and transitions? Or we post messages to it? +Use case: +the user raises the inspector .. if we are up we'll ignore, if we are hidden we'll +go through the whole process (initialise, look at what is selected, display) +then we enter an active state (listening for select / deselects and applying stuff) + +all in all it seems to be too big a change for next release. will see later probably. +Trying a few more days with it, see what happens. after all the interface is fairly restricted +so there's a good chance our changes are fairly stable in the end. But rebuilding the whole interface +part might be too much ... +We need something state based? AND a set of messages .. +but first, need to write the initialisation loop +build the dialog, get the current surface information and display + +Undoing the changes on the selected stuff: +at any point in time, one can get a snapshot of selected stuff and use it to store the surface +properties settings for later on. But what happens if the user modifies the selected brush, pushing +it in the undo stack? Then we would cancel the changes? (and just backup to the state right after +the modif) +We could has the 'Apply' button used for that .. grey it out when the current state is the one in +the backup. This happens whenever we hit 'Apply' or change something in the selection. +The selection has several items: entities, brushes and selected faces (possibly later generic plugin entities) +Current undo stuff is aimed at entities and brushes. +NOTE: you can't have selected faces and brushes/entities at the same time, that's a good point to +keep that seperated to deal with undo and storage +On what side should the implemetation be ? undo.cpp select.cpp or surfacedialog.cpp ? +We are going to do it with the messaging API anyway.. +And hook in the undo stuff, to reset the snapshot each time something gets pushed in the undo? + +We have advanced stuff on the Inspector branch, doing basics on Alpha branch. +Start writing the watch code in surfacedialog.cpp, see if we need some merging with Undo stuff l8r +We need to track for the patch inspector as well.. + +basic code for CSurfaceUndo written. need to add hooks for the snapshot stuff and undo stuff. and a +debug flag to monitor the life cycle of the object. + +some use cases: +- select a brush +- bring up surface inspector +- check we had the debug messages from CSurfaceUndo (initialise, activate, snapshot) +- edit the surface settings +- check the views are updating correctly +- hit Ok +- check we had a deactivate message +OK + +- select a brush +- bring up surface inspector +- check we had the debug messages from CSurfaceUndo (initialise, activate, snapshot) +- edit the surface settings +- check the views are updating correctly +- hit cancel / escape +- check we have a undo and deactivate from CSurfaceUndo +OK + +- select a brush +- bring up the surface inspector +- edit the surface settings +- hit apply +- edit them again +- hit cancel / escape +- check you get back to the apply state +OK + +- make two brushes +- select a brush +- bring up surface inspector +- change settings +- select an additional brush +- check the surface inspector, new snapshot +- hit cancel +- check brushes remained in the same state +- use standard Undo +- check the first brush got back to it's initial settings +OK + +- select a brush +- bring up surface inspector +- change settings +- select an additional brush +- check the surface inspector, new snapshot +- change more settings +- hit cancel +- check the first brush returned to intermediate state, and second to initial state (i.e. last snapshot) +OK + +g_surfaceUndo acts as a layer on top of the core Undo code when the surface inspector is activated. +We need it because the surface inspector can edit faces which are not handled by the undo? +(or does the current code push the whole brush when editing a face?) + +not sure of the utility of the g_surfaceDialog hooks here .. +default undo usage in the sruface inspector sends way too many undo messages. +with the new scheme we store in undo only when select/deselect or user hits apply +that way the 'Cancel' and later Ctrl+Z calls make sense +but is it worth implementing a new class to achieve that?? .. yes because we intend a later cleanup +of this part. (ahem is this reason good enough..) +this part is actually much closer from the undo code than I had expected.. +'Cancel' call being an Undo call.. + +going to Inspector3: +don't create a new class, simply use the Undo more intelligently? +i.e. don't create undo stuff when editing the brush +-> we add a flag to turn off the default undo behaviour and force Undo storage when we want +we could also store the undo Id we are interested in and call undo several times to get it back + +NOTE: what happens if the user hits undo when the surface inspector is up? +-> we'll have to take his request into account? +err .. performing which undo? The texture positioning or something else? +seems the snapshot approach would still make sense then? + +more use cases, see with Undo calls and select/deselect events +NOTE: this whole thing is probably a single call to select_settexture that needs to be turned on/off +instead of working at the undo level. but we would like to move to messaging so maybe it still makes sense +the undo call is in Select_SetTexture (which does not have that many callers, I was expecting more) + +the question about having the undo code keep working when surface inspector is around is still raised. +but it makes it a lot harder, gotta have a real inspector mode in the undo? +dunno, think about it again later + +two operations are mixed in a single one and should not be: +reading the map to get the current data we'll manipulate +feed it in the dialog box widgets +WARNING: when putting stuff in the widgets, it raises a shitload of update messages and therefor completely +fucks up our OnOK OnApply OnCancel scheme (specially OnApply!) + +NOTE: we want to switch between Surface inspector for brushes only and Patch inspector for patches only +there's some crappy code in the surface inspector that we need to get rid of +but need to check about that before with Spog or others + +Forcing the way into using the surface inspector is SCREWED? +Doesn't seem to work the way we want to. Always get parasite Undo messages and stuff. +We could use a seperate stack for Undo with the surface inspector? +Just store the surface properties in a seperate stack? +When user hits cancel you go back and apply whatever you had? +Doesn't seem like a clean way either. + +Now dealing with both regular surface inspector and patch inspector: +we have some stuff that needs to be on/off with the two inspectors +what about catching the messages and issuing new snapshots? +the main surface inspector is doing it? +no! +so what, we have several states? +FUCKED UP + +INSPECTOR 5 ---------------------------------------------------------------- +restarted from scratch, made much more simple changes. +trying another trick for undo (!) +just let the undo work as usual, but call undo ourselves in SetTexMods if we have create the last do +requires proper initialization/deinitialisation.. in SetTexMods and GetTexMods.. + +getting rid of patch manipulation code in the regular surface inspector. The buttons will +still work, but manip will require the patch inspector. (seems the patch inspector doesn't have that +much success anyway) + +TODO: +OK get rid of patch stuff +OK get rid of the texture toolbar? (it's broken right now) + (and doesn't have anything usefull..) +OK (Partial) OnCancel? we need to cancel the texdef as well + store an undo texdef each time we grab new texdef stuff + this works in reverse than the Undo code? When we do the initial + problem is, in some cases the settings that show up are not in sync with what's in the inspector?? + (we can't avoid that because if a brush is selected there's no single setting) + prolly get it out as is and let Spog or others send feedback about what it's supposed to do.. + for now: store stuff in the cancel texdef when we initialize an undo loop + revert to that if OnCancel is used +OK message when spinning over a patch? +DUPLICATE (.. see below ..) check the increments we store in the SI are used when shift + arrows etc. + no it doesn't work .. the shifting on keyboard shortcuts is done with m_nTextureTweak + seems m_nTextureTweak is nowhere available in the prefs (and it's not in MFC builds either) + some cleanup to be done around that it seems +OK (.. merged with below, maybe some special cases left ..) texture widget (catch the Enter key to force-call an OnApply) +OK (.. see above ..) catch Enter key at dialog level to call OnDone +NO (.. it's clean, but thats too many lines of code ..) move the code that blokes updates to use gtk_signal_handler_block_by_func and gtk_signal_handler_block_by_func +OK shift + arrow must match the SI settings, +OK (FIXME .. not using the right scale (using the scale step instead! + add a button in SI to 'Match grid') +POSTPONED (.. m_nTextureTweak is used in the nudge commands .. + .. and nudge shortcuts are broken right now ..) get rid of m_nTextureTweak ++ SI and PI always on top! + ++ known issues: "Match Grid" is broken in BP mode + +now on the patch inspector (nightmare!): +OK (.. put it as readonly .. don't bother ..) texture name widget is screwed? +OK the spinners scheme doesn't work, the stuff in the dialog is the inc step and we just need arrows +OK get rid of the 'Type' dialog box +POSTPONED (.. can't do undo on PI without proper Undo module ..) add proper Done Apply Cancel with Undo +NO (.. too much work for something that sucks ..) make the changes reflect in the views when manipulating the entries +OK (.. using %g ..) cut down on the number of digits! +OK increment steps to be stored in the registry + +putting the Cancel stuff in the surface inspector: only based on the Undo code, no cancel settings to store +because we don't have actual storage of a current texdef (we only send alterations) BTW we should do that for +brushes as well +the patch inspector works by increments, Patch_SetTextureInfo to incrementally modify the patch. +we can still do some undo by having a texdef storing the changes and working together with the undo +if the undo is recognized, it means our current texdef increment is valid +no, we can't represent the combination of several increments scale and rotate in a single texdef.. +get rid of the undo code for now .. only Apply and Done left + +it seems it's still vastly broken when you select something. or is it on linux only? +need a LOT of testing and figuring it out!! +selecting a brush breaks totally.. (the texture screws up it seems) +does it attempt to change the texture of the selected object?? +also: it seems you can multiple select a same brush?? + +the UNDO code of the SURFACE INSPECTOR IS STILL BROKEN ???? +(ok I'm really screwed, time to sleep) +-> can't reproduce now?? maybe it's linux specific problem, I can't tell + +FOUND A WAY TO REPRODUCE THE CRASH: ++ select brush ++ hit "Fit" ++ hit the shift spinners two times +OR: ++ select single face on brush ++ manually edit scale values +-> maybe we have a problem with current texture? (NO) +it's some kind of infinite loop? we call UpdateSurfaceInspector from Select_Brush and bang! +no, it's a texdef from a face that got deleted +prolly that hooking the undo code in there screws up the selected faces stuff +if you undo a selected face operation, you end up with the whole brush selected. +but that does not necessarily explain why you remove the face at Undo_Start +ho well .. removed the undo buffering when selected faces and everything's better +would need to re-establish the right face selection after undo, might solve the problem +(actually you'd still need to have the settings point to the right object) + +From PJ about the 'Match Grid' stuff: textures are moved in pixels, not units. +We must rely on the current texture scale AND gridsize to compute the shift increment diff --git a/docs/developer/RegExp/replace.pl b/docs/developer/RegExp/replace.pl index 86bbb389..83d8a88c 100644 --- a/docs/developer/RegExp/replace.pl +++ b/docs/developer/RegExp/replace.pl @@ -1,17 +1,17 @@ -#!perl -rename("$ARGV[0]", "$ARGV[0].old"); -open(FILE, "$ARGV[0].old"); -open(OFILE, ">$ARGV[0]"); -while() -{ -if($. != $ARGV[1]) -{ -print OFILE; -next; -} -s/Sys_Printf \(/Sys_FPrintf \(SYS_VRB,/; -s/Sys_Printf\(/Sys_FPrintf \(SYS_VRB,/; -print OFILE; -} -close(OFILE); +#!perl +rename("$ARGV[0]", "$ARGV[0].old"); +open(FILE, "$ARGV[0].old"); +open(OFILE, ">$ARGV[0]"); +while() +{ +if($. != $ARGV[1]) +{ +print OFILE; +next; +} +s/Sys_Printf \(/Sys_FPrintf \(SYS_VRB,/; +s/Sys_Printf\(/Sys_FPrintf \(SYS_VRB,/; +print OFILE; +} +close(OFILE); close(FILE); \ No newline at end of file diff --git a/docs/developer/RegExp/tstscrpt.pl b/docs/developer/RegExp/tstscrpt.pl index 84e646d3..a7194b17 100644 --- a/docs/developer/RegExp/tstscrpt.pl +++ b/docs/developer/RegExp/tstscrpt.pl @@ -1,17 +1,17 @@ -#!perl -rename("brush.c", "brush.c.old"); -open(FILE, "brush.c.old"); -open(OFILE, ">brush.c"); -while() -{ -if($. != 150) -{ -print OFILE; -next; -} -s/Sys_Printf \(/Sys_FPrintf \(SYS_VRB,/; -s/Sys_Printf\(/Sys_FPrintf \(SYS_VRB,/; -print OFILE; -} -close(OFILE); +#!perl +rename("brush.c", "brush.c.old"); +open(FILE, "brush.c.old"); +open(OFILE, ">brush.c"); +while() +{ +if($. != 150) +{ +print OFILE; +next; +} +s/Sys_Printf \(/Sys_FPrintf \(SYS_VRB,/; +s/Sys_Printf\(/Sys_FPrintf \(SYS_VRB,/; +print OFILE; +} +close(OFILE); close(FILE); \ No newline at end of file diff --git a/docs/developer/XML.txt b/docs/developer/XML.txt index 2e2ef596..3523ef0e 100644 --- a/docs/developer/XML.txt +++ b/docs/developer/XML.txt @@ -1,27 +1,27 @@ -printf mess in q3map -(and in the libs) - -q3map: several breeds .. qprintf _printf printf -should all resolve to use a single Sys_Printf thing -and put #define printf .. - -for the static libs? need to use function pointers.. - -q3map uses common/cmdlib.c -Radiant links against cmdlib.lib based on libs/cmdlib/cmdlib.cpp - -but eventually we'll want to use the same Sys_Printf scheme in q3map AND Radiant? -qprintf and _printf are defined in common/cmdlib.c -BUT: modifying cmdlib would probably break bspc and other stuff that relies on it? - -moving q3map to use a custom version of cmdlib.c in q3map/cmdlib.c -removing the qprintf and _printf stuff, moving to a seperate printout.c file - -compiling libxml on win32: need to turn off a bunch of stuff. -problem: we got two xmlversion.h files?? -we can't get rid of using libxml/xmlversion.h, so the solution is to get rid of xmlversion.h -(add ../libxml to the paths) - -fuck! -we also compile some .c files from common/ ! --> create a common2/ dir .. +printf mess in q3map +(and in the libs) + +q3map: several breeds .. qprintf _printf printf +should all resolve to use a single Sys_Printf thing +and put #define printf .. + +for the static libs? need to use function pointers.. + +q3map uses common/cmdlib.c +Radiant links against cmdlib.lib based on libs/cmdlib/cmdlib.cpp + +but eventually we'll want to use the same Sys_Printf scheme in q3map AND Radiant? +qprintf and _printf are defined in common/cmdlib.c +BUT: modifying cmdlib would probably break bspc and other stuff that relies on it? + +moving q3map to use a custom version of cmdlib.c in q3map/cmdlib.c +removing the qprintf and _printf stuff, moving to a seperate printout.c file + +compiling libxml on win32: need to turn off a bunch of stuff. +problem: we got two xmlversion.h files?? +we can't get rid of using libxml/xmlversion.h, so the solution is to get rid of xmlversion.h +(add ../libxml to the paths) + +fuck! +we also compile some .c files from common/ ! +-> create a common2/ dir .. diff --git a/docs/developer/XMLPush/ReadMe.txt b/docs/developer/XMLPush/ReadMe.txt index f2c6ab49..395608d7 100644 --- a/docs/developer/XMLPush/ReadMe.txt +++ b/docs/developer/XMLPush/ReadMe.txt @@ -1,34 +1,34 @@ -======================================================================== - CONSOLE APPLICATION : XMLPush -======================================================================== - - -AppWizard has created this XMLPush application for you. - -This file contains a summary of what you will find in each of the files that -make up your XMLPush application. - -XMLPush.dsp - This file (the project file) contains information at the project level and - is used to build a single project or subproject. Other users can share the - project (.dsp) file, but they should export the makefiles locally. - -XMLPush.cpp - This is the main application source file. - - -///////////////////////////////////////////////////////////////////////////// -Other standard files: - -StdAfx.h, StdAfx.cpp - These files are used to build a precompiled header (PCH) file - named XMLPush.pch and a precompiled types file named StdAfx.obj. - - -///////////////////////////////////////////////////////////////////////////// -Other notes: - -AppWizard uses "TODO:" to indicate parts of the source code you -should add to or customize. - -///////////////////////////////////////////////////////////////////////////// +======================================================================== + CONSOLE APPLICATION : XMLPush +======================================================================== + + +AppWizard has created this XMLPush application for you. + +This file contains a summary of what you will find in each of the files that +make up your XMLPush application. + +XMLPush.dsp + This file (the project file) contains information at the project level and + is used to build a single project or subproject. Other users can share the + project (.dsp) file, but they should export the makefiles locally. + +XMLPush.cpp + This is the main application source file. + + +///////////////////////////////////////////////////////////////////////////// +Other standard files: + +StdAfx.h, StdAfx.cpp + These files are used to build a precompiled header (PCH) file + named XMLPush.pch and a precompiled types file named StdAfx.obj. + + +///////////////////////////////////////////////////////////////////////////// +Other notes: + +AppWizard uses "TODO:" to indicate parts of the source code you +should add to or customize. + +///////////////////////////////////////////////////////////////////////////// diff --git a/docs/developer/XMLmap.txt b/docs/developer/XMLmap.txt index a88dd7f9..07fe15a3 100644 --- a/docs/developer/XMLmap.txt +++ b/docs/developer/XMLmap.txt @@ -1,27 +1,27 @@ -XMLmap branch: - -need to move the map loading / saving code out in a module -what are the main dependencies? - -main functions to move out: -Map_LoadFile -Map_SaveFile -(and all their direct dependencies/call graph) -ex Entity_Parse Brush_Parse Entity_Write Brush_Write - -but? even changing to XML format we would need those functions too? -is it worth having the .map and .xmlmap through a same interface? - -what dependencies? --> active_brushes --> GetToken etc. --> LoadFile (load into a buffer) .. that's VFS right? - -first step: move some code out in map module and try to compile it.. -Map_LoadFile for example -or the whole map.cpp? - -first problem: entity_t is declared in entity.h, currently not available to -the plugin API. Clean way would be to create a wrapper, but speed says we -should move entity_t to qertypes.h.. - +XMLmap branch: + +need to move the map loading / saving code out in a module +what are the main dependencies? + +main functions to move out: +Map_LoadFile +Map_SaveFile +(and all their direct dependencies/call graph) +ex Entity_Parse Brush_Parse Entity_Write Brush_Write + +but? even changing to XML format we would need those functions too? +is it worth having the .map and .xmlmap through a same interface? + +what dependencies? +-> active_brushes +-> GetToken etc. +-> LoadFile (load into a buffer) .. that's VFS right? + +first step: move some code out in map module and try to compile it.. +Map_LoadFile for example +or the whole map.cpp? + +first problem: entity_t is declared in entity.h, currently not available to +the plugin API. Clean way would be to create a wrapper, but speed says we +should move entity_t to qertypes.h.. + diff --git a/docs/developer/data-driven-design.txt b/docs/developer/data-driven-design.txt index 698fa1b5..1c682995 100644 --- a/docs/developer/data-driven-design.txt +++ b/docs/developer/data-driven-design.txt @@ -1,76 +1,76 @@ -Listing of required modules and interfaces as an XML file -========================================================= - -Purpose: --------- - -Make the editor more data driven. Be able to specify during -startup the full running configuration of the editor: -- what modules to load -- general execution paths (i.e. what's in the project settings) -- configuration for the loaded modules -- user preferences - -Feature Requirements: ---------------------- - -This is primarily intended for multiple games support. A restart -of the editor may be required when going from one game to the -other, but otherwise it should read the XML file and initialize -the right modules and APIs from there. - -Don't have a clear view of what multiple games support is gonna -be like. Can list a few things: - -- some interfaces are required for startup in a given game mode. -That's primarily what the XML config file is there for. -For instance in Q3 you will require Q3 map format module -and Q1 will require Q1 map format module - -- some modules are to be ignored? that's primary intended to -avoid loading unneeded modules. - -- some plugins are loaded for all games? -- some plugins are only relevant for some games? -(those two suggest various installation paths for modules -and directory-based scan?) - -- a plugin might require some other APIs to complete it's loading -process (i.e. sending it's own XML description of required -interfaces). - -Constaints: ------------ - -We have a nasty collision between preferences / project settings -and XML requirements. All three things need to be unified in some way. -The long term target being to have a central installation location -for the editor, and independant packages for each game. - -What kind of difference is there between project settings and prefs? -Prefs would be user settings that survive throughout all games, -whereas project settings are per-game / per-mod configuration. Turns -out it's all a matter of loading the right configuration chunks at the -right time. - -Proposed implementation: ------------------------- - -Use key/values (== property bags) based on XML format for everything. -Use them on project settings, and user prefs. The only difference -between what would be project settings and what would be user pref -is in which game configuration they are loaded, and how they are used. - -Project templates: We have a particular syntax to build settings from -a 'template' version. Instead of loading a project template, we should -be selecting a template from a list. - -Default startup: If we are configured to load last project on startup, -load it .. otherwise display a list of games and templates? - -Module library: ---------------- - -The dynamic loading / interfaces sharing / pure virtual classes needs -to be implemented in a generic module. It should be the basis of the -editor startup process. +Listing of required modules and interfaces as an XML file +========================================================= + +Purpose: +-------- + +Make the editor more data driven. Be able to specify during +startup the full running configuration of the editor: +- what modules to load +- general execution paths (i.e. what's in the project settings) +- configuration for the loaded modules +- user preferences + +Feature Requirements: +--------------------- + +This is primarily intended for multiple games support. A restart +of the editor may be required when going from one game to the +other, but otherwise it should read the XML file and initialize +the right modules and APIs from there. + +Don't have a clear view of what multiple games support is gonna +be like. Can list a few things: + +- some interfaces are required for startup in a given game mode. +That's primarily what the XML config file is there for. +For instance in Q3 you will require Q3 map format module +and Q1 will require Q1 map format module + +- some modules are to be ignored? that's primary intended to +avoid loading unneeded modules. + +- some plugins are loaded for all games? +- some plugins are only relevant for some games? +(those two suggest various installation paths for modules +and directory-based scan?) + +- a plugin might require some other APIs to complete it's loading +process (i.e. sending it's own XML description of required +interfaces). + +Constaints: +----------- + +We have a nasty collision between preferences / project settings +and XML requirements. All three things need to be unified in some way. +The long term target being to have a central installation location +for the editor, and independant packages for each game. + +What kind of difference is there between project settings and prefs? +Prefs would be user settings that survive throughout all games, +whereas project settings are per-game / per-mod configuration. Turns +out it's all a matter of loading the right configuration chunks at the +right time. + +Proposed implementation: +------------------------ + +Use key/values (== property bags) based on XML format for everything. +Use them on project settings, and user prefs. The only difference +between what would be project settings and what would be user pref +is in which game configuration they are loaded, and how they are used. + +Project templates: We have a particular syntax to build settings from +a 'template' version. Instead of loading a project template, we should +be selecting a template from a list. + +Default startup: If we are configured to load last project on startup, +load it .. otherwise display a list of games and templates? + +Module library: +--------------- + +The dynamic loading / interfaces sharing / pure virtual classes needs +to be implemented in a generic module. It should be the basis of the +editor startup process. diff --git a/docs/developer/q3mapfeedback.txt b/docs/developer/q3mapfeedback.txt index 4831eb13..94e0038e 100644 --- a/docs/developer/q3mapfeedback.txt +++ b/docs/developer/q3mapfeedback.txt @@ -1,33 +1,33 @@ -** currently supported debug messages: - -* map leaked / pointfile information -+ tested - -* duplicate plane -+ tested - -* degenerate plane, mirrored plane -+ testing may not be necessary, exact same code as duplicate plane - -* mixed CONTENTS_DETAIL and CONTENTS_STRUCTURAL -- not tested! - -* fog brush has multiple visible sides -+ tested - -* WindingFromDrawSurf failed: MAX_POINTS_ON_WINDING exceeded -+ tested, only outputs a single point, would need much improvement - (TstMaps/western.map) - -* MAX_BUILD_SIDES -uses xml_Select as other warnings, switched xml_Select to error or warn -+ tested - -** to-be-added list (and associated test map file if any) - -* Node without a volume -* leaf with too many portals --> both in Desktop_p_leaf.map, contributed by y_lavanant@vistech.ie - -Mesh lightmap miscount +** currently supported debug messages: + +* map leaked / pointfile information ++ tested + +* duplicate plane ++ tested + +* degenerate plane, mirrored plane ++ testing may not be necessary, exact same code as duplicate plane + +* mixed CONTENTS_DETAIL and CONTENTS_STRUCTURAL +- not tested! + +* fog brush has multiple visible sides ++ tested + +* WindingFromDrawSurf failed: MAX_POINTS_ON_WINDING exceeded ++ tested, only outputs a single point, would need much improvement + (TstMaps/western.map) + +* MAX_BUILD_SIDES +uses xml_Select as other warnings, switched xml_Select to error or warn ++ tested + +** to-be-added list (and associated test map file if any) + +* Node without a volume +* leaf with too many portals +-> both in Desktop_p_leaf.map, contributed by y_lavanant@vistech.ie + +Mesh lightmap miscount (no test map) \ No newline at end of file diff --git a/docs/manual/quake3/Compile_Manual/bspc.txt b/docs/manual/quake3/Compile_Manual/bspc.txt index 90fd96d4..0547b97b 100644 --- a/docs/manual/quake3/Compile_Manual/bspc.txt +++ b/docs/manual/quake3/Compile_Manual/bspc.txt @@ -1,565 +1,565 @@ - - -Title: BSP Converter -Version: 2.1h -Date: 2001-03-28 -Author: Mr. Elusive - - -Description ------------ - -The BSPC tool is used to create AAS files from BSP files. -An AAS file is a file with areas used by the Quake III Arena bot in order -to navigate and understand a map. The Quake III Arena maps are stored in -BSP files. - - -Usage ------ - -bspc [- [- ...]] - -Example 1: bspc -bsp2aas d:\quake3\baseq3\maps\mymap?.bsp -Example 2: bspc -bsp2aas d:\quake3\baseq3\pak0.pk3\maps/q3dm*.bsp - -Switches: - bsp2aas <[pakfilter/]filter.bsp> = convert BSP to AAS - reach = compute reachability & clusters - cluster = compute clusters - aasopt = optimize aas file - output = set output path - threads = set number of threads to X - cfg = use this cfg file - optimize = enable optimization - noverbose = disable verbose output - breadthfirst = breadth first bsp building - nobrushmerge = don't merge brushes - freetree = free the bsp tree - nocsg = disables brush chopping - forcesidesvisible = force all sides to be visible - grapplereach = calculate grapple reachabilities - - -Several metacharacter may be used in the filter and pakfilter. - -* match any string of zero or more characters -? match any single character -[abc...] match any of the enclosed characters; a hyphen can - be used to specify a range (e.g. a-z, A-Z, 0-9) - -.pk3 files are accessed as if they are normal folders. For instance -use "d:\quake3\baseq3\pak0.pk3\maps/q3dm1.bsp" to access the -map q3dm1.bsp from the pak0.pk3 file. - -Multiple files may be listed after the switches bsp2map, bsp2aas, reach, -cluster and aasopt. - -If a BSP file is being converted to an AAS file and no output path -is entered on the command-line then the AAS file will automatically -be stored in the same folder as the BSP file. However if the BSP file -was stored in a .pk3 file then the AAS file will be stored in a folder -with the name 'maps' outside the .pk3 file. - - -Updating entity lump --------------------- - -If an AAS file is already available for a BSP file and you ONLY change -the entities inside this BSP file then you only have to recalculate the -reachabilities. This way you can move items, platforms etc. around -without the need to recalculate the whole AAS file which can save quite -some compile time. You can recalculate the reachabilities as follows: - -bspc -reach mymap.bsp - -Where mymap.bsp is the BSP file. The mymap.aas file has to be in the -same folder as mymap.bsp or should be in the output folder specified -with the -output option. - -Keep in mind that as soon as ANY geometry in the map changes the whole -AAS file HAS to be recalculated in order to play with bots. - -NOTE: -reach does not work on optimized .AAS files! -NOTE: don't use -reach when moving the position of doors. - - -Leaks ------ - -Just like there can be vis leaks in a map there can also be clipping -leaks. Two things can be wrong when the BSPC tool outputs that a map -leaks. - -1. There are no entities in the map at all, or all entities that are -actually in the map are placed in solid. In this case the BSPC tool -outputs "WARNING: no entities inside". (At least a player start entity -is needed to load a map.) - -2. There is a spot in the map where players can go outside the map -into the void. This is bad, players should never be able to fall out -of a level. In this case the BSPC tool outputs "WARNING: entity -reached from outside". The BSPC tool also writes a mymap.lin file -that can be loaded in the Q3Radiant editor to show lines that go -through the actual leak. - -Make sure the .lin file is stored in the same folder as where q3radiant -stores the .bsp file. Load the map in q3radiant and use the -menu -> File -> Pointfile... to load the .lin file. A thick red line -will be shown in the map. Follow this line to find the leak. - - -Map bounds ----------- - -Currently a map should be within the bounds (-65536, -65536, -65536) - -(65536, 65536, 65536) for the bspc tool to compile. These are the same -limits the q3map tool has. - - -Physics -------- - -The player bounding box is a 30 units by 30 units square with a height -of 56 units. If we assume 1.75 meters being the average height of a human -and a player in Quake III Arena being 56 units high we get 32 units = 1 meter. - -Maximum step height of a player is 18 units (just keep steps 16 units or -lower). - -The maximum water jump height for bots has been set to 18 units. (height -difference between water surface and the floor jumping onto). If the -waterjump height is made higher human players will have a hard time getting -out of the water. - -With normal gravity and without the quad the maximum rocket jump height is -around 280 units (you can sometimes jump a few units higher but this is a -safe value for reference). - -The maximum height for barriers the bots will jump on is 32 units. - -Some math to calculate some other values of interest: - -gravity = 800; -jump velocity = 270; -max vertical rocketjump velocity = 670; -max run velocity = 320; -max step height = 18; - -max jump height = 0.5 * gravity * (jumpvelocity/gravity)*(jumpvelocity/gravity); -max jump height = 45 units; -NOTE: even though this is the mathematical maximum jump height always keep -the the 32 units maximum barrier height for bots in mind when building maps. - -maximum horizontal jump distance over a gap from one spot to another both -at the same height: - -t = sqrt((maxjumpheight + maxstep) / (0.5 * gravity)); -t = 0.3986 seconds; -dist = maxrunvelocity * (t + jumpvelocity / gravity); -dist = 235 units; -Because players use a bounding box we can jump a full bounding box width -furter in the ideal case. (15 units at the jump start and 15 at the -landing place). -235 + 15 + 15 = 265 units. -Again this is the mathematical maximum which players can only reach under -ideal circumstances. - - -Optimizing a map for bspc -------------------------- - -Hint brushes have no effect on the bspc tool. Only solid, clip, liquid, -cluster portal and do not enter brushes are used by the bspc tool. - -The bspc tool outputs how many areas are created for a map. Less areas -is better. Often the number of areas can be reduced by adding additional -clip brushes. By adding these additional clip brushes the complexity -of the geometry used for collision can be reduced. Do not add clip -brushes in front of the complex geometry but get the complex shaped -geometry contained within these clip brushes. Things that should be -contained within clip brushes are small or complex shaped (often detail) -brushes and complex and twisted curves, but also more regular curves -can be placed within a clip brush. When containing a curve within a -clip brush it's preferred to place the whole curve within the clip -brush (not just part of the curve). -Note: you can make brushes or curves non-solid when they are contained -within *full* clip or *weap* clip brushes to speed up bspc calculations. - -Always try to align your geometry to the grids. Always use the largest -grid possible for alignment of your geometry. Also try to align the -back sides of brushes which may not be visible. The more brush sides -are aligned the better. This will also speed up bspc calculations. - -Align adjacent brushes as much as possible. Make sure no tiny faces are -created due to badly aligned brushes. - -Quite often there are places in a map that are visible to players -but that players can never get to. Players would be able to walk around there -but since players can never reach such places they will never actually -move around there. If players are never able to get to such places -it's better to put a large clip brush which encloses that whole space. -This will also speed up bspc calculations and reduce the number of areas -created by the bspc tool. - -Note: the number of areas relative to the map size tells something about -the navigation complexity for players in general (also human players). -Reducing the collision complexity for bots also makes the map easier to -navigate for human players - - -func_plat and func_bobbing --------------------------- - -When func_plat or func_bobbing entities are placed in a map the bots will -use them if possible. The bots assume they can stand on top of the bounding -box of the model used for the func_plat or func_bobbing entity. As a result -creating complex shaped func_plat or func_bobbing models is mostly a bad -idea. You have to make sure the bots (and players) can actually stand -everywhere ontop of the bounding box of the model. - - -Cluster Portals ---------------- - -A map is divided into areas. Several of these areas can be grouped together -to create a cluster. The clusters are seperated by cluster portals which are -areas themselves. One of the things the bot uses these clusters for is a -multi-level routing algorithm. When a map is efficiently divided up into -clusters bot calculations will be faster. - -several things to take into account: - -- The BSPC tool tries to create cluster portals automatically but additional - cluster portals can be created by placing "clusterportal" brushes. -- Cluster portals are manually created by placing "clusterportal" brushes - inside the map. -- Cluster portal brushes are a tool to optimize a map for CPU usage by the - bots. They are not needed for the bots to operate correctly. -- The "clusterportal" brushes should not be used outside the world hull. -- The cluster portals do not have any effect on vis. -- If a door is already sealed with an areaportal brush, a clusterportal is - not necessary there. (area portals are also used as cluster portals). -- Just like the area portals, the cluster portals must seal a space off - entirely from other areas. -- The cluster portal areas should seal off a cluster in a way that the only - path towards another cluster is through a cluster portal area. -- Only create cluster portals where people can walk or swim through. -- Don't create cluster portals in gaps in the floor. (people would fall through) -- If you have two sealed off clusters and you add a teleporter between them - then the two clusters will be merged again because of the teleporter. -- Cluster portals must seperate no more and no less than two (2) clusters. -- Try to create clusters with all the same number of 'reachability' areas. - for instance if the map has 5400 areas try to create 10 clusters with 540 - areas each, or 12 clusters with 450 areas each, etc. The BSPC tool lists - the number of reachability areas in each cluster. - With Q3A version 1.25 and up you can use /set bot_testclusters 1 on the - console and the area number and cluster number you're in will be printed - on the screen. These cluster number correspond to the cluster numbers - the BSPC tool prints. -- Minimize the number of clusters with only a few (less than 10) areas. -- When adding "cluster portal" brushes try to place them in places with - minimal geometric complexity. For instance place them inside convex door - openings or small hallways (not infront of door openings). Ideally the shape - of the face through which a player walks or swims into the cluster portal - is the same as the shape of the face through which a player leaves the - cluster portal. Also ideally the open space inside the cluster portal - brush is convex. -- Make cluster portals about 16 or 32 units thick or align them with - adjacent geometry. Don't make them too thick though. -- Minimize the total number of cluster portal areas at all times. The more - cluster portal areas you have the more CPU the bots need. -- Items have no effect at all on the creation of areas or clusters. - The same goes for item_botroam. - - -Do Not Enter areas ------------------- - -When bot navigation problems show up or you want to make sure a bot never tries -to go to a certain place "do not enter" brushes can be used. - -several things to take into account: - -- The "do not enter" brushes should not be used outside the world hull. -- The "do not enter" brush is Not a clip brush for the bot. -- The "do not enter" brush is a tool of last resort. Do not use it unless - there are serious navigation problems. -- The number of "do not enter" brushes should be minimized because these - brushes create additional areas for the bots. -- The "do not enter" brush will create a New area that the bot will try to - avoid. However if the bot somehow ends up in a "do not enter" area or there - is a valid goal inside the "do not enter" area then the bot is allowed to - go into and out of that area. So if the bot somehow gets in a "do not enter" - area the bot will be able to get out. - - -Bot roaming ------------ - -The item_botroam entity can be used when a bot does not roam the whole level -or prefers to go to only specific areas. This (invisible) item can be placed -in a map just like regular items. Nobody can actually pick up the item it's -only used to attract bots to certain places of the map. The item_botroam has -a key "origin". The value is set by Q3Radiant automatically. The item_botroam -also has a key "weight". The value is the weight of the roam item and is -relative to the weight of other items in the map. The bot character specific -item weights are stored with the bot characters in the botfiles/bots/ sub-folder -in the .pk3 file. The value of the weight is a non-zero floating point value, -most often in the range 0 to 400. (Higher values are allowed but keep in mind -that the bot should also still go for normal items, so don't make the -item_botroam weight to high.) - -When a bot should never go for a specific item the key "notbot" with value "1" -can be used for that item. This key with value can be used for every available -item in Quake III Arena. - -The suspended flag can be used on all items (item_botroam included). -However keep in mind that when a suspended item is not anywhere near the -ground the bot will ONLY try to go for this suspended item using jump pads. - - -Team based entities -------------------- - -You can use the "bot_notteam" entity key with value "1" or "2" on teleporters -(trigger_teleport or trigger_multiple pointing at a target_teleporter), -elevators (func_plat), cyclic movers (func_bobbing), jumppads (trigger_push) -and areas that hurt the player (trigger_hurt). -When "notteam" is set to "1" only bots using the travel flag TFL_NOTTEAM1 will -use the entity or move through the area. When "bot_notteam" is set to "2" only -bots using the travel flag TFL_NOTTEAM2 will use the entity or move through the -area. These travel flags can be used in the game source code. Using this entity -key also only has effect if the mod the map is being made for supports team based -navigation for bots. - - -Testing AAS files ------------------ - -One of the easiest ways to test the AAS file is to load the map in -Quake3 in teamplay mode (type /set g_gametype 3 on the console before -loading the map). Enter a team and add a bot to your team. Use the -team order menu (by default bound to the key F3) to command the bot -to follow you. Walk around the map and see if the bot is able to -follow you everywhere. - -Map bugs can sometimes cause certain places in the map to show up -'solid' in the AAS file. The bots cannot travel through these 'solid' -areas. To test for these 'solid' places set the cvar bot_testsolid -to 1 on the console. (type /set bot_testsolid 1) The map has to be -started with devmap instead of map before the cvar bot_testsolid can -be set. When the cvar is set to 1 then either "empty area" or -"SOLID area" will be printed on the screen while traveling through a map. -Several map bugs can cause these 'solid' places in the AAS file. -- Sometimes microscopic brushes are left over after a brush CSG. Search - for such brushes in the problem area and delete them. -- Tiny brush faces (not curves) can also cause problems. Due to vertex - snapping in the q3map tool those tiny brush faces can be snapped out - of existence. Such faces will not show up in Quake3 and you'll see - tiny peek holes or slits where you can view through the geometry. - Allign vertexes of and edges of adjacent brushes to remove and avoid - such tiny faces. Placing a clip brush in front of the face that is - snapped out of existence will also remove the 'solid' area but ofcourse - it's much better to remove the peek holes and slits. -- Another cause could be a brush with a collapsed side. Check how many - sides a brush has and how many sides actually have a surface. Rebuild - brushes with collapsed sides. -- All faces contained within liquid brushes using a shader without - "surfaceparm trans" set will be removed. Those contained surfaces will - not be visible and can cause the liquid to appear "solid" in the AAS file. - -If you insist creating an AAS file for a map with bugs then the option --forcesidesvisible can be used. This should fix all the problems with areas -showing up solid in the AAS file. However creating an AAS file with this -option takes a lot longer (often more than twice the normal compile time). - -Clusters can be tested with the cvar bot_testclusters. -(type "/set bot_testclusters 1" on the console) - -Jumppads can also be tested. Type the following on the Quake3 console -before loading your map: - -/set bot_maxdebugpolys 1024 -/set bot_visualizejumppads 1 -/set bot_forcereachability 1 - -Now load the map. A counter will be shown and goes from 0% to 100%. -When the counter has reached 100% type /set bot_debug 1 and -/set r_debugSurface 2 on the console. For every jumppad the -default arch of travel (without using air control) will be visualized. -This only works if your .aas file is not optimized. - - -Error messages --------------- - -Level designers should not worry too much about the following messages and/or warnings. The things reported are non fatal and won't cause any major problems. Some of the messages are just debug left overs. - -"AAS_CheckArea: area %d face %d is flipped\n" -"AAS_CheckArea: area %d center is %f %f %f\n" -"AAS_CheckFaceWindingPlane: face %d winding plane unequal to face plane\r\n" -"AAS_CheckFaceWindingPlane: face %d winding reversed\r\n" -"area %d face %d flipped: front area %d, back area %d\n" -"area %d face %d is tiny\r\n" -"face %d and %d, same front and back area but flipped planes\r\n" -"AAS_SplitFace: tiny back face\r\n" -"AAS_SplitFace: tiny back face\r\n" -"AAS_SplitArea: front area without faces\n" -"AAS_SplitArea: back area without faces\n" -"gsubdiv: area %d has a tiny winding\r\n" -"AAS_TestSplitPlane: tried face plane as splitter\n" -"found %d epsilon faces trying to split area %d\r\n" -"AAS_SplitArea: front area without faces\n" -"AAS_GetFace: face %d had degenerate edge %d-%d\r\n" -"AAS_GetFace: face %d was tiny\r\n" -"WARNING: huge winding\n" -"bogus brush after clip" -"split removed brush" -"split not on both sides" -"two tiny brushes\r\n" -"possible portal: %d\r\n" -"portal %d: area %d\r\n" -"WARNING: CM_GridPlane unresolvable\n" -"WARNING: CM_AddFacetBevels... invalid bevel\n" -"WARNING: CM_SetBorderInward: mixed plane sides\n" -"WARNING: bevel plane already used\n" -"trigger_multiple model = \"%s\"\n" -"trigger_teleport model = \"%s\"\n" -"found a trigger_push with velocity %f %f %f\n" -"AAS_TraceBoundingBox: stack overflow\n" -"AAS_TraceAreas: stack overflow\n" -"AAS_LinkEntity: stack overflow\n" -"MergeWindings: degenerate edge on winding %f %f %f\n" -"Warning: MergeWindings: front to back found twice\n" -"FindPlaneSeperatingWindings: winding1 non-convex\r\n" -"FindPlaneSeperatingWindings: winding2 non-convex\r\n" - - -When one of the following messages, errors or warnings is found then there is often something to be fixed. - -"WARNING! HashVec: point %f %f %f outside valid range\n" -"This should never happen!\n" - While storing the AAS file some vertex was found outside the valid map bounds. When this happens some part of the map is likely to have badly aligned brushes or weird shaped curves. Clipping off or rebuilding complex shapes often helps. -"trigger_push start solid\n" - The trigger_push start point is in solid. Try making the trigger_push brush a bit larger or move it around a bit. -"trigger_push without target entity %s\n" - Could not find the target entity of the trigger_push with the target field %s. -"trigger_push without time\n" - trigger_push entity found without "time" field. -"trigger_multiple not in any jump pad area\n" -"trigger_push not in any jump pad area\n" - A trigger_push entity was found not to be in any valid jumppad area. (the message states trigger_multiple but it should have been trigger_push) Try making the trigger_push brush a bit larger or move it around a bit. -"trigger_multiple at %1.0f %1.0f %1.0f without target\n" - A trigger multiple was found at the given coordinates without a "target" field. -"target_teleporter without target\n" - A target_teleporter entity was found without target field. -"trigger_teleport at %1.0f %1.0f %1.0f without target\n" - A trigger_teleport entity was found at the given coordinates without "target" field. -"teleporter without misc_teleporter_dest (%s)\n" - The destination of a teleporter with target field %s could not be found. -"teleporter destination (%s) without origin\n" - A teleporter destination with the target name %s was found without origin field. -"teleporter destination (%s) in solid\n" - A teleporter destination with the targetname %s was found to be in solid. -"teleported into slime or lava at dest %s\n" - A player would be pushed into slime or lave at the teleporter destination with the targetname %s. -"trigger_multiple not in any area\n" - A teleporter trigger was found not to be in any valid area. Try moving the trigger around a bit. -"func_plat without model\n" - A func_plat entity was found without model field. -"func_plat with invalid model number\n" - A func_plat entity was found with the model field set to some invalid number. -"func_bobbing without model\n" - A func_bobbing entity was found without model field. -"func_bobbing with invalid model number\n" - A func_bobbing entity was found with the model field set to some invalid number. -"%s in solid at (%1.1f %1.1f %1.1f)\n" - An item with classname %s was found to be in solid at the given coordinates. -"empty aas link heap\n" - Some part of the map has some rather complex clipping. Reduce the geometric complexity or use clip brushes to reduce the clipping complexity. -"too many entities in BSP file\n" - There are too many entities in the bsp file. -"error opening %s\n" - Could not create a new AAS file. Hard disk might be full. -"error writing lump %s\n" - Could not write an AAS lump to file. Hard disk might be full. - - - -Version Changes ---------------- - -2.1h (2001-03-28) - -- fixed crash bug - -2.1g (2001-02-18) - -- added bot_notteam support on trigger_hurt entities - - -2.1f (2001-02-06) - -- added some AAS statistics -- don't flood through faces when creating clusters - - -2.1e (2001-01-10) - -- fix map size limitation - - -2.1d (2000-12-17) - -- renamed "notteam" to "bot_notteam" - - -2.1c (2000-11-02) - -- added fs_maxfallheight -- compiled with larger map size bounds - - -2.1b (2000-09-15) - -- fixed cfg file loading - - -2.1 (2000-06-28) - -- added model numbers for AREACONTENTS_MOVER -- added team based func_plat, func_bobbing, trigger_teleport and trigger_push reachabilities - - -2.0 (2000-06-21) - -- fixed swim reachabilities -- fixed some reachabilities through cluster portals -- fixed jump reachabilities -- changed some start travel times -- added travel time settings to cfg - - -1.9 (2000-03-27) - -- fixed func_bobbing entities with origin brush - - -1.8 (2000-01-14) - -- fixed trigger_teleport bug. -- increased max map bounds to (-8192, -8192, -8192)-(8192, 8192, 8192) -- increased max points on winding -- made "HashVec: point x y z outside valid range" non-fatal -- fixed rocket jump reachabilities -- added force sides visible option -- increased simulated stack size for area traces - - -1.7 (1999-12-22) - -- fixed ducked bounding box size -- fixed sv_maxsteepness being zero in aas configuration -- AAS files are now automatically stored in BSP file folder -- fixed crash bug caused by overflow of a simulated stack + + +Title: BSP Converter +Version: 2.1h +Date: 2001-03-28 +Author: Mr. Elusive + + +Description +----------- + +The BSPC tool is used to create AAS files from BSP files. +An AAS file is a file with areas used by the Quake III Arena bot in order +to navigate and understand a map. The Quake III Arena maps are stored in +BSP files. + + +Usage +----- + +bspc [- [- ...]] + +Example 1: bspc -bsp2aas d:\quake3\baseq3\maps\mymap?.bsp +Example 2: bspc -bsp2aas d:\quake3\baseq3\pak0.pk3\maps/q3dm*.bsp + +Switches: + bsp2aas <[pakfilter/]filter.bsp> = convert BSP to AAS + reach = compute reachability & clusters + cluster = compute clusters + aasopt = optimize aas file + output = set output path + threads = set number of threads to X + cfg = use this cfg file + optimize = enable optimization + noverbose = disable verbose output + breadthfirst = breadth first bsp building + nobrushmerge = don't merge brushes + freetree = free the bsp tree + nocsg = disables brush chopping + forcesidesvisible = force all sides to be visible + grapplereach = calculate grapple reachabilities + + +Several metacharacter may be used in the filter and pakfilter. + +* match any string of zero or more characters +? match any single character +[abc...] match any of the enclosed characters; a hyphen can + be used to specify a range (e.g. a-z, A-Z, 0-9) + +.pk3 files are accessed as if they are normal folders. For instance +use "d:\quake3\baseq3\pak0.pk3\maps/q3dm1.bsp" to access the +map q3dm1.bsp from the pak0.pk3 file. + +Multiple files may be listed after the switches bsp2map, bsp2aas, reach, +cluster and aasopt. + +If a BSP file is being converted to an AAS file and no output path +is entered on the command-line then the AAS file will automatically +be stored in the same folder as the BSP file. However if the BSP file +was stored in a .pk3 file then the AAS file will be stored in a folder +with the name 'maps' outside the .pk3 file. + + +Updating entity lump +-------------------- + +If an AAS file is already available for a BSP file and you ONLY change +the entities inside this BSP file then you only have to recalculate the +reachabilities. This way you can move items, platforms etc. around +without the need to recalculate the whole AAS file which can save quite +some compile time. You can recalculate the reachabilities as follows: + +bspc -reach mymap.bsp + +Where mymap.bsp is the BSP file. The mymap.aas file has to be in the +same folder as mymap.bsp or should be in the output folder specified +with the -output option. + +Keep in mind that as soon as ANY geometry in the map changes the whole +AAS file HAS to be recalculated in order to play with bots. + +NOTE: -reach does not work on optimized .AAS files! +NOTE: don't use -reach when moving the position of doors. + + +Leaks +----- + +Just like there can be vis leaks in a map there can also be clipping +leaks. Two things can be wrong when the BSPC tool outputs that a map +leaks. + +1. There are no entities in the map at all, or all entities that are +actually in the map are placed in solid. In this case the BSPC tool +outputs "WARNING: no entities inside". (At least a player start entity +is needed to load a map.) + +2. There is a spot in the map where players can go outside the map +into the void. This is bad, players should never be able to fall out +of a level. In this case the BSPC tool outputs "WARNING: entity +reached from outside". The BSPC tool also writes a mymap.lin file +that can be loaded in the Q3Radiant editor to show lines that go +through the actual leak. + +Make sure the .lin file is stored in the same folder as where q3radiant +stores the .bsp file. Load the map in q3radiant and use the +menu -> File -> Pointfile... to load the .lin file. A thick red line +will be shown in the map. Follow this line to find the leak. + + +Map bounds +---------- + +Currently a map should be within the bounds (-65536, -65536, -65536) - +(65536, 65536, 65536) for the bspc tool to compile. These are the same +limits the q3map tool has. + + +Physics +------- + +The player bounding box is a 30 units by 30 units square with a height +of 56 units. If we assume 1.75 meters being the average height of a human +and a player in Quake III Arena being 56 units high we get 32 units = 1 meter. + +Maximum step height of a player is 18 units (just keep steps 16 units or +lower). + +The maximum water jump height for bots has been set to 18 units. (height +difference between water surface and the floor jumping onto). If the +waterjump height is made higher human players will have a hard time getting +out of the water. + +With normal gravity and without the quad the maximum rocket jump height is +around 280 units (you can sometimes jump a few units higher but this is a +safe value for reference). + +The maximum height for barriers the bots will jump on is 32 units. + +Some math to calculate some other values of interest: + +gravity = 800; +jump velocity = 270; +max vertical rocketjump velocity = 670; +max run velocity = 320; +max step height = 18; + +max jump height = 0.5 * gravity * (jumpvelocity/gravity)*(jumpvelocity/gravity); +max jump height = 45 units; +NOTE: even though this is the mathematical maximum jump height always keep +the the 32 units maximum barrier height for bots in mind when building maps. + +maximum horizontal jump distance over a gap from one spot to another both +at the same height: + +t = sqrt((maxjumpheight + maxstep) / (0.5 * gravity)); +t = 0.3986 seconds; +dist = maxrunvelocity * (t + jumpvelocity / gravity); +dist = 235 units; +Because players use a bounding box we can jump a full bounding box width +furter in the ideal case. (15 units at the jump start and 15 at the +landing place). +235 + 15 + 15 = 265 units. +Again this is the mathematical maximum which players can only reach under +ideal circumstances. + + +Optimizing a map for bspc +------------------------- + +Hint brushes have no effect on the bspc tool. Only solid, clip, liquid, +cluster portal and do not enter brushes are used by the bspc tool. + +The bspc tool outputs how many areas are created for a map. Less areas +is better. Often the number of areas can be reduced by adding additional +clip brushes. By adding these additional clip brushes the complexity +of the geometry used for collision can be reduced. Do not add clip +brushes in front of the complex geometry but get the complex shaped +geometry contained within these clip brushes. Things that should be +contained within clip brushes are small or complex shaped (often detail) +brushes and complex and twisted curves, but also more regular curves +can be placed within a clip brush. When containing a curve within a +clip brush it's preferred to place the whole curve within the clip +brush (not just part of the curve). +Note: you can make brushes or curves non-solid when they are contained +within *full* clip or *weap* clip brushes to speed up bspc calculations. + +Always try to align your geometry to the grids. Always use the largest +grid possible for alignment of your geometry. Also try to align the +back sides of brushes which may not be visible. The more brush sides +are aligned the better. This will also speed up bspc calculations. + +Align adjacent brushes as much as possible. Make sure no tiny faces are +created due to badly aligned brushes. + +Quite often there are places in a map that are visible to players +but that players can never get to. Players would be able to walk around there +but since players can never reach such places they will never actually +move around there. If players are never able to get to such places +it's better to put a large clip brush which encloses that whole space. +This will also speed up bspc calculations and reduce the number of areas +created by the bspc tool. + +Note: the number of areas relative to the map size tells something about +the navigation complexity for players in general (also human players). +Reducing the collision complexity for bots also makes the map easier to +navigate for human players + + +func_plat and func_bobbing +-------------------------- + +When func_plat or func_bobbing entities are placed in a map the bots will +use them if possible. The bots assume they can stand on top of the bounding +box of the model used for the func_plat or func_bobbing entity. As a result +creating complex shaped func_plat or func_bobbing models is mostly a bad +idea. You have to make sure the bots (and players) can actually stand +everywhere ontop of the bounding box of the model. + + +Cluster Portals +--------------- + +A map is divided into areas. Several of these areas can be grouped together +to create a cluster. The clusters are seperated by cluster portals which are +areas themselves. One of the things the bot uses these clusters for is a +multi-level routing algorithm. When a map is efficiently divided up into +clusters bot calculations will be faster. + +several things to take into account: + +- The BSPC tool tries to create cluster portals automatically but additional + cluster portals can be created by placing "clusterportal" brushes. +- Cluster portals are manually created by placing "clusterportal" brushes + inside the map. +- Cluster portal brushes are a tool to optimize a map for CPU usage by the + bots. They are not needed for the bots to operate correctly. +- The "clusterportal" brushes should not be used outside the world hull. +- The cluster portals do not have any effect on vis. +- If a door is already sealed with an areaportal brush, a clusterportal is + not necessary there. (area portals are also used as cluster portals). +- Just like the area portals, the cluster portals must seal a space off + entirely from other areas. +- The cluster portal areas should seal off a cluster in a way that the only + path towards another cluster is through a cluster portal area. +- Only create cluster portals where people can walk or swim through. +- Don't create cluster portals in gaps in the floor. (people would fall through) +- If you have two sealed off clusters and you add a teleporter between them + then the two clusters will be merged again because of the teleporter. +- Cluster portals must seperate no more and no less than two (2) clusters. +- Try to create clusters with all the same number of 'reachability' areas. + for instance if the map has 5400 areas try to create 10 clusters with 540 + areas each, or 12 clusters with 450 areas each, etc. The BSPC tool lists + the number of reachability areas in each cluster. + With Q3A version 1.25 and up you can use /set bot_testclusters 1 on the + console and the area number and cluster number you're in will be printed + on the screen. These cluster number correspond to the cluster numbers + the BSPC tool prints. +- Minimize the number of clusters with only a few (less than 10) areas. +- When adding "cluster portal" brushes try to place them in places with + minimal geometric complexity. For instance place them inside convex door + openings or small hallways (not infront of door openings). Ideally the shape + of the face through which a player walks or swims into the cluster portal + is the same as the shape of the face through which a player leaves the + cluster portal. Also ideally the open space inside the cluster portal + brush is convex. +- Make cluster portals about 16 or 32 units thick or align them with + adjacent geometry. Don't make them too thick though. +- Minimize the total number of cluster portal areas at all times. The more + cluster portal areas you have the more CPU the bots need. +- Items have no effect at all on the creation of areas or clusters. + The same goes for item_botroam. + + +Do Not Enter areas +------------------ + +When bot navigation problems show up or you want to make sure a bot never tries +to go to a certain place "do not enter" brushes can be used. + +several things to take into account: + +- The "do not enter" brushes should not be used outside the world hull. +- The "do not enter" brush is Not a clip brush for the bot. +- The "do not enter" brush is a tool of last resort. Do not use it unless + there are serious navigation problems. +- The number of "do not enter" brushes should be minimized because these + brushes create additional areas for the bots. +- The "do not enter" brush will create a New area that the bot will try to + avoid. However if the bot somehow ends up in a "do not enter" area or there + is a valid goal inside the "do not enter" area then the bot is allowed to + go into and out of that area. So if the bot somehow gets in a "do not enter" + area the bot will be able to get out. + + +Bot roaming +----------- + +The item_botroam entity can be used when a bot does not roam the whole level +or prefers to go to only specific areas. This (invisible) item can be placed +in a map just like regular items. Nobody can actually pick up the item it's +only used to attract bots to certain places of the map. The item_botroam has +a key "origin". The value is set by Q3Radiant automatically. The item_botroam +also has a key "weight". The value is the weight of the roam item and is +relative to the weight of other items in the map. The bot character specific +item weights are stored with the bot characters in the botfiles/bots/ sub-folder +in the .pk3 file. The value of the weight is a non-zero floating point value, +most often in the range 0 to 400. (Higher values are allowed but keep in mind +that the bot should also still go for normal items, so don't make the +item_botroam weight to high.) + +When a bot should never go for a specific item the key "notbot" with value "1" +can be used for that item. This key with value can be used for every available +item in Quake III Arena. + +The suspended flag can be used on all items (item_botroam included). +However keep in mind that when a suspended item is not anywhere near the +ground the bot will ONLY try to go for this suspended item using jump pads. + + +Team based entities +------------------- + +You can use the "bot_notteam" entity key with value "1" or "2" on teleporters +(trigger_teleport or trigger_multiple pointing at a target_teleporter), +elevators (func_plat), cyclic movers (func_bobbing), jumppads (trigger_push) +and areas that hurt the player (trigger_hurt). +When "notteam" is set to "1" only bots using the travel flag TFL_NOTTEAM1 will +use the entity or move through the area. When "bot_notteam" is set to "2" only +bots using the travel flag TFL_NOTTEAM2 will use the entity or move through the +area. These travel flags can be used in the game source code. Using this entity +key also only has effect if the mod the map is being made for supports team based +navigation for bots. + + +Testing AAS files +----------------- + +One of the easiest ways to test the AAS file is to load the map in +Quake3 in teamplay mode (type /set g_gametype 3 on the console before +loading the map). Enter a team and add a bot to your team. Use the +team order menu (by default bound to the key F3) to command the bot +to follow you. Walk around the map and see if the bot is able to +follow you everywhere. + +Map bugs can sometimes cause certain places in the map to show up +'solid' in the AAS file. The bots cannot travel through these 'solid' +areas. To test for these 'solid' places set the cvar bot_testsolid +to 1 on the console. (type /set bot_testsolid 1) The map has to be +started with devmap instead of map before the cvar bot_testsolid can +be set. When the cvar is set to 1 then either "empty area" or +"SOLID area" will be printed on the screen while traveling through a map. +Several map bugs can cause these 'solid' places in the AAS file. +- Sometimes microscopic brushes are left over after a brush CSG. Search + for such brushes in the problem area and delete them. +- Tiny brush faces (not curves) can also cause problems. Due to vertex + snapping in the q3map tool those tiny brush faces can be snapped out + of existence. Such faces will not show up in Quake3 and you'll see + tiny peek holes or slits where you can view through the geometry. + Allign vertexes of and edges of adjacent brushes to remove and avoid + such tiny faces. Placing a clip brush in front of the face that is + snapped out of existence will also remove the 'solid' area but ofcourse + it's much better to remove the peek holes and slits. +- Another cause could be a brush with a collapsed side. Check how many + sides a brush has and how many sides actually have a surface. Rebuild + brushes with collapsed sides. +- All faces contained within liquid brushes using a shader without + "surfaceparm trans" set will be removed. Those contained surfaces will + not be visible and can cause the liquid to appear "solid" in the AAS file. + +If you insist creating an AAS file for a map with bugs then the option +-forcesidesvisible can be used. This should fix all the problems with areas +showing up solid in the AAS file. However creating an AAS file with this +option takes a lot longer (often more than twice the normal compile time). + +Clusters can be tested with the cvar bot_testclusters. +(type "/set bot_testclusters 1" on the console) + +Jumppads can also be tested. Type the following on the Quake3 console +before loading your map: + +/set bot_maxdebugpolys 1024 +/set bot_visualizejumppads 1 +/set bot_forcereachability 1 + +Now load the map. A counter will be shown and goes from 0% to 100%. +When the counter has reached 100% type /set bot_debug 1 and +/set r_debugSurface 2 on the console. For every jumppad the +default arch of travel (without using air control) will be visualized. +This only works if your .aas file is not optimized. + + +Error messages +-------------- + +Level designers should not worry too much about the following messages and/or warnings. The things reported are non fatal and won't cause any major problems. Some of the messages are just debug left overs. + +"AAS_CheckArea: area %d face %d is flipped\n" +"AAS_CheckArea: area %d center is %f %f %f\n" +"AAS_CheckFaceWindingPlane: face %d winding plane unequal to face plane\r\n" +"AAS_CheckFaceWindingPlane: face %d winding reversed\r\n" +"area %d face %d flipped: front area %d, back area %d\n" +"area %d face %d is tiny\r\n" +"face %d and %d, same front and back area but flipped planes\r\n" +"AAS_SplitFace: tiny back face\r\n" +"AAS_SplitFace: tiny back face\r\n" +"AAS_SplitArea: front area without faces\n" +"AAS_SplitArea: back area without faces\n" +"gsubdiv: area %d has a tiny winding\r\n" +"AAS_TestSplitPlane: tried face plane as splitter\n" +"found %d epsilon faces trying to split area %d\r\n" +"AAS_SplitArea: front area without faces\n" +"AAS_GetFace: face %d had degenerate edge %d-%d\r\n" +"AAS_GetFace: face %d was tiny\r\n" +"WARNING: huge winding\n" +"bogus brush after clip" +"split removed brush" +"split not on both sides" +"two tiny brushes\r\n" +"possible portal: %d\r\n" +"portal %d: area %d\r\n" +"WARNING: CM_GridPlane unresolvable\n" +"WARNING: CM_AddFacetBevels... invalid bevel\n" +"WARNING: CM_SetBorderInward: mixed plane sides\n" +"WARNING: bevel plane already used\n" +"trigger_multiple model = \"%s\"\n" +"trigger_teleport model = \"%s\"\n" +"found a trigger_push with velocity %f %f %f\n" +"AAS_TraceBoundingBox: stack overflow\n" +"AAS_TraceAreas: stack overflow\n" +"AAS_LinkEntity: stack overflow\n" +"MergeWindings: degenerate edge on winding %f %f %f\n" +"Warning: MergeWindings: front to back found twice\n" +"FindPlaneSeperatingWindings: winding1 non-convex\r\n" +"FindPlaneSeperatingWindings: winding2 non-convex\r\n" + + +When one of the following messages, errors or warnings is found then there is often something to be fixed. + +"WARNING! HashVec: point %f %f %f outside valid range\n" +"This should never happen!\n" + While storing the AAS file some vertex was found outside the valid map bounds. When this happens some part of the map is likely to have badly aligned brushes or weird shaped curves. Clipping off or rebuilding complex shapes often helps. +"trigger_push start solid\n" + The trigger_push start point is in solid. Try making the trigger_push brush a bit larger or move it around a bit. +"trigger_push without target entity %s\n" + Could not find the target entity of the trigger_push with the target field %s. +"trigger_push without time\n" + trigger_push entity found without "time" field. +"trigger_multiple not in any jump pad area\n" +"trigger_push not in any jump pad area\n" + A trigger_push entity was found not to be in any valid jumppad area. (the message states trigger_multiple but it should have been trigger_push) Try making the trigger_push brush a bit larger or move it around a bit. +"trigger_multiple at %1.0f %1.0f %1.0f without target\n" + A trigger multiple was found at the given coordinates without a "target" field. +"target_teleporter without target\n" + A target_teleporter entity was found without target field. +"trigger_teleport at %1.0f %1.0f %1.0f without target\n" + A trigger_teleport entity was found at the given coordinates without "target" field. +"teleporter without misc_teleporter_dest (%s)\n" + The destination of a teleporter with target field %s could not be found. +"teleporter destination (%s) without origin\n" + A teleporter destination with the target name %s was found without origin field. +"teleporter destination (%s) in solid\n" + A teleporter destination with the targetname %s was found to be in solid. +"teleported into slime or lava at dest %s\n" + A player would be pushed into slime or lave at the teleporter destination with the targetname %s. +"trigger_multiple not in any area\n" + A teleporter trigger was found not to be in any valid area. Try moving the trigger around a bit. +"func_plat without model\n" + A func_plat entity was found without model field. +"func_plat with invalid model number\n" + A func_plat entity was found with the model field set to some invalid number. +"func_bobbing without model\n" + A func_bobbing entity was found without model field. +"func_bobbing with invalid model number\n" + A func_bobbing entity was found with the model field set to some invalid number. +"%s in solid at (%1.1f %1.1f %1.1f)\n" + An item with classname %s was found to be in solid at the given coordinates. +"empty aas link heap\n" + Some part of the map has some rather complex clipping. Reduce the geometric complexity or use clip brushes to reduce the clipping complexity. +"too many entities in BSP file\n" + There are too many entities in the bsp file. +"error opening %s\n" + Could not create a new AAS file. Hard disk might be full. +"error writing lump %s\n" + Could not write an AAS lump to file. Hard disk might be full. + + + +Version Changes +--------------- + +2.1h (2001-03-28) + +- fixed crash bug + +2.1g (2001-02-18) + +- added bot_notteam support on trigger_hurt entities + + +2.1f (2001-02-06) + +- added some AAS statistics +- don't flood through faces when creating clusters + + +2.1e (2001-01-10) + +- fix map size limitation + + +2.1d (2000-12-17) + +- renamed "notteam" to "bot_notteam" + + +2.1c (2000-11-02) + +- added fs_maxfallheight +- compiled with larger map size bounds + + +2.1b (2000-09-15) + +- fixed cfg file loading + + +2.1 (2000-06-28) + +- added model numbers for AREACONTENTS_MOVER +- added team based func_plat, func_bobbing, trigger_teleport and trigger_push reachabilities + + +2.0 (2000-06-21) + +- fixed swim reachabilities +- fixed some reachabilities through cluster portals +- fixed jump reachabilities +- changed some start travel times +- added travel time settings to cfg + + +1.9 (2000-03-27) + +- fixed func_bobbing entities with origin brush + + +1.8 (2000-01-14) + +- fixed trigger_teleport bug. +- increased max map bounds to (-8192, -8192, -8192)-(8192, 8192, 8192) +- increased max points on winding +- made "HashVec: point x y z outside valid range" non-fatal +- fixed rocket jump reachabilities +- added force sides visible option +- increased simulated stack size for area traces + + +1.7 (1999-12-22) + +- fixed ducked bounding box size +- fixed sv_maxsteepness being zero in aas configuration +- AAS files are now automatically stored in BSP file folder +- fixed crash bug caused by overflow of a simulated stack diff --git a/docs/manual/quake3/Compile_Manual/headskins.txt b/docs/manual/quake3/Compile_Manual/headskins.txt index 2418fd6b..bf45f9f5 100644 --- a/docs/manual/quake3/Compile_Manual/headskins.txt +++ b/docs/manual/quake3/Compile_Manual/headskins.txt @@ -1,75 +1,75 @@ -search orders with different settings - - -===================== -NON-TEAMPLAY -===================== - -------------------------------------------------- -headmodel = *callisto/lily - -models/players/heads/callisto/lily/head_default.skin -models/players/heads/callisto/head_lily.skin - - -------------------------------------------------- -headmodel = callisto/lily - -models/players/callisto/lily/head_default.skin -models/players/callisto/head_lily.skin -models/players/heads/callisto/lily/head_default.skin -models/players/heads/callisto/head_lily.skin - - - -===================== -Q3 TEAMPLAY -===================== - -------------------------------------------------- -team_headmodel = *callisto/lily -team = red - -models/players/heads/callisto/lily/head_red.skin -models/players/heads/callisto/head_red.skin - - -------------------------------------------------- -team_headmodel = callisto/lily -team = red - -models/players/callisto/lily/head_red.skin -models/players/callisto/head_red.skin -models/players/heads/callisto/lily/head_red.skin -models/players/heads/callisto/head_red.skin - - - -===================== -TA TEAMPLAY -===================== - -------------------------------------------------- -team_headmodel = *callisto/lily -team = red -teamName = Stroggs - -models/players/heads/callisto/lily/Stroggs/head_red.skin -models/players/heads/callisto/Stroggs/head_red.skin -models/players/heads/callisto/lily/head_red.skin -models/players/heads/callisto/head_red.skin - - -------------------------------------------------- -team_headmodel = callisto/lily -team = red -teamName = Stroggs - -models/players/callisto/lily/Stroggs/head_red.skin -models/players/callisto/Stroggs/head_red.skin -models/players/callisto/lily/head_red.skin -models/players/callisto/head_red.skin -models/players/heads/callisto/lily/Stroggs/head_red.skin -models/players/heads/callisto/Stroggs/head_red.skin -models/players/heads/callisto/lily/head_red.skin -models/players/heads/callisto/head_red.skin +search orders with different settings + + +===================== +NON-TEAMPLAY +===================== + +------------------------------------------------- +headmodel = *callisto/lily + +models/players/heads/callisto/lily/head_default.skin +models/players/heads/callisto/head_lily.skin + + +------------------------------------------------- +headmodel = callisto/lily + +models/players/callisto/lily/head_default.skin +models/players/callisto/head_lily.skin +models/players/heads/callisto/lily/head_default.skin +models/players/heads/callisto/head_lily.skin + + + +===================== +Q3 TEAMPLAY +===================== + +------------------------------------------------- +team_headmodel = *callisto/lily +team = red + +models/players/heads/callisto/lily/head_red.skin +models/players/heads/callisto/head_red.skin + + +------------------------------------------------- +team_headmodel = callisto/lily +team = red + +models/players/callisto/lily/head_red.skin +models/players/callisto/head_red.skin +models/players/heads/callisto/lily/head_red.skin +models/players/heads/callisto/head_red.skin + + + +===================== +TA TEAMPLAY +===================== + +------------------------------------------------- +team_headmodel = *callisto/lily +team = red +teamName = Stroggs + +models/players/heads/callisto/lily/Stroggs/head_red.skin +models/players/heads/callisto/Stroggs/head_red.skin +models/players/heads/callisto/lily/head_red.skin +models/players/heads/callisto/head_red.skin + + +------------------------------------------------- +team_headmodel = callisto/lily +team = red +teamName = Stroggs + +models/players/callisto/lily/Stroggs/head_red.skin +models/players/callisto/Stroggs/head_red.skin +models/players/callisto/lily/head_red.skin +models/players/callisto/head_red.skin +models/players/heads/callisto/lily/Stroggs/head_red.skin +models/players/heads/callisto/Stroggs/head_red.skin +models/players/heads/callisto/lily/head_red.skin +models/players/heads/callisto/head_red.skin diff --git a/docs/manual/quake3/Compile_Manual/modelskins.txt b/docs/manual/quake3/Compile_Manual/modelskins.txt index 6c253559..b0f4a011 100644 --- a/docs/manual/quake3/Compile_Manual/modelskins.txt +++ b/docs/manual/quake3/Compile_Manual/modelskins.txt @@ -1,73 +1,73 @@ -search orders with different settings - - -===================== -NON-TEAMPLAY -===================== - -------------------------------------------------- -model = hunter/harpy - - -legs: - models/players/hunter/lower_harpy_default.skin - models/players/hunter/lower_harpy.skin - models/players/characters/james/lower_harpy_default.skin - models/players/characters/james/lower_harpy.skin -torso: - models/players/hunter/upper_harpy_default.skin - models/players/hunter/upper_harpy.skin - models/players/characters/hunter/upper_harpy_default.skin - models/players/characters/hunter/upper_harpy.skin - - -===================== -Q3 TEAMPLAY -===================== - -------------------------------------------------- -team_model = hunter/harpy -team = red - -legs: - models/players/hunter/lower_harpy_red.skin - models/players/hunter/lower_red.skin - models/players/characters/hunter/lower_harpy_red.skin - models/players/characters/hunter/lower_red.skin -torso: - models/players/hunter/upper_harpy_red.skin - models/players/hunter/upper_red.skin - models/players/characters/hunter/upper_harpy_red.skin - models/players/characters/hunter/upper_red.skin - - -===================== -TA TEAMPLAY -===================== - -------------------------------------------------- -team_model = james/badass -team = red -teamName = Stroggs - -legs: - models/players/james/Stroggs/lower_badass_red.skin - models/players/james/Stroggs/lower_red.skin - models/players/james/lower_badass_red.skin - models/players/james/lower_red.skin - models/players/characters/james/Stroggs/lower_badass_red.skin - models/players/characters/james/Stroggs/lower_red.skin - models/players/characters/james/lower_badass_red.skin - models/players/characters/james/lower_red.skin -torso: - models/players/james/Stroggs/upper_badass_red.skin - models/players/james/Stroggs/upper_red.skin - models/players/james/upper_badass_red.skin - models/players/james/upper_red.skin - models/players/characters/james/Stroggs/upper_badass_red.skin - models/players/characters/james/Stroggs/upper_red.skin - models/players/characters/james/upper_badass_red.skin - models/players/characters/james/upper_red.skin - - - +search orders with different settings + + +===================== +NON-TEAMPLAY +===================== + +------------------------------------------------- +model = hunter/harpy + + +legs: + models/players/hunter/lower_harpy_default.skin + models/players/hunter/lower_harpy.skin + models/players/characters/james/lower_harpy_default.skin + models/players/characters/james/lower_harpy.skin +torso: + models/players/hunter/upper_harpy_default.skin + models/players/hunter/upper_harpy.skin + models/players/characters/hunter/upper_harpy_default.skin + models/players/characters/hunter/upper_harpy.skin + + +===================== +Q3 TEAMPLAY +===================== + +------------------------------------------------- +team_model = hunter/harpy +team = red + +legs: + models/players/hunter/lower_harpy_red.skin + models/players/hunter/lower_red.skin + models/players/characters/hunter/lower_harpy_red.skin + models/players/characters/hunter/lower_red.skin +torso: + models/players/hunter/upper_harpy_red.skin + models/players/hunter/upper_red.skin + models/players/characters/hunter/upper_harpy_red.skin + models/players/characters/hunter/upper_red.skin + + +===================== +TA TEAMPLAY +===================== + +------------------------------------------------- +team_model = james/badass +team = red +teamName = Stroggs + +legs: + models/players/james/Stroggs/lower_badass_red.skin + models/players/james/Stroggs/lower_red.skin + models/players/james/lower_badass_red.skin + models/players/james/lower_red.skin + models/players/characters/james/Stroggs/lower_badass_red.skin + models/players/characters/james/Stroggs/lower_red.skin + models/players/characters/james/lower_badass_red.skin + models/players/characters/james/lower_red.skin +torso: + models/players/james/Stroggs/upper_badass_red.skin + models/players/james/Stroggs/upper_red.skin + models/players/james/upper_badass_red.skin + models/players/james/upper_red.skin + models/players/characters/james/Stroggs/upper_badass_red.skin + models/players/characters/james/Stroggs/upper_red.skin + models/players/characters/james/upper_badass_red.skin + models/players/characters/james/upper_red.skin + + + diff --git a/install.py b/install.py index 7d1807d8..cf0a74ba 100644 --- a/install.py +++ b/install.py @@ -1,48 +1,48 @@ -#!/usr/bin/env python - -import os.path, sys, shutil - -def install_file( path, src_path, f ): - src = os.path.join( src_path, f ) - dst = os.path.join( path, f ) - print '%s -> %s' % ( src, dst ) - shutil.copyfile( src, dst ) - -def install( path, src_path ): - for f in [ 'radiant.exe', 'radiant.pdb' ]: - install_file( path, src_path, f ) - - modules_path = os.path.join( path, 'modules' ) - try: - os.makedirs( modules_path ) - except: - pass - assert( os.path.exists( modules_path ) ) - - modules_src = os.path.join( src_path, 'modules' ) - assert( os.path.exists( modules_src ) ) - - for e in os.listdir( modules_src ): - if ( e[-4:] == '.dll' or e[-4:] == '.pdb' ): - install_file( modules_path, modules_src, e ) - - plugins_path = os.path.join( path, 'plugins' ) - try: - os.makedirs( plugins_path ) - except: - pass - assert( os.path.exists( plugins_path ) ) - - plugins_src = os.path.join( src_path, 'plugins' ) - assert( os.path.exists( plugins_src ) ) - - for e in os.listdir( plugins_src ): - if ( e[-4:] == '.dll' or e[-4:] == '.pdb' ): - install_file( plugins_path, plugins_src, e ) - -if __name__ == '__main__': - if ( len( sys.argv ) <= 2 or not os.path.exists( sys.argv[1] ) or not os.path.exists( sys.argv[2] ) ): - print 'usage: install [target directory] [source directory]' - sys.exit(1) - print 'Install %s into %s' % ( sys.argv[2], sys.argv[1] ) - install( sys.argv[1], sys.argv[2] ) +#!/usr/bin/env python + +import os.path, sys, shutil + +def install_file( path, src_path, f ): + src = os.path.join( src_path, f ) + dst = os.path.join( path, f ) + print '%s -> %s' % ( src, dst ) + shutil.copyfile( src, dst ) + +def install( path, src_path ): + for f in [ 'radiant.exe', 'radiant.pdb' ]: + install_file( path, src_path, f ) + + modules_path = os.path.join( path, 'modules' ) + try: + os.makedirs( modules_path ) + except: + pass + assert( os.path.exists( modules_path ) ) + + modules_src = os.path.join( src_path, 'modules' ) + assert( os.path.exists( modules_src ) ) + + for e in os.listdir( modules_src ): + if ( e[-4:] == '.dll' or e[-4:] == '.pdb' ): + install_file( modules_path, modules_src, e ) + + plugins_path = os.path.join( path, 'plugins' ) + try: + os.makedirs( plugins_path ) + except: + pass + assert( os.path.exists( plugins_path ) ) + + plugins_src = os.path.join( src_path, 'plugins' ) + assert( os.path.exists( plugins_src ) ) + + for e in os.listdir( plugins_src ): + if ( e[-4:] == '.dll' or e[-4:] == '.pdb' ): + install_file( plugins_path, plugins_src, e ) + +if __name__ == '__main__': + if ( len( sys.argv ) <= 2 or not os.path.exists( sys.argv[1] ) or not os.path.exists( sys.argv[2] ) ): + print 'usage: install [target directory] [source directory]' + sys.exit(1) + print 'Install %s into %s' % ( sys.argv[2], sys.argv[1] ) + install( sys.argv[1], sys.argv[2] ) diff --git a/libs/synapse/doc/design.txt b/libs/synapse/doc/design.txt index 3e8fd317..e3da4dc3 100644 --- a/libs/synapse/doc/design.txt +++ b/libs/synapse/doc/design.txt @@ -1,190 +1,190 @@ -synapse code design documentation -================================= - -Objective: ----------- - -Provide a simple cross platform layer to use dynamically loaded code -inside a core application. Portability intended to win32 / linux / MacOS (?) - -Main features are: - -- designed for single process only, no remote clients, no asynchronous processes -- a client/server architecture, based on configuration files: a main binary, - loading a set of shared objects - -Constraints: ------------- - -- large existing plugin code in Radiant! - must be compatible with minimal changes, specially for plugins (i.e. clients) - -- make things as much transparent as possible - (ideally, no real difference between a static linkage and dynamic linkage, - cf usage of #define macros to wrap a function call onto a code pointer) - -Features: ---------- - -Gather as much generic code as possible in a static .lib with minimal dependencies -(only dependency should be configuration files parser) - -NOTE: current effective dependency is STL / glib / xml - -Main executable implemented as a server, all others as clients. What has to -be done for a server / what has to be done for a client needs to be documented. -Provide as much scripts and tools and guidelines as needed (scripted generation of -some .h files?) - -Proposed implementation: ------------------------- - -- have linux/ and win32/ subdirectories with OS-specific implementations -(such as dynamically loading shared objects, and doing the initial query?) - -- reduce the API of a client to the minimum: one exported function? -provide a squeleton to make new clients easily? - -Server use case: -1) build information about location of the modules (from code and config files) -2) load all modules and query information about their APIs -NOTE: could read the APIs from some XML description files instead of -querying it from the modules? -3) build information about the required function tables -i.e.: setup a list with the function tables to be filled in, and what they -need to be filled in with. -4) resolve the function table -NOTE: is this iterative? will some plugins request more APIs as they get filled -up? -NOTE: do we have optional tables? -5) unload unreferences modules -NOTE: we don't expect to be unloading a LOT of modules, otherwise we would -setup a solution that allows exploring of the APIs a given module provides -from a file description. Or you could 'cache' that (md5-checksum the file, and -maintain an XML list). - -Client use case: -1) dynamically loaded -2) prompted for the interfaces it provides -2) prompted for the interfaces it requires -3) either unloaded, or told what interfaces have been filled in - -The client module exports an Synapse_EnumerateInterfaces entry point -This returns an ISynapseClient, which lists what the plugin provides, and what it requires - -The APIs: - -An interface is a function table, GUID / major string / minor string -GUID is a shortcut to reference a major string (i.e. the human readable thing) -the GUID / major string is unique for a given interface -minor string is used to reference a particular version of an API - (for instance when talking about image loading functionality, tga and jpg etc.) - -The GUID scheme is handy because it provides easy tests. They are not strictly -necessary but we will probably want to keep them. Should we extend to GUIDs -for minor too? - -Roadmap: --------- - -Need to convert the core (as server) and the required modules. Will have -clearer view of what's to be done along the way. - -Implementation design: ----------------------- - -There is a client and server side to synapse. Typically server is in Radiant or q3map, -client is in any module. For implementation, we have one server class and one client class. -It would be possible to have two seperate libraries, synapse-client and synapse-server. But -that only brings down the statically linked stuff to make things more complicated build-sysem -wise. - -Initial implementation has been using isynapse.h and synapse.h, to provide a pure virtual -base class for server and client. But that doesn't bring any major functionality, it's easier -if both sides see the full API of the client and server classes. - -A side problem is the diagnostic printing functionality. For easy debugging we require that -the synapse code can have access to a Sys_Printf or similar function at all times (that is for -client and server implementation). On client we will pipe through the main API to the server -as soon as we can in most cases. Using Sys_Printf would bring us to a dead end situation, since -when synapse is used as the server, the main code implements it's own Sys_Printf stuff. -Instead we introduce a local Syn_Printf implementation, which can be overriden in the server -to point to the appropriate print functions. - -Runtime config: ---------------- - -Something that has not been looked upon a lot yet, runtime configuration. What interfaces -are loaded etc. Ideally, from an XML config file. A client explicitely requests the -server to load all the interfaces it requires (in this case, the client is radiant or -q3map). - -Plugins are somewhat out of the 'required interfaces' frame, since they are loaded -whenever they are found. It is possible however that some plugins would not want to be -loaded in if the game doesn't match etc. in case they would need to access the global -config? - -In most cases a given API is only required once for editor functionality. (VFS for -instance), so our #define strategy for easy mapping of the functions should still work. - -Version checks, reference counting: ------------------------------------- - -Need version checking at several levels. A version string (major/minor) on the main API -entry point (straight in the exported function to save as much as possible for -compatibility). For individual APIs, we have been feeding the struct size into the first -int of the struct so far, and it has worked very well. - -Reference counting: we introduced class based APIs to solve the ref counting issues, -which are not easy to solve on C function tables. That problem would arise in plugin -situations where we might want to 'reload' or 'unload' some plugins. The server could -keep track of the ref count. - -Caching? --------- - -We are going to load every shared object we find and query it for it's interfaces. Then -we will unload the stuff we don't want. This is going to slow down the startup process. -We could extract the API information in a cache to avoid the loading step. - -Interfaces with multiple minors against I* objects? ---------------------------------------------------- - -Looking at the iimage.h API, why not having instead something that enumerates C++ objects -directly? Mainly because we want to be able to spread several minors accross multiple modules -and still use them together. And straight laid out function tables in C structs are only -one indirection when the table is static. - -This raises a broader topic, instead of requesting APIs, we could request objects directly. -Would that be of any use? - -Loading interfaces / resolving interdependencies strategy ---------------------------------------------------------- - -Some notes about how we load the modules and resolve interdependencies: - -We want to avoid requesting a module for an API it provides before all the APIs it requires -have been filled in (mostly stability concerns, a module may be doing whatever internally -when we request something from it). The exception being the module we are trying to resolve -for (since we need a start point for resolution). But in all likelyness we resolve for radiant -or q3map for instance. - -With this approach, it is possible that some situations could not be resolved, for instance: -Radiant - requires A - provides B -module 1 - requires C - provides A -module 2 - requires A - provides C -if we start by resolving Radiant, we will get stuck -if we are ready to ask module to provide the API even though the required is not meant, it would work -but that kind of situation is very unlikely, so sticking to safer strategy - -Configuration -------------- - -the config info needs to go down to the clients too +synapse code design documentation +================================= + +Objective: +---------- + +Provide a simple cross platform layer to use dynamically loaded code +inside a core application. Portability intended to win32 / linux / MacOS (?) + +Main features are: + +- designed for single process only, no remote clients, no asynchronous processes +- a client/server architecture, based on configuration files: a main binary, + loading a set of shared objects + +Constraints: +------------ + +- large existing plugin code in Radiant! + must be compatible with minimal changes, specially for plugins (i.e. clients) + +- make things as much transparent as possible + (ideally, no real difference between a static linkage and dynamic linkage, + cf usage of #define macros to wrap a function call onto a code pointer) + +Features: +--------- + +Gather as much generic code as possible in a static .lib with minimal dependencies +(only dependency should be configuration files parser) + +NOTE: current effective dependency is STL / glib / xml + +Main executable implemented as a server, all others as clients. What has to +be done for a server / what has to be done for a client needs to be documented. +Provide as much scripts and tools and guidelines as needed (scripted generation of +some .h files?) + +Proposed implementation: +------------------------ + +- have linux/ and win32/ subdirectories with OS-specific implementations +(such as dynamically loading shared objects, and doing the initial query?) + +- reduce the API of a client to the minimum: one exported function? +provide a squeleton to make new clients easily? + +Server use case: +1) build information about location of the modules (from code and config files) +2) load all modules and query information about their APIs +NOTE: could read the APIs from some XML description files instead of +querying it from the modules? +3) build information about the required function tables +i.e.: setup a list with the function tables to be filled in, and what they +need to be filled in with. +4) resolve the function table +NOTE: is this iterative? will some plugins request more APIs as they get filled +up? +NOTE: do we have optional tables? +5) unload unreferences modules +NOTE: we don't expect to be unloading a LOT of modules, otherwise we would +setup a solution that allows exploring of the APIs a given module provides +from a file description. Or you could 'cache' that (md5-checksum the file, and +maintain an XML list). + +Client use case: +1) dynamically loaded +2) prompted for the interfaces it provides +2) prompted for the interfaces it requires +3) either unloaded, or told what interfaces have been filled in + +The client module exports an Synapse_EnumerateInterfaces entry point +This returns an ISynapseClient, which lists what the plugin provides, and what it requires + +The APIs: + +An interface is a function table, GUID / major string / minor string +GUID is a shortcut to reference a major string (i.e. the human readable thing) +the GUID / major string is unique for a given interface +minor string is used to reference a particular version of an API + (for instance when talking about image loading functionality, tga and jpg etc.) + +The GUID scheme is handy because it provides easy tests. They are not strictly +necessary but we will probably want to keep them. Should we extend to GUIDs +for minor too? + +Roadmap: +-------- + +Need to convert the core (as server) and the required modules. Will have +clearer view of what's to be done along the way. + +Implementation design: +---------------------- + +There is a client and server side to synapse. Typically server is in Radiant or q3map, +client is in any module. For implementation, we have one server class and one client class. +It would be possible to have two seperate libraries, synapse-client and synapse-server. But +that only brings down the statically linked stuff to make things more complicated build-sysem +wise. + +Initial implementation has been using isynapse.h and synapse.h, to provide a pure virtual +base class for server and client. But that doesn't bring any major functionality, it's easier +if both sides see the full API of the client and server classes. + +A side problem is the diagnostic printing functionality. For easy debugging we require that +the synapse code can have access to a Sys_Printf or similar function at all times (that is for +client and server implementation). On client we will pipe through the main API to the server +as soon as we can in most cases. Using Sys_Printf would bring us to a dead end situation, since +when synapse is used as the server, the main code implements it's own Sys_Printf stuff. +Instead we introduce a local Syn_Printf implementation, which can be overriden in the server +to point to the appropriate print functions. + +Runtime config: +--------------- + +Something that has not been looked upon a lot yet, runtime configuration. What interfaces +are loaded etc. Ideally, from an XML config file. A client explicitely requests the +server to load all the interfaces it requires (in this case, the client is radiant or +q3map). + +Plugins are somewhat out of the 'required interfaces' frame, since they are loaded +whenever they are found. It is possible however that some plugins would not want to be +loaded in if the game doesn't match etc. in case they would need to access the global +config? + +In most cases a given API is only required once for editor functionality. (VFS for +instance), so our #define strategy for easy mapping of the functions should still work. + +Version checks, reference counting: +------------------------------------ + +Need version checking at several levels. A version string (major/minor) on the main API +entry point (straight in the exported function to save as much as possible for +compatibility). For individual APIs, we have been feeding the struct size into the first +int of the struct so far, and it has worked very well. + +Reference counting: we introduced class based APIs to solve the ref counting issues, +which are not easy to solve on C function tables. That problem would arise in plugin +situations where we might want to 'reload' or 'unload' some plugins. The server could +keep track of the ref count. + +Caching? +-------- + +We are going to load every shared object we find and query it for it's interfaces. Then +we will unload the stuff we don't want. This is going to slow down the startup process. +We could extract the API information in a cache to avoid the loading step. + +Interfaces with multiple minors against I* objects? +--------------------------------------------------- + +Looking at the iimage.h API, why not having instead something that enumerates C++ objects +directly? Mainly because we want to be able to spread several minors accross multiple modules +and still use them together. And straight laid out function tables in C structs are only +one indirection when the table is static. + +This raises a broader topic, instead of requesting APIs, we could request objects directly. +Would that be of any use? + +Loading interfaces / resolving interdependencies strategy +--------------------------------------------------------- + +Some notes about how we load the modules and resolve interdependencies: + +We want to avoid requesting a module for an API it provides before all the APIs it requires +have been filled in (mostly stability concerns, a module may be doing whatever internally +when we request something from it). The exception being the module we are trying to resolve +for (since we need a start point for resolution). But in all likelyness we resolve for radiant +or q3map for instance. + +With this approach, it is possible that some situations could not be resolved, for instance: +Radiant + requires A + provides B +module 1 + requires C + provides A +module 2 + requires A + provides C +if we start by resolving Radiant, we will get stuck +if we are ready to ask module to provide the API even though the required is not meant, it would work +but that kind of situation is very unlikely, so sticking to safer strategy + +Configuration +------------- + +the config info needs to go down to the clients too for instance, mapxml loaded for q3map or radiant, doesn't rely on the same major? \ No newline at end of file diff --git a/libs/synapse/doc/runtime.txt b/libs/synapse/doc/runtime.txt index 7d21f2b2..fd376d5c 100644 --- a/libs/synapse/doc/runtime.txt +++ b/libs/synapse/doc/runtime.txt @@ -1,59 +1,59 @@ -XML config files for customized synapse initialization at runtime ------------------------------------------------------------------ - -Objective: ----------- - -We have to assign the minors of the APIs to function tables -(and possibly to the API managers) at runtime from some config files. - -For instance in Q3 or RTCW mode, we will want to fill in -g_FileSystemTable and g_ShadersTable with the "quake3" minor. Whereas -those tables will be filled in with a different minor for HL mode. - -This affects SYN_REQUIRE for all the clients of the system, so that -config will need to be global and passed around to the clients. - -Implementation: ---------------- - -an XML hierarchy to describe the APIs: - - - quake3 - - - quake3 - - .. - - - - - -Each client will have to be identified by a specific name, if a name in the -config is not found in the client list, the init should fail. A client can -still be hardcoded and not appear in this list though. -(a GetName() function to synapse client) - -SYN_REQUIRE_ANY support will work for strict API lists. Just the same way -we do the simple SYN_REQUIRE - -Discussion: ------------ - -We only deal with SYN_REQUIRE. It is possible that at some point we will want -to customize the SYN_PROVIDE too. For instance depending on the game mode, a -same module could provide two different minors. Couldn't provide the two minors -at the same time though, only one. - -Implementation: ---------------- - -Default config file will be synapse.config in the gametools path. We can override -this later with a custom line in the .game file. Should Synapse be able to operate -without this config file though, as it is looked up by the main program and handed -over to synapse before init? Possibly .. we'll just pass a NULL config node ptr - -Add the config file path to CSynpaseServer::Initialize, pass the loaded XML file to +XML config files for customized synapse initialization at runtime +----------------------------------------------------------------- + +Objective: +---------- + +We have to assign the minors of the APIs to function tables +(and possibly to the API managers) at runtime from some config files. + +For instance in Q3 or RTCW mode, we will want to fill in +g_FileSystemTable and g_ShadersTable with the "quake3" minor. Whereas +those tables will be filled in with a different minor for HL mode. + +This affects SYN_REQUIRE for all the clients of the system, so that +config will need to be global and passed around to the clients. + +Implementation: +--------------- + +an XML hierarchy to describe the APIs: + + + quake3 + + + quake3 + + .. + + + + + +Each client will have to be identified by a specific name, if a name in the +config is not found in the client list, the init should fail. A client can +still be hardcoded and not appear in this list though. +(a GetName() function to synapse client) + +SYN_REQUIRE_ANY support will work for strict API lists. Just the same way +we do the simple SYN_REQUIRE + +Discussion: +----------- + +We only deal with SYN_REQUIRE. It is possible that at some point we will want +to customize the SYN_PROVIDE too. For instance depending on the game mode, a +same module could provide two different minors. Couldn't provide the two minors +at the same time though, only one. + +Implementation: +--------------- + +Default config file will be synapse.config in the gametools path. We can override +this later with a custom line in the .game file. Should Synapse be able to operate +without this config file though, as it is looked up by the main program and handed +over to synapse before init? Possibly .. we'll just pass a NULL config node ptr + +Add the config file path to CSynpaseServer::Initialize, pass the loaded XML file to the clients. Do we need to wrap in an object with some convenience functions? \ No newline at end of file diff --git a/libs/synapse/doc/unload.txt b/libs/synapse/doc/unload.txt index 3f01f8c5..aa51dce8 100644 --- a/libs/synapse/doc/unload.txt +++ b/libs/synapse/doc/unload.txt @@ -1,85 +1,85 @@ -Release / Reload of modules ---------------------------- - -The 'not active' modules are unloaded after startup -Plugins should be allowed to be unloaded and reloaded on the fly -Modules too, when possible? - -Don't want to 'force' all plugins to have unload capabilities -Just has to be something specified at compile time wether or not they can unload 'cleanly' - -Dependency implications. When you release a module, you need to remove a number of interfaces. -If those interfaces are being used, can you explicitely ask for them to be unloaded? - -Also, problem with plugins breaking the startup process: -http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=441 - -The most important is to provide a clean shutdown method -What's the != between unload and shutdown? - -Means that the server proceeds to the shutdown, and nothing else is supposed to be making -calls through APIs post shutdown. - -Should be done in 3 steps: -#1 prepare shutdown, all APIs are active, just release and save all the stuff you want -#2 tell the modules to shutdown, i.e. release the APIs they point to? (at this point they can't call through anymore) -#3 force all things to be unloaded, warn about reference count problems - -What is different when we unload a module, and we want to keep the editor up? -All the interfaces obtained from this plugin need to be released -If some pure virtual classes have been obtained from this plugin, we need a mecanism to have them removed -Do we need a first path to check if the unload procedure is going to be allowed? - -For instance, a plugin that provides custom entities rendering etc. -Need to unload first, then need to reload (scan the map again, rebuild) - -Summing up, when doing a reload we need to keep track of the modules and let them know after the -module has been reloaded, so that the links can be rebuilt. When doing unload we need to do a -'check' pass prior to anything to know if the release is possible. Because it does not depend -on the module we unload, it depends on the other clients that use it. - -Objectives: ------------ - -- 'release check' of a module - walk through the interfaces this module has provided, and make sure the release will be possible -- 'release' of a module - actually drop all the interfaces. this should be done only after a 'release check' - if something fails here, we are in an unstable state and need to abort -- 'client shutdown' unused modules after initial startup - actual DLL unload / complete shutdown of the client interface - this comes after 'release check' and 'release' -- 'refresh' modules - 'release check', 'release', 'shutdown' and then, reload and build the links again -- 'core shutdown' - 'release' and force 'shutdown' of all clients - even if we encounter some interfaces that we are not able to release cleanly - force things and shutdown all clients - then the core process is ready to exit.. - -Constraints: ------------- - -- refresh and shutdown are sharing some code -- the 'release' part of a module refresh may not be always possible (that's what 'release check' is there for) -- 'core shutdown' has to be forced to happen, in the safest way possible obviously - -Implementation: ---------------- - -- 'client shutdown' comes first - this is used after initial startup, since we don't have to do a prior 'release' on those - this will be used in the 'core shutdown' and 'refresh' too -- then 'core shutdown' procedure? - that's the most urgent thing we need - but 'release check' and 'release' have to be written in and used during 'core shutdown' -- 'refresh' takes an essential part of the design, but that's not something we need to have written right now? - (it mostly relies on 'release check' 'release' 'client shutdown', and then reload and rebuild the links) - -'client shutdown': -this is server side code though, you tell the server 'shutdown this client' -we don't have to exchange anything with the client while we do that -(written initially for unload of unused modules after startup) - -'core shutdown': -is a shutdown of all clients +Release / Reload of modules +--------------------------- + +The 'not active' modules are unloaded after startup +Plugins should be allowed to be unloaded and reloaded on the fly +Modules too, when possible? + +Don't want to 'force' all plugins to have unload capabilities +Just has to be something specified at compile time wether or not they can unload 'cleanly' + +Dependency implications. When you release a module, you need to remove a number of interfaces. +If those interfaces are being used, can you explicitely ask for them to be unloaded? + +Also, problem with plugins breaking the startup process: +http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=441 + +The most important is to provide a clean shutdown method +What's the != between unload and shutdown? + +Means that the server proceeds to the shutdown, and nothing else is supposed to be making +calls through APIs post shutdown. + +Should be done in 3 steps: +#1 prepare shutdown, all APIs are active, just release and save all the stuff you want +#2 tell the modules to shutdown, i.e. release the APIs they point to? (at this point they can't call through anymore) +#3 force all things to be unloaded, warn about reference count problems + +What is different when we unload a module, and we want to keep the editor up? +All the interfaces obtained from this plugin need to be released +If some pure virtual classes have been obtained from this plugin, we need a mecanism to have them removed +Do we need a first path to check if the unload procedure is going to be allowed? + +For instance, a plugin that provides custom entities rendering etc. +Need to unload first, then need to reload (scan the map again, rebuild) + +Summing up, when doing a reload we need to keep track of the modules and let them know after the +module has been reloaded, so that the links can be rebuilt. When doing unload we need to do a +'check' pass prior to anything to know if the release is possible. Because it does not depend +on the module we unload, it depends on the other clients that use it. + +Objectives: +----------- + +- 'release check' of a module + walk through the interfaces this module has provided, and make sure the release will be possible +- 'release' of a module + actually drop all the interfaces. this should be done only after a 'release check' + if something fails here, we are in an unstable state and need to abort +- 'client shutdown' unused modules after initial startup + actual DLL unload / complete shutdown of the client interface + this comes after 'release check' and 'release' +- 'refresh' modules + 'release check', 'release', 'shutdown' and then, reload and build the links again +- 'core shutdown' + 'release' and force 'shutdown' of all clients + even if we encounter some interfaces that we are not able to release cleanly + force things and shutdown all clients + then the core process is ready to exit.. + +Constraints: +------------ + +- refresh and shutdown are sharing some code +- the 'release' part of a module refresh may not be always possible (that's what 'release check' is there for) +- 'core shutdown' has to be forced to happen, in the safest way possible obviously + +Implementation: +--------------- + +- 'client shutdown' comes first + this is used after initial startup, since we don't have to do a prior 'release' on those + this will be used in the 'core shutdown' and 'refresh' too +- then 'core shutdown' procedure? + that's the most urgent thing we need + but 'release check' and 'release' have to be written in and used during 'core shutdown' +- 'refresh' takes an essential part of the design, but that's not something we need to have written right now? + (it mostly relies on 'release check' 'release' 'client shutdown', and then reload and rebuild the links) + +'client shutdown': +this is server side code though, you tell the server 'shutdown this client' +we don't have to exchange anything with the client while we do that +(written initially for unload of unused modules after startup) + +'core shutdown': +is a shutdown of all clients diff --git a/makeversion.py b/makeversion.py index 89f02b6c..06c86312 100644 --- a/makeversion.py +++ b/makeversion.py @@ -1,72 +1,72 @@ -# version and about message management -# NOTE: this module is meant to be used on all platforms, it is not SCons centric - -# version: -# input: -# include/version.default -# output: -# include/version.h include/RADIANT_MAJOR include/RADIANT_MINOR -# the header is used by C/C++ code, the straight text file by setup - -# about message -# for non-official builds, we have a default message -# otherwise, use environment variable $RADIANT_ABOUTMSG -# input: -# include/aboutmsg.default -# or file pointed to by $RADIANT_ABOUTMSG if exists -# ouput: -# include/aboutmsg.h - -import sys, re, string, os - -def get_version(): - # version - f = open('include/version.default', 'r') - buffer = f.read() - line = string.split(buffer, '\n')[0] - f.close() - sys.stdout.write("version: %s\n" % line) - exp = re.compile('^1\\.([^\\.]*)\\.([0-9]*)') - (major, minor) = exp.findall(line)[0] - sys.stdout.write("minor: %s major: %s\n" % (minor, major)) - return (line, major, minor) - -# you can pass an optional message to append to aboutmsg -def radiant_makeversion(append_about): - (line, major, minor) = get_version() - f = open('include/version.h', 'w') - f.write('// generated header, see makeversion.py\n') - f.write('#define RADIANT_VERSION "%s"\n' % line) - f.write('#define RADIANT_MINOR_VERSION "%s"\n' % minor) - f.write('#define RADIANT_MAJOR_VERSION "%s"\n' % major) - f.close() - f = open('include/RADIANT_MINOR', 'w') - f.write(minor) - f.close() - f = open('include/RADIANT_MAJOR', 'w') - f.write(major) - f.close() - f = open('include/version', 'w') - f.write(line) - f.close() - # aboutmsg - aboutfile = 'include/aboutmsg.default' - if ( os.environ.has_key('RADIANT_ABOUTMSG') ): - aboutfile = os.environ['RADIANT_ABOUTMSG'] - sys.stdout.write("about message is in %s\n" % aboutfile) - f = open(aboutfile, 'r') - buffer = f.read() - line = string.split(buffer, '\n')[0] - f.close() - # optional additional message - if ( not append_about is None ): - line += append_about - sys.stdout.write("about: %s\n" % line) - f = open('include/aboutmsg.h', 'w') - f.write('// generated header, see makeversion.py\n') - f.write('#define RADIANT_ABOUTMSG "%s"\n' % line) - f.close() - -# can be used as module (scons build), or by direct call -if __name__ == '__main__': - radiant_makeversion(None) +# version and about message management +# NOTE: this module is meant to be used on all platforms, it is not SCons centric + +# version: +# input: +# include/version.default +# output: +# include/version.h include/RADIANT_MAJOR include/RADIANT_MINOR +# the header is used by C/C++ code, the straight text file by setup + +# about message +# for non-official builds, we have a default message +# otherwise, use environment variable $RADIANT_ABOUTMSG +# input: +# include/aboutmsg.default +# or file pointed to by $RADIANT_ABOUTMSG if exists +# ouput: +# include/aboutmsg.h + +import sys, re, string, os + +def get_version(): + # version + f = open('include/version.default', 'r') + buffer = f.read() + line = string.split(buffer, '\n')[0] + f.close() + sys.stdout.write("version: %s\n" % line) + exp = re.compile('^1\\.([^\\.]*)\\.([0-9]*)') + (major, minor) = exp.findall(line)[0] + sys.stdout.write("minor: %s major: %s\n" % (minor, major)) + return (line, major, minor) + +# you can pass an optional message to append to aboutmsg +def radiant_makeversion(append_about): + (line, major, minor) = get_version() + f = open('include/version.h', 'w') + f.write('// generated header, see makeversion.py\n') + f.write('#define RADIANT_VERSION "%s"\n' % line) + f.write('#define RADIANT_MINOR_VERSION "%s"\n' % minor) + f.write('#define RADIANT_MAJOR_VERSION "%s"\n' % major) + f.close() + f = open('include/RADIANT_MINOR', 'w') + f.write(minor) + f.close() + f = open('include/RADIANT_MAJOR', 'w') + f.write(major) + f.close() + f = open('include/version', 'w') + f.write(line) + f.close() + # aboutmsg + aboutfile = 'include/aboutmsg.default' + if ( os.environ.has_key('RADIANT_ABOUTMSG') ): + aboutfile = os.environ['RADIANT_ABOUTMSG'] + sys.stdout.write("about message is in %s\n" % aboutfile) + f = open(aboutfile, 'r') + buffer = f.read() + line = string.split(buffer, '\n')[0] + f.close() + # optional additional message + if ( not append_about is None ): + line += append_about + sys.stdout.write("about: %s\n" % line) + f = open('include/aboutmsg.h', 'w') + f.write('// generated header, see makeversion.py\n') + f.write('#define RADIANT_ABOUTMSG "%s"\n' % line) + f.close() + +# can be used as module (scons build), or by direct call +if __name__ == '__main__': + radiant_makeversion(None) diff --git a/plugins/eclassfgd/fgd.def b/plugins/eclassfgd/fgd.def index c628b525..7ca58d79 100644 --- a/plugins/eclassfgd/fgd.def +++ b/plugins/eclassfgd/fgd.def @@ -1,8 +1,8 @@ -; fgd.def : Declares the module parameters for the DLL. - -LIBRARY "FGD" -DESCRIPTION 'FGD Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; fgd.def : Declares the module parameters for the DLL. + +LIBRARY "FGD" +DESCRIPTION 'FGD Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/entity/entity.def b/plugins/entity/entity.def index 6a237542..6c40d040 100644 --- a/plugins/entity/entity.def +++ b/plugins/entity/entity.def @@ -1,8 +1,8 @@ -; entity.def : Declares the module parameters for the DLL. - -LIBRARY "ENTITY" -DESCRIPTION 'ENTITY Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; entity.def : Declares the module parameters for the DLL. + +LIBRARY "ENTITY" +DESCRIPTION 'ENTITY Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/image/image.def b/plugins/image/image.def index 18bc1096..77635858 100644 --- a/plugins/image/image.def +++ b/plugins/image/image.def @@ -1,8 +1,8 @@ -; image.def : Declares the module parameters for the DLL. - -LIBRARY "Image" -DESCRIPTION 'Image Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; image.def : Declares the module parameters for the DLL. + +LIBRARY "Image" +DESCRIPTION 'Image Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/imagehl/imagehl.def b/plugins/imagehl/imagehl.def index 57cbbd4e..0e4eb081 100644 --- a/plugins/imagehl/imagehl.def +++ b/plugins/imagehl/imagehl.def @@ -1,8 +1,8 @@ -; hlimage.def : Declares the module parameters for the DLL. - -LIBRARY "ImageHL" -DESCRIPTION 'ImageHL Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; hlimage.def : Declares the module parameters for the DLL. + +LIBRARY "ImageHL" +DESCRIPTION 'ImageHL Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/imagehl/imagehl.txt b/plugins/imagehl/imagehl.txt index 73b8ff2f..e442e644 100644 --- a/plugins/imagehl/imagehl.txt +++ b/plugins/imagehl/imagehl.txt @@ -1,30 +1,30 @@ -ImageHL -======= - -Coding by Dominic Clifton - Hydra - hydra@hydras-world.com - -What is it ? ------------- - -This GTKRadiant 1.2+ plugin handles the loading of textures from .WAD files. -I'll refer to these textures as .HLW files, even though they don't have any -extension when they're stored in the .WAD file itself. - -You need a VFS plugin to go with this plugin that can open and read .WAD files -My VFSWAD plugin does just this. - -Developer Notes ---------------- - -The project file will copy the compiled DLL file and this .TXT file to -"$(HLRADIANTDIR)modules" so make sure you have that environment variable -defined. - -For my GTKRadiant 1.2 HalfLife game pack files I use the directory: -"E:\games\HalfLife\Tools\GTKR12N". Under which there are the directories -"modules" and "plugins" - -Credits -------- -Thanks to the guys that made Wally for releasing an example WAD loader. -without it this would not have been possible. +ImageHL +======= + +Coding by Dominic Clifton - Hydra - hydra@hydras-world.com + +What is it ? +------------ + +This GTKRadiant 1.2+ plugin handles the loading of textures from .WAD files. +I'll refer to these textures as .HLW files, even though they don't have any +extension when they're stored in the .WAD file itself. + +You need a VFS plugin to go with this plugin that can open and read .WAD files +My VFSWAD plugin does just this. + +Developer Notes +--------------- + +The project file will copy the compiled DLL file and this .TXT file to +"$(HLRADIANTDIR)modules" so make sure you have that environment variable +defined. + +For my GTKRadiant 1.2 HalfLife game pack files I use the directory: +"E:\games\HalfLife\Tools\GTKR12N". Under which there are the directories +"modules" and "plugins" + +Credits +------- +Thanks to the guys that made Wally for releasing an example WAD loader. +without it this would not have been possible. diff --git a/plugins/imagem8/imagem8.def b/plugins/imagem8/imagem8.def index 3a0e2727..74739a05 100644 --- a/plugins/imagem8/imagem8.def +++ b/plugins/imagem8/imagem8.def @@ -1,8 +1,8 @@ -; imagem8.def : Declares the module parameters for the DLL. - -LIBRARY "ImageM8" -DESCRIPTION 'ImageM8 Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; imagem8.def : Declares the module parameters for the DLL. + +LIBRARY "ImageM8" +DESCRIPTION 'ImageM8 Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/imagepng/imagepng.def b/plugins/imagepng/imagepng.def index b3d3c593..cc876885 100644 --- a/plugins/imagepng/imagepng.def +++ b/plugins/imagepng/imagepng.def @@ -1,8 +1,8 @@ -; imagepng.def : Declares the module parameters for the DLL. - -LIBRARY "IMAGEPNG" -DESCRIPTION 'IMAGEPNG Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; imagepng.def : Declares the module parameters for the DLL. + +LIBRARY "IMAGEPNG" +DESCRIPTION 'IMAGEPNG Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/map/map.def b/plugins/map/map.def index 6497dd51..80a9c861 100644 --- a/plugins/map/map.def +++ b/plugins/map/map.def @@ -1,8 +1,8 @@ -; mapq3.def : Declares the module parameters for the DLL. - -LIBRARY "MAPQ3" -DESCRIPTION 'MAPQ3 Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; mapq3.def : Declares the module parameters for the DLL. + +LIBRARY "MAPQ3" +DESCRIPTION 'MAPQ3 Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/mapxml/mapxml.def b/plugins/mapxml/mapxml.def index 98700862..feca2974 100644 --- a/plugins/mapxml/mapxml.def +++ b/plugins/mapxml/mapxml.def @@ -1,8 +1,8 @@ -; mapxml.def : Declares the module parameters for the DLL. - -LIBRARY "MAPXML" -DESCRIPTION 'MAPXML Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; mapxml.def : Declares the module parameters for the DLL. + +LIBRARY "MAPXML" +DESCRIPTION 'MAPXML Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/model/model.def b/plugins/model/model.def index fc23bd28..18e255e3 100644 --- a/plugins/model/model.def +++ b/plugins/model/model.def @@ -1,8 +1,8 @@ -; model.def : Declares the module parameters for the DLL. - -LIBRARY "MODEL" -DESCRIPTION 'MODEL Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here +; model.def : Declares the module parameters for the DLL. + +LIBRARY "MODEL" +DESCRIPTION 'MODEL Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here Synapse_EnumerateInterfaces @1 \ No newline at end of file diff --git a/plugins/shaders/shaders.def b/plugins/shaders/shaders.def index f542aff0..3f3b6a1e 100644 --- a/plugins/shaders/shaders.def +++ b/plugins/shaders/shaders.def @@ -1,8 +1,8 @@ -; shaders.def : Declares the module parameters for the DLL. - -LIBRARY "Shaders" -DESCRIPTION 'Shaders Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; shaders.def : Declares the module parameters for the DLL. + +LIBRARY "Shaders" +DESCRIPTION 'Shaders Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/shaders/shadershl.def b/plugins/shaders/shadershl.def index 2cea27cb..8c046f04 100644 --- a/plugins/shaders/shadershl.def +++ b/plugins/shaders/shadershl.def @@ -1,8 +1,8 @@ -; shaders.def : Declares the module parameters for the DLL. - -LIBRARY "ShadersHL" -DESCRIPTION 'ShadersHL Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; shaders.def : Declares the module parameters for the DLL. + +LIBRARY "ShadersHL" +DESCRIPTION 'ShadersHL Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/spritemodel/spritemodel.def b/plugins/spritemodel/spritemodel.def index 7282bd99..fcc9245f 100644 --- a/plugins/spritemodel/spritemodel.def +++ b/plugins/spritemodel/spritemodel.def @@ -1,8 +1,8 @@ -; md3model.def : Declares the module parameters for the DLL. - -LIBRARY "SPRITEMODEL" -DESCRIPTION 'SPRITEMODEL Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; md3model.def : Declares the module parameters for the DLL. + +LIBRARY "SPRITEMODEL" +DESCRIPTION 'SPRITEMODEL Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/surface_heretic2/surface_heretic2.def b/plugins/surface_heretic2/surface_heretic2.def index 382ffcb2..7f26db48 100644 --- a/plugins/surface_heretic2/surface_heretic2.def +++ b/plugins/surface_heretic2/surface_heretic2.def @@ -1,8 +1,8 @@ -; surface_heretic2.def : Declares the module parameters for the DLL. - -LIBRARY "Surface_Heretic2" -DESCRIPTION 'Surface_Heretic2 Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; surface_heretic2.def : Declares the module parameters for the DLL. + +LIBRARY "Surface_Heretic2" +DESCRIPTION 'Surface_Heretic2 Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/textool/TexTool.def b/plugins/textool/TexTool.def index d992fe0e..95cbb273 100644 --- a/plugins/textool/TexTool.def +++ b/plugins/textool/TexTool.def @@ -1,12 +1,12 @@ -; TexTool.def : Declares the module parameters for the DLL. - -LIBRARY "TexTool" -DESCRIPTION 'TexTool Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - QERPlug_Init @1 - QERPlug_GetName @2 - QERPlug_GetCommandList @3 - QERPlug_Dispatch @4 - QERPlug_GetFuncTable @5 +; TexTool.def : Declares the module parameters for the DLL. + +LIBRARY "TexTool" +DESCRIPTION 'TexTool Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + QERPlug_Init @1 + QERPlug_GetName @2 + QERPlug_GetCommandList @3 + QERPlug_Dispatch @4 + QERPlug_GetFuncTable @5 diff --git a/plugins/textool/changelog.txt b/plugins/textool/changelog.txt index ff5dcb28..9d660cbc 100644 --- a/plugins/textool/changelog.txt +++ b/plugins/textool/changelog.txt @@ -1,8 +1,8 @@ -11/19/99 -first usable version -here is the TODO-list for next release, ( most certainly a wish list ) - -- TODO: add hooks with the selected face and selected patch data. tell the plugin when selected face -or selected patch has changed. -the hooks should use a generic interface inside Radiant for "observers" +11/19/99 +first usable version +here is the TODO-list for next release, ( most certainly a wish list ) + +- TODO: add hooks with the selected face and selected patch data. tell the plugin when selected face +or selected patch has changed. +the hooks should use a generic interface inside Radiant for "observers" - TODO: add other usefull texturing tools, if designers come up with good ideas \ No newline at end of file diff --git a/plugins/vfspk3/vfspk3.def b/plugins/vfspk3/vfspk3.def index c9e249d4..d4c34e7f 100644 --- a/plugins/vfspk3/vfspk3.def +++ b/plugins/vfspk3/vfspk3.def @@ -1,8 +1,8 @@ -; vfspk3.def : Declares the module parameters for the DLL. - -LIBRARY "VFSPK3" -DESCRIPTION 'VFSPK3 Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; vfspk3.def : Declares the module parameters for the DLL. + +LIBRARY "VFSPK3" +DESCRIPTION 'VFSPK3 Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/vfswad/vfswad.def b/plugins/vfswad/vfswad.def index 45fa85c7..0515e470 100644 --- a/plugins/vfswad/vfswad.def +++ b/plugins/vfswad/vfswad.def @@ -1,8 +1,8 @@ -; vfswad.def : Declares the module parameters for the DLL. - -LIBRARY "vfswad" -DESCRIPTION 'vfswad Windows Dynamic Link Library' - -EXPORTS - ; Explicit exports can go here - Synapse_EnumerateInterfaces @1 +; vfswad.def : Declares the module parameters for the DLL. + +LIBRARY "vfswad" +DESCRIPTION 'vfswad Windows Dynamic Link Library' + +EXPORTS + ; Explicit exports can go here + Synapse_EnumerateInterfaces @1 diff --git a/plugins/vfswad/vfswad.txt b/plugins/vfswad/vfswad.txt index a5afa599..34185307 100644 --- a/plugins/vfswad/vfswad.txt +++ b/plugins/vfswad/vfswad.txt @@ -1,30 +1,30 @@ -VFSWAD -====== - -Coding by Dominic Clifton - Hydra - hydra@hydras-world.com - -What is it ? ------------- - -This GTKRadiant 1.2+ plugin handles the extracting of files from .WAD files. -I'll refer to these files as .HLW files, even though they don't have any -extension when they're stored in the .WAD file itself. - -You need an image plugin to go with this plugin that can read .HLW files -My ImageHL plugin does just this. - -Developer Notes ---------------- - -The project file will copy the compiled DLL file and this .TXT file to -"$(HLRADIANTDIR)\modules" so make sure you have that environment variable -defined. - -For my GTKRadiant 1.2 HalfLife game pack files I use the directory: -"E:\games\HalfLife\Tools\GTKR12N\". Under which there are the directories -"modules" and "plugins" - -Credits -------- -Thanks to the guys that made Wally for releasing an example WAD loader. -without it this would not have been possible. +VFSWAD +====== + +Coding by Dominic Clifton - Hydra - hydra@hydras-world.com + +What is it ? +------------ + +This GTKRadiant 1.2+ plugin handles the extracting of files from .WAD files. +I'll refer to these files as .HLW files, even though they don't have any +extension when they're stored in the .WAD file itself. + +You need an image plugin to go with this plugin that can read .HLW files +My ImageHL plugin does just this. + +Developer Notes +--------------- + +The project file will copy the compiled DLL file and this .TXT file to +"$(HLRADIANTDIR)\modules" so make sure you have that environment variable +defined. + +For my GTKRadiant 1.2 HalfLife game pack files I use the directory: +"E:\games\HalfLife\Tools\GTKR12N\". Under which there are the directories +"modules" and "plugins" + +Credits +------- +Thanks to the guys that made Wally for releasing an example WAD loader. +without it this would not have been possible. diff --git a/tools/quake3/q3map2/changelog.q3map2.txt b/tools/quake3/q3map2/changelog.q3map2.txt index 29446abd..47bceb51 100644 --- a/tools/quake3/q3map2/changelog.q3map2.txt +++ b/tools/quake3/q3map2/changelog.q3map2.txt @@ -1,607 +1,607 @@ -Q3Map2 Version History + Changelog (Reverse Chronological Order) - -2.5.11 (2003-12-01) - -- New: added support for _skybox entities to generate "portal sky" - surfaces in games w/o native support (Quake 3). _skybox entities have - 3 keys: _scale (default 64), and angle/angles (for rotation of the - skybox relative to the map) -- New: added -skyfix switch to BSP phase as a workaround hack for - the black GL_CLAMP border on skybox edges on ATI (and newer nvidia) - video cards. Note: unnecessary in ET or JA -- New: Added _anglescale to light entities for scaling angle attenuation. - Use a small value (< 1.0) to lessen the angle attenuation, and a high - value (> 1.0) for sharper, more faceted lighting -- New: Added _lightmapscale support to misc_model entities -- Custom shaders (external lightmaps, styles) will not be generated - if the find/replace text cannot be found -- Tightened up light culling epsilon from 1.0 to 0.125 to stop certain - surface lights from being incorrectly culled (thanks RasputiN!) -- Fixed bug where small 3 and 4 sided brush faces were getting fanned, - adding triangle/vertex counts -- Moved to Visual Studio .NET, with aggressive optimizations enabled -- Cleaned up missing image warnings -- Parsing images out of shader stages if not found explicit/implicitly -- Loads Enemy Territory implicitMap images if editor/light image not found - - -2.5.10 (2003-10-22) - -- New: Lightwave model support (beta) courtesy of RR2DO2 -- New: Heretic 2 FM model support courtesy of Nurail -- Re-enabled vertex cache friendly triangle reordering with fix -- Disabled triangle reordering on certain surfaces, including autosprite - shaders due to visual errors -- Fixed bug in radiosity where sorting of lights by style took forever. - Thanks ReBoOT! -- Fixed bug in sun lighting code where maps too far off the origin would - not be properly it by sun or sky light. Thanks MindLink! -- Entity causing a leak will be printed and selected in Radiant if BSP - monitoring is enabled. Requested by heeen -- Fixed odd bug causing 10x slowdown in lighting in some maps. Should - be back to 2.5.7 performance. Also fixed a couple old bugs related to - autosprite shader (point) lights and backsplash lights not being styled - or setup correctly - - -2.5.9 (2003-10-12) - -- Disabled triangle reordering for now (crashing on some maps) - - -2.5.8 (2003-10-02) - -- New: Added two new sun parameters: angular deviation (width of the sun in - degrees) and sampling count (jitters). This allows for decent approximation - of penumbra "half-shadow" effects from sunlight with 16+ samples. These - parameters are accessible for entity lights (including spots and suns) via - these entity keys: _deviance and _samples. To use in shaders, use the new - q3map_sunExt -- New: q3map_lightmapFilterRadius for light-emitting shaders. - Put *after* any q3map_sun directives or else your sun will be filtered. This - is good for eliminating the "stadium lighting" effect from q3map_skyLight. - Also usable as an entity key: _filterradius or _filter -- New: Quake 2 MD2 model support in PicoModel for misc_model entities - (thanks to Nurail!) -- Re-enabled vertex-cache-aware triangle reordering. Will probably have a - negligible effect on rendering performance, but can't hurt -- Added short-circuit to raytracer: any empty nodes (including children) are - ignored on sun traces -- Added BSP file size printout -- Filtering of any kind now disables adaptive supersampling on a per-light, - per-ightmap basis -- Fixed another _minlight <-> styled light interaction bug (thanks pjw!) - - -2.5.7 (2003-08-31) - -- New: Jedi Academy support via -game ja -- New: DDS (DXT1/3/5) texture support for future games -- Re-enabled q3map_surfaceModel support, and the 'oriented' flag works as well -- Re-enabled (fixed, really) large external lightmap support -- Fixed a bug in the model code that would cause a crash if an uninvertable - matrix was created -- Fixed a bug in Mathlib m4x4_t code where the tolerance for a singular matrix - was too low and crapping out on small (scaled down) matrices -- Fixed bug in divide-by-zero on lightmap efficiency calculation -- Added -force switch, allows unsupported BSP formats to (try) to be loaded - - -2.5.6 (2003-08-15) - -- New: can convert BSP files to MAP files via -convert -format map. Note: not - perfect by any means, as certain pieces of data are irretrievably lost, such - as func_group entities (including terrain specifics), brush face texturing - info, and light/misc_model entities with Q3Map2-generated BSPs - - -2.5.5 - -- New: -scale N.N mode to scale the BSP -- New: -light -lomem switch to supress trace BSP optimization. This - feature trades lighting performance for decreased memory usage -- New: Added negative light support (note: will not darken below _minlight value) - might screw up radiosity, haven't tested much. Should work with entity - lights, shader lights, sun/sky lights and radiosity. Lightfilter shadows - tint negative lights too, so the end effect is subtraction of the color -- New: Lightstyle support for non-Raven (JK2/SOF2) games, including Quake 3, - RTCW, ET, EF. Only works with lightmapped surfaces, use with care -- Fixed long standing terrain texturing bug, should produce exact desired - results all of the time now. May require fixing alphamaps that were - kludged together to accomodate this bug on existing maps -- Fixed bug (huh, wtf) causing misc_model surfaces to not be fogged -- Fixed bug where fog brushes wouldn't fog surfaces if a global map fog - shader was present -- Fixed bug where -patchmeta surfaces were being ignored for raytracing -- Fixed long-standing bug where twosided surfaces were not correctly - bouncing light. You can now have a foggy glass window that re-emits - bright light with q3map_bounce 3.0 or so -- Fixed really stupid bug in radiosity with bouncing styled lights -- Stripping .map and appending .bsp in -info mode -- Fixed bug where tesselated brush face surfaces were not being fogged -- Twosided surfaces (using cull disable/twosided/none) are now lit twosided -- Added tighter tolerance for alphashadow/lightfilter shadowing to raytracer - which fixed problem with double shadows from tracing near triangle seams -- Brush entities should now be properly fogged. Really. -- Styled lightmaps are no longer affected by _minlight (doh) - - -2.5.4 (2003-04-01) - -- New: q3map_tessSize support for JK2/SOF2 -- New: -lightmapsize N argument -- Fixed bug where switched styled lights weren't working correctly in SOF2/JK2 -- Fixed bug where external lightmaps with generated shaders were referencing - the wrong lightmap -- Fixed bug causing lightgrid brushes to be ignored -- Added variable sphere around trace sample points to inhibit occluder geometry - - -2.5.3 (2003-03-06) - -- New: SOF2/JK2 light styles now supported -- New: q3map_lightStyle N to set shader lightstyles -- New: Tenebrae 2 support via -game tenebrae -- New: -light -deluxe and -debugdeluxe for Tenebrae "deluxemap" static - lighting algorithm -- Light envelopes now properly clipped to the PVS -- q3map_vertexScale re-enabled (scales vertex lighting per-shader) -- Minor bug in brush bevel code corrected -- Brushes from func_group entities are correctly sorted on insertion -- Fixed a couple misc warnings to print "percent" instead of "%" -- Added -custinfoparms support to -light mode to suppress warnings -- _minlight, _minvertexlight and _mingridlight order independent, and now - allow for values of 0 - - -2.5.2 (2003-02-17) - -- Fixed crash bugs with global map fog -- Model loading really only warns once now - - -2.5.1 (2003-02-17) (Splash Damage internal release) - -- Added more Hella-Fast juice to light code. Overall should be 35% faster -- Refactored surface portion of raytracer code for less memory usage -- Changed UVW epsilon in raytracer to catch more edge cases -- Removed bounds check on occluded luxel finding, was causing more problems - than it was solving -- Adaptive antialiasing code now ignores unmapped luxels for better shadow - edges and higher performance -- Brushes in the BSP are now sorted opaque first -- Fixed Really Stupid bug causing MapRawLightmap to take about 4x as long -- Added optimization to make MapRawLightmap 2x as fast -- New non-sucky quadrilateral subdivision of patches for MapRawLightmap -- Patches with < 90 degrees of curvature are now box-lightmapped -- Patch vertex normals now correctly stored, fixing bug in 2.5.0 -- Prints warning if map with < 10% detail brushes is detected - - -2.5.0 (2003-02-14) (Splash Damage internal release) - -RAYTRACING AND SHADOW CALCULATION -- New raytracing code. Rewrote the raytracer to maximize efficiency on modern - "caulk-hull" maps. Uses triangle intercept code written by SPoG, based on code - by Tomas Moller and Ben Trumbore (Journal of Graphics Tools, 2(1):21-28, 1997) - and a biased octree leaf subdivision scheme by Y.T. -- Shadows (casting and receiving) are now controllable per-entity - New entity keys: "_castShadows" or "_cs" and "_receiveShadows" or "_rc" - Values: 0 = no shadows, 1 = worldspawn shadows, > 1 explicit shadow group, - negative values imply no worldspawn shadow interation. - *Entities, including model2 and RTCW misc_gamemodels can now cast shadows* - -RADIOSITY -- Bumped up default and smallest radiosity patch size. Performance should be - approximately 4x with a small quality tradeoff -- Radiosity patches now trace to centroid of triangle, and not bounds center -- Radiosity and surface lights are now nudged around a bit if in solid -- Radiosity light generation code is now thread-safe -- Radiosity -dump files now .map instead of .pfb -- Poorly worded "q3map_bounce" renamed to "q3map_bounceScale" (old still works) -- New -bounceonly switch to store only bounced light in the BSP (for Tenebrae) - -MISC LIGHTING -- Optimized case where light and sample are coplanar -- Forcing nudged luxels to stay within lightmap surfaces' bounds - -CURVED SURFACES -- New -subdivisions N argument, works with -patchmeta and -light for setting - patch level-of-detail. Default value is 8, use 4 to simulate default Q3 -- All patch tesselation code changed to create x-patterned tesselation for - better lighting -- Storing patch LOD info in the .srf file for better patch light/shadows - -FOG -- Reworked fog code to fix bad interation with fog and clipped models - -MODELS -- Entities with attached MD3/ASE misc_models now have their bounds correctly set -- Attached misc_models now support q3map_clipModel for solidity -- Missing models will only warn once, rather than spew errors - -MISC -- Metasurface merging no longer folds nonplanar triangles into planar surfaces - and vice-versa * -- Fixed Really Stupid Bug where entity numbering was not loaded by lighting code - resulting in lightmaps merging across entity boundaries * - -* Might result in slightly larger BSP. For maximum efficiency, ungroup - func_group entities before doing a final compile - -TODO -+ Document new shadow stuff -+ Merge adjacent light-casting triangles into convex windings - - -2.3.38 (2003-02-07) - -- New lighting code, return of Smoove-B. Intelligently antialises shadow edges - when you use the new -samples N switch. Get -extra quality in 1/3 the time -- New lightmap filtering code. Now using a proper 0.25/0.5/1.0 filter kernel. - Also operates on individual lightsources, so per-lightsource filter/kernel - settings are now possible -- New -patchmeta fixes, now does stitching and adaptive subdivision. - Thanks Sock! -- Nonsolid patches will no longer be in the BSP when run with -patchmeta -- Misc fog fixes, including q3map_noFog support in maps with global _fog - support (SOF2/JK2) -- Now stripping misc_model entities from the BSP -- Fixed disappearing face bug that's been present since 2.3.36. - Thanks Shadowspawn! - - -2.3.37 (2003-01-24) - -- Building from GtkRadiant CVS trunk -- Added new brush bevel code by MrElusive to fix lingering aas problems (sweet!) -- Added -snap N arg to BSP phase for axial bevel plane snapping to reduce - clipped model plane count (note: will muck with above, use with care) -- Patches in terrain entities should now have proper vertex alpha set -- Fixed bug in fur code where fur was being limited to 2 layers (thanks pazur) -- Reduced vertexlight search area to a reasonable size to keep vertex lighting - times down - - -2.3.36 (2003-01-15) - -- Plane hashing re-enabled (I suck) -- Plane hashing optimized (faster parsing of larger maps) -- Plane finding accuracy code enabled -- New ASE clipping code - + With above should be 10-50% faster - + Should generate 33% fewer planes - + Generates mostly-axial 5-sided polyhedra instead of pyramids, - for tighter 2-sided clipping -- New -light args: - + -scale N -- scales all lightsources (area, radiosity, point, sky) - + -sky[scale] N -- scales sky lights (q3map_skylight, q3map_sunlight) -- Changed fur code to scale fur offset based on original vertex alpha - - -2.3.35 (2003-01-14) - -- PicoModel now inverts ASE T coordinate -- BSP to ASE converter now inverts T coordinate -- Disabling 2.3.34 triangle optimization code until I find out why it crashes -- Fixed Conscript-q3map2 to use stack_size ld flags directly on Darwin/OS X -- Added Conscript-q3map2 to q3map2.dsp for easier Win32 edit, *nix target - - -2.3.34 (2003-01-08) - -- Building from merged GtkRadiant 1.2 -> 1.3 merged codebase -- IMPORTANT NEW CHANGE: Light entities are now STRIPPED from the BSP file. - They are re-read in by -light from the MAP file. This has two consequences: - + It is no longer necessary to re-BSP & re-vis a map in order to change - lighting. You can just change lights in the map file and run -light. - + Slightly smaller BSP file, due to fewer entities - + Faster loading time, as the game code doesn't have to deal with them -- Added new -ne (normal epsilon) and -de (distance epsilon) for tuning precision - of plane snapping to correct potential AAS/BSP issues -- Using latest PicoModel, with support for RTCW MDC models -- Surfaces per raw lightmap are now sorted by shader name, which should give - slightly better lightmap efficiency and lower in-game shader counts -- Adjusted model code to use correct m4x4_t code & angles key -- Minor bugfix in patch color gradient calculation code -- Silenced erroneous areaportal warning spew -- q3map_tcGen now works on model surfaces -- Using default radiosity subdivide of 256 again (should make radiosity faster) -- Enabled byte-swapping code so Q3Map2 can be compiled/run on little-endian - architectures (Mac OS X) - - -2.3.33 (2002-12-08) - -- Added new -bouncescale argument for radiosity scaling -- Added -pointscale and -areascale for consistent naming -- Radiosity patch subdivision code enhanced -- Hint portals split the BSP first (higher priority) -- Antiportal and areaportal faces split the BSP last, to minimize errors -- Areaportals work internally like hint and antiportals, so they no longer need - to be full brushes (the other sides can be skip) -- External lightmaps are now named "lm_NNNN.tga" in the maps/mapname dir -- Cleaned up some of -light argument processing -- Planar surfaces w/o lightmaps will no longer be tagged as MST_TRIANGLE_SOUP - (this fixes problems with Particle Studio particles dropping out of view) - - -2.3.32 (2002-11-30) - -- GtkRadiant (1.2.11) integration -- Added epsilon to texture plane choose code to eliminate numerical - inconsistencies on brush faces slanted at 45 degree angles (bug 637) -- Fixed bug in lightmap export after lighting when map contains 0 BSP lightmaps -- Adjusted some light tracing constants to fix certain brush/patch seam shadows -- Tinkered with skylight code again -- Fixed bug where lightgrid would be black if level was compiled with -nogrid -- Fixed -approx code to work in floating-point space, using _minlight -- Fixed bug where vertex light code was using invalid pvs data to create - light list for surface, leading to incorrect vertex lighting -- Fixed related bug in anti-light-leak code that was causing brush faces to go - black (bug 694) -- New: _minlight sets _minvertexlight and (new) _mingridlight automatically -- New: _mingridlight key to set minimum grid lighting - - -2.3.31 (2002-11-21) - -- Stitching the edges of lightmaps on patches that wrap around (cyls and cones) - so the seam is no longer visible -- The -patchmeta switch works better now, the patches are still stored in the - BSP for collision, but are pre-tesselated into nonplanar meta surfaces for - more efficient rendering -- Better, more uniform lightmap sample position finding on patch meshes -- Moved q3map_tcMod and q3map_alphaMod processing to the final phase -- New: q3map_skylight AMOUNT ITERATIONS to replace surfacelight on sky surfaces - for much faster and more uniform sky illumination - - -2.3.30 (Splash Damage internal release) - -- Fixed bug in PicoModel ASE material parsing code -- Fixed a few seam/lightmap precision/projection errors -- Increased MAX_SHADER FILES to 1024 and fixed overrun error when more than that - number of shaders was listed in shaderlist.txt -- Increased a few compiler maximums for larger maps -- New: -np N switch on BSP phase, works like -shadeangle, in that it forces all - planar shaders to be nonplanar with the shading angle specified -- New: -nohint switch on BSP phase, omits hint brushes from compile for testing -- New: -debugaxis switch on light mode. Colors lightmaps based on their lightmap - axis (which direction the lightmap was projected on) -- New: -debugorigin switch on light mode. Colors lightmaps based on the luxel - origin relative to the raw lightmap's bounding box -- New: -debugcluster switch on light mode. Colors lightmaps based on the pvs - cluster the luxel falls into -- New: -convert switch to convert BSP to ASE file (experimental) -- New: q3map_lightmapmergable directive to allow terrain to be mapped onto a - single lightmap page for seamless terrain shadows - - -2.3.29 (2002-11-03) - -- Merged with latest CVS, fixed minor issues with matrix order -- Fixed minor Sys_FPrintf/Sys_Printf substitution typo in Q3Map2 -- Expanded debug colors to 12 for debugging surface meshes -- PicoModel: fixed ASE loader to support > 1 texture coordinate per-vertex, - so more models supported correctly, also loading vertex normals -- PicoModel: md3 shader names are now cleaned. Suffixes (such as .tga or .jpg) - are stripped, and \ path separators are changed to / -- New: Add :q3map to the end of any shader name, and it will be interpreted as - the named shader minus :q3map. Example: - textures/shaderlab/concrete:q3map -> textures/shaderlab/concrete - One potential use is the -approx feature to collapse lightmapped surfaces - into vertexlit surfaces, saving lightmap space/memory -- New: q3map_clipModel -- does what you think it does, sort of. This code ix - really experimental, and should *only* be used on large models such as terrain - (not small decorative models). This code will be evolving. Note: the shader's - surfaceparms are inherited by the magic clip brush, so if you have nonsolid - in your model's shader that uses q3map_clipModel, then the brush will also - be nonsolid - - -2.3.28 (2002-11-01) - -- Bug 654 (http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=654): - Fixed problem where brush faces, drawsurfaces, and surfaceparms weren't living - together in perfect harmony (terrain surfaceparms now inherited by brushes) -- Nodraw fog works now, albeit when you're underneath, surfaces above don't get - fogged properly. Could be good for foggy water where you want the above-water - portions to only be occluded by the water surface -- Bug 656 (http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=656): - Number of lightgrid points displayed (byte size is currently out of proportion - due to internal storage format) when Q3Map is called with the -info switch -- Fixed wack surface merging bug where code would attempt to merge triangles not - adjacent to the current set, causing bad lightmap projections on nonplanar - surfaces -- Fixed tiny 1-character bug in 2d lightmap texture allocator where adjacent - luxels were being checked for occlusion rather than the actual source luxel - - -2.3.27 (2002-10-31) Happy Halloween! - -- Fixed minor bug in scriplib bugfix where the last character in a file wasn't - being read. -- Fixed bug where 0-area or bogus triangles were causing crash in MapRawLightmap - if they used a shader with a normalmap (thanks ShadowSpawn) -- Fixed bug where lightmaps were getting hosed levelwide on a prerelease version - of 2.3.27 -- Fixed bug where lightmaps were getting knackered on models and certain patches -- Merged latest PicoModel version from seaw0lf, adding support for ASE and WF OBJ - models (preliminary) -- Increased MAX_MAP_PLANES to 0x40000 (~256k) - -Known issues: -- Lightmap projection and surface merging on large ASE models sometimes flakes -- Surface to brush surfaceparm propogation doesn't work properly with large - metasurfaces: http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=654 - - -2.3.26 (2002-10-27) - -- Now using GtkRadiant's libpng and zlib config (linked as DLLs) -- Fixed bug in script parser where repeat calls to GetToken() were causing - memory corruption -- Fixed SOF2 -rename bug -- When using -game sof2 or -game jk2, the -flares argument is implied -- Added -noflares argument to disable the above behavior -- Added support for flares on entities. Use one of the following keys: - "_flare" "1" -- use default flare (different for each game) - "_flareshader" "path/to/flareshader" -- use a specific flare shader - Note: This only matters in SOF2/JK2 now. Make a light targetted (a spotlight) - to get it to aim the correct direction, otherwise it defaults to pointing - downward. You cannot have omnidirectional flares -- Lightgrid size is automatically increased to accomodate large maps. The - MAX_MAP_LIGHTGRID error will never happen again - - -2.3.25 (2002-10-22) - -- Go Giants! -- Fixed bug where Q3Map would crash on writing the BSP after the light stage. - Thanks to Rap7or (#q3map) and loon8 (Q3W forums) [bug 641] -- Fixed bug where surface lights were not affecting the light grid properly. - Thanks to Shadowspawn and djbob [bug 642] -- NEW: Added -faster support to lightgrid calculations while fixing previous bug -- NEW: Changed it so the BSP file is written to a temp file first, then renamed. - This should prevent BSP file corruption on crashes during writes - - -2.3.24 (2002-10-20) - -- Fixed numerous outstanding bugs and issues. -- Normal interpolation is now improved. It's slightly slower, but more 'correct' - in cases where you have 10 triangles in one plane and 1 triangle in another - meeting up and the 10 triangles were over-affecting the average. Only new - identical normals are averaged now. This change affects phong shading, meta - surfaces, and PicoModel -- PicoModel up to version 0.7.6, BSD license, better 3DS model support -- PicoModel library now fixes broken normals on MD3 and 3DS models -- Bumpmapping code is improved. The correct tangent vectors per-triangle are - now calculated so the bumpmaps are consistent with regards to light direction -- Metasurface merging code optimized. Should be about 100x as fast on complex - maps or maps using models with high triangle counts -- Vertexlight code tweaked a bit -- Triangle/winding orders now more consistent. Tesselated surfaces will have - a uniform triangle ordering (thanks RR2DO2) -- NEW: "vertexDeform move" now parsed and surfaces are merged into the - appropriate BSP leaves they may enter into (thanks to Bart Vrijkorte) -- NEW: shader command: q3map_alphaMod. Currently takes a single form: - q3map_alphaMod dotproduct ( NX NY NZ ) - where NX NY NZ are a unit normal (length of 1.0) specifying direction. - An example use would be snow in a shader's 2nd pass, using alphaFunc or - blendFunc: - q3map_alphaMod dotproduct ( 0 0 1 ) // surfaces facing upwards have snow - (idea contributed by RR2DO2) - - -2.3.23 (2002-10-18) - -- In my haste to release the previous version, I neglected to give credit where - it was due. Seaw0lf had as much (probably more) to do with the new model - loading library (PicoModel). Because of his efforts, you can load 3DS models - and use them in misc_model entities. -- PicoModel model library up to version 0.7. Improved 3DS support, more stable. -- Surface models still not reenabled. Soon. :) -- You can now remap a misc_model's shaders like this: - Key "_remapNN" "the/model/shader;the/real/shader" - This works just like TA terrain vertexRemapShader key. You can also supply a - * glob for the source shader if you want all your model's shaders to use the - specified shader: - "_remap" "*;models/mapobjects/tree/bark" - - -2.3.22 (2002-10-16) - -- Moving to sensible Linux-style versioning. -- The misc_model code has been completely rewritten, breaking surface models. - Surface models will reappear in the next release, once the new model API has - stablized. -- New: MD3 and 3D Studio 3DS models now natively supported. -- The misc_model "angles" key now supported. Values: "pitch yaw roll" in keeping - with standard Quake 3 angles order. -- Models scaled with "modelscale_vec" now have proper normal scaling/rotation - (thanks SPOG). -- Models can now be lightmapped. -- Models can now have > 1000 vertexes per surface. -- For best results for above, add the following to models' shaders: - q3map_splotchfix - q3map_nonplanar -- 3DS models' MATERIAL NAMES ARE THE FINAL Q3 SHADER NAMES. YOU HAVE BEEN WARNED. -- Models are generally 13373R. :) - - -2.3.0-a21 (2002-10-02) - -- Fixed a stack of really stupid bugs in the lightgrid code. Should be faster - and more predictable now. -- SOF2/JK2 lightgrid now compiled. This is the first version of Q3Map2 that can - compile full, release-worthy SOF2 and JK2 maps. -- SOF2/JK2 damageshader and damagable brush faces should work correctly now. - - -2.3.0-a20 (2002-09-26) - -- SOF2/JK2 worldspawn "fog" (and "_fog") shader key support for levelwide fog -- SOF2/JK2 light "scale" key to scale light brightness -- SOF2/JK2 -rename function for _bsp and _rmg_bsp shader renaming - - -2.3.0-a19 (2002-09-24) - -- Shaders can now be subclassed (Q3Map relavant portions only, such as - surfaceparms, lighting, texture projection, etc). To subclass an existing - shader, add "q3map_baseshader X" where X is the name of the base shader. -- Preliminary auto-model distribution over surfaces. You can now have things - like grass and tree models automatically distributed across your terrain - or other surfaces. To wit: - - q3map_surfacemodel models/mapobjects/tree2/tree2.md3 64 0.001 0.5 4.0 0 360 1 - - q3map_surfacemodel - - - The last flag is 1 or 0, and sets whether the model gets fitted to the - orientation of the surface. Not functional yet. See screenshots page for - shots of this in action. - - -2.3.0-a18 (2002-09-21) - -- misc_models can now be attached to any brush model entity. Just target the - brush entity with the misc_model (select model, then entity, hit Ctrl+K) -- q3map_tcMod translate (or shift or offset) -- q3map_tcMod rotate (rotates around origin, not center) -- q3map_tcMod scale -- Metasurface merging now much, much better. Merges into roughly rectangular or - square areas wherever possible -- q3map_terrain no longer sets Z-axis lightmap projection. It must be set in - the terrain layer shaders if you want previous behavior -- Worlspawn _blocksize key now supports 3 elements for setting X Y and Z splits - independently of each other (use a value of 0 for no splits on that axis) -- Misc bugfixes - - -2.3.0-a1 through 2.3.0-a17 (2002-07 through 2002-09-20) - -- Elite Force support (via -game ef) -- SOF2 and JK2 support (via -game sof2 or -game jk2) -- All new image handling with PNG support -- q3map_lightimage specifies image for radiosity and lighting -- External lightmaps, set using q3map_lightmapsize . Up to - 1024 x 1024 supported. -- q3map_lightmapGamma sets the brightness scale of a lightmap -- q3map_lightmapsampleoffset to fix glitches in lightmapped terrain -- Tons more features and bugfixes. See the forum threads for details/screenshots -- Two new surfaceparms, "antiportal" and "skip," and associated shaders, for - allowing the mapper to more cleanly set up visibility data -- Lightmaps will always have square texels now (no more stretching) -- Vertex light improvements -- Light grid improvements -- q3map_lightrgb support for RTCW - - - - - - +Q3Map2 Version History + Changelog (Reverse Chronological Order) + +2.5.11 (2003-12-01) + +- New: added support for _skybox entities to generate "portal sky" + surfaces in games w/o native support (Quake 3). _skybox entities have + 3 keys: _scale (default 64), and angle/angles (for rotation of the + skybox relative to the map) +- New: added -skyfix switch to BSP phase as a workaround hack for + the black GL_CLAMP border on skybox edges on ATI (and newer nvidia) + video cards. Note: unnecessary in ET or JA +- New: Added _anglescale to light entities for scaling angle attenuation. + Use a small value (< 1.0) to lessen the angle attenuation, and a high + value (> 1.0) for sharper, more faceted lighting +- New: Added _lightmapscale support to misc_model entities +- Custom shaders (external lightmaps, styles) will not be generated + if the find/replace text cannot be found +- Tightened up light culling epsilon from 1.0 to 0.125 to stop certain + surface lights from being incorrectly culled (thanks RasputiN!) +- Fixed bug where small 3 and 4 sided brush faces were getting fanned, + adding triangle/vertex counts +- Moved to Visual Studio .NET, with aggressive optimizations enabled +- Cleaned up missing image warnings +- Parsing images out of shader stages if not found explicit/implicitly +- Loads Enemy Territory implicitMap images if editor/light image not found + + +2.5.10 (2003-10-22) + +- New: Lightwave model support (beta) courtesy of RR2DO2 +- New: Heretic 2 FM model support courtesy of Nurail +- Re-enabled vertex cache friendly triangle reordering with fix +- Disabled triangle reordering on certain surfaces, including autosprite + shaders due to visual errors +- Fixed bug in radiosity where sorting of lights by style took forever. + Thanks ReBoOT! +- Fixed bug in sun lighting code where maps too far off the origin would + not be properly it by sun or sky light. Thanks MindLink! +- Entity causing a leak will be printed and selected in Radiant if BSP + monitoring is enabled. Requested by heeen +- Fixed odd bug causing 10x slowdown in lighting in some maps. Should + be back to 2.5.7 performance. Also fixed a couple old bugs related to + autosprite shader (point) lights and backsplash lights not being styled + or setup correctly + + +2.5.9 (2003-10-12) + +- Disabled triangle reordering for now (crashing on some maps) + + +2.5.8 (2003-10-02) + +- New: Added two new sun parameters: angular deviation (width of the sun in + degrees) and sampling count (jitters). This allows for decent approximation + of penumbra "half-shadow" effects from sunlight with 16+ samples. These + parameters are accessible for entity lights (including spots and suns) via + these entity keys: _deviance and _samples. To use in shaders, use the new + q3map_sunExt +- New: q3map_lightmapFilterRadius for light-emitting shaders. + Put *after* any q3map_sun directives or else your sun will be filtered. This + is good for eliminating the "stadium lighting" effect from q3map_skyLight. + Also usable as an entity key: _filterradius or _filter +- New: Quake 2 MD2 model support in PicoModel for misc_model entities + (thanks to Nurail!) +- Re-enabled vertex-cache-aware triangle reordering. Will probably have a + negligible effect on rendering performance, but can't hurt +- Added short-circuit to raytracer: any empty nodes (including children) are + ignored on sun traces +- Added BSP file size printout +- Filtering of any kind now disables adaptive supersampling on a per-light, + per-ightmap basis +- Fixed another _minlight <-> styled light interaction bug (thanks pjw!) + + +2.5.7 (2003-08-31) + +- New: Jedi Academy support via -game ja +- New: DDS (DXT1/3/5) texture support for future games +- Re-enabled q3map_surfaceModel support, and the 'oriented' flag works as well +- Re-enabled (fixed, really) large external lightmap support +- Fixed a bug in the model code that would cause a crash if an uninvertable + matrix was created +- Fixed a bug in Mathlib m4x4_t code where the tolerance for a singular matrix + was too low and crapping out on small (scaled down) matrices +- Fixed bug in divide-by-zero on lightmap efficiency calculation +- Added -force switch, allows unsupported BSP formats to (try) to be loaded + + +2.5.6 (2003-08-15) + +- New: can convert BSP files to MAP files via -convert -format map. Note: not + perfect by any means, as certain pieces of data are irretrievably lost, such + as func_group entities (including terrain specifics), brush face texturing + info, and light/misc_model entities with Q3Map2-generated BSPs + + +2.5.5 + +- New: -scale N.N mode to scale the BSP +- New: -light -lomem switch to supress trace BSP optimization. This + feature trades lighting performance for decreased memory usage +- New: Added negative light support (note: will not darken below _minlight value) + might screw up radiosity, haven't tested much. Should work with entity + lights, shader lights, sun/sky lights and radiosity. Lightfilter shadows + tint negative lights too, so the end effect is subtraction of the color +- New: Lightstyle support for non-Raven (JK2/SOF2) games, including Quake 3, + RTCW, ET, EF. Only works with lightmapped surfaces, use with care +- Fixed long standing terrain texturing bug, should produce exact desired + results all of the time now. May require fixing alphamaps that were + kludged together to accomodate this bug on existing maps +- Fixed bug (huh, wtf) causing misc_model surfaces to not be fogged +- Fixed bug where fog brushes wouldn't fog surfaces if a global map fog + shader was present +- Fixed bug where -patchmeta surfaces were being ignored for raytracing +- Fixed long-standing bug where twosided surfaces were not correctly + bouncing light. You can now have a foggy glass window that re-emits + bright light with q3map_bounce 3.0 or so +- Fixed really stupid bug in radiosity with bouncing styled lights +- Stripping .map and appending .bsp in -info mode +- Fixed bug where tesselated brush face surfaces were not being fogged +- Twosided surfaces (using cull disable/twosided/none) are now lit twosided +- Added tighter tolerance for alphashadow/lightfilter shadowing to raytracer + which fixed problem with double shadows from tracing near triangle seams +- Brush entities should now be properly fogged. Really. +- Styled lightmaps are no longer affected by _minlight (doh) + + +2.5.4 (2003-04-01) + +- New: q3map_tessSize support for JK2/SOF2 +- New: -lightmapsize N argument +- Fixed bug where switched styled lights weren't working correctly in SOF2/JK2 +- Fixed bug where external lightmaps with generated shaders were referencing + the wrong lightmap +- Fixed bug causing lightgrid brushes to be ignored +- Added variable sphere around trace sample points to inhibit occluder geometry + + +2.5.3 (2003-03-06) + +- New: SOF2/JK2 light styles now supported +- New: q3map_lightStyle N to set shader lightstyles +- New: Tenebrae 2 support via -game tenebrae +- New: -light -deluxe and -debugdeluxe for Tenebrae "deluxemap" static + lighting algorithm +- Light envelopes now properly clipped to the PVS +- q3map_vertexScale re-enabled (scales vertex lighting per-shader) +- Minor bug in brush bevel code corrected +- Brushes from func_group entities are correctly sorted on insertion +- Fixed a couple misc warnings to print "percent" instead of "%" +- Added -custinfoparms support to -light mode to suppress warnings +- _minlight, _minvertexlight and _mingridlight order independent, and now + allow for values of 0 + + +2.5.2 (2003-02-17) + +- Fixed crash bugs with global map fog +- Model loading really only warns once now + + +2.5.1 (2003-02-17) (Splash Damage internal release) + +- Added more Hella-Fast juice to light code. Overall should be 35% faster +- Refactored surface portion of raytracer code for less memory usage +- Changed UVW epsilon in raytracer to catch more edge cases +- Removed bounds check on occluded luxel finding, was causing more problems + than it was solving +- Adaptive antialiasing code now ignores unmapped luxels for better shadow + edges and higher performance +- Brushes in the BSP are now sorted opaque first +- Fixed Really Stupid bug causing MapRawLightmap to take about 4x as long +- Added optimization to make MapRawLightmap 2x as fast +- New non-sucky quadrilateral subdivision of patches for MapRawLightmap +- Patches with < 90 degrees of curvature are now box-lightmapped +- Patch vertex normals now correctly stored, fixing bug in 2.5.0 +- Prints warning if map with < 10% detail brushes is detected + + +2.5.0 (2003-02-14) (Splash Damage internal release) + +RAYTRACING AND SHADOW CALCULATION +- New raytracing code. Rewrote the raytracer to maximize efficiency on modern + "caulk-hull" maps. Uses triangle intercept code written by SPoG, based on code + by Tomas Moller and Ben Trumbore (Journal of Graphics Tools, 2(1):21-28, 1997) + and a biased octree leaf subdivision scheme by Y.T. +- Shadows (casting and receiving) are now controllable per-entity + New entity keys: "_castShadows" or "_cs" and "_receiveShadows" or "_rc" + Values: 0 = no shadows, 1 = worldspawn shadows, > 1 explicit shadow group, + negative values imply no worldspawn shadow interation. + *Entities, including model2 and RTCW misc_gamemodels can now cast shadows* + +RADIOSITY +- Bumped up default and smallest radiosity patch size. Performance should be + approximately 4x with a small quality tradeoff +- Radiosity patches now trace to centroid of triangle, and not bounds center +- Radiosity and surface lights are now nudged around a bit if in solid +- Radiosity light generation code is now thread-safe +- Radiosity -dump files now .map instead of .pfb +- Poorly worded "q3map_bounce" renamed to "q3map_bounceScale" (old still works) +- New -bounceonly switch to store only bounced light in the BSP (for Tenebrae) + +MISC LIGHTING +- Optimized case where light and sample are coplanar +- Forcing nudged luxels to stay within lightmap surfaces' bounds + +CURVED SURFACES +- New -subdivisions N argument, works with -patchmeta and -light for setting + patch level-of-detail. Default value is 8, use 4 to simulate default Q3 +- All patch tesselation code changed to create x-patterned tesselation for + better lighting +- Storing patch LOD info in the .srf file for better patch light/shadows + +FOG +- Reworked fog code to fix bad interation with fog and clipped models + +MODELS +- Entities with attached MD3/ASE misc_models now have their bounds correctly set +- Attached misc_models now support q3map_clipModel for solidity +- Missing models will only warn once, rather than spew errors + +MISC +- Metasurface merging no longer folds nonplanar triangles into planar surfaces + and vice-versa * +- Fixed Really Stupid Bug where entity numbering was not loaded by lighting code + resulting in lightmaps merging across entity boundaries * + +* Might result in slightly larger BSP. For maximum efficiency, ungroup + func_group entities before doing a final compile + +TODO ++ Document new shadow stuff ++ Merge adjacent light-casting triangles into convex windings + + +2.3.38 (2003-02-07) + +- New lighting code, return of Smoove-B. Intelligently antialises shadow edges + when you use the new -samples N switch. Get -extra quality in 1/3 the time +- New lightmap filtering code. Now using a proper 0.25/0.5/1.0 filter kernel. + Also operates on individual lightsources, so per-lightsource filter/kernel + settings are now possible +- New -patchmeta fixes, now does stitching and adaptive subdivision. + Thanks Sock! +- Nonsolid patches will no longer be in the BSP when run with -patchmeta +- Misc fog fixes, including q3map_noFog support in maps with global _fog + support (SOF2/JK2) +- Now stripping misc_model entities from the BSP +- Fixed disappearing face bug that's been present since 2.3.36. + Thanks Shadowspawn! + + +2.3.37 (2003-01-24) + +- Building from GtkRadiant CVS trunk +- Added new brush bevel code by MrElusive to fix lingering aas problems (sweet!) +- Added -snap N arg to BSP phase for axial bevel plane snapping to reduce + clipped model plane count (note: will muck with above, use with care) +- Patches in terrain entities should now have proper vertex alpha set +- Fixed bug in fur code where fur was being limited to 2 layers (thanks pazur) +- Reduced vertexlight search area to a reasonable size to keep vertex lighting + times down + + +2.3.36 (2003-01-15) + +- Plane hashing re-enabled (I suck) +- Plane hashing optimized (faster parsing of larger maps) +- Plane finding accuracy code enabled +- New ASE clipping code + + With above should be 10-50% faster + + Should generate 33% fewer planes + + Generates mostly-axial 5-sided polyhedra instead of pyramids, + for tighter 2-sided clipping +- New -light args: + + -scale N -- scales all lightsources (area, radiosity, point, sky) + + -sky[scale] N -- scales sky lights (q3map_skylight, q3map_sunlight) +- Changed fur code to scale fur offset based on original vertex alpha + + +2.3.35 (2003-01-14) + +- PicoModel now inverts ASE T coordinate +- BSP to ASE converter now inverts T coordinate +- Disabling 2.3.34 triangle optimization code until I find out why it crashes +- Fixed Conscript-q3map2 to use stack_size ld flags directly on Darwin/OS X +- Added Conscript-q3map2 to q3map2.dsp for easier Win32 edit, *nix target + + +2.3.34 (2003-01-08) + +- Building from merged GtkRadiant 1.2 -> 1.3 merged codebase +- IMPORTANT NEW CHANGE: Light entities are now STRIPPED from the BSP file. + They are re-read in by -light from the MAP file. This has two consequences: + + It is no longer necessary to re-BSP & re-vis a map in order to change + lighting. You can just change lights in the map file and run -light. + + Slightly smaller BSP file, due to fewer entities + + Faster loading time, as the game code doesn't have to deal with them +- Added new -ne (normal epsilon) and -de (distance epsilon) for tuning precision + of plane snapping to correct potential AAS/BSP issues +- Using latest PicoModel, with support for RTCW MDC models +- Surfaces per raw lightmap are now sorted by shader name, which should give + slightly better lightmap efficiency and lower in-game shader counts +- Adjusted model code to use correct m4x4_t code & angles key +- Minor bugfix in patch color gradient calculation code +- Silenced erroneous areaportal warning spew +- q3map_tcGen now works on model surfaces +- Using default radiosity subdivide of 256 again (should make radiosity faster) +- Enabled byte-swapping code so Q3Map2 can be compiled/run on little-endian + architectures (Mac OS X) + + +2.3.33 (2002-12-08) + +- Added new -bouncescale argument for radiosity scaling +- Added -pointscale and -areascale for consistent naming +- Radiosity patch subdivision code enhanced +- Hint portals split the BSP first (higher priority) +- Antiportal and areaportal faces split the BSP last, to minimize errors +- Areaportals work internally like hint and antiportals, so they no longer need + to be full brushes (the other sides can be skip) +- External lightmaps are now named "lm_NNNN.tga" in the maps/mapname dir +- Cleaned up some of -light argument processing +- Planar surfaces w/o lightmaps will no longer be tagged as MST_TRIANGLE_SOUP + (this fixes problems with Particle Studio particles dropping out of view) + + +2.3.32 (2002-11-30) + +- GtkRadiant (1.2.11) integration +- Added epsilon to texture plane choose code to eliminate numerical + inconsistencies on brush faces slanted at 45 degree angles (bug 637) +- Fixed bug in lightmap export after lighting when map contains 0 BSP lightmaps +- Adjusted some light tracing constants to fix certain brush/patch seam shadows +- Tinkered with skylight code again +- Fixed bug where lightgrid would be black if level was compiled with -nogrid +- Fixed -approx code to work in floating-point space, using _minlight +- Fixed bug where vertex light code was using invalid pvs data to create + light list for surface, leading to incorrect vertex lighting +- Fixed related bug in anti-light-leak code that was causing brush faces to go + black (bug 694) +- New: _minlight sets _minvertexlight and (new) _mingridlight automatically +- New: _mingridlight key to set minimum grid lighting + + +2.3.31 (2002-11-21) + +- Stitching the edges of lightmaps on patches that wrap around (cyls and cones) + so the seam is no longer visible +- The -patchmeta switch works better now, the patches are still stored in the + BSP for collision, but are pre-tesselated into nonplanar meta surfaces for + more efficient rendering +- Better, more uniform lightmap sample position finding on patch meshes +- Moved q3map_tcMod and q3map_alphaMod processing to the final phase +- New: q3map_skylight AMOUNT ITERATIONS to replace surfacelight on sky surfaces + for much faster and more uniform sky illumination + + +2.3.30 (Splash Damage internal release) + +- Fixed bug in PicoModel ASE material parsing code +- Fixed a few seam/lightmap precision/projection errors +- Increased MAX_SHADER FILES to 1024 and fixed overrun error when more than that + number of shaders was listed in shaderlist.txt +- Increased a few compiler maximums for larger maps +- New: -np N switch on BSP phase, works like -shadeangle, in that it forces all + planar shaders to be nonplanar with the shading angle specified +- New: -nohint switch on BSP phase, omits hint brushes from compile for testing +- New: -debugaxis switch on light mode. Colors lightmaps based on their lightmap + axis (which direction the lightmap was projected on) +- New: -debugorigin switch on light mode. Colors lightmaps based on the luxel + origin relative to the raw lightmap's bounding box +- New: -debugcluster switch on light mode. Colors lightmaps based on the pvs + cluster the luxel falls into +- New: -convert switch to convert BSP to ASE file (experimental) +- New: q3map_lightmapmergable directive to allow terrain to be mapped onto a + single lightmap page for seamless terrain shadows + + +2.3.29 (2002-11-03) + +- Merged with latest CVS, fixed minor issues with matrix order +- Fixed minor Sys_FPrintf/Sys_Printf substitution typo in Q3Map2 +- Expanded debug colors to 12 for debugging surface meshes +- PicoModel: fixed ASE loader to support > 1 texture coordinate per-vertex, + so more models supported correctly, also loading vertex normals +- PicoModel: md3 shader names are now cleaned. Suffixes (such as .tga or .jpg) + are stripped, and \ path separators are changed to / +- New: Add :q3map to the end of any shader name, and it will be interpreted as + the named shader minus :q3map. Example: + textures/shaderlab/concrete:q3map -> textures/shaderlab/concrete + One potential use is the -approx feature to collapse lightmapped surfaces + into vertexlit surfaces, saving lightmap space/memory +- New: q3map_clipModel -- does what you think it does, sort of. This code ix + really experimental, and should *only* be used on large models such as terrain + (not small decorative models). This code will be evolving. Note: the shader's + surfaceparms are inherited by the magic clip brush, so if you have nonsolid + in your model's shader that uses q3map_clipModel, then the brush will also + be nonsolid + + +2.3.28 (2002-11-01) + +- Bug 654 (http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=654): + Fixed problem where brush faces, drawsurfaces, and surfaceparms weren't living + together in perfect harmony (terrain surfaceparms now inherited by brushes) +- Nodraw fog works now, albeit when you're underneath, surfaces above don't get + fogged properly. Could be good for foggy water where you want the above-water + portions to only be occluded by the water surface +- Bug 656 (http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=656): + Number of lightgrid points displayed (byte size is currently out of proportion + due to internal storage format) when Q3Map is called with the -info switch +- Fixed wack surface merging bug where code would attempt to merge triangles not + adjacent to the current set, causing bad lightmap projections on nonplanar + surfaces +- Fixed tiny 1-character bug in 2d lightmap texture allocator where adjacent + luxels were being checked for occlusion rather than the actual source luxel + + +2.3.27 (2002-10-31) Happy Halloween! + +- Fixed minor bug in scriplib bugfix where the last character in a file wasn't + being read. +- Fixed bug where 0-area or bogus triangles were causing crash in MapRawLightmap + if they used a shader with a normalmap (thanks ShadowSpawn) +- Fixed bug where lightmaps were getting hosed levelwide on a prerelease version + of 2.3.27 +- Fixed bug where lightmaps were getting knackered on models and certain patches +- Merged latest PicoModel version from seaw0lf, adding support for ASE and WF OBJ + models (preliminary) +- Increased MAX_MAP_PLANES to 0x40000 (~256k) + +Known issues: +- Lightmap projection and surface merging on large ASE models sometimes flakes +- Surface to brush surfaceparm propogation doesn't work properly with large + metasurfaces: http://zerowing.idsoftware.com/bugzilla/show_bug.cgi?id=654 + + +2.3.26 (2002-10-27) + +- Now using GtkRadiant's libpng and zlib config (linked as DLLs) +- Fixed bug in script parser where repeat calls to GetToken() were causing + memory corruption +- Fixed SOF2 -rename bug +- When using -game sof2 or -game jk2, the -flares argument is implied +- Added -noflares argument to disable the above behavior +- Added support for flares on entities. Use one of the following keys: + "_flare" "1" -- use default flare (different for each game) + "_flareshader" "path/to/flareshader" -- use a specific flare shader + Note: This only matters in SOF2/JK2 now. Make a light targetted (a spotlight) + to get it to aim the correct direction, otherwise it defaults to pointing + downward. You cannot have omnidirectional flares +- Lightgrid size is automatically increased to accomodate large maps. The + MAX_MAP_LIGHTGRID error will never happen again + + +2.3.25 (2002-10-22) + +- Go Giants! +- Fixed bug where Q3Map would crash on writing the BSP after the light stage. + Thanks to Rap7or (#q3map) and loon8 (Q3W forums) [bug 641] +- Fixed bug where surface lights were not affecting the light grid properly. + Thanks to Shadowspawn and djbob [bug 642] +- NEW: Added -faster support to lightgrid calculations while fixing previous bug +- NEW: Changed it so the BSP file is written to a temp file first, then renamed. + This should prevent BSP file corruption on crashes during writes + + +2.3.24 (2002-10-20) + +- Fixed numerous outstanding bugs and issues. +- Normal interpolation is now improved. It's slightly slower, but more 'correct' + in cases where you have 10 triangles in one plane and 1 triangle in another + meeting up and the 10 triangles were over-affecting the average. Only new + identical normals are averaged now. This change affects phong shading, meta + surfaces, and PicoModel +- PicoModel up to version 0.7.6, BSD license, better 3DS model support +- PicoModel library now fixes broken normals on MD3 and 3DS models +- Bumpmapping code is improved. The correct tangent vectors per-triangle are + now calculated so the bumpmaps are consistent with regards to light direction +- Metasurface merging code optimized. Should be about 100x as fast on complex + maps or maps using models with high triangle counts +- Vertexlight code tweaked a bit +- Triangle/winding orders now more consistent. Tesselated surfaces will have + a uniform triangle ordering (thanks RR2DO2) +- NEW: "vertexDeform move" now parsed and surfaces are merged into the + appropriate BSP leaves they may enter into (thanks to Bart Vrijkorte) +- NEW: shader command: q3map_alphaMod. Currently takes a single form: + q3map_alphaMod dotproduct ( NX NY NZ ) + where NX NY NZ are a unit normal (length of 1.0) specifying direction. + An example use would be snow in a shader's 2nd pass, using alphaFunc or + blendFunc: + q3map_alphaMod dotproduct ( 0 0 1 ) // surfaces facing upwards have snow + (idea contributed by RR2DO2) + + +2.3.23 (2002-10-18) + +- In my haste to release the previous version, I neglected to give credit where + it was due. Seaw0lf had as much (probably more) to do with the new model + loading library (PicoModel). Because of his efforts, you can load 3DS models + and use them in misc_model entities. +- PicoModel model library up to version 0.7. Improved 3DS support, more stable. +- Surface models still not reenabled. Soon. :) +- You can now remap a misc_model's shaders like this: + Key "_remapNN" "the/model/shader;the/real/shader" + This works just like TA terrain vertexRemapShader key. You can also supply a + * glob for the source shader if you want all your model's shaders to use the + specified shader: + "_remap" "*;models/mapobjects/tree/bark" + + +2.3.22 (2002-10-16) + +- Moving to sensible Linux-style versioning. +- The misc_model code has been completely rewritten, breaking surface models. + Surface models will reappear in the next release, once the new model API has + stablized. +- New: MD3 and 3D Studio 3DS models now natively supported. +- The misc_model "angles" key now supported. Values: "pitch yaw roll" in keeping + with standard Quake 3 angles order. +- Models scaled with "modelscale_vec" now have proper normal scaling/rotation + (thanks SPOG). +- Models can now be lightmapped. +- Models can now have > 1000 vertexes per surface. +- For best results for above, add the following to models' shaders: + q3map_splotchfix + q3map_nonplanar +- 3DS models' MATERIAL NAMES ARE THE FINAL Q3 SHADER NAMES. YOU HAVE BEEN WARNED. +- Models are generally 13373R. :) + + +2.3.0-a21 (2002-10-02) + +- Fixed a stack of really stupid bugs in the lightgrid code. Should be faster + and more predictable now. +- SOF2/JK2 lightgrid now compiled. This is the first version of Q3Map2 that can + compile full, release-worthy SOF2 and JK2 maps. +- SOF2/JK2 damageshader and damagable brush faces should work correctly now. + + +2.3.0-a20 (2002-09-26) + +- SOF2/JK2 worldspawn "fog" (and "_fog") shader key support for levelwide fog +- SOF2/JK2 light "scale" key to scale light brightness +- SOF2/JK2 -rename function for _bsp and _rmg_bsp shader renaming + + +2.3.0-a19 (2002-09-24) + +- Shaders can now be subclassed (Q3Map relavant portions only, such as + surfaceparms, lighting, texture projection, etc). To subclass an existing + shader, add "q3map_baseshader X" where X is the name of the base shader. +- Preliminary auto-model distribution over surfaces. You can now have things + like grass and tree models automatically distributed across your terrain + or other surfaces. To wit: + + q3map_surfacemodel models/mapobjects/tree2/tree2.md3 64 0.001 0.5 4.0 0 360 1 + + q3map_surfacemodel + + + The last flag is 1 or 0, and sets whether the model gets fitted to the + orientation of the surface. Not functional yet. See screenshots page for + shots of this in action. + + +2.3.0-a18 (2002-09-21) + +- misc_models can now be attached to any brush model entity. Just target the + brush entity with the misc_model (select model, then entity, hit Ctrl+K) +- q3map_tcMod translate (or shift or offset) +- q3map_tcMod rotate (rotates around origin, not center) +- q3map_tcMod scale +- Metasurface merging now much, much better. Merges into roughly rectangular or + square areas wherever possible +- q3map_terrain no longer sets Z-axis lightmap projection. It must be set in + the terrain layer shaders if you want previous behavior +- Worlspawn _blocksize key now supports 3 elements for setting X Y and Z splits + independently of each other (use a value of 0 for no splits on that axis) +- Misc bugfixes + + +2.3.0-a1 through 2.3.0-a17 (2002-07 through 2002-09-20) + +- Elite Force support (via -game ef) +- SOF2 and JK2 support (via -game sof2 or -game jk2) +- All new image handling with PNG support +- q3map_lightimage specifies image for radiosity and lighting +- External lightmaps, set using q3map_lightmapsize . Up to + 1024 x 1024 supported. +- q3map_lightmapGamma sets the brightness scale of a lightmap +- q3map_lightmapsampleoffset to fix glitches in lightmapped terrain +- Tons more features and bugfixes. See the forum threads for details/screenshots +- Two new surfaceparms, "antiportal" and "skip," and associated shaders, for + allowing the mapper to more cleanly set up visibility data +- Lightmaps will always have square texels now (no more stretching) +- Vertex light improvements +- Light grid improvements +- q3map_lightrgb support for RTCW + + + + + + diff --git a/tools/quake3/q3map2/listen.pl b/tools/quake3/q3map2/listen.pl index 20001360..6101a767 100644 --- a/tools/quake3/q3map2/listen.pl +++ b/tools/quake3/q3map2/listen.pl @@ -1,46 +1,46 @@ -#!/usr/bin/perl -w - -use IO::Socket; -use Net::hostent; - -my $port = shift || 13131; - -my $server = IO::Socket::INET->new( - Proto => 'tcp', - LocalPort => $port, - Listen => SOMAXCONN, - Reuse => 1 ) - || die "can't setup server"; -print "[Q3Map2 listener $0 is now active on port $port]\n"; - -while( $client = $server->accept() ) -{ - - $client->autoflush( 1 ); - - $hostinfo = gethostbyaddr( $client->peeraddr ); - printf "[Connect from %s]\n\n", $hostinfo ? $hostinfo->name : $client->peerhost; - - #ask the client for a command - print $client "[server]\$"; - my $text = ""; - while( <$client> ) - { - $text .= $_; - while( $text =~ s|]*>([^<]+)|| ) - { - my $msg = $1; - - # fix xml ents - $msg =~ s|<|<|g; - $msg =~ s|>|>|g; - $msg =~ s|"|"|g;#" - $msg =~ s|'|'|g;#' - - print $msg; - } - } - - printf "\n[Disconnected: %s]\n\n", $hostinfo ? $hostinfo->name : $client->peerhost; - close $client; -} +#!/usr/bin/perl -w + +use IO::Socket; +use Net::hostent; + +my $port = shift || 13131; + +my $server = IO::Socket::INET->new( + Proto => 'tcp', + LocalPort => $port, + Listen => SOMAXCONN, + Reuse => 1 ) + || die "can't setup server"; +print "[Q3Map2 listener $0 is now active on port $port]\n"; + +while( $client = $server->accept() ) +{ + + $client->autoflush( 1 ); + + $hostinfo = gethostbyaddr( $client->peeraddr ); + printf "[Connect from %s]\n\n", $hostinfo ? $hostinfo->name : $client->peerhost; + + #ask the client for a command + print $client "[server]\$"; + my $text = ""; + while( <$client> ) + { + $text .= $_; + while( $text =~ s|]*>([^<]+)|| ) + { + my $msg = $1; + + # fix xml ents + $msg =~ s|<|<|g; + $msg =~ s|>|>|g; + $msg =~ s|"|"|g;#" + $msg =~ s|'|'|g;#' + + print $msg; + } + } + + printf "\n[Disconnected: %s]\n\n", $hostinfo ? $hostinfo->name : $client->peerhost; + close $client; +} diff --git a/utils.py b/utils.py index f8838952..1e9774af 100644 --- a/utils.py +++ b/utils.py @@ -1,130 +1,130 @@ -# -*- mode: python -*- -# QuakeZero build scripts -# TTimo -# http://scons.sourceforge.net - -import os, commands, platform, xml.sax, re, string, platform - -class vcproj( xml.sax.handler.ContentHandler ): - def __init__( self, filepath ): - self.source_files = [] - self.misc_files = [] - self._files = [] - print 'parse %s' % filepath - xml.sax.parse( filepath, self ) - - def getSourceFiles( self ): - return self.source_files - - def filterSource( self, expression, filelist = None ): - if ( filelist is None ): - filelist = self.source_files - match = [] - nomatch = [] - for s in filelist: - if ( re.match( expression, s ) ): - match.append( s ) - else: - nomatch.append( s ) - return ( match, nomatch ) - - def startElement( self, name, attrs ): - if ( name == 'File' ): - self._files.append( attrs.getValue('RelativePath') ) - - def endDocument( self ): - # split into source and headers, remap path seperator to the platform - for f in self._files: - if ( platform.system() != 'Windows' ): - f = f.replace( '\\', '/' ) - if ( f[-2:] == '.c' or f[-4:] == '.cpp' ): - self.source_files.append( f.encode('ascii') ) - else: - self.misc_files.append( f ) - print '%d source files' % len( self.source_files ) - -# action uses LDD to verify that the source doesn't hold unresolved symbols -# setup as an AddPostAction of a regular SharedLibrary call -def CheckUnresolved( source, target, env ): - # TODO: implement this for OSX - if ( platform.system() == 'Darwin' ): - return None - print 'CheckUnresolved %s' % target[0].abspath - if ( not os.path.isfile( target[0].abspath ) ): - print 'CheckUnresolved: %s does not exist' % target[0] - return 1 # fail - ( status, output ) = commands.getstatusoutput( 'ldd -r %s' % target[0] ) - if ( status != 0 ): - print 'CheckUnresolved: ldd command failed (exit code %d)' % status - os.system( 'rm %s' % target[ 0 ] ) - return 1 # fail - lines = string.split( output, '\n' ) - have_undef = 0 - for i_line in lines: - regex = re.compile('undefined symbol: (.*)\t\\((.*)\\)') - if ( regex.match( i_line ) ): - symbol = regex.sub( '\\1', i_line ) - try: - env['ALLOWED_SYMBOLS'].index( symbol ) - except: - have_undef = 1 - if ( have_undef ): - print output - print "CheckUnresolved: undefined symbols" - os.system('rm %s' % target[0]) - return 1 - -# http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/413486 - -def Enum(*names): - ##assert names, "Empty enums are not supported" # <- Don't like empty enums? Uncomment! - - class EnumClass(object): - __slots__ = names - def __iter__(self): return iter(constants) - def __len__(self): return len(constants) - def __getitem__(self, i): return constants[i] - def __repr__(self): return 'Enum' + str(names) - def __str__(self): return 'enum ' + str(constants) - - class EnumValue(object): - __slots__ = ('__value') - def __init__(self, value): self.__value = value - Value = property(lambda self: self.__value) - EnumType = property(lambda self: EnumType) - def __hash__(self): return hash(self.__value) - def __cmp__(self, other): - # C fans might want to remove the following assertion - # to make all enums comparable by ordinal value {;)) - assert self.EnumType is other.EnumType, "Only values from the same enum are comparable" - return cmp(self.__value, other.__value) - def __invert__(self): return constants[maximum - self.__value] - def __nonzero__(self): return bool(self.__value) - def __repr__(self): return str(names[self.__value]) - - maximum = len(names) - 1 - constants = [None] * len(names) - for i, each in enumerate(names): - val = EnumValue(i) - setattr(EnumClass, each, val) - constants[i] = val - constants = tuple(constants) - EnumType = EnumClass() - return EnumType - -#if __name__ == '__main__': -# print '\n*** Enum Demo ***' -# print '--- Days of week ---' -# Days = Enum('Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su') -# print Days -# print Days.Mo -# print Days.Fr -# print Days.Mo < Days.Fr -# print list(Days) -# for each in Days: -# print 'Day:', each -# print '--- Yes/No ---' -# Confirmation = Enum('No', 'Yes') -# answer = Confirmation.No -# print 'Your answer is not', ~answer - +# -*- mode: python -*- +# QuakeZero build scripts +# TTimo +# http://scons.sourceforge.net + +import os, commands, platform, xml.sax, re, string, platform + +class vcproj( xml.sax.handler.ContentHandler ): + def __init__( self, filepath ): + self.source_files = [] + self.misc_files = [] + self._files = [] + print 'parse %s' % filepath + xml.sax.parse( filepath, self ) + + def getSourceFiles( self ): + return self.source_files + + def filterSource( self, expression, filelist = None ): + if ( filelist is None ): + filelist = self.source_files + match = [] + nomatch = [] + for s in filelist: + if ( re.match( expression, s ) ): + match.append( s ) + else: + nomatch.append( s ) + return ( match, nomatch ) + + def startElement( self, name, attrs ): + if ( name == 'File' ): + self._files.append( attrs.getValue('RelativePath') ) + + def endDocument( self ): + # split into source and headers, remap path seperator to the platform + for f in self._files: + if ( platform.system() != 'Windows' ): + f = f.replace( '\\', '/' ) + if ( f[-2:] == '.c' or f[-4:] == '.cpp' ): + self.source_files.append( f.encode('ascii') ) + else: + self.misc_files.append( f ) + print '%d source files' % len( self.source_files ) + +# action uses LDD to verify that the source doesn't hold unresolved symbols +# setup as an AddPostAction of a regular SharedLibrary call +def CheckUnresolved( source, target, env ): + # TODO: implement this for OSX + if ( platform.system() == 'Darwin' ): + return None + print 'CheckUnresolved %s' % target[0].abspath + if ( not os.path.isfile( target[0].abspath ) ): + print 'CheckUnresolved: %s does not exist' % target[0] + return 1 # fail + ( status, output ) = commands.getstatusoutput( 'ldd -r %s' % target[0] ) + if ( status != 0 ): + print 'CheckUnresolved: ldd command failed (exit code %d)' % status + os.system( 'rm %s' % target[ 0 ] ) + return 1 # fail + lines = string.split( output, '\n' ) + have_undef = 0 + for i_line in lines: + regex = re.compile('undefined symbol: (.*)\t\\((.*)\\)') + if ( regex.match( i_line ) ): + symbol = regex.sub( '\\1', i_line ) + try: + env['ALLOWED_SYMBOLS'].index( symbol ) + except: + have_undef = 1 + if ( have_undef ): + print output + print "CheckUnresolved: undefined symbols" + os.system('rm %s' % target[0]) + return 1 + +# http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/413486 + +def Enum(*names): + ##assert names, "Empty enums are not supported" # <- Don't like empty enums? Uncomment! + + class EnumClass(object): + __slots__ = names + def __iter__(self): return iter(constants) + def __len__(self): return len(constants) + def __getitem__(self, i): return constants[i] + def __repr__(self): return 'Enum' + str(names) + def __str__(self): return 'enum ' + str(constants) + + class EnumValue(object): + __slots__ = ('__value') + def __init__(self, value): self.__value = value + Value = property(lambda self: self.__value) + EnumType = property(lambda self: EnumType) + def __hash__(self): return hash(self.__value) + def __cmp__(self, other): + # C fans might want to remove the following assertion + # to make all enums comparable by ordinal value {;)) + assert self.EnumType is other.EnumType, "Only values from the same enum are comparable" + return cmp(self.__value, other.__value) + def __invert__(self): return constants[maximum - self.__value] + def __nonzero__(self): return bool(self.__value) + def __repr__(self): return str(names[self.__value]) + + maximum = len(names) - 1 + constants = [None] * len(names) + for i, each in enumerate(names): + val = EnumValue(i) + setattr(EnumClass, each, val) + constants[i] = val + constants = tuple(constants) + EnumType = EnumClass() + return EnumType + +#if __name__ == '__main__': +# print '\n*** Enum Demo ***' +# print '--- Days of week ---' +# Days = Enum('Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su') +# print Days +# print Days.Mo +# print Days.Fr +# print Days.Mo < Days.Fr +# print list(Days) +# for each in Days: +# print 'Day:', each +# print '--- Yes/No ---' +# Confirmation = Enum('No', 'Yes') +# answer = Confirmation.No +# print 'Your answer is not', ~answer + diff --git a/win32_install.py b/win32_install.py index 825ebcc2..03db6c12 100644 --- a/win32_install.py +++ b/win32_install.py @@ -1,166 +1,166 @@ -# install the fucking files -# check the md5 to decide for a copy -# we have a site.conf to go through -# and a data list of stuff -# it's called at the end of each build to copy what needs to be -# it could be called only at GtkRadiant link time - -# command line: a bunch of config switches default would be debug?, and release flag - - -import sys, traceback, os, re, filecmp, shutil, pickle, string -from makeversion import get_version - -(line, major, minor) = get_version() - -paths = { - 'CORERADIANTDIR' : 'C:\\Program Files\\GtkRadiant-1.' + major, - 'RTCWRADIANTDIR' : 'C:\\Program Files\\Return to Castle Wolfenstein - Game of The Year Edition\\Radiant-1.' + major, - 'HLRADIANTDIR' : 'C:\\Sierra\\Half-Life\\Radiant-1.' + major, - 'SOF2RADIANTDIR' : 'C:\\Program Files\\Soldier of Fortune II - Double Helix\\Radiant-1.' + major, - 'QUAKE2RADIANTDIR' : 'C:\\Quake2\\Radiant-1.' + major, - 'HERETIC2RADIANTDIR' : 'C:\\Heretic2\\Radiant-1.' + major - } - -conf_filename='site.conf.win32' - -# site settings ---------------------- - -if (os.path.exists(conf_filename)): - site_file = open(conf_filename, 'r') - p = pickle.Unpickler(site_file) - paths = p.load() - print 'Loaded configuration from ' + conf_filename - -# end site settings ------------------ - -# command line overrides ------------- - -print '\nCommand line:' -regex = re.compile("(.*)=(.*)") -for i in sys.argv[1:]: - #print i - if ( regex.match(i) ): - (key, val) = string.split(i, '=') - #print 'key: %s val: %s' % (key, val) - paths[key] = val - else: - print 'Can''t parse command line - ignore: ' + i - -# end command line overrides --------- - -# save config ------------------------ - -site_file = open(conf_filename, 'w') -p = pickle.Pickler(site_file) -p.dump(paths) -site_file.close() - -print '\nConfiguration:' - -for i in paths.keys(): - print '%s -> %s' % (i, paths[i]) - -# end save config -------------------- - -q3map2_list = [ -# ( ( '..\\libpng\\projects\\msvc\\win32\\zlib\\dll_dbg\\zlibd.dll', '..\\libpng\\projects\\msvc\\win32\\zlib\\dll\\zlib.dll' ), '$CORERADIANTDIR' ), -# ( ( '..\\libpng\\projects\\msvc\\win32\\libpng\\dll_dbg\\libpng13d.dll', '..\\libpng\\projects\\msvc\\win32\\libpng\\dll\\libpng13.dll' ), '$CORERADIANTDIR' ), -# ( ( '..\\libxml2\\win32\\binaries-debug\\libxml2.dll', '..\\libxml2\\win32\\binaries-release\\libxml2.dll' ), '$CORERADIANTDIR' ), - ( ( 'tools\\quake3\\q3map2\\Debug\\Q3Map2.exe', 'tools\\quake3\\q3map2\\Release\\Q3Map2.exe' ), '$CORERADIANTDIR' ), - ] - -all = [ - ( ( 'radiant\\Debug\\GtkRadiant.exe', 'radiant\\Release\\GtkRadiant.exe' ) , '$CORERADIANTDIR' ), - ( ( 'contrib\\bobtoolz\\Debug\\bobToolz.dll', 'contrib\\bobtoolz\\Release\\bobToolz.dll' ), '$CORERADIANTDIR\\plugins' ), - ( ( 'contrib\\camera\\Debug\\camera.dll', 'contrib\\camera\\Release\\camera.dll' ), '$CORERADIANTDIR\\plugins' ), - ( ( 'plugins\\entity\\Debug\\entity.dll', 'plugins\\entity\\Release\\entity.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\eclassfgd\\Debug\\fgd.dll', 'plugins\\eclassfgd\\Release\\fgd.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'contrib\\gtkgensurf\\Debug\\gensurf.dll', 'contrib\\gtkgensurf\\Release\\gensurf.dll' ), '$CORERADIANTDIR\\plugins' ), - ( ( 'contrib\\hydratoolz\\Debug\\hydratoolz.dll', 'contrib\\hydratoolz\\Release\\hydratoolz.dll' ), '$HLRADIANTDIR\\plugins' ), - ( ( 'plugins\\image\\Debug\\image.dll', 'plugins\\image\\Release\\image.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\imagewal\\Debug\\imagewal.dll', 'plugins\\imagewal\\Release\\imagewal.dll' ), '$QUAKE2RADIANTDIR\\modules' ), - ( ( 'plugins\\imagehl\\Debug\\imagehl.dll', 'plugins\\imagehl\\Release\\imagehl.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\imagepng\\Debug\\imagepng.dll', 'plugins\\imagepng\\Release\\imagepng.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\map\\Debug\\map.dll', 'plugins\\map\\Release\\map.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\mapxml\\Debug\\mapxml.dll', 'plugins\\mapxml\\Release\\mapxml.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\model\\Debug\\model.dll', 'plugins\\model\\Release\\model.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'contrib\\prtview\\Debug\\PrtView.dll', 'contrib\\prtview\\Release\\PrtView.dll' ), '$CORERADIANTDIR\\plugins' ), - ( ( 'tools\\quake3\\q3data\\Debug\\q3data.exe', 'tools\\quake3\\q3data\\Release\\q3data.exe' ), '$CORERADIANTDIR' ), - ( ( 'plugins\\shaders\\Debug\\shaders.dll', 'plugins\\shaders\\Release\\shaders.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\spritemodel\\Debug\\spritemodel.dll', 'plugins\\spritemodel\\Release\\spritemodel.dll' ), '$CORERADIANTDIR\\modules' ), -# ( ( 'Debug\\TexTool.dll', 'Release\\TexTool.dll' ), '$CORERADIANTDIR\\plugins' ), - ( ( 'plugins\\vfspk3\\Debug\\vfspk3.dll', 'plugins\\vfspk3\\Release\\vfspk3.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\vfspak\\Debug\\vfspak.dll', 'plugins\\vfspak\\Release\\vfspak.dll' ), '$QUAKE2RADIANTDIR\\modules' ), - ( ( 'plugins\\vfswad\\Debug\\vfswad.dll', 'plugins\\vfswad\\Release\\vfswad.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\surface\\Debug\\surface.dll', 'plugins\\surface\\Release\\surface.dll' ), '$CORERADIANTDIR\\modules' ), - ( ( 'plugins\\surface_quake2\\Debug\\surface_quake2.dll', 'plugins\\surface_quake2\\Release\\surface_quake2.dll' ), '$QUAKE2RADIANTDIR\\modules' ), - ( ( 'tools\\quake2\\q2map\\Debug\\q2map.exe', 'tools\\quake2\\q2map\\Release\\q2map.exe' ) , '$QUAKE2RADIANTDIR' ), - ( ( 'tools\\quake2\\qdata\\Debug\\qdata3.exe', 'tools\\quake2\\qdata\\Release\\qdata3.exe' ) , '$QUAKE2RADIANTDIR' ), - ( ( 'plugins\\vfspak\\Debug\\vfspak.dll', 'plugins\\vfspak\\Release\\vfspak.dll' ), '$HERETIC2RADIANTDIR\\modules' ), - ( ( 'plugins\\imagem8\\Debug\\imagem8.dll', 'plugins\\imagem8\\Release\\imagem8.dll' ), '$HERETIC2RADIANTDIR\\modules' ), - ( ( 'plugins\\surface_heretic2\\Debug\\surface_heretic2.dll', 'plugins\\surface_heretic2\\Release\\surface_heretic2.dll' ), '$HERETIC2RADIANTDIR\\modules' ), - ( ( 'tools\\quake2\\qdata_heretic2\\Debug\\qdata3.exe', 'tools\\quake2\\qdata_heretic2\\Release\\qdata3.exe' ) , '$HERETIC2RADIANTDIR' ), - ( ( 'contrib\\bkgrnd2d\\Debug\\bkgrnd2d.dll', 'contrib\\bkgrnd2d\\Release\\bkgrnd2d.dll' ), '$CORERADIANTDIR\\plugins' ), - ] - -config = 0 -q3map2 = 0 - -# config check -for i in sys.argv: - if ( i == 'release' ): - config = 1 - elif ( i == 'q3map2' ): - q3map2 = 1 - -if ( config == 1 ): - print 'installing release binaries' -else: - print 'installing debug binaries' - -def expand(path_in): - for matches in paths.keys(): - exp = re.compile('\\$%s' % matches) - if ( not re.match(exp, path_in) is None ): - #print "Got a match for %s on %s" % ( matches, path_in ) - path_in = re.sub(exp, paths[matches], path_in) - #print "Processed to: %s" % path_in - return path_in - -# don't bother about stderr -sys.stderr = sys.stdout - -if ( q3map2 == 0 ): - stuff = q3map2_list - stuff += all -else: - stuff = q3map2_list - -for entries in stuff: - try: - src = expand(entries[0][config]) - #print "src basename: %s -> %s" % (src, os.path.basename(src)) - dst = entries[1] - dst = os.path.join( entries[1], os.path.basename(src) ) - dst = expand(dst) - #print "src: %s dst: %s" % (src, dst) - if (os.path.isfile(src)): - if (os.path.isfile(dst)): - if (not filecmp.cmp(src, dst)): - shutil.copy(src, dst) - print "%s: OK - updated" % dst - else: - print "%s: OK - already up to date" % dst - else: - shutil.copy(src, dst) - print "%s: OK - installed" % dst - else: - print "%s: FAILED - not found" % src - if (os.path.isfile(dst)): - print "delete %s" % dst - os.remove(dst) - except: - print "%s: FAILED" % src - traceback.print_exc() - +# install the fucking files +# check the md5 to decide for a copy +# we have a site.conf to go through +# and a data list of stuff +# it's called at the end of each build to copy what needs to be +# it could be called only at GtkRadiant link time + +# command line: a bunch of config switches default would be debug?, and release flag + + +import sys, traceback, os, re, filecmp, shutil, pickle, string +from makeversion import get_version + +(line, major, minor) = get_version() + +paths = { + 'CORERADIANTDIR' : 'C:\\Program Files\\GtkRadiant-1.' + major, + 'RTCWRADIANTDIR' : 'C:\\Program Files\\Return to Castle Wolfenstein - Game of The Year Edition\\Radiant-1.' + major, + 'HLRADIANTDIR' : 'C:\\Sierra\\Half-Life\\Radiant-1.' + major, + 'SOF2RADIANTDIR' : 'C:\\Program Files\\Soldier of Fortune II - Double Helix\\Radiant-1.' + major, + 'QUAKE2RADIANTDIR' : 'C:\\Quake2\\Radiant-1.' + major, + 'HERETIC2RADIANTDIR' : 'C:\\Heretic2\\Radiant-1.' + major + } + +conf_filename='site.conf.win32' + +# site settings ---------------------- + +if (os.path.exists(conf_filename)): + site_file = open(conf_filename, 'r') + p = pickle.Unpickler(site_file) + paths = p.load() + print 'Loaded configuration from ' + conf_filename + +# end site settings ------------------ + +# command line overrides ------------- + +print '\nCommand line:' +regex = re.compile("(.*)=(.*)") +for i in sys.argv[1:]: + #print i + if ( regex.match(i) ): + (key, val) = string.split(i, '=') + #print 'key: %s val: %s' % (key, val) + paths[key] = val + else: + print 'Can''t parse command line - ignore: ' + i + +# end command line overrides --------- + +# save config ------------------------ + +site_file = open(conf_filename, 'w') +p = pickle.Pickler(site_file) +p.dump(paths) +site_file.close() + +print '\nConfiguration:' + +for i in paths.keys(): + print '%s -> %s' % (i, paths[i]) + +# end save config -------------------- + +q3map2_list = [ +# ( ( '..\\libpng\\projects\\msvc\\win32\\zlib\\dll_dbg\\zlibd.dll', '..\\libpng\\projects\\msvc\\win32\\zlib\\dll\\zlib.dll' ), '$CORERADIANTDIR' ), +# ( ( '..\\libpng\\projects\\msvc\\win32\\libpng\\dll_dbg\\libpng13d.dll', '..\\libpng\\projects\\msvc\\win32\\libpng\\dll\\libpng13.dll' ), '$CORERADIANTDIR' ), +# ( ( '..\\libxml2\\win32\\binaries-debug\\libxml2.dll', '..\\libxml2\\win32\\binaries-release\\libxml2.dll' ), '$CORERADIANTDIR' ), + ( ( 'tools\\quake3\\q3map2\\Debug\\Q3Map2.exe', 'tools\\quake3\\q3map2\\Release\\Q3Map2.exe' ), '$CORERADIANTDIR' ), + ] + +all = [ + ( ( 'radiant\\Debug\\GtkRadiant.exe', 'radiant\\Release\\GtkRadiant.exe' ) , '$CORERADIANTDIR' ), + ( ( 'contrib\\bobtoolz\\Debug\\bobToolz.dll', 'contrib\\bobtoolz\\Release\\bobToolz.dll' ), '$CORERADIANTDIR\\plugins' ), + ( ( 'contrib\\camera\\Debug\\camera.dll', 'contrib\\camera\\Release\\camera.dll' ), '$CORERADIANTDIR\\plugins' ), + ( ( 'plugins\\entity\\Debug\\entity.dll', 'plugins\\entity\\Release\\entity.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\eclassfgd\\Debug\\fgd.dll', 'plugins\\eclassfgd\\Release\\fgd.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'contrib\\gtkgensurf\\Debug\\gensurf.dll', 'contrib\\gtkgensurf\\Release\\gensurf.dll' ), '$CORERADIANTDIR\\plugins' ), + ( ( 'contrib\\hydratoolz\\Debug\\hydratoolz.dll', 'contrib\\hydratoolz\\Release\\hydratoolz.dll' ), '$HLRADIANTDIR\\plugins' ), + ( ( 'plugins\\image\\Debug\\image.dll', 'plugins\\image\\Release\\image.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\imagewal\\Debug\\imagewal.dll', 'plugins\\imagewal\\Release\\imagewal.dll' ), '$QUAKE2RADIANTDIR\\modules' ), + ( ( 'plugins\\imagehl\\Debug\\imagehl.dll', 'plugins\\imagehl\\Release\\imagehl.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\imagepng\\Debug\\imagepng.dll', 'plugins\\imagepng\\Release\\imagepng.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\map\\Debug\\map.dll', 'plugins\\map\\Release\\map.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\mapxml\\Debug\\mapxml.dll', 'plugins\\mapxml\\Release\\mapxml.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\model\\Debug\\model.dll', 'plugins\\model\\Release\\model.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'contrib\\prtview\\Debug\\PrtView.dll', 'contrib\\prtview\\Release\\PrtView.dll' ), '$CORERADIANTDIR\\plugins' ), + ( ( 'tools\\quake3\\q3data\\Debug\\q3data.exe', 'tools\\quake3\\q3data\\Release\\q3data.exe' ), '$CORERADIANTDIR' ), + ( ( 'plugins\\shaders\\Debug\\shaders.dll', 'plugins\\shaders\\Release\\shaders.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\spritemodel\\Debug\\spritemodel.dll', 'plugins\\spritemodel\\Release\\spritemodel.dll' ), '$CORERADIANTDIR\\modules' ), +# ( ( 'Debug\\TexTool.dll', 'Release\\TexTool.dll' ), '$CORERADIANTDIR\\plugins' ), + ( ( 'plugins\\vfspk3\\Debug\\vfspk3.dll', 'plugins\\vfspk3\\Release\\vfspk3.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\vfspak\\Debug\\vfspak.dll', 'plugins\\vfspak\\Release\\vfspak.dll' ), '$QUAKE2RADIANTDIR\\modules' ), + ( ( 'plugins\\vfswad\\Debug\\vfswad.dll', 'plugins\\vfswad\\Release\\vfswad.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\surface\\Debug\\surface.dll', 'plugins\\surface\\Release\\surface.dll' ), '$CORERADIANTDIR\\modules' ), + ( ( 'plugins\\surface_quake2\\Debug\\surface_quake2.dll', 'plugins\\surface_quake2\\Release\\surface_quake2.dll' ), '$QUAKE2RADIANTDIR\\modules' ), + ( ( 'tools\\quake2\\q2map\\Debug\\q2map.exe', 'tools\\quake2\\q2map\\Release\\q2map.exe' ) , '$QUAKE2RADIANTDIR' ), + ( ( 'tools\\quake2\\qdata\\Debug\\qdata3.exe', 'tools\\quake2\\qdata\\Release\\qdata3.exe' ) , '$QUAKE2RADIANTDIR' ), + ( ( 'plugins\\vfspak\\Debug\\vfspak.dll', 'plugins\\vfspak\\Release\\vfspak.dll' ), '$HERETIC2RADIANTDIR\\modules' ), + ( ( 'plugins\\imagem8\\Debug\\imagem8.dll', 'plugins\\imagem8\\Release\\imagem8.dll' ), '$HERETIC2RADIANTDIR\\modules' ), + ( ( 'plugins\\surface_heretic2\\Debug\\surface_heretic2.dll', 'plugins\\surface_heretic2\\Release\\surface_heretic2.dll' ), '$HERETIC2RADIANTDIR\\modules' ), + ( ( 'tools\\quake2\\qdata_heretic2\\Debug\\qdata3.exe', 'tools\\quake2\\qdata_heretic2\\Release\\qdata3.exe' ) , '$HERETIC2RADIANTDIR' ), + ( ( 'contrib\\bkgrnd2d\\Debug\\bkgrnd2d.dll', 'contrib\\bkgrnd2d\\Release\\bkgrnd2d.dll' ), '$CORERADIANTDIR\\plugins' ), + ] + +config = 0 +q3map2 = 0 + +# config check +for i in sys.argv: + if ( i == 'release' ): + config = 1 + elif ( i == 'q3map2' ): + q3map2 = 1 + +if ( config == 1 ): + print 'installing release binaries' +else: + print 'installing debug binaries' + +def expand(path_in): + for matches in paths.keys(): + exp = re.compile('\\$%s' % matches) + if ( not re.match(exp, path_in) is None ): + #print "Got a match for %s on %s" % ( matches, path_in ) + path_in = re.sub(exp, paths[matches], path_in) + #print "Processed to: %s" % path_in + return path_in + +# don't bother about stderr +sys.stderr = sys.stdout + +if ( q3map2 == 0 ): + stuff = q3map2_list + stuff += all +else: + stuff = q3map2_list + +for entries in stuff: + try: + src = expand(entries[0][config]) + #print "src basename: %s -> %s" % (src, os.path.basename(src)) + dst = entries[1] + dst = os.path.join( entries[1], os.path.basename(src) ) + dst = expand(dst) + #print "src: %s dst: %s" % (src, dst) + if (os.path.isfile(src)): + if (os.path.isfile(dst)): + if (not filecmp.cmp(src, dst)): + shutil.copy(src, dst) + print "%s: OK - updated" % dst + else: + print "%s: OK - already up to date" % dst + else: + shutil.copy(src, dst) + print "%s: OK - installed" % dst + else: + print "%s: FAILED - not found" % src + if (os.path.isfile(dst)): + print "delete %s" % dst + os.remove(dst) + except: + print "%s: FAILED" % src + traceback.print_exc() +