2D Toolkit Forum
2D Toolkit => Support => Topic started by: jeresun on July 04, 2013, 10:34:42 pm
-
Hi, I've changed the code based on a previous topic to comment out the line in tk2dTileMapMeshBuilder.cs:
if (tileMap.serializeRenderData)
This works fine for tilemaps and regular sprites, but when I try to add clipped sprites, the normals are still in the opposite direction. Any fix for this? Thanks.
Jeremiah
-
Is your clipped sprite flipped? mesh.RecalculateNormals should produce "forward" facing normals, unless the clipped sprite is flipped to start with. What version of tk2d are you using?
-
My sprites are not flipped. In addition to clipped sprites, this issue occurs also on tiled and sliced sprites. I am using version 2 final + hotfix 2. Thanks
Jeremiah
-
I just tested this, and it seems to work fine. What happens if you switch to a default unity shader, is it facing the correct direction? Just in case it was generating flipped geometry for some reason
-
sorry for the late reply. I changed the material to a unity shader, and the mesh is facing the correct direction, but the lighting is still reversed. I created a new project and downloaded 2d toolkit from scratch, and I am still getting the same problem with only sliced and tiled sprites. Thanks
-
Can you email a repro case to support at unikronsoftware.com, please?