Exemplo n.º 1
0
        /// <summary>
        /// Formats the Transforms rotation in euler angles.
        /// </summary>
        /// <param name="index"></param>
        /// <param name="serializableObject"></param>
        /// <returns>Returns a Formatted string with EulerAngles</returns>
        private string formatRotation(int index, ISerializableObject serializableObject)
        {
            string tempRotation = string.Format("newGameObject{0}.Rotation = ", index);

            tempRotation += "{ ";
            tempRotation += string.Format("x = {0}, y = {1}, z = {2}, w = {3}",
                                          serializableObject.GetRotation().x,
                                          serializableObject.GetRotation().y * -1,
                                          serializableObject.GetRotation().z * -1,
                                          serializableObject.GetRotation().w);
            tempRotation += " }\n";
            return(tempRotation);
        }