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

broken chams #53

Closed
ghost opened this issue Mar 18, 2024 · 2 comments
Closed

broken chams #53

ghost opened this issue Mar 18, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Mar 18, 2024

Chams don't work properly, invisible chams don't work at all

@ghost ghost added the bug Something isn't working label Mar 18, 2024
@ghost ghost assigned maecry Mar 18, 2024
@Exlodium
Copy link
Collaborator

Exlodium commented Mar 18, 2024

Read the comment, it only sets material function on debug build

// @note: SetCreateDataByMaterial failed on release build idk why
#ifdef _DEBUG
I::MaterialSystem2->SetCreateDataByMaterial(pData, &pMatPrototype);
pData->SetShaderType(szShaderType);
pData->SetMaterialFunction(CS_XOR("F_DISABLE_Z_BUFFERING"), bDisableZBuffering ? 1 : 0);
pData->SetMaterialFunction(CS_XOR("F_BLEND_MODE"), bBlendMode ? 1 : 0);
pData->SetMaterialFunction(CS_XOR("F_TRANSLUCENT"), bTranslucent ? 1 : 0);
CMaterial2** pMaterial;
I::MaterialSystem2->CreateMaterial(&pMaterial, szName, pData);
I::MemAlloc->Free(pData);
return *pMaterial;
#endif

@maecry
Copy link
Owner

maecry commented Mar 20, 2024

Seem like he deleted his acc

@maecry maecry closed this as completed Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants