dharvinia Posted December 24, 2017 Posted December 24, 2017 Hello I have been doing some building in FO4 vault 88. I do not have a menu board for Vault-tec items, so I have been using the spawn command in console. This means that all I have to do is find the associated ID number for the item then spawn it. This method although somewhat tedious, works very well...when you can find the number for the item you want to spawn. I need a number for the Vault-Tec sliding door/w controller that will respond to the "select and place" command originating from the workstation in game. I did find a number, but once spawned, I cannot access the part in build mode so that I can install it. ANY help or suggestions would be appreciated. Thanks in advance.
cold steel Posted February 2, 2018 Posted February 2, 2018 Hello everyone, I am trying to write a sctipt to change my custom CBBE slider from 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) EndIf EndEvent 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") EndIf EndFunction Unfortunatelly I am getting this errors: "SSBBW.psc(18,14): variable BodyGen is undefined SSBBW.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?
Halstrom Posted February 10, 2018 Posted February 10, 2018 Hey I'm trying to script something to add keywords to added armors and getting an error when I try this: Scriptname CCL:Kerrigan extends Quest KeyWord Property kw01 Auto Const Event OnInit() Int iArmorLevel = 1 Armor arArmor Int iForm iForm = 0x00000800 ; Kerrigan Skinsuit arArmor = Game.GetFormFromFile(iForm, "Kerrigan.esp") as Armor arArmor.AddKeyword(kw01) EndEvent The error is : "C:\Users\Owner\AppData\Local\Temp\PapyrusTemp\CCL\Kerrigan.psc(35,9): AddKeyword is not a function or does not exist" Any idea what I'm doing wrong and how to do it? I cant seem to find any F4SE Functions to AddKeywords to armor, though I cant seem to find the proper list anymore either. Also is there an Equivalent to IsModLoaded so I could lock out the script if the Mod was not in Load Order?
AWP3RATOR Posted February 10, 2018 Posted February 10, 2018 3 hours ago, Halstrom said: Also is there an Equivalent to IsModLoaded so I could lock out the script if the Mod was not in Load Order? This is from Vinfamy's Violate script, dealing with if Devious Devices is loaded or not: Function LoadDD() If Game.IsPluginInstalled("Devious Devices.esm") Quest DDQuest = Game.GetFormFromFile(0x09004C50, "Devious Devices.esm") as Quest DDlibs = DDQuest.CastAs("DD:DD_Library") DD_FL_All = Game.getFormFromFile(0x0905E95B, "Devious Devices.esm") as FormList DD_MaleModelItems = Game.getFormFromFile(0x09044EBB, "Devious Devices.esm") as FormList debug.notification("Vinfamy: Violate integrated with Devious Devices.") utility.Wait(0.1) DDLoaded = 2 Endif EndFunction You are looking for the 'If Game.IsPluginInstalled()' function there?
Halstrom Posted February 10, 2018 Posted February 10, 2018 6 hours ago, AWP3RATOR said: This is from Vinfamy's Violate script, dealing with if Devious Devices is loaded or not: Function LoadDD() If Game.IsPluginInstalled("Devious Devices.esm") Quest DDQuest = Game.GetFormFromFile(0x09004C50, "Devious Devices.esm") as Quest DDlibs = DDQuest.CastAs("DD:DD_Library") DD_FL_All = Game.getFormFromFile(0x0905E95B, "Devious Devices.esm") as FormList DD_MaleModelItems = Game.getFormFromFile(0x09044EBB, "Devious Devices.esm") as FormList debug.notification("Vinfamy: Violate integrated with Devious Devices.") utility.Wait(0.1) DDLoaded = 2 Endif EndFunction You are looking for the 'If Game.IsPluginInstalled()' function there? Yeah that solves my second question I'm still stuck on the first problem though adding keywords to armor by script, I really don't want to add a script to all the armors to do it, there must be an easier way.
AWP3RATOR Posted February 10, 2018 Posted February 10, 2018 I found this from the CK's wiki site - though not sure if it's for Skyrim or not, nor if it will apply in your situation. Function SetKeywordData(Keyword akKeyword, float afData) native Edit: This may be setting a value for the keyword and not the keyword itself, now that I read it...
AWP3RATOR Posted February 10, 2018 Posted February 10, 2018 However, this appears to be what you were looking for: https://www.creationkit.com/fallout4/index.php?title=AddKeyword_-_ObjectReference
Halstrom Posted February 11, 2018 Posted February 11, 2018 21 hours ago, AWP3RATOR said: However, this appears to be what you were looking for: https://www.creationkit.com/fallout4/index.php?title=AddKeyword_-_ObjectReference Which is what I'm trying to do with this line: arArmor.AddKeyword(kw01) But it seems it only works in a native script
Evan555alpha Posted February 12, 2018 Posted February 12, 2018 Right, so I've got an NPC, and I want it so that they're human, but they attack enemies of the player the same way that feral ghouls attack, generally lunging towards the enemy. I also want it so that they're spawned in much like how synths are spawned in via the Synth Relay Grenade. Now, I've got the whole spawning them in part down. That works. What doesn't work is that they won't attack enemies. They'll go in to the fighting stance, and even run up to the enemy, but they won't actually do anything beyond that. The way they're set up, is that their overall race is the DefaultHumanRace, and their Attack Race is FeralGhoulRace. Their Combat style is csFeralGhoul, and their class is FeralGhoulClass. The template data is set up so that the NPC gets their AI Packages from POIWastelanderFemale01, and they get their Attack data from encFeralGhoul01Template. The Combat Override Package is set to DefaultCombatMasterPackageList. They're set to be part of the PlayerAllyFaction, with a rank of one. i'm stumped as to why they're not attacking properly. Any ideas? Am I doing something wrong? I've been at this for several hours, and I'm at my wit's end.
Halstrom Posted February 12, 2018 Posted February 12, 2018 16 hours ago, Evan555alpha said: Have you checked AI Data Aggression and Confidence settings?
Evan555alpha Posted February 13, 2018 Posted February 13, 2018 1 hour ago, Halstrom said: Have you checked AI Data Aggression and Confidence settings? Aggression is set to Aggressive, and Confidence is set to Brave. Their Mood is Neutral, and they're set to help both friends and allies.
Halstrom Posted February 13, 2018 Posted February 13, 2018 10 hours ago, Evan555alpha said: Aggression is set to Aggressive, and Confidence is set to Brave. Their Mood is Neutral, and they're set to help both friends and allies. They don't still have their old faction or the creature faction by chance?
Evan555alpha Posted February 13, 2018 Posted February 13, 2018 2 hours ago, Halstrom said: They don't still have their old faction or the creature faction by chance? Nope. The only faction that they're a part of is the PlayerAllyFaction. I've tried setting their rank from 1 to 0, and there was no difference.
SlapMeSilly Posted February 15, 2018 Posted February 15, 2018 On 2/10/2018 at 4:40 AM, Halstrom said: Hey I'm trying to script something to add keywords to added armors and getting an error when I try this: Scriptname CCL:Kerrigan extends Quest KeyWord Property kw01 Auto Const Event OnInit() Int iArmorLevel = 1 Armor arArmor Int iForm iForm = 0x00000800 ; Kerrigan Skinsuit arArmor = Game.GetFormFromFile(iForm, "Kerrigan.esp") as Armor arArmor.AddKeyword(kw01) EndEvent On 2/10/2018 at 6:56 PM, Halstrom said: Which is what I'm trying to do with this line: arArmor.AddKeyword(kw01) But it seems it only works in a native script AddKeyword only works on an specific object reference. Not the base object type. There is no function to add a keyword to the entire class of that object in one shot. That must be done in the plugin as a record override creating a master dependency which it looks like you're trying to avoid. So, adding it piecemeal after it's been created as a reference is your only option.
Evan555alpha Posted February 16, 2018 Posted February 16, 2018 Any other suggestions for this NPC not attacking anything? As I said before, they'll walk right up to the enemy, but they just will not attack. I'm at my wit's end trying to find a solution to all this. I just want them to dive at enemies, the same way that ghouls do. Spoilered is screenshots of what I think is all relevant NPC pages in the CK. Spoiler
Halstrom Posted February 16, 2018 Posted February 16, 2018 4 hours ago, SlapMeSilly said: AddKeyword only works on an specific object reference. Not the base object type. There is no function to add a keyword to the entire class of that object in one shot. That must be done in the plugin as a record override creating a master dependency which it looks like you're trying to avoid. So, adding it piecemeal after it's been created as a reference is your only option. Hmm yeah, seems like that, another messy option I'm looking at is to add the keywords via an Enchantment which it seems F4SE has SetEnchantment and it seems to accept it, not sure if it works yet.
cold steel Posted February 16, 2018 Posted February 16, 2018 Hello everyone, I hope someone here can help me with my modification. I am trying to find a way of how to replace walking, running and sprinting step effect Sounds after my playable character getting Perk. Can someone tell me please how can I do this?Simply put:Character get Perk - new footstep sounds.Character don't get Perk - default footstep sounds.
Evan555alpha Posted February 18, 2018 Posted February 18, 2018 Another question, this time script related. I've extracted the "base.zip" in "Data\Scripts\Source\Base" folder, however line 35 of my script is throwing an error. Spoiler ScriptName LoveConsumedEggGiver extends ActiveMagicEffect ;List of perks here Perk property ChangelingPerk Auto Perk property LoveConsumed01 Auto Perk property LoveConsumed02 Auto Perk property LoveConsumed03 Auto Perk property LoveConsumed04 Auto Perk property LoveConsumed05 Auto Perk property LoveConsumed06 Auto Perk property LoveConsumed07 Auto Perk property LoveConsumed08 Auto Perk property LoveConsumed09 Auto Perk property LoveConsumed10 Auto ;Items and shit defined int WhichEgg Weapon property DroneSpawnGrenade Auto Weapon property EliteSpawnGrenade Auto Bool property isSilent Auto ;Where the magic happens Event OnEffectStart(Actor Player, Actor akCaster) If Player.hasPerk(LoveConsumed10) == 1 Player.removePerk(LoveConsumed10) Player.removePerk(LoveConsumed09) Player.removePerk(LoveConsumed08) Player.removePerk(LoveConsumed07) Player.removePerk(LoveConsumed06) Player.removePerk(LoveConsumed05) Player.removePerk(LoveConsumed04) Player.removePerk(LoveConsumed03) Player.removePerk(LoveConsumed02) Player.removePerk(LoveConsumed01) WhichEgg.SetValue(Utility.RandomInt(1, 100)) If WhichEgg > 80 Player.addItem(EliteSpawnGrenade, 1, isSilent) Else Player.addItem(DroneSpawnGrenade, 1, isSilent) EndIf ;Perk checks to make this thing work properly ElseIf Player.hasPerk(LoveConsumed09) == 1 Player.addPerk(LoveConsumed10) ElseIf Player.hasPerk(LoveConsumed08) == 1 Player.addPerk(LoveConsumed09) ElseIf Player.hasPerk(LoveConsumed07) == 1 Player.addPerk(LoveConsumed08) ElseIf Player.hasPerk(LoveConsumed06) == 1 Player.addPerk(LoveConsumed07) ElseIf Player.hasPerk(LoveConsumed05) == 1 Player.addPerk(LoveConsumed06) ElseIf Player.hasPerk(LoveConsumed04) == 1 Player.addPerk(LoveConsumed05) ElseIf Player.hasPerk(LoveConsumed03) == 1 Player.addPerk(LoveConsumed04) ElseIf Player.hasPerk(LoveConsumed02) == 1 Player.addPerk(LoveConsumed03) ElseIf Player.hasPerk(LoveConsumed01) == 1 Player.addPerk(LoveConsumed02) ElseIf Player.hasPerk(ChangelingPerk) == 1 Player.addPerk(LoveConsumed01) EndIf EndEvent More specifically: WhichEgg.SetValue(Utility.RandomInt(1, 100)) Attempting to compile in the CK spews out this single error: int is not a known user-defined script type Everything that I've looked up tells me that I need to have extracted the base source scripts, which I've done already. Any ideas on what could be causing this? Papyrus' syntax is new to me, and I'm not sure how to fix it. EDIT: I found the fix for it. Changing the snippet from what it was, to: WhichEgg = Utility.RandomInt(1, 100) leads to a successful compilation.
Halstrom Posted February 19, 2018 Posted February 19, 2018 Any idea how to set the value of a global variable or float property from a script? It keeps telling me they are read only.
Halstrom Posted February 21, 2018 Posted February 21, 2018 I can't count how many times this Beth Creation Kit naming SNAFU has confused me Spell Property spShockEffect Auto Enchantment Property enchShockEffect Auto if (rActor.HasSpell(enchShockEffect)) Is it a frigging Spell or Enchantment, don't call it one in one place in GECK then call it the other elsewhere And there is no HasEnchantment function either
Halstrom Posted February 21, 2018 Posted February 21, 2018 Next question Is there an equivalent to IsMoving, I want to detect is the player is moving. I have IsRunning and IsSprinting, but there' seems to be no IsWalking.
Tentacus Posted February 21, 2018 Posted February 21, 2018 I'm in a real bind with a mod I've been working on for ages. What I need to know is: Is there any way to reliably override Vanilla settler dialogue (IE: "Want to trade a few things?") with my quest dialog? I haven't had any trouble with most NPCs but 90% of the time Settlers in active settlements will just ignore my quest's dialogue and open their inventory like normal. I've tried messing with Quest priority (even setting my quest's priority up to 100!) Is there a trick to this or am I just boned? UPDATE: After not working on my mod for weeks in frustration at this problem, I figured it out on my own. In case anybody else has this problem: The fix was a combination of setting all my greets to have the "forcegreet hello" flag and set the topic priority high (I just went with 90 because screw it) UPDATE: Or my succesful test was just a complete fucking fluke cause it's back to not working today. I am about 10 seconds from throwing away months of work because I am so done with this undocumented pile of crap. UPDATE: I think I am onto a solution but I probably won't test it for a few days because I am spent and Farcry 5 comes out Tuesday. I think the key to bypassing the Trade and merchant menues entirely is the solution I posted before... BUT Using NON randomized responses. Therefore it will ONLY pick my one reply for the given conditions and not cycle in the vanilla dialogue (I hope) If I solve this crap I hope it helps somebody else. It's times like these I really miss Skyrim's straightforward dialogue system. UPDATE: (Hopefully final) After a very small ammount of very basic testing I do think the last fix did in fact take.
Evan555alpha Posted February 25, 2018 Posted February 25, 2018 Am I missing something extremely basic here? Scriptname Evan555alpha:LLAdder Extends Quest ;properties n shit Container Property SCGSVendorChest Auto LeveledItem Property ChrysArmourSet Auto Event OnInit() If SCGSVendorChest.GetItemCount(ChrysArmourSet) < 1 SCGSVendorChest.AddItem(ChrysArmourSet, 1) Debug.Trace("Mod Initialised, adding items!") Else Debug.Trace("Vendor Has the book. Stopping!") EndIf EndEvent Even though this script extends Quest, I'm being hit with LLAdder.psc(8,20): GetItemCount is not a function or does not exist LLAdder.psc(8,49): cannot compare a void to a int (cast missing or types unrelated) LLAdder.psc(9,18): AddItem is not a function or does not exist My other scripts, although they extend ActiveMagicEffect, also use AddItem, and they compile just fine. What the hell? EDIT:: Solution: Change "Container" to "ObjectReference", and refill the property value makes it compile. Edit 2, electric boogaloo: Okay, so, my Levelled List "item" is added to the vendor chest successfully, as the items in said list show up when I use the "inv" command on the vendor chest in game. A new issue, though, is that these newly added items do not show up in the barter menu at all, even if I exit the cell, sleep for 72 hours, and come back. Any ideas why that might be happening?
Appledragon31 Posted March 2, 2018 Posted March 2, 2018 Hi there! I have an issue. Animations dont playing after my character surrend to NPC with FP-Violate mod. I have installed Leito and Crazy animations for FO4. What's the problem?
Halstrom Posted March 5, 2018 Posted March 5, 2018 I'm trying to check if stuff is enabled before setting it and the short version of my script is this: Scriptname Synth:PhysicalIntegrity extends Actor InputEnableLayer ielInputLayer Bool Function IsActivateEnabled() EventInit() ielInputLayer = InputEnableLayer.Create() EndEvent EventTimer() Bool bTemp = ielInputLayer.IsActivateEnabled(rActor) if (fSystemActivate >= 75) && (!bTemp) ielInputLayer.EnableActivate(true) endif EndEvent Due to obvious Papyrus noobness its failing to compile of course since I added the check, seems ok with the setting part though. Can't find much in Google or the Wiki on it as its a F4SE command.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now