Exemple #1
0
        public void ShowTestField()
        {
            var list = new List <ValueTuple <List <TerrainPointInfo>, Vector3> >();

            foreach (var f in FindObjectsOfType <FieldSnapshotComponent>())
            {
                list.Add((FieldTemplate.CreateTerrainPointInfo(f.Range, f.Highest, f.MaterialType, f.Seeds), f.transform.position));
            }

            realizer.Reset();
            foreach (var tuple in list)
            {
                realizer.Realize(Vector3.zero, tuple.Item1, tuple.Item2);
            }

            foreach (var u in FindObjectsOfType <UnitSnapshotComponent>())
            {
                u.SetHeight(rate);
            }
        }
 private void Start()
 {
     Realize(FieldTemplate.CreateTerrainPointInfo(range, highest));
 }