NWN Custom Model Collision Issue

Anyone know how to export models out of NWMax+ in 3DSMax with proper collision? I made some building placeables for a module I’m making. I get it in the toolset just fine with textures and such, edit the 2da, import into hakpak, then make the custom placeable appear in the blueprints list to use, but they have no collision? is there some sort of setting that needs attention prior to export? I also use VelTools plugin but for the process mentioned prior, I have had no need to use it. My 3DS Max version is 2022. Thanks in advance!

If you didn’t make a walkmesh for your placeable, everyone will be able to walk through it.
If your placeables auroabase is named plc_xyz01 you need a dummy named plc_xyz01_pwk linked to it and the geometry of your walkmesh (let’s name it “pwk”) linked to that dummy and the dummy needs a placeable modifier as shown in the picture.
Old style NWN placeables only have a flat plane with faces set to material type 7 which indicates where walking is not possible. This however means that you can move it a bit below ground and it won’t work any more.
Newer placeables use 3d walkmeshes. To keep it simple let’s say your placeable is a rectangular shed, then your “pwk” would be a box around that shed with the bottom faces removed. You can set the material type of the remaining faces to 2 or 7. You also have to make sure that the pivot point of the pwk is at 0, 0, 0.
If you have done everything right, you’ll not only get a .mdl file when you export but also a .pwk file (placeable walkmesh). You need both of those files in your hak.
https://cdn.discordapp.com/attachments/457236670664933378/896816933658308628/pwk.jpg

ty kindly for this. I’m just curious…what’s this about material types on faces needing to be numbered? I just use the typical material slots in 3DSMax for texturing, or is this not the same thing? I will try the other points you disscused. I been using AuroraTrimesh just to get my models exported. Using AuroraPlaceable didn’t work and probably because I failed to do what you mention above.

So maybe I’m not understanding what your saying here or maybe I do but am missing something.
Would it be possible if you could make a list of exact steps to do to make this all happen and possible screenshots of the side menu with the models, aurorabase, walk mesh, dummy etc? I still do not understand walk meshes, or creating a 3D one except the concept of making an actual edit poly mesh for the collision box, and how would it become invisible for when in use or at export? I tried doing as close as I could to what you said but it won’t even export now unless I go back to what I did before and make it a AuroraTrimesh. :frowning:

I wish there was a good tutorial online somewhere to just learn this step by step but thats why I came here, couldn’t seem to find one.

I can list what I did step by step here though to give you an idea what I did:

1.) I created a “Dummy” and centered it on the grid to ,0,0,0. I named it “plc_grave_pwk” as my placeable is named “plc_grave”. Both the placeable and dummy share the 0,0,0 space and are centered including pivots.

2.) I created a box right around the placeable and named it “pwk”. I put a material on it and gave it 10 opacity so i could still see my placeable. This too is centered to 0,0,0 and removed the bottom face/polygon.

3.) I linked the dummy to the aurorabase, and linked the “pwk” (collision box model) to the dummy. (oddly, the aurorabase is now a child and the dummy is the parent? idk if that is correct or not after linking)

4.) Gave the “dummy” a placeable modifier “AuroraPlaceable” just like the picture you showed there in the link.

So what I’m having an issue understanding is what is setting faces to a “material type”? Is this a special option within NWMax+? and how would I go about it and setting them to 2 or 7?

I will include screenshots of what I have in the left side hierarchy for the placeable and the aurorabase, dummy, pwk, etc. as well as the right side menu and placeable itself.

So hierarchy is as follows from top to bottom:

Top: Dummy = plc_grave_pwk

Right Below Dummy: AuroraBase = plc_grave

Right Below AuroraBase: ignore_NGon001 and the “Placeable” model itself that will be the actual model placeable, “plc_grave”

Right Below Placeable Model: Collision Mesh Box = “pwk” (Clear Box)

If I screwed up somewhere help would be greatly appreciated. If it is all correct, maybe my issue is what I fail to understand above about material types.

