Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HL] Scientist don't make remarks on bad smells #2982

Open
Maxi605 opened this issue Sep 27, 2020 · 1 comment
Open

[HL] Scientist don't make remarks on bad smells #2982

Maxi605 opened this issue Sep 27, 2020 · 1 comment

Comments

@Maxi605
Copy link

Maxi605 commented Sep 27, 2020

As Guards, Scientist were supposed to make a remark when there's something dead near them, but this seems to be broken.

https://youtu.be/1tvz0WVaQGg?t=62

@SamVanheer
Copy link

This is because the Scientist's sound mask doesn't include carcasses, meat and garbage:

halflife/dlls/scientist.cpp

Lines 772 to 783 in c7240b9

//=========================================================
// ISoundMask - returns a bit mask indicating which types
// of sounds this monster regards. In the base class implementation,
// monsters care about all sounds, but no scents.
//=========================================================
int CScientist :: ISoundMask ( void )
{
return bits_SOUND_WORLD |
bits_SOUND_COMBAT |
bits_SOUND_DANGER |
bits_SOUND_PLAYER;
}

Barney's sound mask handles these cases correctly:

halflife/dlls/barney.cpp

Lines 243 to 256 in c7240b9

//=========================================================
// ISoundMask - returns a bit mask indicating which types
// of sounds this monster regards.
//=========================================================
int CBarney :: ISoundMask ( void)
{
return bits_SOUND_WORLD |
bits_SOUND_COMBAT |
bits_SOUND_CARCASS |
bits_SOUND_MEAT |
bits_SOUND_GARBAGE |
bits_SOUND_DANGER |
bits_SOUND_PLAYER;
}

Using the same one should fix it.

Thanks to NongBenz for letting me know about this.

nekonomicon added a commit to FWGS/hlsdk-portable that referenced this issue Jun 5, 2021
tyabus pushed a commit to tyabus/hlsdk-xash3d that referenced this issue Jun 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants