SandMouseAnarchy Posted April 29, 2019 Share Posted April 29, 2019 Hi guys, im pretty stuck here... My power armor mod has a strange problem, when i take armor from the power armor container some of the armor stays visible on the frame even though the armor is now in my invintory and not on the frame. its also happening when previewing armor mods in the power armor workbench, im not sure why. To get around this issue i can disable the power armor furniture, move to player, move back to original location and the enable()((this gets rid of any extra pieces of armor that stay on the frame even though theyre not in the power armor container anymore))But now, after disabling, moving and enabling the frame again, if i add a piece of power armor to the frame by script the piece of armor stays invisible until i manually add or remove something from the container in game or until i enter the armor or until i enter the power armor workbench. Can anyone help me understand why the armor wont show on a power armor frame after it has been disabled and then enabled again? Or does anyone have an idea how i can force the frame to update when its container is changed so that there are no strange ghost armor pieces left on the frame after they are all removed? Link to comment Share on other sites More sharing options...
SKKmods Posted April 29, 2019 Share Posted April 29, 2019 (edited) What your seeing is PROBABLY because the power armor frame you are working on stops being a power armor frame and becomes the the power armor workbench. Have a look at PowerArmorWorkbench.psc 99 nearestPowerArmor.AddKeyword( workbenchKeyword ) 101 nearestPowerArmor.RemoveKeyword( powerArmorFurnitureKW ) 108 nearestPowerArmor.SetLinkedRef( Self, LinkedWorkbenchContainerKeyword ) MU-Ahahahaa & etc edit: add the word PROBABLY Edited April 29, 2019 by SKK50 Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted April 29, 2019 Author Share Posted April 29, 2019 Oh, thats so strange... 0.0So a power armor frame becomes a workbench when the player enters the actual power armor workbench menu? Then maybe by adding the workbench keyword and removing the powerarmorfurniture keyword will force the frame to update and show the actual currently equipped armor? great idea, SKK50 you are a legend! im going to try that staight away! :) Link to comment Share on other sites More sharing options...
SKKmods Posted April 29, 2019 Share Posted April 29, 2019 Yes that had me stumped for about 9 months trying to connect Power armor workbenches to in my Quantum global Storage mod, with random inventory bits appearing and disappearing until I actually looked at that script. Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted April 29, 2019 Author Share Posted April 29, 2019 (edited) ah that sounds like the same kind of problem im having ^.^ but unfortunately i have tried messing with those keywords and it doesnt seem to solve the problem for me. Can i ask how you used those keywords exactly to stop the random armor parts staying? This is the method im trying at the moment.i have this bit of script in a magic effect -> If NearestPowerArmor.HasKeyword(MFrameKW) Int iButton = OptionsMESG_Armor.Show() ; Show menu If iButton == 0 Game.GetPlayer().AddKeyword(Isfitting) NearestPowerArmor.RemoveItem(M_PA_FormList, 7, true, akOtherContainer = Game.GetPlayer()) NearestPowerArmor.RemoveItem(Vanilla_PA_FormList, 7, true, akOtherContainer = Game.GetPlayer()) Game.GetPlayer().RemovePerk(fit_Armor_WorkbenchKW) ;______________________________________________________________________ ; This is where my quest script adds armor pieces to the frame ;______________________________________________________________________ ; this bit definately gets rid of random pieces showing, but after this section runs the armor added by my quest script is invisible NearestPowerArmor.DisableNoWait() NearestPowerArmor.Moveto(akCaster) NearestPowerArmor.Moveto(NearestWorkbench) NearestPowerArmor.Enable() Debug.MessageBox("test Complete") ;_______________________________________________________________________ ;i put this section in to test to see if those keywords will make the power armor pieces visible again. Utility.Wait(5) nearestPowerArmor.AddKeyword( workbenchKeyword ) nearestPowerArmor.RemoveKeyword( powerArmorFurnitureKW ) Utility.Wait(3) debug.notification("removing keywords...") nearestPowerArmor.AddKeyword( powerArmorFurnitureKW ) nearestPowerArmor.RemoveKeyword( workbenchKeyword ) ;_______________________________________________________________________ ElseIf iButton == 1 ; Cancel Debug.Notification("fit cancelled") Else Debug.Notification("fit cancelled") EndIf EndIf i then have another script in a quest that looks for power armor being added to the player invintory from the above script - and then it re adds a corisponding piece of power armor back onto the frame. Unfortunately my armor is still invisible whether or not i have the workbench keyword or powerarmorfurniture keyword on the frame at the time it gets added :/ Edited April 29, 2019 by SandMouseAnarchy Link to comment Share on other sites More sharing options...
SKKmods Posted April 29, 2019 Share Posted April 29, 2019 In my case I did not mess with the keywords directly, what I needed was the actual PowerArmor workbench to connect shared storage: Event Actor.OnPlayerUseWorkBench(Actor akSender, ObjectReference akWorkBench) Bool bIsPowerArmor = False If (akWorkBench is PowerArmorBatteryInsertScript) ;Its a power armor frame in a PA workbench bIsPowerArmor = TRUE ObjectReference ThisREF = akWorkBench.GetLinkedREF(pLinkedWorkbenchContainerKeyword) akWorkBench = ThisREF ; I never substitute the same variable on one line EndIf Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted April 29, 2019 Author Share Posted April 29, 2019 ah i see, thanks for the insight SKK50 but i cant find a way to solve my problem using those keywords :(ill have to look for another solution Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted April 30, 2019 Author Share Posted April 30, 2019 (edited) Just a note for anyone following these bread crumbs in the future... So after some experimenting iv found that the frame has to be enabled after the armor has been added by the other script and that the enable command should be "EnableNoWait()". Something like this... NearestPowerArmor.DisableNoWait() NearestPowerArmor.Moveto(akCaster) NearestPowerArmor.Moveto(NearestWorkbench) :____________________________________________ ;Other script adds armor to frame here ;____________________________________________ Utility.Wait(0.5) NearestPowerArmor.EnableNoWait() Im now going to try this method with OnTutorialEvent("Modding Success") and OnItemRemoved Events to ensure that the ghost armor parts wont show after the armor has been removed from the frame or modified at the workbench. Thanks again for the help SKK50! its a shame i couldnt get your solution to work this time though ^.^ Edited April 30, 2019 by SandMouseAnarchy Link to comment Share on other sites More sharing options...
SKKmods Posted April 30, 2019 Share Posted April 30, 2019 Thanks again for the help SKK50! its a shame i couldnt get your solution to work this time though ^.^ Looks like we enjoyed similar symptoms but different root causes. Link to comment Share on other sites More sharing options...
Recommended Posts