Search Unity

decal with random rotation

Discussion in 'Scripting' started by chiblue3D, Jan 27, 2013.

  1. chiblue3D

    chiblue3D

    Joined:
    Apr 25, 2012
    Posts:
    20
    I have almost perfected my decal system, I am trying to add random rotation and scale to the decal but I cannot get my rotation to work I have tried using the transform of the decal and rotating it using x,y,z and up forward etc, but the decal always rotates the wring way. I want the decal to simply turn randomly in it the facing plane.

    any ideas on how to ensure that the rotation is only on the forward facing axis?