Skip to content

Commit

Permalink
server: fixed video file extension check in env_dynlight entity
Browse files Browse the repository at this point in the history
  • Loading branch information
SNMetamorph committed Dec 13, 2024
1 parent 39c39ea commit 71f080f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions server/lights.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -657,9 +657,8 @@ void CDynamicLight::Precache()

if (!FStringNull(pev->message))
{
const char *ext = UTIL_FileExtension(STRING(pev->message));

if (!Q_stricmp(ext, "avi"))
const char *filepath = STRING(pev->message);
if (UTIL_ValidMovieFileExtension(filepath))
{
// 0 if movie not found
pev->sequence = UTIL_PrecacheMovie(pev->message);
Expand Down

0 comments on commit 71f080f

Please sign in to comment.