dhewm3/neo
Daniel Gibson a7e4eb8644 Fix renderlights loaded from savegames aliasing other lights
Some entities wrote the handle from gameRenderWorld->AddLightDef()
into savegames and reused it after restoring it.
That's a bad idea, because at that point the handle most likely belongs
to something else (likely some idLight). The most visible issue this
can create is that the flashlight may not work correctly after loading
a savegame with flashlight on, when it happens to alias a light that's
updated each frame to (mostly) being off..

The correct way to handle this (THAT FOR SOME REASON WAS ALREADY
IMPLEMENTED IN D3XP BUT NOT THE BASE GAME - WHY?!) is to get a fresh
handle with AddLightDef() when restoring a savegame - unless the handle
was -1, which means that the light didn't exist when saving.

fixes #495
2022-11-06 18:12:54 +01:00
..
cm Work around assertion in alphalabs4, fix #409 2022-05-16 05:43:47 +02:00
d3xp StartSoundShader() event: special-case for soundName "", refs #494 2022-10-31 03:20:57 +01:00
framework Bump version to 1.5.3pre 2022-10-22 20:57:48 +02:00
game Fix renderlights loaded from savegames aliasing other lights 2022-11-06 18:12:54 +01:00
idlib Add D3_(v)snprintfC99() for C99-compatible implementations 2022-01-10 04:06:54 +01:00
MayaImport s/LittleLong/LittleInt/ to match the return type 2012-06-28 13:02:47 +02:00
renderer Fix some ubsan warnings 2022-11-06 03:09:05 +01:00
sound Disable assertion in idSampleDecoderLocal::Decode*(), fix #461 2022-05-28 18:05:49 +02:00
sys Remove deprecated warnings on mac for cString use. 2022-07-07 22:47:12 +02:00
tools Fix crash in Radiant Model Preview Dialog, fix #496 2022-10-22 20:47:33 +02:00
TypeInfo Get rid of Sys_FPU_StackIsEmpty() 2012-07-06 01:06:53 +02:00
ui Add absolute mouse mode and refactor mouse grabbing code 2022-01-10 00:46:32 +01:00
CMakeLists.txt HARDLINK_GAME option in cmake 2022-11-06 03:09:05 +01:00
config.h.in Introduce CMAKE_INSTALL_PREFIX relative paths 2012-07-04 02:18:42 +02:00
mmakefile.src # move the AROS specific folder icon and default.cfg mmakefile.src under neo/sys/aros/setup 2017-04-22 16:21:14 +02:00