coldsteelf Posted February 2, 2018 Share Posted February 2, 2018 Hello everyone, I am trying to write a script to change my custom CBBE slider for Looks Menu when character eat any food, but I have a problem:Scriptname SSBBW extends Quest MagicEffect Property MagicEffectFood Auto Const Keyword property LoL auto Event OnMagicEffectApply(ObjectReference akTarget, ObjectReference akCaster, MagicEffect akEffect) Actor Player = Game.GetPlayer() Self.RegisterForMagicEffectApplyEvent(Player as ScriptObject, None, None, True) If (akEffect == MagicEffectFood) Self.SsbbwSetBody(0 as float, 0.5) EndIfEndEvent float Function SsbbwSetBody(float akOperation, float akBelly) Actor Player = Game.GetPlayer() If (akOperation == 0 as float) BodyGen.SetMorph(Player, true, "Giant belly (coldsteelj)", LoL, akBelly) Else Debug.Notification("SSBBW Error: Function input doesn't equal 1") EndIfEndFunction Unfortunatelly I am getting this errors:"SSBBW.psc(18,14): variable BodyGen is undefinedSSBBW.psc(18,22): none is not a known user-defined script type"Can someone help me to understand how to fix it? I understand that BodyGen is undefined in my script since it is a part of "Looks Menu" scripts, but how do I link my script so that it uses the functions of "Looks Menu" mod scripts? Link to comment Share on other sites More sharing options...
coldsteelf Posted February 3, 2018 Author Share Posted February 3, 2018 (edited) Nevermind, I asked vinfamy from loverslab for help and he explained that I need to have BodyGen.psc file in Fallout 4\Data\Scripts\Source folder to let compiler know where is BodyGen variable come out from. Big thanks to Vinfamy. Edited February 3, 2018 by coldsteelf Link to comment Share on other sites More sharing options...
Carreau Posted February 4, 2018 Share Posted February 4, 2018 You will also need to run updatemorph(actor) to see changes created with setmorph. Link to comment Share on other sites More sharing options...
Recommended Posts