dUNCEnOIR Posted March 14, 2019 Posted March 14, 2019 Hello! Im making a mod, (or at least trying to) And I would like the mod to turn the player into a Wraith (using Ethereal FX) when crouched. I know I need to write a script for this, But I have no idea what I'm doing. Here's what I have so far Event OnInit() If Game.Getplayer().IsSneaking() WraithBind.Cast(Game.GetPlayer()) endIf EndEvent "Wraith Bind" Is the name of the spell I created with the effects. yet, The magic effect itself still needs the code so this only happens while sneaking. I have it so when I equip the ring It turns me Ethereal ALLL the time. Not only when I'm sneaking. Thanks so much for any help. And keep in note, I'm a beginner. Thanks again!!! (Yes I did post the same thing on reddit, I nEeD sOmE hElP)
foamyesque Posted March 14, 2019 Posted March 14, 2019 You may not need any scripting at all for this, in fact! So, spells and enchantments work by having a list of magic effects added to them, I assume you're familiar with this, since you say you've created a spell with those effects. You can add conditions to what effects happens in that screen. If they're added *on the spell* editing screen they will be polled for by the game engine without the need for further scripts. IsSneaking is a valid condition function (full list here: https://www.creationkit.com/index.php?title=Condition_Functions). If this is an enchantment on the ring, boom, you're done.
NexusComa Posted March 16, 2019 Posted March 16, 2019 There is a mod that lets you turn into many things. Sorry I forgot the name. Long ago I used it as a template and was able to turn into most anything in Skyrim.it may have been this one ... https://www.nexusmods.com/skyrim/mods/8784/?Anyways it's a good place to start.
lofgren Posted March 16, 2019 Posted March 16, 2019 There is also the perk entry point Apply Sneaking Spell used by the armor of Boethia. https://www.creationkit.com/index.php?title=Perk_Entry_Point
ANaj Posted March 19, 2019 Posted March 19, 2019 onInit() is bad choice for a script, which should check if the player is sneaking. https://www.creationkit.com/index.php?title=Category:Events here you will find a list of all possible events and where they are running. If you want to learn more about programming in Papyrus, bookmark this site, it is very helpful. If i understood you right, you want to cast a spell and if player is sneaking do the effect.Event OnEffectStart(Actor akTarget, Actor akCaster) If Game.Getplayer().IsSneaking() ;your turning into wraith code here endif endEventYou have to bind the script onto the magic effect the spell is using.
Recommended Posts