Jump to content

[FO4 CK] General Help Thread


Recommended Posts

well the doors also work for keycard access too, only Synths, some females and the player wear collars.

Add a script to the keycard as well, maybe? Perhaps with checks so it doesn't conflict with the collars. 

 

I don't know, I generally try to avoid editing door scripts in my code since they'd need to be run every few cycles scanning for valid actors if they're automatic.  An event would only trigger when needed if coded right.  I don't know what the restrictions are so I'm only kinda guessing based on what I do in FONV. 

Link to comment

Well actually the script isn't in the door, its in an activator placed around each door so it triggers as the door is approached.

Ah, that makes more sense.  I was so confused there since the only way I could think of having a door script that functions like that is by using a GameMode script that scans through a list of actors with a specific token or whatever but that'd be so cycle intensive. 

 

I should stop spamming this thread. :|

Link to comment

Ok next crazy question, anyone found that twhen pickpocketing an NPC, mainly clothing and ammo is all I can get, I've tried adding keycards as Misc and Armor to Allie Filmore in the GECK and they just aren't there in game. I tried reloading the cell with no difference

Link to comment
  • 2 weeks later...

I have a collar, a single asset with 8 templates for color variations, if I want to add the green version to an actor is there a way to specify the template used in a script?

I tried putting it in a LeveledItemList with the green keyword and equipping the LeveledItem but that failed.

Link to comment

Trying to make a custom armor work with child settlers mod.

I used the CK on a vanilla armor to set "ArmorAddon" to allow humanchild, it worked with the vanilla armor.

The custom armor doesn't allow being worn by the child settlers, i.e., give to child via trade menu, no option to press 'T' to make them equip it.

To be clear, the vanilla armor did allow being equipped on the child settler with "T" after the modification.

 

If I use the console to equipitem on them, a messed up skin texture appears. What is the problem?

 

Referring to this dialog: http://www.creationkit.com/fallout4/index.php?title=ArmorAddon

Link to comment

Is akActor being set properly? I'm still wrapping my head around papyrus but something looks wrong there to me for some reason. 

 

This is probably a dumb question to be honest but why don't you use Game.GetPlayer as your check instead of initialising via a property? I would've done something along the lines of

bool bIsPlayer = (Game.GetPlayer() == akActor) ? true : false  

in C-style ternary logic. 

 

This has a few problems:

1) There is no question conditional in Papyrus.

2) The property is way faster than Game.getPlayer

3) A comparison gives you a boolean as result, so the whole question conditional will be useless

Trying to make a custom armor work with child settlers mod.

I used the CK on a vanilla armor to set "ArmorAddon" to allow humanchild, it worked with the vanilla armor.

The custom armor doesn't allow being worn by the child settlers, i.e., give to child via trade menu, no option to press 'T' to make them equip it.

To be clear, the vanilla armor did allow being equipped on the child settler with "T" after the modification.

 

If I use the console to equipitem on them, a messed up skin texture appears. What is the problem?

 

Referring to this dialog: http://www.creationkit.com/fallout4/index.php?title=ArmorAddon

 

Be aware that all children are a custom race(s)

So an armor that is OK for "humans" or any other race, will not work with them.

Link to comment

 

 

 

Is akActor being set properly? I'm still wrapping my head around papyrus but something looks wrong there to me for some reason. 

 

This is probably a dumb question to be honest but why don't you use Game.GetPlayer as your check instead of initialising via a property? I would've done something along the lines of

bool bIsPlayer = (Game.GetPlayer() == akActor) ? true : false  

in C-style ternary logic. 

 

This has a few problems:

1) There is no question conditional in Papyrus.

2) The property is way faster than Game.getPlayer

3) A comparison gives you a boolean as result, so the whole question conditional will be useless

 

 

I'd treat the C++ ternary operator as a type of pseudo code that I could write on one line over proper papyrus with a full statement spread over multiple lines.  bIsPlayer was kinda meant to be run in the OnEquipped block there so speed didn't really matter to me when I asked that.  I don't know but it seemed less resource intensive to use a Bool over an Actor in a script that could be used in 20+ actors, not really sure how memory allocation works in Papyrus and in save files considering I mainly write FONV code. 

 

