Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- hasDefinitions = true;
- int x, y, z; // May be removed in future.
- for (int i = 0; i < 16; i++)
- {
- tangents.Add(FProcMeshTangent(1, 1, 1));
- }
- // Top
- topDefinition = FVector2D(0, 3);
- vertices.Add(FVector(x - 50, y + 50, z + 50));
- vertices.Add(FVector(x + 50, y + 50, z + 50));
- vertices.Add(FVector(x + 50, y - 50, z + 50));
- vertices.Add(FVector(x - 50, y - 50, z + 50));
- normals.Add(FVector(0, 0, 1));
- normals.Add(FVector(0, 0, 1));
- normals.Add(FVector(0, 0, 1));
- normals.Add(FVector(0, 0, 1));
- // Bottom
- topDefinition = FVector2D(4, 7);
- vertices.Add(FVector(x - 50, y - 50, z - 50));
- vertices.Add(FVector(x + 50, y - 50, z - 50));
- vertices.Add(FVector(x + 50, y + 50, z - 50));
- vertices.Add(FVector(x - 50, y + 50, z - 50));
- normals.Add(FVector(0, 0, -1));
- normals.Add(FVector(0, 0, -1));
- normals.Add(FVector(0, 0, -1));
- normals.Add(FVector(0, 0, -1));
- tangents.Add(FProcMeshTangent(1, 1, 1));
- tangents.Add(FProcMeshTangent(1, 1, 1));
- tangents.Add(FProcMeshTangent(1, 1, 1));
- tangents.Add(FProcMeshTangent(1, 1, 1));
- // Left
- topDefinition = FVector2D(8, 11);
- vertices.Add(FVector(x + 50, y - 50, z - 50));
- vertices.Add(FVector(x + 50, y - 50, z + 50));
- vertices.Add(FVector(x + 50, y + 50, z + 50));
- vertices.Add(FVector(x + 50, y + 50, z - 50));
- normals.Add(FVector(1, 0, 0));
- normals.Add(FVector(1, 0, 0));
- normals.Add(FVector(1, 0, 0));
- normals.Add(FVector(1, 0, 0));
- // Right
- topDefinition = FVector2D(11, 15);
- vertices.Add(FVector(x - 50, y + 50, z - 50));
- vertices.Add(FVector(x - 50, y + 50, z + 50));
- vertices.Add(FVector(x - 50, y - 50, z + 50));
- vertices.Add(FVector(x - 50, y - 50, z - 50));
- normals.Add(FVector(-1, 0, 0));
- normals.Add(FVector(-1, 0, 0));
- normals.Add(FVector(-1, 0, 0));
- normals.Add(FVector(-1, 0, 0));
- // Front
- topDefinition = FVector2D(16, 19);
- vertices.Add(FVector(x + 50, y + 50, z - 50));
- vertices.Add(FVector(x + 50, y + 50, z + 50));
- vertices.Add(FVector(x - 50, y + 50, z + 50));
- vertices.Add(FVector(x - 50, y + 50, z - 50));
- normals.Add(FVector(0, 1, 0));
- normals.Add(FVector(0, 1, 0));
- normals.Add(FVector(0, 1, 0));
- normals.Add(FVector(0, 1, 0));
- // Back
- topDefinition = FVector2D(20, 23);
- vertices.Add(FVector(x - 50, y - 50, z - 50));
- vertices.Add(FVector(x - 50, y - 50, z + 50));
- vertices.Add(FVector(x + 50, y - 50, z + 50));
- vertices.Add(FVector(x + 50, y - 50, z - 50));
- normals.Add(FVector(0, -1, 0));
- normals.Add(FVector(0, -1, 0));
- normals.Add(FVector(0, -1, 0));
- normals.Add(FVector(0, -1, 0));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement