Difference between revisions of "Pathing and Playtesting"

186 bytes added ,  17:51, 21 November 2015
m
imported>Snarker
imported>Megalomaniakaal
 
(5 intermediate revisions by 4 users not shown)
Line 1: Line 1:
[[Category:My First Dungeon]]
[[Category:My First Dungeon]]
(Back to [[Furniture, Traps, and Lighting]])
== Pathing ==
== Pathing ==
Pathnodes are placed to create a network which AI uses to navigate the cell.  While certain aspects of AI may not use the pathnodes, most navigation is handled by analyzing this network.  Thusly, it's very important to pathnode our cells carefully to get good behavior from our NPC's.
Pathnodes are placed to create a network which AI uses to navigate the cell.  While certain aspects of AI may not use the pathnodes, most navigation is handled by analyzing this network.  Thus it's very important to pathnode our cells carefully to get good behavior from our NPC's.
<br>[[Image:tut_img_15.jpg]]<br>
<br>
Press the button indicated above to switch to pathnode mode in the CS.  Depending on your viewing angle, you may notice a pre-existing network of pathnodes in the cell.  Remember the cell we duplicated way back at the beginning of this tutorial?  Pathnodes exist in parrallel of the cell, so they can only be manipulated, created or deleted in this mode.  (Notice also that you cannot select or otherwise affect the regular cell objects in this mode.) Drag a selection box around the old nodes and delete them now.  Move the camera around to make sure you got them all.
[[Image:tut_img_15.jpg|center]]
<br>
Press the dotted button circled in the image above to switch to pathnode mode in the CS.  Depending on your viewing angle, you may notice a pre-existing network of pathnodes in the cell.  Remember the cell we duplicated way back at the beginning of this tutorial?  Pathnodes exist in parrallel of the cell, so they can only be manipulated, created or deleted in this mode.  (Notice also that you cannot select or otherwise affect the regular cell objects in this mode.) Drag a selection box around the old nodes and delete them now.  Move the camera around to make sure you got them all.


Maneuver your view to the dungeon entrance and go into pathnode mode.  Right click the floor just inside the door.  This creates a basic node.  Now, while holding <b>"ctrl"</b>, click to create another where the entrance widens.  Notice the yellow line linking these?  That means the AI will see a valid path between the two points.  Note that this overrides what you may consider "common sense".  Be sure that these paths <i>actually are valid.</i>
Maneuver your view to the dungeon entrance and go into pathnode mode.  Right click the floor just inside the door.  This creates a basic node.  Now, while holding <b>"ctrl"</b>, click to create another where the entrance widens.  Notice the yellow line linking these?  That means the AI will see a valid path between the two points.  Note that this overrides what you may consider "common sense".  Be sure that these paths <i>actually are valid.</i>
<blockquote>
<blockquote>
Good pathing is learned from lots and lots of testing.   
Good pathing is learned from lots and lots of testing.   
Line 13: Line 18:
and such large monsters have different pathing needs.
and such large monsters have different pathing needs.
</blockquote>
</blockquote>
Notice the green outline around the new node?  This means it's currently selected.  Still holding "<b>ctrl</b>", create a third node by right-clicking the floor.  Let's link this one back to the entrance node we originally placed.  To do this; continue holding "ctrl" and <i>left-click</i> the node in question.  All 3 nodes should now be linked as shown below:
Notice the green outline around the new node?  This means it's currently selected.  Still holding "<b>ctrl</b>", create a third node by right-clicking the floor.  Let's link this one back to the entrance node we originally placed.  To do this; continue holding "ctrl" and <i>left-click</i> the node in question.  All 3 nodes should now be linked as shown below:
[[Image:img_tut_16.jpg|thumb|left|Basic Pathnode Linking]]
[[Image:img_tut_16.jpg|center|Basic Pathnode Linking]]
 
<blockquote>
Make a mistake on selecting a link? "ctrl" left-click again on the node to remove the link.
</blockquote>