I could've written the following code instead but meh:

bool bIsPlayer = False
if (Game.GetPlayer() == akActor)
bIsPlayer = True
endif

At least that's how it works in FONV, I wasn't sure if I could directly allocate bIsPlayer via the conditional so I just used a conditional operator to show it. 

Link to comment

 

I'd treat the C++ ternary operator as a type of pseudo code that I could write on one line over proper papyrus with a full statement spread over multiple lines.  bIsPlayer was kinda meant to be run in the OnEquipped block there so speed didn't really matter to me when I asked that.  I don't know but it seemed less resource intensive to use a Bool over an Actor in a script that could be used in 20+ actors, not really sure how memory allocation works in Papyrus and in save files considering I mainly write FONV code. 

 

I could've written the following code instead but meh:

bool bIsPlayer = False
if (Game.GetPlayer() == akActor)
bIsPlayer = True
endif

At least that's how it works in FONV, I wasn't sure if I could directly allocate bIsPlayer via the conditional so I just used a conditional operator to show it. 

The shortest compiled Papyrus result are:

 

bool bIsPlayer = game.getPlayer() == akActor

 

and

 

bool bIsPlayer = playerRef == akActor

 

 

Both generate only 5 opcodes.

(The IF case will generate 7 opcodes)

 

For performance the "payerRef" one is slightly faster because it saves a call (that is NOT .getPlayer(), you have the hidden equivalent playerReF.get(); it is the actual global call to Game object.)

Link to comment

 

For some reason Fortaleza's bodysuits work with the child settlers.

 

 

Edit it in CK and compare it with another armor.

Maybe there is something.

 

Check also the NIF file.

Link to comment

 

Edit it in CK and compare it with another armor.

Maybe there is something.

 

Check also the NIF file.

 

 

Already did that, couldn't figure out what :(

 

But I just went through all of the "armoraddon" entries and made most of the Vanilla and DLC armors and clothing usable for child settlers.  Submitted it to downloads.

Link to comment
  • 1 month later...

I'm trying to follow this tutorial but am getting a error during the scripts for follow and dismiss at 24:30.

 

 

Papyrus Compiler Version 2.8.0.4 for Fallout 4
Copyright © ZeniMax Media. All rights reserved.
Starting 1 compile threads for 1 files...
Compiling "Fragments:Quests:QF_DDNatashaCompQuest_01000FAB"...
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,41): variable DDNatasha is undefined
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): none is not a known user-defined script type
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): type mismatch on parameter 1 - cannot pass a void to a actor
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,45): variable DDNatasha is undefined
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): none is not a known user-defined script type
C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): type mismatch on parameter 1 - cannot pass a void to a actor
No output generated for Fragments:Quests:QF_DDNatashaCompQuest_01000FAB, compilation failed.

Batch compile of 1 files finished. 0 succeeded, 1 failed.
Failed on Fragments:Quests:QF_DDNatashaCompQuest_01000FAB

 

If anyone can help please do so, I'm getting fed up with FO CK its always been shit, even Skyrim's is better and hell of a lot less complex.

Link to comment

I'm trying to follow this tutorial but am getting a error during the scripts for follow and dismiss at 24:30.

 

 

 

 

Papyrus Compiler Version 2.8.0.4 for Fallout 4

Copyright © ZeniMax Media. All rights reserved.

Starting 1 compile threads for 1 files...

Compiling "Fragments:Quests:QF_DDNatashaCompQuest_01000FAB"...

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,41): variable DDNatasha is undefined

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): none is not a known user-defined script type

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): type mismatch on parameter 1 - cannot pass a void to a actor

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,45): variable DDNatasha is undefined

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): none is not a known user-defined script type

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): type mismatch on parameter 1 - cannot pass a void to a actor

No output generated for Fragments:Quests:QF_DDNatashaCompQuest_01000FAB, compilation failed.

 

Batch compile of 1 files finished. 0 succeeded, 1 failed.

Failed on Fragments:Quests:QF_DDNatashaCompQuest_01000FAB

 

 

