Commit Graph
85 Commits
Author SHA1 Message Date
ac-stef edc7f48f33 revert (hack style) fix to clean up invisible cubes
This fix is no longer needed, because the new corner handling in the
physics engine does no longer care about those cubes. Also, they can
now be cleaned up by mapmrproper.
2014-05-15 13:48:31 +02:00
ac-stef 859df26089 refactored load_world and save_world
* separated "loading the map" from "collecting map statistics"
* replaced the buggy toptimize with mapmrproper as default
  pre-save optimiser
* add timestamps to loadmap-stats
2014-05-15 13:48:30 +02:00
ac-stef 24c5fada62 new cleanup tool for hidden map attributes
"mapmrproper" tries to optimize hidden attributes of maps in a way, that
the map can be handled in bigger chunks by the renderer.

The mipmapping routine does not take into account, if certain textures
of a cube are visible at all, when it collects otherwise identical cubes
to be handled en-bloc. "mapmrproper" changes invisible textures in a way,
that the cubes are in fact identical - so, that the mipmapper is satisfied.

This optimization is a bit too huge for now, to be used by savemap by
default (instead of toptimize()) - even though mapmrproper is far superior
to toptimize(). Since mapmrproper potentially changes a lot of textures,
it may be too annoying during the creation of a map anyway. It is a tool
to optimize the map, as soon as the geometry (and texturing) is done.

The optimizer does not change any map properties that are visible in any
way. The optical effect of slightly changing lighting of the map is caused
by the (light-) recalc() function at the end of the optimization run.
Every run of recalc() seems to have that effect (check for yourself, by
typing /recalc several times).

Before any changes are made, mapmrproper creates a backup, which can be
restored by "undo" (press "U"). Enable mipstats (F6), to see, what has
been done.

The command "calcmipstats" just counts all the mips in the current map,
and prints their numbers as 1x1/2x2/4x4/8x8/16x16/32x32/64x64.

Keep in mind, that map geometry /and/ lighting affects the mipmapping.
(To get a better idea of this, try changing the "lighterror" parameter)
2014-05-15 13:48:30 +02:00
ac-stef 2c2395d97a have the waterlevel variable reflect the actual value of the map 2014-05-15 11:43:37 +02:00
ac-stef 5058172a06 fix empty map name after /newmap and fix voting for nonexistent maps
now /savemap after /newmap saves to "newmap.cgz" instead of ".cgz"

also, voting for a nonexistent map in singleplayer leaves the client in
some sort of a broken state. this fix blocks the vote.

and: newmap is blocked in bot modes, since that isn't working stable.
2014-05-14 22:39:57 +02:00
ac-stef c3d4713904 clean up map header handling
Older versions of ac did not obey the map header field "headersize".
When a map was written, only the "version" field was updated, even if
the new written header had a different size. Thanks to bigger headers
in map versions 7 & 8 (and now smaller headers again in 9), the headersize
of basically all official maps is bogus. This fix makes sure, only proper
headersizes are written. It also makes the game tolerate different (bigger)
headers - and keeps their content untouched. Future map format extensions
can use this to add header information without breaking existing map parsers.

This patch establishes a new map format 10, which is identical to format 9,
with the exception that the headersize field is guaranteed to be correct.
Format 10 also allows any amount of additional header data.

This patch also cleans up the transformation routines for old map entities.
2014-01-27 23:01:23 +01:00
ac-stef 9066c36b89 physics fix: clean up invisible cubes
have the physics engine take the same shortcuts as the render engine
2014-01-26 20:36:06 +01:00
Lucas GAUTHERON a7a1e46bcc merged branch
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7382 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2013-03-22 19:49:21 +00:00
Lucas GAUTHERON 3beb50b3c6 scalelights disabled in MP
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7335 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2013-03-10 01:34:36 +00:00
Lucas GAUTHERON 33bd0e9420 newmap and minimap bug fix
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7293 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2013-03-03 23:39:56 +00:00
Bukz 7480f036d3 persistidents fixes (plz review/test)
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7213 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2013-02-16 01:43:47 +00:00
aerkefiende 58abfb3ace Sound bug fix by Felix-The-Ghost
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7117 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2013-01-19 21:44:40 +00:00
sireus b33116712c sane(r) command signatures (warning: huge commit)
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6908 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2012-10-06 22:49:49 +00:00
Lucas GAUTHERON ad97f148ef newmap bug fix
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6652 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-09-15 20:09:37 +00:00
Lucas GAUTHERON 8f90268d82 multiple selections support in editmode
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6647 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-09-14 14:59:40 +00:00
Bukz dff42f8ee9 gametimestart & mapbackupsonsave
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6565 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-08-08 21:47:50 +00:00
sireus b5c863a900 persistidents - control whether newly defined idents are persistent (suggested by Bukz)
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6526 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-06-09 13:28:52 +00:00
Bukz 001af391bb temporarily ensure arg1 of /newmap is within a sane valid range (6-9)
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6382 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-04-27 23:32:40 +00:00
sireus 4de620f757 entproperty now works in MP coop, but buffered
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6359 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-04-26 13:22:35 +00:00
Bukz 4cf0f94191 onNewMap native alias
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6306 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2011-04-23 10:11:35 +00:00
flowtron e4bc0ea4c6 informative edittoggle
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@5687 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2010-09-11 14:38:51 +00:00
flowtron deb082b15b show/hide sets of sparklies in editmode
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@5441 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2010-07-22 16:40:18 +00:00
Lee Salzman be94c703f2 setsize -> shrink
setsizenodelete -> setsize
deletecontentsa -> deletearrays
deletecontentsp -> deletecontents
vrealloc -> growbuf



