ddnet/src/game/client
Robert Müller ab3c6c4353 Improve envelope evaluation and validation
Call `EnvelopeEval` functions directly instead of passing them and their arguments to `CRenderTools::RenderTilemap` and `CRenderTools::RenderTileRectangle`.

Only evaluate color envelopes for tiles layers once instead of separately for the opaque and transparent passes.

Only evaluate relevant number of envelope channels instead of always evaluating all channels.

Avoid unnecessary calculations by only evaluating position envelopes for quads which are not fully transparent.

Fully ignore layer color and envelope color for entities layers, as these cannot be specified in the editor and should not be changeable.

Remove duplicate and insufficient checks for invalid envelope index before calling `EnvelopeEval`. Instead, set the correct default for all channels before calling `EnvelopeEval` and only change the result on success. Now, white color will consistently be assumed for invalid color envelopes, zero positions and rotations for invalid position envelopes, and full volume for invalid sound envelopes.

Validate number of envelope channels to prevent crashes. When loading maps containing envelopes with invalid number of channels (not equal to 1, 3 or 4), the number of channels of these envelopes is reset to 4 and an error message is displayed, so the mapper can examine all channels' data and transfer it to another envelope if necessary. Closes #7985.
2024-02-23 19:24:34 +01:00
..
components Improve envelope evaluation and validation 2024-02-23 19:24:34 +01:00
prediction Character: Incapsulate m_MoveRestrictions and m_Core 2024-01-21 20:59:50 +03:00
animstate.cpp Minor refactoring of CAnimState and tee rendering functions 2023-06-10 13:10:26 +02:00
animstate.h Minor refactoring of CAnimState and tee rendering functions 2023-06-10 13:10:26 +02:00
component.cpp Use curl-multi 2023-12-18 20:06:43 +01:00
component.h Refactor skin refreshing in gameclient, fix crash in skin settings 2024-02-01 20:41:10 +01:00
gameclient.cpp Show warnings after client close instead of preventing quitting 2024-02-07 22:11:44 +01:00
gameclient.h Show warnings after client close instead of preventing quitting 2024-02-07 22:11:44 +01:00
laser_data.cpp Add flag to ddnetlaser for enabling prediction, let server control starttick 2023-09-19 23:22:15 +02:00
laser_data.h Add flag to ddnetlaser for enabling prediction, let server control starttick 2023-09-19 23:22:15 +02:00
lineinput.cpp Better map settings input (autocomplete, validation) 2024-01-23 20:13:56 +01:00
lineinput.h Better map settings input (autocomplete, validation) 2024-01-23 20:13:56 +01:00
pickup_data.cpp Add net netobjs for projectile and pickup, extend ddnetlaser, remove EntityEx server-side 2023-05-04 23:43:05 +02:00
pickup_data.h Add net netobjs for projectile and pickup, extend ddnetlaser, remove EntityEx server-side 2023-05-04 23:43:05 +02:00
projectile_data.cpp Add net netobjs for projectile and pickup, extend ddnetlaser, remove EntityEx server-side 2023-05-04 23:43:05 +02:00
projectile_data.h Add net netobjs for projectile and pickup, extend ddnetlaser, remove EntityEx server-side 2023-05-04 23:43:05 +02:00
race.cpp Use std::vector and std::deque instead of most std::lists 2023-07-01 15:44:35 +02:00
race.h Organize game-client includes 2022-05-29 21:24:43 +02:00
render.cpp CRenderTools: Mark some methods static and (some) const 2023-12-26 19:37:21 +03:00
render.h Improve envelope evaluation and validation 2024-02-23 19:24:34 +01:00
render_map.cpp Improve envelope evaluation and validation 2024-02-23 19:24:34 +01:00
skin.h Extract SSkinTextures::Unload function 2024-02-09 21:32:44 +01:00
ui.cpp Better map settings input (autocomplete, validation) 2024-01-23 20:13:56 +01:00
ui.h Add return value docs to DoEditBox* 2024-02-19 22:51:55 +01:00
ui_listbox.cpp Make listbox scrollbar width and margin adjustable 2023-09-16 13:24:19 +02:00
ui_listbox.h Make listbox scrollbar width and margin adjustable 2023-09-16 13:24:19 +02:00
ui_rect.cpp Add CUIRect::Margin with vec2 argument 2023-10-06 18:08:03 +02:00
ui_rect.h Add doc comment for CUIRect::Draw() 2024-02-05 16:43:52 +08:00
ui_scrollregion.cpp Small cleanup: simplify member type and computation 2023-11-19 17:36:17 +01:00
ui_scrollregion.h Small cleanup: simplify member type and computation 2023-11-19 17:36:17 +01:00