If anyone can help please do so, I'm getting fed up with FO CK its always been shit, even Skyrim's is better and hell of a lot less complex.

 

Looking at what the guy in the video is doing, I can say he is creation a couple of script fragments on a quest.

And he added a property "SeddonComp" (or something like that) to his script, before adding the code.

 

Looking at the name of your file, from your error log, I suppose you created an NPC called DDNatasha.

Be sure you create a ReferenceAlias in the quest with exactly this name (and be sure to fill it, in case it will not auto-fill.)

 

 

TL&DN: Be sure your ReferenceAlias name is DDNatasha.

Link to comment

 

I'm trying to follow this tutorial but am getting a error during the scripts for follow and dismiss at 24:30.

 

 

 

 

Papyrus Compiler Version 2.8.0.4 for Fallout 4

Copyright © ZeniMax Media. All rights reserved.

Starting 1 compile threads for 1 files...

Compiling "Fragments:Quests:QF_DDNatashaCompQuest_01000FAB"...

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,41): variable DDNatasha is undefined

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): none is not a known user-defined script type

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(7,51): type mismatch on parameter 1 - cannot pass a void to a actor

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,45): variable DDNatasha is undefined

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): none is not a known user-defined script type

C:\Users\admin\AppData\Local\Temp\PapyrusTemp\Fragments\Quests\QF_DDNatashaCompQuest_01000FAB.psc(15,55): type mismatch on parameter 1 - cannot pass a void to a actor

No output generated for Fragments:Quests:QF_DDNatashaCompQuest_01000FAB, compilation failed.

 

Batch compile of 1 files finished. 0 succeeded, 1 failed.

Failed on Fragments:Quests:QF_DDNatashaCompQuest_01000FAB

 

 

If anyone can help please do so, I'm getting fed up with FO CK its always been shit, even Skyrim's is better and hell of a lot less complex.

 

Looking at what the guy in the video is doing, I can say he is creation a couple of script fragments on a quest.

And he added a property "SeddonComp" (or something like that) to his script, before adding the code.

 

Looking at the name of your file, from your error log, I suppose you created an NPC called DDNatasha.

Be sure you create a ReferenceAlias in the quest with exactly this name (and be sure to fill it, in case it will not auto-fill.)

 

 

TL&DN: Be sure your ReferenceAlias name is DDNatasha.

 

 

OK um....where is that referencealias?

Link to comment

 

OK um....where is that referencealias?

 

 

RefAlias is something you define in a quest.

It is a reference to some object, very often an Actor.

 

Probably following the tutorial you missed this step.

Link to comment

 

 

OK um....where is that referencealias?

 

 

In the video at 4:30 is where he created the alias.

 

At 24:10 is where he sets the property to use it.

 

 

 

 

 

OK um....where is that referencealias?

 

 

RefAlias is something you define in a quest.

It is a reference to some object, very often an Actor.

 

Probably following the tutorial you missed this step.

 

Thanks figured it out had to put FollowersScript.GetScript().SetCompanion(DDNatashaComp.GetActorReference())

 

Comp was needed as that was in the Quest Alias name. Now to go test it and try to expand and get basic likes, dislikes, perk, romance, etc.

Link to comment

This is probably a dumb question, but I'm kind of confused by how you can add scripts and keywords to records now. >_<

 

If I added a script or a keyword to an actor, say the player, in the CK would that object now be marked as changed and overwrite any new losing conflicts or would it merge the records together adding that new script or keyword to the player record whilst retaining any additive changes to the form?

 

I'm so confused.

Link to comment

This is probably a dumb question, but I'm kind of confused by how you can add scripts and keywords to records now. >_<

 

If I added a script or a keyword to an actor, say the player, in the CK would that object now be marked as changed and overwrite any new losing conflicts or would it merge the records together adding that new script or keyword to the player record whilst retaining any additive changes to the form?

 

I'm so confused.

 

Welcome to the object oriented world.

 

In short:

If you change an "Attribute" then you are modifying the object for good. At least in Skyrim, all attributes for an object are updated by the last mod in the load order.

