Vegetation System Problems
Hi, Have been playing with getting Vegetation Studio working with 1.9.1 with mixed results. I watched your video on how to set VS up, but still unsure about some setup options.
Here's some notes I took as I encountered issues:
- How are we adjusting global settings instead of per terrain chunk? Ie draw distance. I set draw distance on one terrain chunk, but the other chunks don't change. I would imagine most people would want draw distance to be the same for each terrain, and during runtime generation we need to take a global value from somewhere, but I don't know where that's coming from right now?
Fixed: #253 (closed)
- On the Vegetation Studio Output Node: Package, once I'd selected a package I couldn't change it to another package file.
-
I didn't get why in your video you were disabling run time generation and using persistent when at the end you show the terrain generating endlessly? Wasn't 100% sure what you were saying, whether you were using run time spawn or persistent, and when. On that note:
-
Why do we need to "fix" runtime spawn on the Vegetation Studio Output Node? It says "runtime spawn is enabled on some Vegetation Items", which is what I want. Unless MM somehow needs to interface with persistent storage to work?
-
Saving scene seemed to take a long time (perhaps from saving millions of VS polygons?), and upon saving, the Game view and scene view would update and show different vegetation/textures/objects than when we hit Play.
-
Each Force Generate resets all my settings on a terrain chunk, except for the package/terrain asset prefabs.
-
Couldn't seem to remove a plant once it had been generated. I thought it might be from the persistent storage I'd tried earlier but couldn't see anything stored (it had been reset on Force Generate?). Pinning/unpinning didn't help, it still remains.
-
On my MM terrain chunk > VS child object > VS component > Vegetation tab > Add Vegetation Items, I added Default Grass Patch prefab, got this error: NullReferenceException: Object reference not set to an instance of an object AwesomeTechnologies.VegetationSystem.SetupVegetationCells () (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/VegetationSystem.cs:804) AwesomeTechnologies.VegetationSystem.SetVegetationPackage (Int32 index, Boolean resetCullingGroup) (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/VegetationSystem.cs:1465) AwesomeTechnologies.VegetationSystem.RefreshVegetationPackage (Boolean isSyncCallback) (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/VegetationSystem.cs:1434) AwesomeTechnologies.VegetationStudio.VegetationStudioManager.VegetationPackageSync_RefreshVegetationPackage (AwesomeTechnologies.VegetationSystem sourceVegetationSystem) (at Assets/AwesomeTechnologies/VegetationStudio/Common/VegetationStudioManager.cs:917) AwesomeTechnologies.VegetationSystem.RefreshVegetationPackage (Boolean isSyncCallback) (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/VegetationSystem.cs:1438) AwesomeTechnologies.VegetationSystemEditor.DrawVegetationInspector () (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/Editor/VegetationSystemEditor.cs:1156) AwesomeTechnologies.VegetationSystemEditor.OnInspectorGUI () (at Assets/AwesomeTechnologies/VegetationStudio/VegetationSystem/Editor/VegetationSystemEditor.cs:146) UnityEditor.InspectorWindow.DrawEditor (UnityEditor.Editor[] editors, Int32 editorIndex, Boolean rebuildOptimizedGUIBlock, System.Boolean& showImportedObjectBarNext, UnityEngine.Rect& importedObjectBarRect) (at C:/buildslave/unity/build/Editor/Mono/Inspector/InspectorWindow.cs:1245) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
I've got an Error on Play (but I can't repro this on a fresh/demo project). This only occurs with Generate Infinite Terrain enabled. Any ideas what might cause this?:
Error generating chunk: MapMagic.Coord x:-1 z:0: System.ArgumentOutOfRangeException: Argument is out of range.
Parameter name: index
at System.Collections.Generic.List1[AwesomeTechnologies.Vegetation.PersistentStorage.PersistentVegetationCell].get_Item (Int32 index) [0x0000c] in /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:633 at MapMagic.VegetationStudioOutput.Process (CoordRect rect, MapMagic.Results results, MapMagic.GeneratorsAsset gens, Size terrainSize, System.Func
2 stop) [0x006ed] in F:\Exbleative\UnityProjects\exoone2017_3\Assets\MapMagic\Generators\VegetationStudioOutput.cs:276
at (wrapper delegate-invoke) MapMagic.Action5<MapMagic.CoordRect, MapMagic.Chunk/Results, MapMagic.GeneratorsAsset, MapMagic.Chunk/Size, System.Func
2<single, bool>>:invoke_void__this___CoordRect_Chunk/Results_GeneratorsAsset_Chunk/Size_Func2<single, bool> (MapMagic.CoordRect,MapMagic.Chunk/Results,MapMagic.GeneratorsAsset,MapMagic.Chunk/Size,System.Func
2<single, bool>)
at MapMagic.GeneratorsAsset.Process (CoordRect rect, MapMagic.Results results, MapMagic.GeneratorsAsset gens, Size terrainSize, System.Collections.Generic.HashSet1 changedTypes, System.Func
2 stop) [0x002c4] in F:\Exbleative\UnityProjects\exoone2017_3\Assets\MapMagic\Main\GeneratorsAsset.cs:490
at MapMagic.GeneratorsAsset.Calculate (CoordRect rect, MapMagic.Results results, Size terrainSize, Int32 seed, System.Func`2 stop) [0x0001e] in F:\Exbleative\UnityProjects\exoone2017_3\Assets\MapMagic\Main\GeneratorsAsset.cs:234
at MapMagic.Chunk.ThreadFn () [0x0005b] in F:\Exbleative\UnityProjects\exoone2017_3\Assets\MapMagic\Main\Chunk.cs:224
UnityEngine.Debug:LogError(Object)
MapMagic.Chunk:ThreadFn() (at Assets/MapMagic/Main/Chunk.cs:227)
MapMagic.ThreadWorker:ThreadFn() (at Assets/MapMagic/Main/ThreadWorker.cs:533)