plc_grave_pwk needs to be a child of plc_grave, not vice versa. Pwk needs to be a child of plc_grave_pwk.

Here is a tutorial: LOK Tutorial 1 : Create Placeable Model | The Neverwinter Vault

So I figured it all out. Got it all to work on 3 separate models. Below I will post screen shots of each model and the setup for each. Basically in a nutshell for anybody looking to make placeables in NWNEE, just follow the steps I list below and you should be just fine. This will be considering you are using NWMax+ only and not with VelTools.

1.) After your model is ready for export and you have it textured (Diffuse in diffuse slot, Bump/Normal Map in Bump slot, Specular, in Specular slot, etc. within the material/UV map properties below under “Maps”) and named your model something like “plc_nameofmodel” were “plc_” is the required prefix for all models, Go to the right side were your “Modifiers” menu would be and go to “Helpers”. This will be shown with a sort of triangle ruler symbol:

HelpersSymbol

Here, make sure you select on the drop down menu “Neverwinter Nights”. This should be available if you installed NWMax+ properly and all scripts have been put in the proper folders within the 3DS Max directory folder. By default the dropdown menu will show “Standard”.

2.) Now select the “AuroraBase” button, then select your 3D Model/Mesh. A menu will pop up looking like this:

AuroraBaseMenu

Alternatively you can also check the “Center to (0,0,0)” box to automaticlly center your AuroraBase.

Under “Model Type” select “WalkMesh”. Under “Name” type in something like “plc_nameofmodel”
were “nameofmodel” is the name of your model you are exporting, this part is very important! So if you have not already named your 3D model prior, do so after this step. It must match whatever you put into this menu for your AuroraBase.

2.) Now you must link your 3D Model/Mesh to the AuroaBase. I tend to simply drag and drop the “plc_nameofmodel” 3D Model/Mesh itself, onto the AuroraBase “plc_nameofmodel” helper by simply selecting the mesh on the menu, and then moving it until I am right over the helper of the same name, then dropping it. It should then be under the AuroraBase helper, this will be shown when a arrow pointed to the right appears next to the helper, and either shows your model/mesh under it, or if closed, when you open it on the menu. Below will show the AuroraBase helper closed, then opened with your 3D Model/Mesh under it. So, the helper aka AuroraBase, in my case “plc_grave” will be the “Parent”, and your 3D Model/Mesh will be the “Child”.

“AuroraBase” Helper closed on the menu.

“AuroraBase” helper open on the menu, and your 3D Model/Mesh under it, here, circled in red.

(Do not worry about the other stuff you see just yet as we will explain those later, just pay attention to the examples of my model here, the AuroraBase, the “Parent” being named exactly the same as my model, and my model, which will have a sort of Sphere symbol next to it, is under the AuroraBase as a “Child”.)

3.) Now you must add a “Dummy” to the scene and link this to your AuroraBase the same way you did your 3D Model/Mesh. This dummy will appear on the grid of the 3D Model viewport as a small wireframe square. To add a “Dummy” tot he scene, you want to go to your NWMax+ menu and under “General Utils” select the “Dummy” button, and then click anywhere on the viewport were your model is displayed. I would try to keep it close to your model, but we will move this to the center of the grid anyways. Now, you must name this dummy “plc_nameofmodel_pwk” and like you did to your 3D Model/Mesh, drag and drop this over your AuroraBase helper. This should make it a child of your AuroraBase helper and show it in the same list as your 3D Model/Mesh “plc_nameofmodel” and “ignore_NGon001”. Now, select the dummy, and go to the right side menu under the modify tab, and in the drop down menu select “AuroraPlaceable”. This should appear above the “Dummy” on the menu. This is needed to tell the game engine your 3D Model is indeed a placeable. It should look like this:

(Note: The “Dummy” on the left side menu will have the same triangle ruler symbol as your helper, but do not worry, it is suppose to look this way. The “_pwk” suffix should help you tell the difference between your AuroraBase helper and the dummy itself.)

4.) Once you have this in place on the grid at 0,0,0, and you have it the “Child” of your AuroraBase Helper on the left side menu, you will now make a “Bounding Box” or “Collision Box” around your model which will be used to tell the game engine were the player cannot pass through. What works best, at least for me, is to just make a clone of your 3D Model/Mesh itself. I would probably do this at the first part of this, but you can do this now if you have not done so, simply make sure the model in the left side menu under your AuroraBase is highlighted, then right click, and select “Clone”. Make sure you select “Copy” not instance, and then simply name it say “plc_yourmodelname_02” for now so you can tell it is the clone. Now, go to the material editor within 3DS Max, make sure it is on slot 2, right after the first one on the top row:

5.) Scroll below were you would see the Ambient, Diffuse, and Specular parts. The color does not matter but I tend to stick with the default grey, and then make the opacity of the color material around 10 or 20 so it looks transparent. You do not have to do this, but I do it so I can still see my model when creating the Collision Box:

6.) Now, make sure your actual model “plc_nameyourmodel” is now hidden by selecting the “Eye” symbol next to it on the left side menu. This will help keep you from dragging and dropping this transparent material onto the wrong model. The model you will drag and drop this transparent material on, will be the “plc_nameyourmodel_02” I listed above which will become your Collision Box. After this is done, you want to then rename this cloned model to “pwk”. What you should now see, is your cloned model fitting perfectly over your original model, with a transparent material so you can see it perfectly. Both models need to be in the exact same place on the grid, 0,0,0 for this to work properly. Now take this “pwk” model and drag and drop it over the “plc_nameyourmodel_pwk” and it should become the “Child”. This part is important as well, as if you do not do this, the model itself will not export and the WalkMesh will not be created on export. You will also be met with issues in the toolset later. You now need to select the “pwk”, and on the right side menu under the “Modify” tab on the drop down menu below, select the “AuroraWalkmesh” modifier. Much like adding the “AuroraPlaceable” above the “Dummy” before, here, do the same for the “pwk” but with the “AuroraWalkmesh” modifier as it is required so the models “pwk” collision model clone/collision box is detected in game while playing and prevents the player from passing through. If done correctly, it should look like the screenshots below. Using an exact copy of your model as a “pwk” helps create a perfect collision for any model and will realistically show this in game.

The screenshots below are as follows:

#1 being your original 3D Model/Mesh, #2 being the “pwk” transparent clone 3D Model/Mesh, and #3 being the “pwk” over your 3D Model/Mesh giving it that sort of faded look and representing the exact collision the model will have in game:

#1

#2

#3

7.) Unhide your original model so you can see it under the transparent cloned model aka “Collision Box” or “pwk” like I have displayed in screenshot #3. In the screenshot below, if you have done everything correctly, the hierarchy should look like this, just replace what I listed above “plc_yourmodelname” with my example “plc_grave” and you will be able to see what I am trying to explain:

The hierarchy should go like this as shown in the screenshot above:

Top: Your AuroraBase helper “Parent”: "plc_yourmodelname"
Below Top: The “Dummy” helper "plc_yourmodelname_pwk"
Below Dummy as “Child”: Your Collision Box Model "pwk"
Below Collision Box (pwk): Your actual 3D Model/Mesh: "plc_yourmodelname"
Bottom of All: "ignore_NGon001"

It will look exactly like that if you did everything properly.

8.) Make sure everything is scaled properly using the “Scale Wizard” button under NWMax+ “General Utils” menu or using “Xform” under the “Utilities” tab on the right side menu.

(You can also easily dock NWMax+ by clicking the “Dock NWMax+” button under the “General Utils” menu.)

9.) Now, select your “AuroraBase” at the very top of the hierarchy menu on the left side, and look to the right side menu. You should see “MDL Base Parameters”, and under that you should see a “Export” section. Select “Browse” and select a folder you will be exporting your models too. Make sure though, to not overwrite models, as sometimes your newest version may not override the older versions. It is best to move or delete the prior model before exporting another into the same folder.

