Skip to content

at least two undefined variables cases found on the code #1536

@fabiosarts

Description

@fabiosarts

cool

i've found at least two declared but not initialized variables in cl_dll/message.cpp and cl_dll/geiger.cpp

on the file message.cpp on CHudMessage::MessageScanNextChar, none of destRed, destGreen or destBlue are defined if switch( m_parms.pMessage->effect ) goes to case 2, which only contains

srcRed = srcGreen = srcBlue = 0;
blend = 0;  // pure source

i've fixed adding an

destRed = destGreen = destBlue = 0;

ob geiger.cpp on int CHudGeiger::Draw (float flTime)
the game crashes about undefined flvol value, which i've found on the first IF

if (m_iGeigerRange > 800)
{
    pct = 0;    //Con_Printf ( "range > 800\n");
}

which i've fixed just adding an flvol = 0.2; like this

if (m_iGeigerRange > 800)
{
    pct = 0;    //Con_Printf ( "range > 800\n");
    flvol = 0.2;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions