Sand's Exterior Area Turorial's
Posted: Tue Apr 20, 2010 11:08 am
OK, so I've decided to share some of my experience in area building with the rest of you ingrates.
First things first, the NWN2 Toolset is more like a graphics design package than an area builder, especially when it comes to exterior areas. There are many things to consider such as bloom settings, walkmesh pathing, shadowing and texturing that I imagine for many people are novel when first opening the toolset. I'll try to dispell some of the myths and give some pointers on how to best utilise (in my opinion) this powerful tool.
To begin with I'm going to work through three types of terrain common to the Forgotten Realms setting. Though in each tutorial I'll show a different type of area, the tricks and methods used can be combined to create all manner of regions for players to enjoy.
PRIMER
Its vital that you know what you are going to build. This might sound obvious, but you need more than a vague idea of what an area is going to be before you begin buiding it, you need to decide things like size, major features, is the area likely to see combat, what will the lighting settings be?
Without this you won't stand a chance of achieving the full potential of any exterior area. You should know, before you even open the toolset, in your imagination what an area is going to look like.
The three things I most often see missing in area building not directly conected to appearance are walkmesh pathing ,elevation and line of sight.
Pathing: The AI uses routines to find a path to any target, these are made "instantly" every 6 seconds (one combat round). If the AI cant find a path to a target or destination, it will look for another one until it finds one that is valid.
The AI will not "wait" if one creature is blocking the quickest route, it will send the NPC onto the next available route and it will then not recalculate a new path for the NPC until one combat round later, by which time the NPC may have lost two or more combat rounds bimbling about when it should be fighting. This is very important to consider as XP awards and CR ratings are based on the creature having some for of common sense that NWN2's AI routines can't simulate. Its up to us as the area builders to give it a helping hand.
With this in mind, there should be NO place in your area where the walkmesh is too narrow for two medium size creatures to fit through simultaneously. I'll demonstrate this in the tutorials.
Elevation: By default, the player can only look up whilst in character drive mode, this camera mode limits the players view in other ways though. It is also unlikely the camera will ever be focused "up" by default. This means any hostile NPCs on a steep elevation that the player can not see on screen will target and attack the PC before the PC has a chance to react. This might seem reasonable enough as the NPCs "surprise" the PC(s) but it passes an unfair advantage to the NPC in that the NPC will automatically attack any PC that comes into its perception range irresepective of elevation differences.
Its tempting for some to create very steep, almost vertical slopes. This should be avoided for two reasons. Firstly, its unrealistic. Slopes over 1:2 are pretty rare in nature and normally collapse through errosion in a very short timeframe. Secondly, it prevents PC's seeing up the slope, but does not affect the AI as the AI routines do not take into account the slope of terrain in any way. So an NPC on top of a slope could fire a crossbow at the PC, but the PC would have difficulty targetting and firing back at the NPC.
Line Of Sight: Line of sight in this example means the line of sight available to the player in the game client, this is very different from line of sight calculated for NPCs. Too much foligae, smoke, etc will mean a PC can not see an NPC to target them, whilst the NPC is again unaffected and can target the PC. When considering this you should also bear in mind the objects around the PC, avoid where possible "boxing in" a location on three sides or leaving only a very narrow entry to an otherwise unaccesible location. This is because the player client camera can not exist within an area of placeable or terrain walkmesh (I'm sure youve all experienced "camera chop" when the camera whips between zoom and close up as the PC moves about). This is builder error and not a game engine error, its avoidable if you use non-static placeables to block movement rather than allowing the placeable to cut the walkmesh during baking.
One other thing to mention before we begin is the difference between placeables and environment objects. Environment objects are a converted placeable that is to all intents and pruposes just a graphic, it hase no "physical" presence within the game's physics engine. This is great for cutting down on module size and server load, but carries a few drawbacks. The Environment object may not fade correctly when blocking camera view and environment objects do not grant PCs a bonus for hiding in shadows (a PC or NPC gets a bonus to hide checks if they are in the shadow of a placeable object) as this is calculated using an objects C1 collision boundary, and environment objects have no C1 collision boundary. Environment objects should only really be used outside the occlusion grid or towards the centre of other wise inaccesible locations.
First things first, the NWN2 Toolset is more like a graphics design package than an area builder, especially when it comes to exterior areas. There are many things to consider such as bloom settings, walkmesh pathing, shadowing and texturing that I imagine for many people are novel when first opening the toolset. I'll try to dispell some of the myths and give some pointers on how to best utilise (in my opinion) this powerful tool.
To begin with I'm going to work through three types of terrain common to the Forgotten Realms setting. Though in each tutorial I'll show a different type of area, the tricks and methods used can be combined to create all manner of regions for players to enjoy.
PRIMER
Its vital that you know what you are going to build. This might sound obvious, but you need more than a vague idea of what an area is going to be before you begin buiding it, you need to decide things like size, major features, is the area likely to see combat, what will the lighting settings be?
Without this you won't stand a chance of achieving the full potential of any exterior area. You should know, before you even open the toolset, in your imagination what an area is going to look like.
The three things I most often see missing in area building not directly conected to appearance are walkmesh pathing ,elevation and line of sight.
Pathing: The AI uses routines to find a path to any target, these are made "instantly" every 6 seconds (one combat round). If the AI cant find a path to a target or destination, it will look for another one until it finds one that is valid.
The AI will not "wait" if one creature is blocking the quickest route, it will send the NPC onto the next available route and it will then not recalculate a new path for the NPC until one combat round later, by which time the NPC may have lost two or more combat rounds bimbling about when it should be fighting. This is very important to consider as XP awards and CR ratings are based on the creature having some for of common sense that NWN2's AI routines can't simulate. Its up to us as the area builders to give it a helping hand.
With this in mind, there should be NO place in your area where the walkmesh is too narrow for two medium size creatures to fit through simultaneously. I'll demonstrate this in the tutorials.
Elevation: By default, the player can only look up whilst in character drive mode, this camera mode limits the players view in other ways though. It is also unlikely the camera will ever be focused "up" by default. This means any hostile NPCs on a steep elevation that the player can not see on screen will target and attack the PC before the PC has a chance to react. This might seem reasonable enough as the NPCs "surprise" the PC(s) but it passes an unfair advantage to the NPC in that the NPC will automatically attack any PC that comes into its perception range irresepective of elevation differences.
Its tempting for some to create very steep, almost vertical slopes. This should be avoided for two reasons. Firstly, its unrealistic. Slopes over 1:2 are pretty rare in nature and normally collapse through errosion in a very short timeframe. Secondly, it prevents PC's seeing up the slope, but does not affect the AI as the AI routines do not take into account the slope of terrain in any way. So an NPC on top of a slope could fire a crossbow at the PC, but the PC would have difficulty targetting and firing back at the NPC.
Line Of Sight: Line of sight in this example means the line of sight available to the player in the game client, this is very different from line of sight calculated for NPCs. Too much foligae, smoke, etc will mean a PC can not see an NPC to target them, whilst the NPC is again unaffected and can target the PC. When considering this you should also bear in mind the objects around the PC, avoid where possible "boxing in" a location on three sides or leaving only a very narrow entry to an otherwise unaccesible location. This is because the player client camera can not exist within an area of placeable or terrain walkmesh (I'm sure youve all experienced "camera chop" when the camera whips between zoom and close up as the PC moves about). This is builder error and not a game engine error, its avoidable if you use non-static placeables to block movement rather than allowing the placeable to cut the walkmesh during baking.
One other thing to mention before we begin is the difference between placeables and environment objects. Environment objects are a converted placeable that is to all intents and pruposes just a graphic, it hase no "physical" presence within the game's physics engine. This is great for cutting down on module size and server load, but carries a few drawbacks. The Environment object may not fade correctly when blocking camera view and environment objects do not grant PCs a bonus for hiding in shadows (a PC or NPC gets a bonus to hide checks if they are in the shadow of a placeable object) as this is calculated using an objects C1 collision boundary, and environment objects have no C1 collision boundary. Environment objects should only really be used outside the occlusion grid or towards the centre of other wise inaccesible locations.




