10.) If everything was done correctly, it should say on the bottom left corner of your window, in a sort of white box, “Exported 1 models”. Check your export folder, it should show the MDL file of your model and a pwk file with it. If not, you did something wrong, and if your MDL file is only 1 Kb, you also did something wrong. Sometimes, a error will pop up saying there was a problem and to check you Sanity Check log file. This option is located in that very same “Export” section I just mentioned at the bottom. This will help you figure out what the problem may be.

(Make sure that your AuroraBase, your 3D Model/Mesh, and Dummy, are all centered to the grid at 0,0,0. This will ensure this all works properly but also keeps things in order. You also want to make sure, your 3D Model/Mesh’s pivot point is centered to the model, and is at 0 on the Z axis. This part I assume you should know as it is a very basic and common thing to do for all models when using this program. Simply look up how to do this on Google or whatever search engine you use.)

Hopefully this helps everybody else running into issues I was. I will eventually make a YouTube video with commentary showing exactly how all this is done, so you can all get a good idea visually what you need to do, from designing the model, texturing the model and adding normal maps, specular maps, and so on, to what I listed here, to editing the “appearances.2da” file to allow your model to show up in the Aurora Toolset Editor and Game Engine, adding all texture files, models, 2das, and MTR files into a Hak Pak for use within the Toolset and game.

(I may edit this further to better explain the process in the future. This should be enough but I may think of a better way to list and word this tutorial at some point.)

The 3 models I made for a NWN:EE module based after the SNES and Amiga game “Drakkhen” which is also a D&D type game. It was partially designed, and written by Gary Gygax himself.

Looks good, BUT I disagree on the PWK. Complex walkmeshes are a bugger on pathfinding. You are much better to use a simpler mesh for the pwk plane - preferably a flat 2D plane. If you must have a 3D pwk, start with a simple 2D plane then use “extrude” on the faces and raise it a few units and then “chamfer” it with a negative value (-5.0 works good). If you want to still have LOS over the placeable, don’t raise the faces more than 15.0-25.0 units. Higher than that and it becomes obscurring.

Interesting. Could you show an example of this occurring? I heard the old way was all 2D planes, but now they use 3D pwks, and that 2D planes can also be an issue if they go too far below the ground, essentially making them useless?. But yes, 3D pwks can be an issue, I just figured you design your model to keep pathfinding in mind best you can if you intend for it to go through your models or the player to go through them. Trying to understand your example but not sure I understand. the LOS (guessing you mean line of sight) I can see being an issue, but some of the models were not intended for that. I might do it for smaller walls, and if scripts I used worked with say more book type rules that would actually utilize and keep in mind all LOS bonuses and negatives depending on the models the player is behind.

Still new to all this so I’m always open to new knowledge. :smiley: so thank you for sharing.

The best example off the top of my head are the NWN2 placeable ports TheGeorge made. According to Soren, they can cause pathing issues due to the complexity of the pwk mesh - the mesh is just a clone of the hi-poly model mesh. Another example is any of LoW’s outdoor tilesets. Some tiles have horrid pathing issues because of the complexity of the wok, it being made by just cloning the hi-poly tile features and merging them all into one mesh.

You are right that 2D pwks can be an issue if they go too far below the ground plane. Thus, you have to anticipate how the placeable will be used. If its an indoor feature, you can probably get away with a 2D plane. If its something you plan to use in an exterior setting where the surface terrain might be uneven, then a 3D pwk is preferred over a 2D plane.

In either case, you’ll still want to keep the polycount as low as possible. For example, looking at one of TheGeorge’s NWN2 workbenches, the complex 3D pwk mesh could have been easily made as a 3D box with a z-height of 20.0 units - eight verts as opposed to how ever many 100 the actual model has.

1 Like