Jump to content

Help request: Custom NPCs incorrectly spawning in interior cell


Guinefort1

Recommended Posts

Hi all,

 

I'm working on a project that places custom NPCs into a custom hut. Everything seemed to be going fine until I checked it out in game. Rather than spawn inside the hut, like they were placed to do in the CS, they spawn outside of the interior cell, in the the outer void. Everything else seems to be working fine otherwise. Any feedback would be appreciated.

 

Thanks,

 

Guinefort1

Link to comment
Share on other sites

Are you sure they are spawning outside the hut, instead of simply walking outside it while you reach the place where they are? Well, I assume you have your PC saved inside the hut, so you don't need to travel there and give the NPCs time to move out but even so, they are capable of doing it. This is even more noticeably with CM Partners NPCs.

 

Check their AI packages, because NPCs will not stay still where they spawn, waiting for you. As soon as they spawn, their AI packages will trigger and if the hour of the day demands that they do something like, say, wander, they will go to the nearest door and, well, wander.

 

In the game, the NPCs that are supposed to be found always inside caves or ruins, have a scripted spawn point, which means they will NOT spawn into the game until you enter the cell.

 

Cheers!

Link to comment
Share on other sites

The NPCs are programmed to wander inside of the hut and remain there, so I'm pretty sure that its not an A.I. problem. As far as I can tell, I didn't do anything different with these NPCs than I with when programming Order of the Lamp, except that the NPCs in the current project are in a custom interior cell, not a vanilla one. The problem is not that the NPCs are moving about when I'm not there, it's that they really are spawning in the void. They aren't outside. They are perpetually falling and re-spawning in the grey space (black in game) you see surrounding interior cells in the CS. I know this because I can see them with detect life spells and can interact with them when I pass through the walls with toggle collision.

 

As for path gridding, no the hut doesn't have that. I'll be sure to look into that.

 

I have screen shots to show what I am talking about. If someone could tell me how to post images on the forums, I'd appreciate it. But don't tell me to use the image tab: that's for URLs, not images saved on my desktop.

Link to comment
Share on other sites

Update:

 

I reset the NPCs by deleting and re-placing them in the cell. Now they are spawning in the appropriate location. I'm still baffled as to how they managed to phase through the walls the first time. :confused: Because the CS acts stupid?

 

I'd forgotten that custom cells need path grids to be put in place, so I'll get on that.

 

Thanks for the help. Hopefully it will be relatively smooth sailing from here.

Link to comment
Share on other sites

Guinefort, you can't post here a pic unless you upload it somewhere. The only way to put here pictures (or whatever) from your hard drive is to attach them using the Attach Files in the "Show more reply options". Like this:

 

Yup, looks like the problem with your NPCs is related to pathgridding. I had the same problem of entering a custom, non path-gridded, cell and instead of appearing where I was expecting, I appeared in the Void and fell to the ignote profoundinessess of the unknown. Just like that. Once I pathgridded the cell, all was well.

 

Cheers!

Edited by IkeCoast
Link to comment
Share on other sites

Well, I figured out how to pathgrid on the CS wiki (mostly, at any rate). When you said you had this problem in the past, did you mean for custom NPCs or for your PC, because as far as I know, your PC does not rely on pathgridding to navigate? Because now I’m having the problem of the NPC AI not recognizing the new pathing. They just stand there like a pack of dolts. Resetting them like I did before hasn't done anything either. Oh, the fun never ends. :dry:

 

Incidentally, thanks for clearing up the image posting question. It is amazing how some features can elude computer morons like me.

 

Regardless, thanks to you both for the help.

 

Edit:

 

 

 

As proof of concept, in case anyone can see any problems. And to ensure that I've learned how to post pics. Ignore the missing textures, lol.

Edited by Guinefort1
Link to comment
Share on other sites

Did you "f" key drop the grid nodes after putting them into the cell?

 

How big of a wander range does the NPC's default wander package have? I think the Energy setting at the top of the NPC's AI package window has something to do with how often they'll evaluate and move on a wander package. I generally set it to a moderate number in the range of 40 to 70 for most NPCs I create.

Link to comment
Share on other sites

The NPCs’ energy levels are set at 50. As for the red nodes, I did press F a few times for the ones that were floating in the air, but most of them spawned on the ground when I first placed them. I'll go ahead and rebuild it from scratch to see if that does anything.

 

Update:

 

Success! I rebuilt the pathgrid and it worked. My guess is that some of the red beacons were not completely level with the ground that first time, hence why they just stood there like statues. One last question, since you probably know more about this that I do. For the location data of their wander packages, would it be better to the location data to be their cell (i.e. selecting their hut from the dropdown menu) or to be the Near Current Location/Near Editor Location options with a manually set radius? Thank you both for all of your help. Unfortunately a lot of minutiae can’t just be gleaned from online tutorials. Happy modding!

Edited by Guinefort1
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...