Skip to content

Conversation

maxcana
Copy link

@maxcana maxcana commented May 9, 2025

The UVs were somehow not generated on a model with Auto UV Generation turned on, causing baked lightmaps to be incorrect.
I put in this hack and it fixed the problem for me.

{
ForceUpdateDelayedUVGeneration();
DelayedUVGeneration(force: true);
}
Copy link
Member

Choose a reason for hiding this comment

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

Sorry for the late comment, I was on vacation and then forgot .. 😬
Also, it's been a while since I looked at this particular code
So, DelayedUVGeneration works on all models, so this is not the right place for this.
In UpdateModels() DelayedUVGeneration is called, after all models are done, and it should already run if ForceUpdateDelayedUVGeneration has been called before
So just calling ForceUpdateDelayedUVGeneration here should be enough

Copy link
Author

Choose a reason for hiding this comment

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

Sounds good. I haven't tested it with just ForceUpdateDelayedUVGeneration() but if you are sure, we can resolve this :)

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.

2 participants