pepperman35 Posted September 3, 2019 Share Posted September 3, 2019 Greetings Fellow Creation Kit Warriors, Background: I am using the CK to build a settlement mod at Nuka World based on my Nuka-World Red Rocket - Settlement Blueprint. Learning CK as I go. Concept of Operations: My vision for this settlement goes something along these lines: After player completes requisite story lines, he/she claims/activates the Nuka-World Red Rocket workshop. Player then turns on power via a terminal [conditional]. Workshop must be claimed before power can be activated. Player turns on recruitment beacon via terminal [conditional]. Power must be turned on before the recruitment beacon can be activated. Player turns on water purifiers via a terminal [conditional]. Power must be turned on before the water purifiers can be activated. Player turns on automated defense systems at each of the four watchtowers via a terminal [conditional]. Power must be turned on before the automated defense systems can be activated.Notes: Items 3-5 can be activated in any order provided the requisite condition has been met (i.e., power has been activated). Questions: What would the Papyrus script look like to check the operation state of the power generator? I’ll be using the Vault-Tec super-reactor. What would the Papyrus script look like to remotely activate the Vault-Tec super-reactor via a terminal? As the rest of the objects are two state devices this should arm me with info to replicate the process. What would the Papyrus script look like to test whether or not the Nuka-World Red Rocket workshop has been claimed by the player?Thanks for reading and offering advice/help. Link to comment Share on other sites More sharing options...
SKKmods Posted September 3, 2019 Share Posted September 3, 2019 Take a look at one of the base game quests and scripts that need stuff built and powered. WorkshopParentScript CustomEvent WorkshopObjectBuilt WorkshopParentScript CustomEvent WorkshopObjectPowerStageChanged would be the triggers to subscribe to. Mercer Safehouse RRR04 is one, there are some Min radiants as well. Link to comment Share on other sites More sharing options...
pepperman35 Posted September 4, 2019 Author Share Posted September 4, 2019 Take a look at one of the base game quests and scripts that need stuff built and powered. WorkshopParentScript CustomEvent WorkshopObjectBuilt WorkshopParentScript CustomEvent WorkshopObjectPowerStageChanged would be the triggers to subscribe to. Mercer Safehouse RRR04 is one, there are some Min radiants as well. Thanks for the prompt response. I'll look closely at those and see what I can figure out. Link to comment Share on other sites More sharing options...
pepperman35 Posted September 4, 2019 Author Share Posted September 4, 2019 Okay, here is what I tried. A setup a link from the wall terminal to the Vault-Tec Super Reactor with the keyword LinkTerminalTripwire. Used this code fragment to try and turn on the reactor ObjectReference[] linkedRefArray = akTerminalRef.getLinkedRefArray(LinkTerminalTripwire) int i = 0while i < linkedRefArray.length ObjectReference theSwitch = linkedRefArray debug.trace(self + " " + i + ": " + theSwitch + " TURNING ON") if theSwitch theSwitch.SetOpen(false) endifi += 1endWhile The reactor is the only switch in the chain. Compiler output...Papyrus Compiler Version 2.8.0.4 for Fallout 4Copyright © ZeniMax Media. All rights reserved.Starting 1 compile threads for 1 files...Compiling "Fragments:Terminals:TERM_nativeWorkshopSwitchTer_1325EE8D"...C:\Users\Omega1\AppData\Local\Temp\PapyrusTemp\Fragments\Terminals\TERM_nativeWorkshopSwitchTer_1325EE8D.psc(7,67): variable LinkTerminalTripwire is undefinedNo output generated for Fragments:Terminals:TERM_nativeWorkshopSwitchTer_1325EE8D, compilation failed. Batch compile of 1 files finished. 0 succeeded, 1 failed.Failed on Fragments:Terminals:TERM_nativeWorkshopSwitchTer_1325EE8D I had taken this code fragment from the nativeWorkshopSwitchTerminalSubMenu so logically it should have worked. Obviously it is operator error, but what am I doing wrong? Link to comment Share on other sites More sharing options...
SKKmods Posted September 5, 2019 Share Posted September 5, 2019 >"variable LinkTerminalTripwire is undefined" You have not told the script what LinkTerminalTripwire actually is (a keyword object in the database). On the script fragment display drop down the [Properties] button, [Create Using Form] paste in LinkTerminalTripwire and it will associate. Link to comment Share on other sites More sharing options...
pepperman35 Posted September 6, 2019 Author Share Posted September 6, 2019 Thank you sir, that did the trick and I now have my first working script. Link to comment Share on other sites More sharing options...
Recommended Posts