robin523790 Posted August 29, 2013 Share Posted August 29, 2013 Have you ever played a vampire and wondered why you're the only one who ever feeds? I regularly have vampire followers (most importantly: Serana), and they go for weeks and months without even having a snack!I am about to change that. A pure immersion mod, nothing else. What follows is a short description of what I want to do, then what I already did, and finally some questions on how to go on from there. So bear with me, please. :smile: What I want to do:Taking Serana as an example: When the player idles around (shopping, talking, scratching his nose...), she goes sandbox with the environment. What I would like to do is to have her pick a random NPC, casts Vampiric Seduction on him/her, then walk over and feed (ie. play a feed animation without actually "attacking" anyone). What I have done:I'm fairly new to writing mods, but I'm a professional software developer, so I figured: How hard can it be? ;-) I went through the official tutorials, built (then modified) my Lokir's Tomb. Put in a patrolling bandit and a vampire. Wrote a Papyrus script for the vampire that gets activated by a trigger the player steps into (or more precisely: the trigger sends an OnActivate to the vampire, and the script reacts to that event from this particular sender). All that works really fine: script gets activated, spell cast, bandit stops his patrol for 30secs, vampire walks over and has a taste. (And some other things. Script is attached, if you're curious. Feel free to steal/use however you see fit.) All that *only* works if the vampire has no AI packages. Sandboxing overrides my script's actions, obviously. Casting Vampiric Seduction on the bandit, however, interrupts his patrol for the duration of the Calm effect, which is nice.What I need next - and I'm unsure about how to proceed: * Randomly determine the victim: pick any nearby, living(!), humanoid NPC as a target (alternative: pick the closest one, or the prettiest) * Activate this behaviour not via trigger, but rather: When determining what kind of sandboxing to do next, have a chance of X percent to go eat someone (optional: X increases with time since last feeding), afterwards continue sandboxing. * Make all NPCs that are a member of both VampireFaction and CurrentFollowerFaction use the new behaviour without breaking anything.So, I don't know who the Actor is (any vampire follower), I don't know who the target is (any nearby, living, humanoid NPC; if any!), I don't even know where the player is (any location the player can reach). I *do* know that the Actor needs to be idle/go sandbox, but I don't want him to abandon sandboxing altogether; only sometimes and only for the duration of my script. I did much trial & error for 2-3 days, then spent some time reading through forums. Found much about AI packages, but also creating quests as a means to change behaviour was mentioned. But before I go and spend more days with testing the different methods, I thought I'd go and ask more experienced modders... How would YOU go about implementing this?Any hints and tips or pointers/links to more tutorials/docs would be highly appreciated! Thanks!-RobinOptional/later plans: * Create a copy of Vampiric Seduction to use in my script, so that a.) other mods changing Vampiric Seduction do not influence my mod, and b.) I can make changes to Vampiric Seduction that do not influence the player or other mods. * Make changes to my copy of Vampiric Seduction, so that it works on NPCs with level >8. * Only feed on NPCs when nobody's watching! Don't know if that's possible for the AI to determine if the victim is "isolated" enough to realistically feed on him/her. For now, I don't care about that. Link to comment Share on other sites More sharing options...
pheo3309 Posted August 31, 2013 Share Posted August 31, 2013 (edited) I'm not experienced, but I really do wish people would look into this as well. It bothered me immensely in the fact that you have random vampire attacks and no one truly feeds. Not to mention the fact your followers never feed. If I could also make a slight suggestion, what about having a random vampire feed on the player if they sleep outside of a town/city? It's probably not relevant in the whole AI of things, but I think it'd also add immersion to the mod you're working on. If it's possible that is. xD Edit: I'll also be tracking this topic and if I learn anything in regards to this, I'll see if I can't help. :D Edited August 31, 2013 by pheo3309 Link to comment Share on other sites More sharing options...
robin523790 Posted August 31, 2013 Author Share Posted August 31, 2013 Hey Pheo, thanks for your comments! I can definitely see using my mod not only for followers, but for vampires in general. For example the vampires in Castle Volkihar would go and snack on the Moth Priest, or on some human cattle in the cellar. Having vampires in the middle of a "random vampire attack" feed on their attackers... is an awesome idea! May be something quite different in terms of mechanics, because they're not idle, but using feeding as a special form of attack. Belua Sanguinare (best vampire overhaul I've ever seen) allows feeding as a kind of "finishing move" against enemies who are almost dead... and I can totally picture NPC vampires doing that in a fight! "...what about having a random vampire feed on the player if they sleep outside of a town/city?"As far as I know, that's already in vanilla. Problem is: main character is sleeping, so there's nobody to see the animation. ;-) Of course you could tweak things and make the character wake up with the vampire still bent over him. Both great ideas! Thanks, again. I will definitely look into them once I got my current problem handled! Link to comment Share on other sites More sharing options...
pheo3309 Posted August 31, 2013 Share Posted August 31, 2013 (edited) "...what about having a random vampire feed on the player if they sleep outside of a town/city?"As far as I know, that's already in vanilla. Problem is: main character is sleeping, so there's nobody to see the animation. ;-) Of course you could tweak things and make the character wake up with the vampire still bent over him. I haven't seen anything in topics, posts, or wikis that have documentation on that with vampire NPCs feeding on the player, nor have I been bitten. :ohdear: I've only rested and been attacked on sight. xD Edited August 31, 2013 by pheo3309 Link to comment Share on other sites More sharing options...
flexcreator Posted December 19, 2013 Share Posted December 19, 2013 Almost done:http://www.youtube.com/watch?v=hX8oYjIPrH4 Link to comment Share on other sites More sharing options...
pheo3309 Posted December 19, 2013 Share Posted December 19, 2013 (edited) Ohhh I can't wait for the release of this Flexcreator! Do you have an idea of a time frame? :O Edited December 19, 2013 by pheo3309 Link to comment Share on other sites More sharing options...
flexcreator Posted December 21, 2013 Share Posted December 21, 2013 The mod will be released tomorrow if everything will go ok. Link to comment Share on other sites More sharing options...
pheo3309 Posted December 21, 2013 Share Posted December 21, 2013 Most excellent! I'll definitely give it a test when I get a friend's housing mod I'm working on settled! Link to comment Share on other sites More sharing options...
flexcreator Posted December 21, 2013 Share Posted December 21, 2013 Another video:http://www.youtube.com/watch?v=5tQdOduLI5M Link to comment Share on other sites More sharing options...
pheo3309 Posted December 21, 2013 Share Posted December 21, 2013 Question; In an update would there be a possible infection rate as well, or would that break the game? xD That thing right there is going to be one of my must haves either way! :P Link to comment Share on other sites More sharing options...
Recommended Posts