Jump to content

npc help


ninjaseikai

Recommended Posts

hello!

 

i recently made a vampire lair that i think looks amazing. its an addon to sinbloods vampire lair. its a chapel located near anvil with plenty inside for a whole clan of vampires, the only;y problem is theres no vampires in it.

 

im not good with the npcs at all. i tried first with placing cattle in the cells and when i loaded it up they were wandering all over the place. not what my cattle should be doing.

 

i dont understand how the AI works at all and i was wondering if anyone would like to help out. i dont want anything complex, just simply add cattle to the cells that stay there and sleep occasionally. and possibly a few vampire npcs. they dont need any fancy dialogue or quests or anything, just maybe wander around the chapel and go out at night or something, nothing too hard. id just like them to look nice with hair other than vanilla.

 

but mostly im just asking for the cattle, i can make vampires in game and have them follow me to my lair but i cant think of a way to make cattle.

 

if your willing to help let me know and ill send you the .esp

 

thank you!

Link to comment
Share on other sites

You might want to try doing it yourself first for the experience.

 

Short Answer: Create a "Sleep" AI Package with no time, duration, or conditions. Set the location to a persistent reference near the cattle's bedroll or, if the cattle are placed in the CS near their bedroll, near editor marker. A radius of 500 should do. Give all the cattle this AI Package, and make sure they don't have any others.

 

Long answer: Take a look at an NPC's AI section. At the top should be some stats.

Aggression: If the actor's disposition towards anyone is lower than their aggression, and they're not faction-mates, the actor will attack. I think unless they have an aggression of five or more they won't start combat under any circumstances, (Aside from sccripting) and with an aggression of zero they won't even fight back.

Confidence: If the NPC's health is at a lower percentage than (100 - Confidence), they'll flee from whoever's fighting them. Someone with a confidence of 0 will always flee combat, someone with a confidence of 50 will flee once they reach half HP, and someone with a confidence of 100 will never flee. (Aside from scripting)

Responsibility: If an NPC's responsibility is less than 30, they'll steal if it's required for an AI package, and won't yell if they see a crime. An NPC with a confidence of 100 can report crimes directly, automatically giving the player a bounty even if not a guard.

Energy: The higher an actor's Energy, the more they'll move about when wandering.

 

The real meat of an Actor's AI, however, can be seen in the AI Package list at the bottom. Open up an AI Package. AI Packages can be given certain conditions and run-times, and are sorted by priority. (How high on the actor's list they are) Some AI Packages also have a target, and most have a location. The run-time is determined by the AI Package's duration and time. AI Packages will run from <time> to <time + duration>. If "time" isn't specified, they'll run whenever.

 

Consider an NPC with the following AI Packages, in the order listed. Assume he was placed (that is to say, his Editor Location is) in his one-cell home. Higher-up AI Packages have priority over lower ones.

 

aaaSleep22x8: A "Sleep" AI Package with a location of "Near Editor Location". Starts at 10 PM, and runs for eight hours.

MyWindowShopping: A brand-new Wander AI Package. The location is set as a marker in a store, with a radius of 1000. The time is 15, and the duration is 2. This one has a condition of (GetItemCount gold001 >= 10).

MyWanderInTown: Another new Wander AI Package, with the location set as a marker in the middle of town, and a radius of 3000 units. The time is 14, and the duration is 4.

aaaEat12x2: Since "aaa" packages are "default" packages, 12x2 means from 12 to 14, or starting at noon and continuing two hours. This is an "Eat" AI Package with the location set as within 2048 units of the Editor Location.

aaaEat18x2: Should be obvious with the description of the last AI Package.

aaaDefaultExploreEditorLoc1024: Wander at the subject's Editor Location, within a radius of 1024 units. No conditions or time specified.

 

This NPC would start his day at 6 AM, since that's when his "Sleep" AI Package ends. aaaDefaultExploreEditorLoc1024 would always run when none of the others are, so he would wander around his house until noon, when he would eat lunch. When he finished, it would be 2 PM, so he would wander around town. Come 3 PM, if he has ten or more gold, he would hang out in a shop until 5 PM, then wander around in town again until 6. If he doesn't have that much gold on him, he would just keep on wandering until 6 PM. This is because the "Wander in town" AI Package is still "ready to go" when the window-shopping one is, but since the window-shopping package is higher-priority, it will be interrupted unless our subject has less than 10 gold, in which case the window-shopping package can't run.

 

At 6, he'll head home and eat dinner, finishing at 8. Since now there aren't any eligible AI Packages aside from the lowest-priority "Wander at Home" package that's always eligible, he'll do that until 10 PM rolls along and the higher-priority Sleep AI Package is also eligible. Then he'll turn in. With this knowledge, you should be able to get your NPCs' AI to work properly with little trouble.

Link to comment
Share on other sites

uh i was deleting dialogue and i just recently realized i was deleting it from everyone and not just my cattle. ive already saved too, is there anyway to restore them without starting my mod over? i kinda want my hellos when i talk to npcs
Link to comment
Share on other sites

Firstly, you might want to set the duration to zero. Secondly, you should know that the game's units of measurement are very, very small. Try 500. If it still doesn't work, if you upload it, I'll take a look.

 

As for the dialogue, try selecting your file under Data, clicking "Details", and looking for "INFO" forms for the dialogues you deleted. Select them individually and press the "Delete" key. Or, if all you've done so far is delete greetings you shouldn't, you can just select the GREETING dialogue and press the delete key.

Link to comment
Share on other sites

Does that mean it works now? Woohoo!

 

I'm not sure at all how file dependency works. All I can reccommend is taking a look at Wrye Bash, which lets you mess with a mod's master list. If you didn't use anything from any of the other .esm files in its making, you should just be able to remove them from the plugin's master list. I think... :unsure:

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

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