Sebasvideo

03-02-2014, 12:46 AM

I'm trying to setup a city with the Metropolitan pack from Video Copilot, which comes in several formats, and after taking a look at how well they import, I settled for FBX. There are 6 layouts that are each a full city block with buildings. This is the problem I have: when I import the FBX, it comes in fine. However, all the objects inside are imported as separate objects, so to make things more neat I create a null and parent all the items in each block layout to its respective null, so I have six nulls that I can use to move the whole block around and instance. So far so good. The problem is that once all the objects of each block are parented to a null, many objects remain the same, and some go crazy. They become rotated 90° pitch, but also sometimes displaced, and it's a mess to fix it all, so in that case I would opt for loading the OBJs, which come all as one object. The problem with the OBJs is that the textures are not all mapped, for example reflection textures are not mapped at all and I have to guess which objects other than buildings would have a reflection map. So if anyone has any clue on why this normally happens, objects going berserk when parenting to a null, I would really appreciate it.

The other question is how can I randomize rotation, but only in steps of 90°. There is a thread here that is over a year old where Dpont posts a method, but then someone mentions it causes a problem when rendering. His method is:

Connect the Instance ID (Instance Info node)

in the A input of a Math Scalar node, set B to 4,

so for your Instance sequence you will get 0, 1, 2 or 3,

multiply by a Constant Angle node set to 90°,

it converts this angle to radian which is the correct

unit for the node editor, you get 0°, 90°, 180° or 270° angles

for your sequence, connect this result in the X Input

of a Make Vector node (Heading), plug it in Rotation.

You could skip the Math Mod node, just multiplying

the Angle by the Instance ID but not sure with

a huge number of instances, when you reach great

angle values.

Is this the best possible way? Or is there a simpler way?

Thanks,

Sebastian

The other question is how can I randomize rotation, but only in steps of 90°. There is a thread here that is over a year old where Dpont posts a method, but then someone mentions it causes a problem when rendering. His method is:

Connect the Instance ID (Instance Info node)

in the A input of a Math Scalar node, set B to 4,

so for your Instance sequence you will get 0, 1, 2 or 3,

multiply by a Constant Angle node set to 90°,

it converts this angle to radian which is the correct

unit for the node editor, you get 0°, 90°, 180° or 270° angles

for your sequence, connect this result in the X Input

of a Make Vector node (Heading), plug it in Rotation.

You could skip the Math Mod node, just multiplying

the Angle by the Instance ID but not sure with

a huge number of instances, when you reach great

angle values.

Is this the best possible way? Or is there a simpler way?

Thanks,

Sebastian