Difference between revisions of "Navmesh Disabling"

84 bytes added ,  04:46, 10 August 2010
no edit summary
imported>JBurgess
 
imported>Omzy
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Incomplete}}
{{Incomplete}}
[[Category:NavMesh]]
 
[[Category:Solutions]]


==Can I enable or disable navmesh?==
==Can I enable or disable navmesh?==
Line 14: Line 13:
You’ll end up with something looking like Fig 1b: Blue edges mean ‘special’ navmesh portal. They only get created when you use this menu command.
You’ll end up with something looking like Fig 1b: Blue edges mean ‘special’ navmesh portal. They only get created when you use this menu command.
   
   
From the Cell View window, name the new navmesh by double clicking on it or hitting F2.  Give it a meaningful name; you'll be using this in a script.  The following two functions enable/disable a navmesh
The following two functions enable/disable a navmesh
*'''EnableNavMesh''' ''myNavmeshNameHere''
*'''EnableNavMesh''' ''NavmeshFormIDHere''
*'''DisableNavMesh''' ''myNavmeshNameHere''
*'''DisableNavMesh''' ''NavmeshFormIDHere''
 
<blockquote>To change the ID of a Navmesh, find its editor ID in the [[Cell View Window]]. Right click on the ID, and select Edit. A new dialog will open, from which you can change the ID and set the Navmesh to be ''Initially Disabled.''
You CAN’T use '''myNavmeshNameHere.enable''', nor can you have activate parents, because Navmeshes are not references.
</blockquote>
You CAN’T use '''NavmeshFormIDHere.enable''', nor can you have activate parents, because Navmeshes are not references.


You can go on to swap this navmesh with a replacement, if your situation calls for such.  To start with, create the first navmesh like I described above Once you do, select a triangle on this new navmesh, as in Fig 1c.  Now HIDE it. Hit H to hide a navmesh, Ctrl-H to unhide Navmeshes.  Your workspace should look like Fig 1d.
You can go on to swap this navmesh with a replacement, if your situation calls for such.  To start with, create the first navmesh like I described above Once you do, select a triangle on this new navmesh, as in Fig 1c.  Now HIDE it. Hit H to hide a navmesh, Ctrl-H to unhide Navmeshes.  Your workspace should look like Fig 1d.
Line 31: Line 31:
Create more triangles for the new version (don’t worry about blue edges) as in Fig 2a.  Repeat the steps above to select this new area and separate into its own navmesh, as in Fig 2b.
Create more triangles for the new version (don’t worry about blue edges) as in Fig 2a.  Repeat the steps above to select this new area and separate into its own navmesh, as in Fig 2b.
   
   
You’ll end up with this something like Fig 2c.  Name this second navmesh as well.  Hit Ctrl-H to unhide all Navmeshes, you should see the overlapping separate navmesh objects, as in fig 2d.
You’ll end up with this something like Fig 2c.  Hit Ctrl-H to unhide all Navmeshes, you should see the overlapping separate navmesh objects, as in fig 2d.


Finalize and save.  In the game, enable one navmesh and disable the other via script, using the commands above.  Be sure that both navmesh objects are not enabled at the same time.
Finalize and save.  In the game, enable one navmesh and disable the other via script, using the commands above.  Be sure that both navmesh objects are not enabled at the same time.
Line 41: Line 41:
image:CutNavmesh08.jpg|Fig 2d:
image:CutNavmesh08.jpg|Fig 2d:
</gallery>
</gallery>
[[Category:NavMesh]]
[[Category:Advanced_Modding_Techniques]]
Anonymous user