git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4787 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2010-03-11 23:06:26 +00:00
Lee Salzman d1253d6394 added support for ambient light
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4737 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-12-03 12:21:21 +00:00
Lee Salzman e725e5ed8c string function cleanups
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4714 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-11-07 22:44:32 +00:00
Lee Salzman 54cc44c3db revising pch setup
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4690 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-11-07 06:42:37 +00:00
flowtron 5196e222ce MediaPack-aware mapformat (MAPVERSION 7)
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4657 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-10-12 19:33:59 +00:00
ac_stef f1e879e7fd akimbo bug fixed; some new bugs added
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4598 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-08-05 21:21:57 +00:00
ac_stef 5626011fdc small optimization
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4241 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-03-03 15:05:29 +00:00
ac_stef 372028ddf4 edit mode: select overlapping map entities; select entities by type; move entities; cycle through playerstart entities
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4231 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-03-01 21:30:00 +00:00
Lee Salzman 4d6ffecf29 reorganized sqr storage for better cache usage
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4113 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2009-01-04 18:42:09 +00:00
driAn 74e1468ee3 ac audio architecture refactoring
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3760 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-11-25 22:50:35 +00:00
Lee Salzman c828c70bb1 separated X and Y radius for clip entities
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3189 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-22 11:08:15 +00:00
Lee Salzman 7ab1bfa104 clip radius tweaks
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3186 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-22 10:18:55 +00:00
Lee Salzman 8472dd3ba2 added clip entities for easier clipping
added entset command for easier ent editing
revised command completion system


git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3182 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-22 03:28:44 +00:00
Lee Salzman 2f53b27d84 fullbright/dynlight fixes
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3025 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-14 22:43:09 +00:00
Lee Salzman 512e8b527e newmap fullbright fix
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3024 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-14 21:59:48 +00:00
Lee Salzman 619d88cbff newmap fix
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3021 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-14 21:39:53 +00:00
Lee Salzman ebcf3f46b8 synchronize newmap command across clients
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3012 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-14 19:44:55 +00:00
Lee Salzman dae268ea4c alternate fix for getmap problem
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2943 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-11 18:23:02 +00:00
Lee Salzman 400f30aa3d ensure sound is preloaded when entproperty is used
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2922 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-11 06:36:12 +00:00
Lee Salzman e898434f8d only load sounds when necessary
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2918 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-10-11 06:21:34 +00:00
Lee Salzman 92b60f874b resetmap/startmap cleanup
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2780 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-09-27 17:52:46 +00:00
Lee Salzman 56191aa2be fixed dynlights to actually work
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2664 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-09-17 07:13:35 +00:00
Lee Salzman b2811e4893 faster reading of world structure
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2655 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-09-17 01:42:40 +00:00
Lee Salzman 5811c51c1a cfg var cleanups
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2605 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-09-15 02:07:20 +00:00
driAn 906184f755 no musicvol reset on mapend, correct music fading, xhair alphablending
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2235 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-07-28 19:22:00 +00:00
driAn f1e1888037 mapmodelreset on "newmap"
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2031 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-05-18 10:48:41 +00:00
driAn 03f608c346 spawn ents right after adding them in editmode
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@1858 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-05-04 10:32:18 +00:00
driAn 3dec83151a bot & sound cleanups
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@1829 e016b1c5-ed68-44aa-a2f7-31cac88cffde
2008-04-23 18:59:31 +00:00