示例#1
0
        public void Execute(int index)
        {
            MatrixInstance matrixInstance = new MatrixInstance
            {
                Matrix = Matrix4x4.TRS(InstanceList[index].Position + VegetationSystemPosition,
                                       InstanceList[index].Rotation, InstanceList[index].Scale),
                DistanceFalloff = InstanceList[index].DistanceFalloff
            };

            matrixInstance.DistanceFalloff      = InstanceList[index].DistanceFalloff;
            VegetationInstanceMatrixList[index] = matrixInstance;
        }
示例#2
0
        public void Execute()
        {
            for (int i = 0; i < InstanceList.Length; i++)
            {
                MatrixInstance matrixInstance = new MatrixInstance
                {
                    Matrix = Matrix4x4.TRS(InstanceList[i].Position + VegetationSystemPosition,
                                           InstanceList[i].Rotation, InstanceList[i].Scale),
                    DistanceFalloff = InstanceList[i].DistanceFalloff
                };

                matrixInstance.DistanceFalloff = InstanceList[i].DistanceFalloff;

                VegetationInstanceMatrixList.Add(matrixInstance);
            }
        }
示例#3
0
        public void Execute()
        {
            for (int i = 0; i < Excluded.Length; i++)
            {
                if (Excluded[i] == 1)
                {
                    continue;
                }

                MatrixInstance matrixInstance = new MatrixInstance
                {
                    Matrix = Matrix4x4.TRS(Position[i],
                                           Rotation[i], Scale[i]),
                    DistanceFalloff = DistanceFalloff[i]
                };
                VegetationInstanceMatrixList.Add(matrixInstance);
            }
        }
示例#4
0
        public void Execute()
        {
            for (int i = 0; i < InstanceList.Length; i++)
            {
                VegetationInstance vegetationInstance = InstanceList[i];
                if (vegetationInstance.Excluded == 1)
                {
                    continue;
                }

                MatrixInstance matrixInstance = new MatrixInstance
                {
                    Matrix = Matrix4x4.TRS(InstanceList[i].Position,
                                           InstanceList[i].Rotation, InstanceList[i].Scale),
                    DistanceFalloff = InstanceList[i].DistanceFalloff
                };
                VegetationInstanceMatrixList.Add(matrixInstance);
            }
        }