-
Posts
498 -
Joined
-
Last visited
Everything posted by Sphered
-
NP. Will mention that I did remember how to get them to cast ritual spells without having to override their AI. Basically you need to add a magic effect that you know NPCs like to cast, like stoneflesh etc, at the top of the list in the spell record. Make sure all effects minimum level is either 0 or low enough for your NPC's skill. They now will cast the spell if they have enough magicka. Quirkly like I said but at least you have another option Combat override is extra steps but still the way I would go for the most control of when and what situations your follower will cast things. Either way can work
-
Not something quickly explained but thankfully there are numerous guides you can refer to for making any package you want There is a routine available called "UseMagic" which like it sounds, makes a NPC use magic. They do not even need to actually have the spell learned, or any amount of magicka to use it. They will cast whatever spell you assign in the AI package, including ritual spells, so long as whatever condition/s you assign, are applicable. There are some quirks here too, rules-wise, but if you mess around with it you will see how it ticks. I suggest just testing on a spawned npc with no aliases or other packages which could interfere. Once you successfully accomplish them casting your ritual spell, you can then play with combat override capability. The guides will help you there. There are also follower frameworks that use combat override AI you can look at, and use their approach as a base
-
Combat AI is finicky and more than just combat-style, affects it. There is simply logic under the hood, that dictates whether a spell is qualified to be cast. Magicka pool for example, matters. They often need more than the cost of the spell, before they will choose to use the spell. Other quirks too. It's annoying and not exact, to get followers to perform how you like You piqued my curiosity so I tested around real quick. I did successfully make another NPC cast Blizzard, but only after assigning them a custom AI package. So unless you find another way, you might want to go with a combat-override package route, so you can be done with it and move on with your project. I still think there is a trick to get them to do it without overriding AI, but it's probably niche and overly-complicated
-
How to get your player to sit on bed edge ?
Sphered replied to aarchieee's topic in Skyrim's Creation Kit and Modders
For the positioning portion of your question: Furniture models have collision. You can move (just) the collision in nifskope, towards the edge or wherever you want it, to get the job done. Alternatively I do recall there is NiStringData (or something similarly named) in furniture nifs where you can change offsets and such, but I never dabbled much with that As for sitting, you could consider not using furniture at all and instead use activator with the model you want. Call Setvehicle() and probably call sit via an animation event. IDK... Could also use chair furniture with edited model, being ofc a bed instead, which you could sit at. I'd have to play around and see what approach I liked -
A little help with NifSkope PLEASE!
Sphered replied to jjensen6823's topic in Skyrim's Creation Kit and Modders
Short version it is nothing to worry about When nifskope has auto-sanitize enabled, and you save a nif, any same-named nodes get renamed to something similar to it's parent node then a colon then a number. The more duplicate named nodes you had, the more renamed nodes with a colon and a number, you will have. Did some get named in a logical way you should care about? Not likely, and even if it was, it could depend on the nifskope version, and any custom settings that might have been used. Don't lose sleep over it basically -
Your keyword property can remain blank since it is only applicable if you set up a linked ref along with a keyword. Personally I never use the keyword approach for linkedrefs As for the undesired npc behavior, you should try temporarily using a non-edited dragur actorbase for that ref and see if it still happens. You might have changed something like aggro radius or aggression or packages, etc interfering with the ambush routine. I ran into a similar frustration some years ago and forget how I solved it, but it was something silly if I recall
-
placeAtMe - seems unreliable?
Sphered replied to dafydd99's topic in Skyrim's Creation Kit and Modders
PlaceAtMe works just fine. Here... save you some heartache. Tweak how you like, and I offer no warranty ObjectReference NazeemSpawn = Gate().PlaceAtMe(Game.GetForm(0x13BBF)); Or use the Nao call to skip immersive visual placement When3D(NazeemSpawn) WhateverYouWanted3DLoadedFirstToDo() Etc() ;================================================================= ObjectReference Function Gate(Float Dist = 300.0,Float Elev = 0.0,Float Bias = 0.0) Global ObjectReference PCO = Game.GetForm(0x14) as ObjectReference ObjectReference Here = PCO.PlaceAtMe(Game.GetForm(0x7CD55),1,False,True); 0xC9ED4 or 0x7CD55 Here.MoveTo(PCO,Dist * Math.Sin(PCO.GetAngleZ()),Dist * Math.Cos(PCO.GetAngleZ()),Elev) Here.SetAngle(0.0,0.0,Here.GetAngleZ() + Here.GetHeadingAngle(PCO) + Bias); Change Bias to 180.0 to make it face away from you instead Here.Enable() Utility.Wait(1.0); Skip if you want... I like a second here Return Here EndFunction ;================================================================= ObjectReference Function Nao(Form What,Float Dist = 300.0,Float Elev = 0.0,Float Bias = 0.0,Bool Insistent = False,Bool Hid = False) Global ObjectReference PCO = Game.GetForm(0x14) as ObjectReference Bool QuietPlacement = Hid || What.GetType() != 43 ObjectReference Here = PCO.PlaceAtMe(What,1,Insistent,QuietPlacement) Here.MoveTo(PCO,Dist * Math.Sin(PCO.GetAngleZ()),Dist * Math.Cos(PCO.GetAngleZ()),Elev) Here.SetAngle(0.0,0.0,Here.GetAngleZ() + Here.GetHeadingAngle(PCO) + Bias); Change Bias to 180.0 to make ref face away from you instead QuietPlacement && !Hid && Here.Enable() Return Here EndFunction ;================================================================= Bool Function When3D(ObjectReference Arriving,Float Delay = 0.1,Float Timeout = 10.0) Global While Arriving as Bool && !Arriving.Is3DLoaded() && Timeout as Bool Utility.Wait(0.1) Timeout -= 0.1 EndWhile Return Utility.Wait(Delay) as String && Arriving as Bool && Arriving.Is3DLoaded() EndFunction ;================================================================= Use properties instead of GetForm calls if you want. Just showing how to do it If placing something in another cell than what player is in, you can, just yeah assume it isn't rendered until you visit. Can always place at player then move them after. Play around with solutions -
No it simply makes the ActiveMagicEffect register that event, with no knowledge of caster/target, unless you do string chaining like it looks like you are playing with, which means you will need a resolve routine on the other end, etc... And TBH your approach looks more hectic than it needs to be, but you could make it work for sure Side opinion: ActiveMagicEffect tends to be a good relayer for sending mod events, not listening. It can do both but yeah. Like if you want the target to send a mod event: GetTargetActor().SendModEvent("WhateverItsCalled") Where above is listened for from a quest or alias etc and you know who called the event. Anyway, that sucks if your npc's aren't keeping their assigned outfits. Suppose you may be doing a dynamic thing PS: The OnLoad() Event will not perform as you hope in regards to loading the game. You need OnPlayerLoadGame() for reload routines, and it has to be a script running from the player. Usually an alias script
-
Walking speed versus other speeds
Sphered replied to dizietemblesssma's topic in Skyrim's Creation Kit and Modders
Since you left it ambiguous whether you were aware of package flags manipulating walk/run behavior, it is a flag called preferred speed -
Add Boss Music Using a Script
Sphered replied to TheCrowKnight's topic in Skyrim's Creation Kit and Modders
Could add a silent track when applicable. There is one called _None that you can invoke after removing yours (Game.GetForm(0x1BA72) as MusicType).Add() Or ofc attach the _None music record as a property. Might as well Alternatively, combat music in the game uses conditions. Could definitely play with that instead/also -
How to keep track of CombatTarget?
Sphered replied to staalo18's topic in Skyrim's Creation Kit and Modders
There's a magiceffect condition you could play with. In theory you could apply that effect to a cloak ability with no damage. A script or shader or whatever else would then apply, but only as long as IsCombatTarget is true Not tested... and could well be one of those dormant conditions that do not do as they sound like they would. Basically just try it out -
Likely won't be able to "port" the mod, but rather reproduce it as feasible If I was tackling this project today, first approach I would go with, is AI ObserveDead routine where the NPC using this routine, will approach lootable bodies and perhaps perform a search animation like they will when saying "What happened?" etc. Let scripts handle the actual looting, and also have the script apply some sort of tag to prevent NPCs from trying to repeat loot, etc I was curious so played with above for a little bit. ObserveDead override pack apparently is a dud or has quirks and too many hoops to jump through to be a viable approach. Aside, I found a mod you can use as a template for the concept you want. Haven't tried it myself but it can at least get you started, if not completely do what you are wanting https://www.nexusmods.com/skyrimspecialedition/mods/4744
-
How to make an NPC with a player's head?
Sphered replied to TheXXI's topic in Skyrim's Creation Kit and Modders
This is a lengthy to explain process which some searching will yield good results for Aside, I have a mod for LE called Blueprints which spawns a NPC with your appearance. You can use the facegen it generates for a CK follower. I made it a long time ago and offer no support for it -
[Skyrim SE] Camera viewpoint for a scene
Sphered replied to Tiziano74's topic in Skyrim's Creation Kit and Modders
Can be done by basically using a cameraman approach. Place someone wherever you want, angle them, etc, then use Game.SetCameraTarget(Whoever) Has to be an actor. Will not work on objects without using a SKSE-based mod Helpful: The actor does NOT have to be enabled to set camera onto them. Lets you set their elevation and other handy things that would be trickier to deal with if they have loaded 3D -
Attaching script to npc using reference alias
Sphered replied to Hector0818's topic in Skyrim's Creation Kit and Modders
You likely have to check the "Allow Dead" box for this to work Otherwise ReferenceAlias automatically releases NPCs from being aliased when they die, and I never tested if OnDeath script triggers happen before that Aside, there is OnDying() which you can mess with too. Just a reminder that exists too Unrelated but yeah: I would avoid naming a script the same as an event name. Maybe that's my coder-OCD triggering but I avoid syntax overlaps like that -
Can't shout if it doesn't HAVE any shouts. To make this problem go away you can have a routine in place to simply remove all their shouts for x time, then re-add them. I'd probably find another way if it was me, but that would def solve your issue for the time being. Can always tweak approaches later once you get something working at all, as you are wanting
-
How to make a Rotating Platform
Sphered replied to Skybroom's topic in Skyrim's Creation Kit and Modders
This is one of those things if you mess around with it enough you will start to figure out how things tick, and likely also learn some new things you didn't expect to find useful Def explore nif files and play with copy/pasting collisions and NIControllers to other nif models, and make new nifs too. CtrlC and CtrlV in skope is def your friend I'd have to give myself a refresher session with the creation side of things, to be more helpful. But do consider what I suggested. It's pretty enjoyable imo just experimenting with this stuff -
This type of project is incredibly more time-intensive than it may sound like it would be Amongst many other lengthy steps, you need copies of all the smoke and fire fx nifs you want to green-ify, since you are not wanting to replace regular fire. Several of these fire and smoke nifs, have a number assigned called BSValueNodes. These values have to be changed, to match whatever you assigned your green addonnodes in the CK to. Green gradient and decal textures will need also be needed in this project If any of above makes little to no sense to you... You would be highly advised to simply download a mod that already does most (or all) or what you want, and use that as a base for what you want
-
Keeping a corpse from despawning?
Sphered replied to gravityzcatz's topic in Skyrim's Creation Kit and Modders
If you spawned it at runtime, yeah I'd see that going away after a while. I believe you are okay. The body should*TM be there permanently since placed in the CK. As for loot, I believe when the cell resets, so do all refs -
You would have to dive into the controller manager in each nif you want to modify, and it isn't simple Each sequence has interpolators and various data like transformdata, floatdata, and others. You MIGHT be able to get away with changing the speed of the controller at the top level and call it a day, but probably not tbh. Been too long since I messed with that stuff, I just remember it's finicky and tedious Very niche area of modding you are asking about. Sorry to inform, your goal is not an easy one