mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-12-17 00:47:05 +00:00
Added PostLoad methods to ensure all models have created vertex buffers and all materials have generated shaders before the user gains control of the camera, to fix hitching issues
This commit is contained in:
@@ -74,6 +74,15 @@ ENodeType CScriptNode::NodeType()
|
||||
return eScriptNode;
|
||||
}
|
||||
|
||||
void CScriptNode::PostLoad()
|
||||
{
|
||||
if (mpActiveModel)
|
||||
{
|
||||
mpActiveModel->BufferGL();
|
||||
mpActiveModel->GenerateMaterialShaders();
|
||||
}
|
||||
}
|
||||
|
||||
void CScriptNode::OnTransformed()
|
||||
{
|
||||
if (mpInstance)
|
||||
|
||||
Reference in New Issue
Block a user