Using this basic procedure, path the entire cell.  Take your time and be mindful of the dungeon surroundings, using "<b>F4</b>" to toggle collision geometry if you need to.
Using this basic procedure, path the entire cell.  Take your time and be mindful of the dungeon surroundings, using "<b>F4</b>" to toggle collision geometry if you need to.
<blockquote>
<blockquote>
Using the "alt" key, you can create blue pathnodes.  These special nodes indicate a preferred path for the AI.
Using the "alt" key, you can create blue pathnodes.  These special nodes indicate a preferred path for the AI.
This is mostly useful for roads, bridges, and city sidewalks, but can be used for special cases in dungeons.
This is mostly useful for roads, bridges, and city sidewalks, but can be used for special cases in dungeons.
</blockquote>
</blockquote>
The trap we placed earlier creates a problem.  As it's pathed now, AI will walk through and trigger the trap.   
The trap we placed earlier creates a problem.  As it's pathed now, AI will walk through and trigger the trap.   
This can be cool, but usually happens off-screen, which does nothing for the player's experience.
This can be cool, but usually happens off-screen, which does nothing for the player's experience.
In certain cases it is appropriate to ignore this problem, or to break the pathnode network here, but we can also set the pathnode to become active only after the trap has been triggered.  To do this, select the path node closest to the tripwire, and press <b>"R"</b>.  Using "Select Reference in Render Window", pick one of the maces.  The purple cage around the node now indicates that it is linked to the trap.
In certain cases it is appropriate to ignore this problem, or to break the pathnode network here, but we can also set the pathnode to become active only after the trap has been triggered.  To do this, select the path node closest to the tripwire, and press <b>"R"</b>.  Using "Select Reference in Render Window", pick one of the maces.  The purple cage around the node now indicates that it is linked to the trap.
<br><br>[[Image:img_tut_17.jpg|Linking pathnode to a persistent reference|320px]]
<br>
[[Image:img_tut_17.jpg|center|Linking pathnode to a persistent reference]]
<br>


== Playtesting ==
== Playtesting ==
Let's save and have our first playtest. To do this navigate to your "<b>Oblivion.ini</b>" file. This is automatically stored in the Oblivion folder in your My Games folder (My Documents\My Games\Oblivion\Oblivion.ini). Open the file and add "CreepyCaveTutorial01.esp" as one of the STestFiles, and change the SStartingCell to "CreepyCave01".  (Change names if you named yours differently.) Refer to this image for reference:
Let's save and have our first playtest. To do this navigate to your "<b>Oblivion.ini</b>" file. This is automatically stored in the Oblivion folder in your My Games folder (My Documents\My Games\Oblivion\Oblivion.ini). Open the file and add "CreepyCaveTutorial01.esp" as one of the STestFiles, and change the SStartingCell to "CreepyCave01".  (Change names if you named yours differently.) Refer to this image for reference:
<br>[[Image:img_tut_18.jpg|thumb|left|Editing Oblivion.ini|120px]]<br>
<br>
[[Image:img_tut_18.jpg|center|Editing Oblivion.ini]]
<br>
Now when you start Oblivion, you will begin as a default level 1 character in the chosen cell. Please note that if you want to test the cell at different levels, you must start outside that cell, manually adjust your level, and only <i>then</i> load into the cell.
Now when you start Oblivion, you will begin as a default level 1 character in the chosen cell. Please note that if you want to test the cell at different levels, you must start outside that cell, manually adjust your level, and only <i>then</i> load into the cell.


Line 53: Line 69:
</blockquote>
</blockquote>


We've still got ground to cover before this dungeon is any good to somebody who wants to play it - let's keep moving forward.<br>
We've still got ground to cover before this dungeon is any good to somebody who wants to play it - let's keep moving forward.
<br>
[[Linking Cells and Connecting to the Outside World]]
[[Linking Cells and Connecting to the Outside World]]