Jump to content

Recommended Posts

Posted

Good evening everybody!

 

For a mod that I am working on I need to create a very heavy backpack that disables running when it is worn.

I will just a backpack mod, duplicate one of the backpacks and attach a script to it. (for testing)

(Eventually I will make a custom mesh ...)

 

That script should disable running for the "wearer" of the backpack.

This should work if the player wears the backpack, but also if an NPC wears the backpack.

 

 

But the only script function I have found that has to do with enabling or disabling running is "EnableRunning - InputEnableLayer".

https://www.creationkit.com/fallout4/index.php?title=EnableRunning_-_InputEnableLayer

 

And I have no idea what is meant with "Enables or disables the player's ability to run on this layer.".

 

 

To get something like this to work on the player would be easy: Just make it very heavy (like 1000000000 units) and the player will be overencumbered.

But NPCs don't care about that, right?

So I would need some scripted way to make them not be able to run while wearing that backpack.

Posted

You could put a script on the armor

InputEnableLayer inputLayer

Event OnItemEquipped(Form akBaseObject, ObjectReference akReference)
inputLayer = InputEnableLayer.Create()
inputLayer.EnableRunning(false)
inputLayer.EnableSprinting(false)
EndEvent


Event OnItemUnEquipped(Form akBaseObject, ObjectReference akReference)
inputLayer.EnableRunning(true)
inputLayer.EnableSprinting(true)
EndEvent

Posted

Ok, but what is this all of this "layer" stuff about?

 

Like the actual layers (in the CK) that can be used to hide things in the CK or to enable lots of things?

Those layers?

 

Or is there another thing that is also called "layer" .... ?

Posted

It's called "Layer" because you can have different layers. One controlled by a Magic Effect, another by a quest...

  • Recently Browsing   0 members

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