Build 2214
SVN-
Generale
Fix sintable access with raw angle value (which might be outside [0..2047])
Mostra dettagli
in overhead map drawing code.
Nickname SVN e nomi Git sono unificati per persona.
Fix sintable access with raw angle value (which might be outside [0..2047])
in overhead map drawing code.
savegame.c: fix initial setting of compression threshold on savegame load;
64-bit fixes
fix displaying the screenshot even for old-version savegames.
Beauty tweaks; revert s_buildDate since we don't want windows builds to pull
snapshots in the current development state now.
Fix non-TROR build and add a warning that such a build is only useful for
debugging, i.e. savegames and the like will break.
Eh, fix out-of-bounds issue in clearfrags() with MAXPLAYERS players.
It was identified with the clearfrags rewriting, but not corrected.
Fix out-of-bounds write when passing a map filename to Mapster32.
savegame.c: minor cleanup and crash prevention in doloadplayer2
if loading directly from file to state.
Fix out-of-bounds access in tile selector code in astub.c
Fix two yax_drawrooms() calls with too large sectnums (copy&paste error).
Fix a number of oob accesses with "switch switches".
Various code checked for switch tiles in the following manner, for (ii=0; ii<2; ii++) switch (DynamicTileMap[sprite[i].picnum-1+ii]) { case SOME_SWITCH: ... } which blows for picnum 0. Now, we simply disallow it.
Fix negative array access in premap.c
Fix potential out-of-bounds array access in P_DisplayTip (happened with
WGR2 SVN, so not sure where there's a tipping animation there).
Fix sintable[] access with out-of-bounds values in core engine functions
(getzrange, hitscan, clipmove, drawmapview). They're reproducible with DNE1.3D; Since these angle values most likely come from CON code, my suggestion would be to bit-and all values representing angles with 2047 when setting the from CON, but I'd have to think about potential side-effects of doing this.
- Fix invalid polymer light array access originating from game's cleanup
callback 'G_Polymer_UnInit'. - In astub.c, reset spritelightid to -1 when nulling the spritelightptr of a sprite (no crashes observed, just precaution) - In sdlayer.c, catch SIGILLs with our signal handler too, since illegal instructions are what the instrumented debug builds will execute when attempting to carry out an undefined (per C) operation.
engine.c: fix shift by negative value in parascan().
Simple one-liner from Robin Green to fix a problem where the menu background tint would sometimes draw over the menu contents
fix filling all sectors of a bunch with Ctrl-U. Previously, only
one sector was filled and the 'clear bunch' message was displayed even if the operation was canceled.
Fix issue reported at http://forums.duke4.net/topic/5068-bug-introduced-in-old-versions-of-eduke32
Revert r2141 functionality because it was a stupid-ass hack and breaks E3L5.
The texture warping mode will need to be set depending on whether we're actually drawing a parallaxed sky or not.
Upload sky textures with s wrapping set to GL_CLAMP{_TO_EDGE}.
This fixes the vertical (~1 texel wide) stripes that are especially noticable with tiled art skies and Polymost with r_parallaxskyclamp=1 or Polymer (which always uploads skies with repeating s and t coords). What constitutes a sky tile is currently hardcoded to be >=78 and <=99.
Fix moving cloud panning like in E4L1.
When restoring temporarily backed up map, clear all TROR bunches. This is
suboptimal, but at least 'correct' and won't produce the aforementioned corruptions anymore.
Auto-correct the just mentioned inconsistency by clearing the respective TROR
nextwalls. (i.e. setting them to -1 on 'corruptcheck tryfix')
corruption checker: catch TROR-nextwalls in non-extended sectors. These
can be caused by copying map parts from one map to another (or a new one). The copying system is slightly broken right now....
Backing up and restoring highlighted portion of map: calculate new
next{wall,sector} indices instead of using checksectorpointer() so that the nextwalls will be restored exactly as they were (provided that they are copied). Also fix tweaking the sectnums of sprites.
Fix two bugs with the loop punching code that made it practically useless.
"Sloped extended sectors cannot be split", oops. Also fix a glitch that
would break out of the 2D mode loop when splitting a sector would exceed limits.
Three Mapster32 changes (2 wall-drawing related, 1 crash fix)
- Don't crash when sector joining fails under certain circumstances. - Increase the point lock (Manhattan) distance from 1/16th to 1/8th of the grid square length, making it easier to snap to vertices not lying at the grid points with grid lock on - When drawing walls, don't snap to any of them except the first drawn
Somewhat largish commit with various keyboard tinkering for Mapster.
The main change consist of adding a key press (and release) callback whose only purpose is to be used from m32script as EVENT_KEYPRESS. When entering that event, the RETURN variable will be set to the keystatus code of the key, and whether it was pressed or released can be checked by looking at keystatus[] at that code (ifholdkey and ifhitkey do this). The purpose of this, then, is to be able to remap keys in a more general (and complicated) fashion than is possible with the mapster32.cfg 'remap' option. Various other additions build around this central one: - add an example EVENT_KEYPRESS to a.m32, among other things emulating the keypad arrows with Alt-<normal arrows> for notebook convenience; disabled initially - a.m32: set 'owner' with Alt-KP2: now Alt-Shift-KP2, because of collision with the above - new m32script command: setkey <keycode>, setting keystatus[<keycode>] to 1 (note: may be restricted to use in EVENT_KEYPRESS only in the future) - fix indexing an m32script array with a defined label, there used to be a 'not a gamevar' error instead - add the following constant labels for some key codes: KEY_SCROLL, KEY_F1 .. KEY_F12
- Make old-nextwalls invalid on the following two occasions: ovh_whiteoutgrab
with no highlighted sectors; and when entering 3D mode, even if there are highlighted sectors. This should have almost no effect, but I find it cleaner that way. - Check map for corruption every time an editing change is done. This was accidentally disabled when commenting out the undo code (which I've yet to debug).
Fix calling glEnable() without checking for the rendering mode in the tile
selector. This could lead to a crash when OpenGL wasn't initialized before.
Fix the Makefile on OSX. Their linker has a different syntax for requesting the
memory map.
Fix the flickering in the tile selector with lazy hightile loading on
(lazy_tileselector=1 in mapster32.cfg). We're drawing tiles one by one, so glDrawBuffer(GL_FRONT_AND_BACK) is our friend.
Tweak raising/lowering (groups of) ceilings or floors.
Now, if more than one sectors are affected, always move them by the same amount. That is, if one of them would be sticking against the other side, don't move the rest. Another change consists of determining the z delta first, and only then moving the sprites by that amount. This fixes the problem where you'd e.g. raise a 'floor door' against the ceiling, and the effector sprites would be raised one time too much, preventing them from being lowered the next time.
A couple of Mapster changes related to saving.
- new mapster32.cfg and OSD variable 'fixmaponsave_sprites', telling the editor whether to 'fix' the sprite sectnums on saving and entering 3D mode. Note that a) sprite sectnums are never fixed when 'script_expertmode' is enabled, as before, and b) sprites that have out-of-bounds sectnums are still fixed if a proper sector is found - if saving and some sprite sectnums have thus been tweaked, inform the mapper on the status line and print the changes in the OSD - fix update issue similar to an earlier one: when 'saving as', the astub.c- based file name is now updated too, so saving with Ctrl-S now saves into the one save with 'save as' (and not the old one) - don't attempt to recheck wall pointers from scratch (when saving and running with -check) if it's a TROR map
Oops. Revert the *alloc wrapping to catch them being called with bad values.
This was meant for debugging only.
On Windows, add command-line switch -nopause, disabling the pause key.
Hopefully this fixes the periodic pausing/unpausing that a few people have been experiencing. Also fix build with GCC 3.
Fix building with both LTO and VPX support enabled. Specifically, don't use
the 'optimize' function attribute if LTO is enabled.
Fix the 'displayrandvar{var}' CON and m32script commands for environments
with RAND_MAX > 32767 (everything except Windows?). The 'displayrand' command now returns values from 0 to 32767 inclusive, across all platforms.
Fix another dragpoint() bug that was wrongly omitting walls.
This one could have only happened with TROR maps, I think.