Skip to content

Fix issue #1170 #1172

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

Merged
merged 4 commits into from
Feb 6, 2020
Merged

Fix issue #1170 #1172

merged 4 commits into from
Feb 6, 2020

Conversation

naydef
Copy link
Contributor

@naydef naydef commented Feb 3, 2020

After doing some testing with a debugger, I noticed that engsound->IsSoundPrecached(waveName) returns true, even though the sound is not precached. Because I don't have the patience to compile Sourcemod, I replaced the jnz instruction with nops and now sounds are successfully precached.
For this reason, I removed IsSoundPrecached from PrecacheSoundScript and GetGameSoundParameters

I think it'll be a good idea to add a note to IsSoundPrecached warning that this function may not work correctly(always returning true)

Fixes issue #1170

and removed IsSoundPrecached checks for GetGameSoundParams, too
Copy link
Member

@asherkin asherkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find!

I think it'll be a good idea to add a note to IsSoundPrecached warning that this function may not work correctly (always returning true)

Might as well do that as part of this change (and mark it as #deprecated too).

@naydef naydef requested a review from asherkin February 3, 2020 16:26
@naydef
Copy link
Contributor Author

naydef commented Feb 3, 2020

I'm not sure what else is required here.

Copy link
Member

@asherkin asherkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing else is required, this all looks good.

I'll pull it when I'm at a proper computer and can merge it into 1.10 at the same time.

@naydef
Copy link
Contributor Author

naydef commented Feb 3, 2020

Alright!

Copy link
Member

@Headline Headline left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, I'll go ahead and take this now

@Headline Headline merged commit fba71ed into alliedmodders:master Feb 6, 2020
Headline pushed a commit that referenced this pull request Feb 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants