Example #1
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
#warning TODO: serialized version acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = base.ExportYAMLRoot(container);
            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_Avatar", Avatar.ExportYAML(container));
            node.Add("m_Controller", Controller.ExportYAML(container));
            node.Add("m_CullingMode", CullingMode);
            node.Add("m_UpdateMode", UpdateMode);
            node.Add("m_ApplyRootMotion", ApplyRootMotion);
            node.Add("m_LinearVelocityBlending", LinearVelocityBlending);
            node.Add("m_HasTransformHierarchy", HasTransformHierarchy);
            node.Add("m_AllowConstantClipSamplingOptimization", AllowConstantClipSamplingOptimization);
            return(node);
        }
Example #2
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(1);
            node.Add("m_Positions", Positions.ExportYAML(container));
            node.Add("m_Parameters", Parameters.ExportYAML(container));
            node.Add("m_UseWorldSpace", UseWorldSpace);
            if (HasLoop(container.ExportVersion))
            {
                node.Add("m_Loop", Loop);
            }

            return(node);
        }
Example #3
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(ToSerializedVersion(container.ExportVersion));
            node.Add(NavMeshTilesName, NavMeshTiles.ExportYAML(container));
            node.Add(NavMeshBuildSettingsName, GetExportNavMeshBuildSettings(container.Version).ExportYAML(container));
            node.Add(HeightmapsName, Heightmaps.ExportYAML(container));
            node.Add(HeightMeshesName, HeightMeshes.ExportYAML(container));
            node.Add(OffMeshLinksName, OffMeshLinks.ExportYAML(container));
            node.Add(SourceBoundsName, SourceBounds.ExportYAML(container));
            node.Add(RotationName, GetExportRotation(container.Version).ExportYAML(container));
            node.Add(PositionName, Position.ExportYAML(container));
            node.Add(AgentTypeIDName, AgentTypeID);
            return(node);
        }
Example #4
0
        protected override YAMLMappingNode ExportYAMLRoot(IAssetsExporter exporter)
        {
#warning TODO: values acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = base.ExportYAMLRoot(exporter);
            node.InsertSerializedVersion(GetSerializedVersion(exporter.Version));
            node.Add("m_NavMeshTiles", NavMeshTiles.ExportYAML(exporter));
            node.Add("m_NavMeshBuildSettings", NavMeshBuildSettings.ExportYAML(exporter));
            node.Add("m_Heightmaps", Heightmaps.ExportYAML(exporter));
            node.Add("m_HeightMeshes", HeightMeshes.ExportYAML(exporter));
            node.Add("m_OffMeshLinks", OffMeshLinks.ExportYAML(exporter));
            node.Add("m_SourceBounds", SourceBounds.ExportYAML(exporter));
            node.Add("m_Rotation", Rotation.ExportYAML(exporter));
            node.Add("m_Position", Position.ExportYAML(exporter));
            node.Add("m_AgentTypeID", AgentTypeID);
            return(node);
        }
Example #5
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_NavMeshTiles", NavMeshTiles.ExportYAML(container));
            node.Add("m_NavMeshBuildSettings", GetExportNavMeshBuildSettings(container.Version).ExportYAML(container));
            node.Add("m_Heightmaps", Heightmaps.ExportYAML(container));
            node.Add("m_HeightMeshes", HeightMeshes.ExportYAML(container));
            node.Add("m_OffMeshLinks", OffMeshLinks.ExportYAML(container));
            node.Add("m_SourceBounds", SourceBounds.ExportYAML(container));
            node.Add("m_Rotation", GetExportRotation(container.Version).ExportYAML(container));
            node.Add("m_Position", Position.ExportYAML(container));
            node.Add("m_AgentTypeID", AgentTypeID);
            return(node);
        }
Example #6
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
#warning TODO:
            YAMLMappingNode node = base.ExportYAMLRoot(container);
            node.InsertSerializedVersion(GetSerializedVersion(container.ExportVersion));
            node.Add(ShaderName, Shader.ExportYAML(container));
            node.Add(ShaderKeywordsName, IsReadKeywords(container.Version) ? (IsKeywordsArray(container.Version) ? string.Join(" ", m_shaderKeywordsArray) : ShaderKeywords) : string.Empty);
            node.Add(LightmapFlagsName, LightmapFlags);
            node.Add(EnableInstancingVariantsName, EnableInstancingVariants);
            node.Add(DoubleSidedGIName, DoubleSidedGI);
            node.Add(CustomRenderQueueName, CustomRenderQueue);
            node.Add(StringTagMapName, IsReadStringTagMap(container.Version) ? StringTagMap.ExportYAML() : YAMLMappingNode.Empty);
            node.Add(DisabledShaderPassesName, IsReadDisabledShaderPasses(container.Version) ? DisabledShaderPasses.ExportYAML() : YAMLSequenceNode.Empty);
            node.Add(SavedPropertiesName, SavedProperties.ExportYAML(container));
            return(node);
        }
Example #7
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_Shader", Shader.ExportYAML(container));
            node.Add("m_ShaderKeywords", IsReadKeywords(container.Version) ? (IsKeywordsArray(container.Version) ? string.Join(" ", m_shaderKeywordsArray) : ShaderKeywords) : string.Empty);
            node.Add("m_LightmapFlags", LightmapFlags);
            node.Add("m_EnableInstancingVariants", EnableInstancingVariants);
            node.Add("m_DoubleSidedGI", DoubleSidedGI);
            node.Add("m_CustomRenderQueue", CustomRenderQueue);
            node.Add("stringTagMap", IsReadStringTagMap(container.Version) ? StringTagMap.ExportYAML() : YAMLMappingNode.Empty);
#warning TODO: untested
            node.Add("disabledShaderPasses", IsReadDisabledShaderPasses(container.Version) ? DisabledShaderPasses.ExportYAML() : YAMLSequenceNode.Empty);
            node.Add("m_SavedProperties", SavedProperties.ExportYAML(container));
            return(node);
        }
Example #8
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.ExportVersion));
            node.Add(ChildStatesName, ChildStates.ExportYAML(container));
            node.Add(ChildStateMachinesName, ChildStateMachines.ExportYAML(container));
            node.Add(AnyStateTransitionsName, AnyStateTransitions.ExportYAML(container));
            node.Add(EntryTransitionsName, EntryTransitions.ExportYAML(container));
            node.Add(StateMachineTransitionsName, StateMachineTransitions.ExportYAML(container));
            node.Add(StateMachineBehavioursName, StateMachineBehaviours.ExportYAML(container));
            node.Add(AnyStatePositionName, AnyStatePosition.ExportYAML(container));
            node.Add(EntryPositionName, EntryPosition.ExportYAML(container));
            node.Add(ExitPositionName, ExitPosition.ExportYAML(container));
            node.Add(ParentStateMachinePositionName, ParentStateMachinePosition.ExportYAML(container));
            node.Add(DefaultStateName, DefaultState.ExportYAML(container));
            return(node);
        }
Example #9
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_ChildStates", ChildStates.ExportYAML(container));
            node.Add("m_ChildStateMachines", ChildStateMachines.ExportYAML(container));
            node.Add("m_AnyStateTransitions", AnyStateTransitions.ExportYAML(container));
            node.Add("m_EntryTransitions", EntryTransitions.ExportYAML(container));
            node.Add("m_StateMachineTransitions", StateMachineTransitions.ExportYAMLArrayPPtr(container));
            node.Add("m_StateMachineBehaviours", StateMachineBehaviours.ExportYAML(container));
            node.Add("m_AnyStatePosition", AnyStatePosition.ExportYAML(container));
            node.Add("m_EntryPosition", EntryPosition.ExportYAML(container));
            node.Add("m_ExitPosition", ExitPosition.ExportYAML(container));
            node.Add("m_ParentStateMachinePosition", ParentStateMachinePosition.ExportYAML(container));
            node.Add("m_DefaultState", DefaultState.ExportYAML(container));
            return(node);
        }
Example #10
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_BodyType", (int)BodyType);
            node.Add("m_Simulated", Simulated);
            node.Add("m_UseFullKinematicContacts", UseFullKinematicContacts);
            node.Add("m_UseAutoMass", UseAutoMass);
            node.Add("m_Mass", Mass);
            node.Add("m_LinearDrag", LinearDrag);
            node.Add("m_AngularDrag", AngularDrag);
            node.Add("m_GravityScale", GravityScale);
            node.Add("m_Material", Material.ExportYAML(container));
            node.Add("m_Interpolate", (int)Interpolate);
            node.Add("m_SleepingMode", (int)SleepingMode);
            node.Add("m_CollisionDetection", (int)CollisionDetection);
            node.Add("m_Constraints", (int)Constraints);
            return(node);
        }
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(ToSerializedVersion(container.ExportVersion));
            node.Add(BodyTypeName, (int)BodyType);
            node.Add(SimulatedName, Simulated);
            node.Add(UseFullKinematicContactsName, UseFullKinematicContacts);
            node.Add(UseAutoMassName, UseAutoMass);
            node.Add(MassName, Mass);
            node.Add(LinearDragName, LinearDrag);
            node.Add(AngularDragName, AngularDrag);
            node.Add(GravityScaleName, GravityScale);
            node.Add(MaterialName, Material.ExportYAML(container));
            node.Add(InterpolateName, (int)Interpolate);
            node.Add(SleepingModeName, (int)SleepingMode);
            node.Add(CollisionDetectionName, (int)CollisionDetection);
            node.Add(ConstraintsName, (int)Constraints);
            return(node);
        }
        protected override YAMLMappingNode ExportYAMLRoot(IAssetsExporter exporter)
        {
#warning TODO: values acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = base.ExportYAMLRoot(exporter);
            node.InsertSerializedVersion(GetSerializedVersion(exporter.Version));
            node.Add("m_BodyType", (int)BodyType);
            node.Add("m_Simulated", Simulated);
            node.Add("m_UseFullKinematicContacts", UseFullKinematicContacts);
            node.Add("m_UseAutoMass", UseAutoMass);
            node.Add("m_Mass", Mass);
            node.Add("m_LinearDrag", LinearDrag);
            node.Add("m_AngularDrag", AngularDrag);
            node.Add("m_GravityScale", GravityScale);
            node.Add("m_Material", Material.ExportYAML(exporter));
            node.Add("m_Interpolate", (int)Interpolate);
            node.Add("m_SleepingMode", (int)SleepingMode);
            node.Add("m_CollisionDetection", (int)CollisionDetection);
            node.Add("m_Constraints", (int)Constraints);
            return(node);
        }
        public override YAMLNode ExportYAML(IAssetsExporter exporter)
        {
#warning TODO: values acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = (YAMLMappingNode)base.ExportYAML(exporter);
            node.InsertSerializedVersion(GetSerializedVersion(exporter.Version));
            node.Add("startLifetime", StartLifetime.ExportYAML(exporter));
            node.Add("startSpeed", StartSpeed.ExportYAML(exporter));
            node.Add("startColor", StartColor.ExportYAML(exporter));
            node.Add("startSize", StartSize.ExportYAML(exporter));
            node.Add("startSizeY", StartSizeY.ExportYAML(exporter));
            node.Add("startSizeZ", StartSizeZ.ExportYAML(exporter));
            node.Add("startRotationX", StartRotationX.ExportYAML(exporter));
            node.Add("startRotationY", StartRotationY.ExportYAML(exporter));
            node.Add("startRotation", StartRotation.ExportYAML(exporter));
            node.Add("randomizeRotationDirection", RandomizeRotationDirection);
            node.Add("maxNumParticles", MaxNumParticles);
            node.Add("size3D", Size3D);
            node.Add("rotation3D", Rotation3D);
            node.Add("gravityModifier", GravityModifier.ExportYAML(exporter));
            return(node);
        }
Example #14
0
        public override YAMLNode ExportYAML(IExportContainer container)
        {
            YAMLMappingNode node = (YAMLMappingNode)base.ExportYAML(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("startLifetime", StartLifetime.ExportYAML(container));
            node.Add("startSpeed", StartSpeed.ExportYAML(container));
            node.Add("startColor", StartColor.ExportYAML(container));
            node.Add("startSize", StartSize.ExportYAML(container));
            node.Add("startSizeY", GetStartSizeY(container.Version).ExportYAML(container));
            node.Add("startSizeZ", GetStartSizeZ(container.Version).ExportYAML(container));
            node.Add("startRotationX", GetStartRotationX(container.Version).ExportYAML(container));
            node.Add("startRotationY", GetStartRotationY(container.Version).ExportYAML(container));
            node.Add("startRotation", StartRotation.ExportYAML(container));
            node.Add("randomizeRotationDirection", RandomizeRotationDirection);
            node.Add("maxNumParticles", MaxNumParticles);
            node.Add("size3D", Size3D);
            node.Add("rotation3D", Rotation3D);
            node.Add("gravityModifier", GravityModifier.ExportYAML(container));
            return(node);
        }
Example #15
0
        public override YAMLNode ExportYAML(IExportContainer container)
        {
            YAMLMappingNode node = (YAMLMappingNode)base.ExportYAML(container);

            node.InsertSerializedVersion(ToSerializedVersion(container.ExportVersion));
            node.Add(StartLifetimeName, StartLifetime.ExportYAML(container));
            node.Add(StartSpeedName, StartSpeed.ExportYAML(container));
            node.Add(StartColorName, StartColor.ExportYAML(container));
            node.Add(StartSizeName, StartSize.ExportYAML(container));
            node.Add(StartSizeYName, GetStartSizeY(container.Version).ExportYAML(container));
            node.Add(StartSizeZName, GetStartSizeZ(container.Version).ExportYAML(container));
            node.Add(StartRotationXName, GetStartRotationX(container.Version).ExportYAML(container));
            node.Add(StartRotationYName, GetStartRotationY(container.Version).ExportYAML(container));
            node.Add(StartRotationName, StartRotation.ExportYAML(container));
            node.Add(RandomizeRotationDirectionName, RandomizeRotationDirection);
            node.Add(MaxNumParticlesName, MaxNumParticles);
            node.Add(Size3DName, Size3D);
            node.Add(Rotation3DName, Rotation3D);
            node.Add(GravityModifierName, GravityModifier.ExportYAML(container));
            return(node);
        }
Example #16
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(GetSerializedVersion(container.ExportVersion));
            node.Add(AvatarName, Avatar.ExportYAML(container));
            node.Add(ControllerName, Controller.ExportYAML(container));
            node.Add(CullingModeName, (int)CullingMode);
            node.Add(UpdateModeName, (int)UpdateMode);
            node.Add(ApplyRootMotionName, ApplyRootMotion);
            node.Add(LinearVelocityBlendingName, LinearVelocityBlending);
            if (IsReadWarningMessage(container.ExportVersion, container.ExportFlags))
            {
                node.Add(WarningMessageName, GetWarningMessage(container.Version, container.Flags));
            }
            node.Add(HasTransformHierarchyName, HasTransformHierarchy);
            node.Add(AllowConstantClipSamplingOptimizationName, AllowConstantClipSamplingOptimization);
            if (IsReadKeepAnimatorControllerStateOnDisable(container.ExportVersion))
            {
                node.Add(KeepAnimatorControllerStateOnDisableName, KeepAnimatorControllerStateOnDisable);
            }
            return(node);
        }
Example #17
0
        public override YAMLNode ExportYAML(IAssetsExporter exporter)
        {
#warning TODO: values acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = (YAMLMappingNode)base.ExportYAML(exporter);
            node.InsertSerializedVersion(GetSerializedVersion(exporter.Version));
            if (IsReadSubEmitters(exporter.Version))
            {
                node.Add("subEmitters", SubEmitters.ExportYAML(exporter));
            }
            else if (Config.IsExportTopmostSerializedVersion)
            {
                SubEmitterData[] subEmitters = new SubEmitterData[IsReadSecond(exporter.Version) ? 6 : 3];
                subEmitters[0] = new SubEmitterData(SubEmitterBirth, ParticleSystemSubEmitterType.Birth);
                subEmitters[1] = new SubEmitterData(SubEmitterDeath, ParticleSystemSubEmitterType.Death);
                subEmitters[2] = new SubEmitterData(SubEmitterCollision, ParticleSystemSubEmitterType.Collision);
                if (IsReadSecond(exporter.Version))
                {
                    subEmitters[3] = new SubEmitterData(SubEmitterBirth1, ParticleSystemSubEmitterType.Birth);
                    subEmitters[4] = new SubEmitterData(SubEmitterDeath1, ParticleSystemSubEmitterType.Death);
                    subEmitters[5] = new SubEmitterData(SubEmitterCollision1, ParticleSystemSubEmitterType.Collision);
                }
            }
            return(node);
        }
Example #18
0
        protected override YAMLMappingNode ExportYAMLRoot(IExportContainer container)
        {
            YAMLMappingNode node = base.ExportYAMLRoot(container);

            node.InsertSerializedVersion(ToSerializedVersion(container.ExportVersion));
            node.Add(TimeName, Time);
            if (HasParameters(container.ExportVersion))
            {
                node.Add(ParametersName, Parameters.ExportYAML(container));
            }
            else
            {
                node.Add(StartWidthName, StartWidth);
                node.Add(EndWidthName, EndWidth);
                node.Add(ColorsName, Colors.ExportYAML(container));
            }
            node.Add(MinVertexDistanceName, MinVertexDistance);
            node.Add(AutodestructName, Autodestruct);
            if (HasEmitting(container.ExportVersion))
            {
                node.Add(EmittingName, Emitting);
            }
            return(node);
        }