/// <summary> /// Returns a list of all used models in the configuration /// </summary> public List <string> GetUsedModelsNames() { var needToLoadModels = BluePrints.Values.OfType <IVoxelEntity>().Select(e => e.ModelName).Where(m => !string.IsNullOrEmpty(m)).ToList(); needToLoadModels.AddRange(CharacterClasses.Select(c => c.ModelName)); needToLoadModels.AddRange(TreeBluePrints.Select(c => c.SeedModel)); needToLoadModels = needToLoadModels.Distinct().ToList(); return(needToLoadModels); }
public int GetNextLandscapeEntityId() { int newId = int.MinValue; //Look into Tree landscape entities; int treeMaxId = 0; if (TreeBluePrints.Count > 0) { treeMaxId = TreeBluePrints.Max(x => x.Id); } if (newId < treeMaxId) { newId = treeMaxId; } return(newId + 1); }