thumbincubation Posted October 4, 2017 Share Posted October 4, 2017 I will definitely try, though it is a bit daunting. Thank you very much for this. :) Link to comment Share on other sites More sharing options...
blippyp Posted March 28, 2018 Share Posted March 28, 2018 EFF, AFT, any Follower Mod worth any thing use's Serana Codes verbatim, it called the Mental Model, & works by monitoring the player, so Serana knows when do something immersive, & when to simply follow & be boring, by triggering (switching) her AI Packages ...... I've been trying for well over a year to get Serana to cuddle as a spouse using the Campfire mod without any luck. I just came across this thread, and I'm not gonna lie, it's a little out of my scope atm. I am a programmer, but to get into all of this would still take a lot of work. You seem to really know your stuff regarding this topic, and can therefore likely easily and intelligently answer my question Could this 'MEMORY MODEL', be why Serana refuses to cuddle with the player like 90% of the other followers? And if you think it is (or have ANY idea what could be causing her to not cuddle), please let me know. This is likely an easy fix, but I can't figure it out, it's probably just a line changed in script somewhere or something. To be honest, I'm astonished that more people aren't complaining about this or that a mod hasn't been made to fix this issue yet. In all my testing, with the mods I use (I tend to use BV, Marriable Serana, Serana Dialogue Edit, Shared Serana Dialogue, Spouses Enhanced, Vampire Lord Serana, many other vamp and relationship type mods that are also related). I have tried limiting these mods, and adding more, I've tried all kinds of combinations of these mods in different load orders... Pretty sure I even did it without mods except for campfire to see if a mod was even causing the issue to begin with and that also failed, which is when I basically gave up until I saw this thread, which seems to explain a lot. I'm certain this is a simple fix. I would LOVE it if you simply made the fix, but if you have any answers for me and can at least point me in the right direction to solving this mystery, you'd make my immersive desires SO damn happy. With all the Serana mods out there, she is basically the best female wife imo, she has a ton of dialogue and literally has a lot to work with, but this one issue is driving me nuts. I just want to camp with my vamp wife and cuddle when we sleep! Is that really so much to ask! ;-P Yes I have also asked Chesko, I can't remember his response (or if he even did) just that it was basically a dead end as far as results. I'd even go with a whole new mod that works with campfire that does basically the same thing, i don't care if it's ONLY for Serana. But she just refuses to cuddle. It's been a long time since I've attempted modifying this, so i can't really explain in detail what I've done myself, but I can assure you I have gotten down to the scripting level to test this out, and I can't figure out any reason why she refuses to acknowledge the campfire code, this is probably my last hope without me becoming putting a ton of time into becoming a serious modder. All I can say is that I've checked the variables and it seems to work great, and have even 'forced' her to run the code, and it all goes fine, but then suddenly it just stops and fails to continue to go further and lay down and sleep. I have no idea why. I don't know if there's a package attached to her that makes is so she can't sleep or whatever. I just don't know enough about modding Skyrim to have the answer. All I know is that I really want this feature in my game and for the life of me I can't figure it out. Such a stupid little thing, but I've clearly gone bonkers over it already. Link to comment Share on other sites More sharing options...
Alerios Posted March 28, 2018 Share Posted March 28, 2018 blippyp : You can try the "Flower Girls" mod for romance and kiss her all the time you want ahah :laugh: Link to comment Share on other sites More sharing options...
blippyp Posted March 28, 2018 Share Posted March 28, 2018 Thx, I can already do all that other stuff... I really enjoy the cuddle animation and the 'idea' of cuddling after adventuring. It's already built into campfire, it just doesn't work for Serana for some ungodly reason. The issue here is that campfire is (as it is for many/most people I would assume) to be a permanent and vital part of my load order. Therefore, clearly my 'wife' would have to sleep with me using that system. It makes no sense for a married couple to sleep in different beds (hell, I don't think Serana EVER sleeps, which is probably 99% of the problem). I've seen her lay down, but I have never seen her actually sleep like other followers, she never uses the empty bedroll. I actually just tried the "Serana Stop Sandboxing" mod, after my previous post in hopes that I missed something before and that maybe this mod would fix the situation but nope. I think it has to do with this Mental Model stuff tbh. But I have no clue. She acts likes she's going to do it (I think I had to 'push' campfire to get that far also last time I tried this), but then she just refuses to lay down and sleep, so like I said, I think she just refuses to sleep at all. I just don't know what is making this happen. Link to comment Share on other sites More sharing options...
ArchitectXim Posted April 13, 2018 Share Posted April 13, 2018 EFF, AFT, any Follower Mod worth any thing use's Serana Codes verbatim, it called the Mental Model, & works by monitoring the player, so Serana knows when do something immersive, & when to simply follow & be boring, by triggering (switching) her AI Packages I use it myself, for my follower, how I how. Take a look, hopefully you can understand it Scriptname DLC1NPCMonitoringPlayerScript extends Quest DLC1_NPCMentalModelScript Property MM auto ReferenceAlias Property RNPC auto int Property UpdateInterval auto float Property SettleRadius auto int __historySize = 8 ; remember to update the declarations if necessary float[] __playerPosX float[] __playerPosY float[] __playerPosZ Function Setup() ; history of player position over the last __historySize updates __playerPosX = new float[8] __playerPosY = new float[8] __playerPosZ = new float[8] ; initialize the position histories with faraway junk datums ; so that we won't immediately assume the player is holding ; still when the quest starts Actor _player = Game.GetPlayer() int count = 0 while (count < __historySize) __playerPosX[count] = _player.X + 1000 __playerPosY[count] = _player.Y + 1000 __playerPosZ[count] = _player.Z + 1000 count += 1 endwhile RegisterForSingleUpdate(UpdateInterval) EndFunction Event OnUpdate() ; cycle all positions down one notch in the history arrays int historyIndex = 0 while (historyIndex < __historySize - 1) __playerPosX[historyIndex] = __playerPosX[historyIndex + 1] __playerPosY[historyIndex] = __playerPosY[historyIndex + 1] __playerPosZ[historyIndex] = __playerPosZ[historyIndex + 1] historyIndex += 1 endwhile ; set the most recent history as the current player position Actor _player = Game.GetPlayer() __playerPosX[__historySize - 1] = _player.X __playerPosY[__historySize - 1] = _player.Y __playerPosZ[__historySize - 1] = _player.Z ; check current position against oldest history point if we're ; in follow mode if (MM.IsFollowing) bool switchedPackageConditions = false if (!MM.IsWillingToWait && RNPC.GetActorReference().GetActorValue("WaitingForPlayer") != 0) ; she's not willing to wait for the player right now, but for ; some reason is waiting. Let's kick her out of this. RNPC.GetActorReference().SetActorValue("WaitingForPlayer", 0) switchedPackageConditions = true endif ; calculate distance between history start and present ; sqrt((x2 - x1)^2 + (y2 - y1)^2 + (z2 - z1)^2) float xFactor = (__playerPosX[0] - _player.X) xFactor = xFactor * xFactor float yFactor = (__playerPosY[0] - _player.Y) yFactor = yFactor * yFactor float zFactor = (__playerPosZ[0] - _player.Z) zFactor = zFactor * zFactor float distance = Math.sqrt(xFactor + yFactor + zFactor) ; if the player has moved less than the defined settle radius, ; set the flag that the sandbox package is looking for. if (distance > SettleRadius) if (MM.PlayerSettled == true) switchedPackageConditions = true endif MM.PlayerSettled = false else if (MM.PlayerSettled == false) switchedPackageConditions = true endif MM.PlayerSettled = true endif ; only do the EVP if we've actually changed the value if (switchedPackageConditions) if (MM.PlayerSettled) Debug.Trace("RNPC: Player settled; sandbox.") else Debug.Trace("RNPC: Player moving more than settle radius; resume follow.") endif RNPC.GetActorReference().EvaluatePackage() endif endif ; do it all again RegisterForSingleUpdate(UpdateInterval) EndEvent Once ya get coding working, with Virtual Machine conditions, move on to AI packages to complete Follower AI behavior. Not that hard really since it is just coping Beth. Little script knowledge is required, but not much. By copying all & sundry, it will be standalone & not require Dawnguard, like the above mods. Hi. I have been moding only somewhat casually for the past couple of years. I have taken a break from modding for awhile but now am working on it again. My current follower mod is turning out great. I made her, her own house and managed to get navmesh working properly. I've also succeeded in giving her a sleep package, eat package, and now a multi target archery training package. All of which I've never done before. I am pretty proud of myself so far and was thinking that I want to try to make her interact with her environment like Serana does. I thought by simply giving her a sandbox package (which is centered around PlayerRef) it would work. But from what you are saying, it sounds like it wont. If I understand you correctly, you are saying there is a way to set this up without having to have the Dawnguard DLC as a master. If that is the case I would very much like to learn how. I read over what you are saying, but I don't really understand it. I have a couple other questions regarding packages too. Link to comment Share on other sites More sharing options...
blippyp Posted April 22, 2018 Share Posted April 22, 2018 (edited) blippyp : You can try the "Flower Girls" mod for romance and kiss her all the time you want ahah :laugh: actually scratch that, although i was wrong about the scripting part (took a little playing around with that to figure that out), although it was related to her memory model like I was hoping after posting here, I did FINALLY get what I was after and even made a mod out of it. I'm a happy 'camper' now :smile: Edited April 22, 2018 by blippyp Link to comment Share on other sites More sharing options...
Recommended Posts