Use custom normals in model replacement (#3649)

A small change that makes the models look a lot better. 
Will likely cause a crash if imported model has no normal data, but
that's on the user to fix on their model.
This commit is contained in:
Will 2024-09-03 00:27:28 +01:00 committed by GitHub
parent ebd02b28a4
commit d46e9fb8bb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -131,9 +131,9 @@ void merc_convert_replacement(MercSwapData& out,
x.pos[0] = y.x;
x.pos[1] = y.y;
x.pos[2] = y.z;
x.normal[0] = copy_from.normal[0];
x.normal[1] = copy_from.normal[1];
x.normal[2] = copy_from.normal[2];
x.normal[0] = in.normals.at(i).x();
x.normal[1] = in.normals.at(i).y();
x.normal[2] = in.normals.at(i).z();
x.weights[0] = copy_from.weights[0];
x.weights[1] = copy_from.weights[1];
x.weights[2] = copy_from.weights[2];