But there are some strange exceptions that I cannot explain.

 

If you are "linking" a property (adding a keyword, for example) you are not really modifying the base object, but only its context. So multiple mods can do changes together.

Scripts are linked objects, so no direct impact on the base object.

Link to comment

 

 

 

This is probably a dumb question, but I'm kind of confused by how you can add scripts and keywords to records now. >_<

 

If I added a script or a keyword to an actor, say the player, in the CK would that object now be marked as changed and overwrite any new losing conflicts or would it merge the records together adding that new script or keyword to the player record whilst retaining any additive changes to the form?

 

I'm so confused.

 

Welcome to the object oriented world.

 

In short:

If you change an "Attribute" then you are modifying the object for good. At least in Skyrim, all attributes for an object are updated by the last mod in the load order.

But there are some strange exceptions that I cannot explain.

 

If you are "linking" a property (adding a keyword, for example) you are not really modifying the base object, but only its context. So multiple mods can do changes together.

Scripts are linked objects, so no direct impact on the base object.

 

 

Ah, I wasn't sure if it was stored and loaded statically by the engine or merged, either could've happened in a object-based system depending on the way they've linked the records and handle loading of conflicting results. 

At least now I know I can safely add a script to the player and keywords to armour without it causing a conflict.  I wish there was an AddScriptToObject function so I could dynamically attach scripts to actors without having to manually attach a script to every actor in the game and without messing around with spells.

Link to comment

 

 

 

This is probably a dumb question, but I'm kind of confused by how you can add scripts and keywords to records now. >_<

 

If I added a script or a keyword to an actor, say the player, in the CK would that object now be marked as changed and overwrite any new losing conflicts or would it merge the records together adding that new script or keyword to the player record whilst retaining any additive changes to the form?

 

I'm so confused.

Welcome to the object oriented world.

 

In short:

If you change an "Attribute" then you are modifying the object for good. At least in Skyrim, all attributes for an object are updated by the last mod in the load order.

But there are some strange exceptions that I cannot explain.

 

If you are "linking" a property (adding a keyword, for example) you are not really modifying the base object, but only its context. So multiple mods can do changes together.

Scripts are linked objects, so no direct impact on the base object.

Ah, I wasn't sure if it was stored and loaded statically by the engine or merged, either could've happened in a object-based system depending on the way they've linked the records and handle loading of conflicting results.

 

At least now I know I can safely add a script to the player and keywords to armour without it causing a conflict. I wish there was an AddScriptToObject function so I could dynamically attach scripts to actors without having to manually attach a script to every actor in the game and without messing around with spells.

I'm not sure how you'd expect that to work. Somehow you'd need to fill in the property fields.

Link to comment

 

 

 

 

 

 

This is probably a dumb question, but I'm kind of confused by how you can add scripts and keywords to records now. >_<

If I added a script or a keyword to an actor, say the player, in the CK would that object now be marked as changed and overwrite any new losing conflicts or would it merge the records together adding that new script or keyword to the player record whilst retaining any additive changes to the form?

I'm so confused.


Welcome to the object oriented world.

In short:
If you change an "Attribute" then you are modifying the object for good. At least in Skyrim, all attributes for an object are updated by the last mod in the load order.
But there are some strange exceptions that I cannot explain.

If you are "linking" a property (adding a keyword, for example) you are not really modifying the base object, but only its context. So multiple mods can do changes together.
Scripts are linked objects, so no direct impact on the base object.

Ah, I wasn't sure if it was stored and loaded statically by the engine or merged, either could've happened in a object-based system depending on the way they've linked the records and handle loading of conflicting results.

At least now I know I can safely add a script to the player and keywords to armour without it causing a conflict. I wish there was an AddScriptToObject function so I could dynamically attach scripts to actors without having to manually attach a script to every actor in the game and without messing around with spells.


I'm not sure how you'd expect that to work. Somehow you'd need to fill in the property fields.

 

 

No reason why the property fields can't be filled via a key-pair struct array if it was properly tagged, even if they have to use a CSV based string variable to fill the struct and array-type fields.  It's not like Bethesda lacks access to the source. >_>

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use